┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/dolphinmainwindow.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/dolphinmainwindow.cpp b/src/dolphinmainwindow.cpp
index ea240ba83..acd1282a2 100644
--- a/src/dolphinmainwindow.cpp
+++ b/src/dolphinmainwindow.cpp
@@ -321,7 +321,12 @@ void DolphinMainWindow::slotSelectionChanged(const KFileItemList& selection)
}
QAction* compareFilesAction = actionCollection()->action("compare_files");
- compareFilesAction->setEnabled(selectedUrlsCount == 2);
+ if (selectedUrlsCount == 2) {
+ const bool kompareInstalled = !KGlobal::dirs()->findExe("kompare").isEmpty();
+ compareFilesAction->setEnabled(selectedUrlsCount == 2 && kompareInstalled);
+ } else {
+ compareFilesAction->setEnabled(false);
+ }
m_activeViewContainer->updateStatusBar();