┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorElvis Angelaccio <[email protected]>2017-01-02 14:57:57 +0100
committerElvis Angelaccio <[email protected]>2017-01-02 14:57:57 +0100
commit331c8bc89e8165bea9c810a80ea67fa70c68ccb0 (patch)
treef39bdc4ff228346f973540c5ada0ecf330df881e /src
parent6af0dad2eeba82929c2299f66ea81e5d0140a251 (diff)
parent24ed38d77f4bc6db71ba2608452fa0cd401bddac (diff)
Merge branch 'Applications/16.12'
Diffstat (limited to 'src')
-rw-r--r--src/search/dolphinsearchbox.cpp7
-rw-r--r--src/search/dolphinsearchbox.h1
-rw-r--r--src/views/dolphinviewactionhandler.cpp4
3 files changed, 11 insertions, 1 deletions
diff --git a/src/search/dolphinsearchbox.cpp b/src/search/dolphinsearchbox.cpp
index 26ddd27f8..60a4a7567 100644
--- a/src/search/dolphinsearchbox.cpp
+++ b/src/search/dolphinsearchbox.cpp
@@ -206,6 +206,13 @@ void DolphinSearchBox::showEvent(QShowEvent* event)
}
}
+void DolphinSearchBox::hideEvent(QHideEvent* event)
+{
+ Q_UNUSED(event);
+ m_startedSearching = false;
+ m_startSearchTimer->stop();
+}
+
void DolphinSearchBox::keyReleaseEvent(QKeyEvent* event)
{
QWidget::keyReleaseEvent(event);
diff --git a/src/search/dolphinsearchbox.h b/src/search/dolphinsearchbox.h
index a80617476..b747679ec 100644
--- a/src/search/dolphinsearchbox.h
+++ b/src/search/dolphinsearchbox.h
@@ -100,6 +100,7 @@ public:
protected:
virtual bool event(QEvent* event) Q_DECL_OVERRIDE;
virtual void showEvent(QShowEvent* event) Q_DECL_OVERRIDE;
+ virtual void hideEvent(QHideEvent* event) Q_DECL_OVERRIDE;
virtual void keyReleaseEvent(QKeyEvent* event) Q_DECL_OVERRIDE;
virtual bool eventFilter(QObject* obj, QEvent* event) Q_DECL_OVERRIDE;
diff --git a/src/views/dolphinviewactionhandler.cpp b/src/views/dolphinviewactionhandler.cpp
index 858f9299b..5c0b49cd2 100644
--- a/src/views/dolphinviewactionhandler.cpp
+++ b/src/views/dolphinviewactionhandler.cpp
@@ -37,6 +37,7 @@
#include <KSelectAction>
#include <KToggleAction>
#include <KPropertiesDialog>
+#include <KProtocolManager>
#include <QIcon>
#include "dolphindebug.h"
@@ -486,7 +487,8 @@ void DolphinViewActionHandler::slotHiddenFilesShownChanged(bool shown)
void DolphinViewActionHandler::slotWriteStateChanged(bool isFolderWritable)
{
- m_actionCollection->action(QStringLiteral("create_dir"))->setEnabled(isFolderWritable);
+ m_actionCollection->action(QStringLiteral("create_dir"))->setEnabled(isFolderWritable &&
+ KProtocolManager::supportsMakeDir(currentView()->url()));
}
KToggleAction* DolphinViewActionHandler::iconsModeAction()