]> cloud.milkyroute.net Git - dolphin.git/commitdiff
DolphinSearchBox setReadOnly: Update if either of the parameters change
authorVishesh Handa <me@vhanda.in>
Mon, 6 May 2013 13:48:11 +0000 (19:18 +0530)
committerVishesh Handa <me@vhanda.in>
Mon, 13 May 2013 09:10:39 +0000 (14:40 +0530)
This way when another read only query is added, the internal state is
changed and the search label gets updated.

REVIEW: 110324
BUG: 315796
FIXED-IN: 4.10.4

src/search/dolphinsearchbox.cpp

index 8b660712a1abff9545499a6164892d62e734f41e..1792b201761f683b8559a4b815805645d953ac1f 100644 (file)
@@ -159,7 +159,7 @@ void DolphinSearchBox::selectAll()
 
 void DolphinSearchBox::setReadOnly(bool readOnly, const KUrl& query)
 {
-    if (m_readOnly != readOnly) {
+    if (m_readOnly != readOnly || m_readOnlyQuery != query) {
         m_readOnly = readOnly;
         m_readOnlyQuery = query;
         applyReadOnlyState();