Title: [98124] trunk/Source/WebCore
Revision
98124
Author
vse...@chromium.org
Date
2011-10-21 12:38:12 -0700 (Fri, 21 Oct 2011)

Log Message

Web Inspector: Advanced search results should be cleared on navigation.
https://bugs.webkit.org/show_bug.cgi?id=70627

Reviewed by Pavel Feldman.

* inspector/front-end/AdvancedSearchController.js:
(WebInspector.AdvancedSearchController):
(WebInspector.AdvancedSearchController.prototype._frameNavigated):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (98123 => 98124)


--- trunk/Source/WebCore/ChangeLog	2011-10-21 19:36:46 UTC (rev 98123)
+++ trunk/Source/WebCore/ChangeLog	2011-10-21 19:38:12 UTC (rev 98124)
@@ -1,3 +1,14 @@
+2011-10-21  Vsevolod Vlasov  <vse...@chromium.org>
+
+        Web Inspector: Advanced search results should be cleared on navigation.
+        https://bugs.webkit.org/show_bug.cgi?id=70627
+
+        Reviewed by Pavel Feldman.
+
+        * inspector/front-end/AdvancedSearchController.js:
+        (WebInspector.AdvancedSearchController):
+        (WebInspector.AdvancedSearchController.prototype._frameNavigated):
+
 2011-10-21  Rafael Weinstein  <rafa...@chromium.org>
 
         [MutationObservers] Implement WebKitMutationObserver.observe for childList changes

Modified: trunk/Source/WebCore/inspector/front-end/AdvancedSearchController.js (98123 => 98124)


--- trunk/Source/WebCore/inspector/front-end/AdvancedSearchController.js	2011-10-21 19:36:46 UTC (rev 98123)
+++ trunk/Source/WebCore/inspector/front-end/AdvancedSearchController.js	2011-10-21 19:38:12 UTC (rev 98124)
@@ -35,6 +35,8 @@
     this._searchId = 0;
     
     WebInspector.settings.advancedSearchConfig = WebInspector.settings.createSetting("advancedSearchConfig", new WebInspector.SearchConfig("", true, false));
+    
+    WebInspector.resourceTreeModel.addEventListener(WebInspector.ResourceTreeModel.EventTypes.FrameNavigated, this._frameNavigated, this);
 }
 
 WebInspector.AdvancedSearchController.createShortcut = function()
@@ -54,6 +56,11 @@
         }
     },
 
+    _frameNavigated: function()
+    {
+        this.resetSearch();
+    },
+
     /**
      * @param {WebInspector.SearchScope} searchScope
      */
@@ -369,6 +376,9 @@
     
     _onAction: function()
     {
+        if (!this.searchConfig.query || !this.searchConfig.query.length)
+            return;
+        
         this._save();
         this._controller.startSearch(this.searchConfig);
     }
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to