void DolphinView::showHoverInformation(const KFileItem& item)
{
- if (hasSelection() || !m_active) {
- return;
- }
-
emit requestItemInfo(item);
}
void DolphinView::clearHoverInformation()
{
- if (m_active) {
- emit requestItemInfo(KFileItem());
- }
+ emit requestItemInfo(KFileItem());
}
void DolphinView::createView()
}
}
}
+ } else if (DolphinSettings::instance().generalSettings()->renameInline()) {
+ Q_ASSERT(items.count() == 1);
+
+ if (isColumnViewActive()) {
+ m_columnView->editItem(items.first());
+ } else {
+ const QModelIndex dirIndex = m_dolphinModel->indexForItem(items.first());
+ const QModelIndex proxyIndex = m_proxyModel->mapFromSource(dirIndex);
+ itemView()->edit(proxyIndex);
+ }
} else {
- // Only one item has been selected for renaming. Use the custom
- // renaming mechanism from the views.
Q_ASSERT(items.count() == 1);
- // TODO: Think about using KFileItemDelegate as soon as it supports editing.
- // Currently the RenameDialog is used, but I'm not sure whether inline renaming
- // is a benefit for the user at all -> let's wait for some input first...
RenameDialog dialog(this, items);
if (dialog.exec() == QDialog::Rejected) {
return;
int result = KMessageBox::questionYesNo(window(),
text,
i18nc("@title:window", "Paste into Folder"),
- KGuiItem(i18nc("@label", "Paste"), "dialog-ok"),
- KGuiItem(i18nc("@label", "Cancel"), "dialog-cancel"));
+ KGuiItem(i18nc("@action:button", "Paste"), "dialog-ok"),
+ KGuiItem(i18nc("@action:button", "Cancel"), "dialog-cancel"));
if (result == KMessageBox::No) {
return;
}