- Revision
- 120760
- Author
- [email protected]
- Date
- 2012-06-19 15:30:10 -0700 (Tue, 19 Jun 2012)
Log Message
Source/WebCore: Web Inspector: extensionPanel.onSearch `action` strings should be
enumerated.
https://bugs.webkit.org/show_bug.cgi?id=89509
Patch by Jan Keromnes <[email protected]> on 2012-06-19
Reviewed by Pavel Feldman.
Fixed LayoutTests/inspector/extensions/extensions-api-expected.txt
accordingly.
* inspector/front-end/ExtensionAPI.js:
(defineCommonExtensionSymbols):
(injectedExtensionAPI.Panels.prototype.setOpenResourceHandler):
(injectedExtensionAPI.Panels.prototype.get SearchAction):
* inspector/front-end/ExtensionPanel.js:
(WebInspector.ExtensionPanel.prototype.searchCanceled):
(WebInspector.ExtensionPanel.prototype.performSearch):
(WebInspector.ExtensionPanel.prototype.jumpToNextSearchResult):
(WebInspector.ExtensionPanel.prototype.jumpToPreviousSearchResult):
LayoutTests: Web Inspector: extensionPanel.onSearch `action` strings should be enumerated
https://bugs.webkit.org/show_bug.cgi?id=89509
Patch by Jan Keromnes <[email protected]> on 2012-06-19
Reviewed by Pavel Feldman.
* inspector/extensions/extensions-api-expected.txt:
Modified Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (120759 => 120760)
--- trunk/LayoutTests/ChangeLog 2012-06-19 22:18:48 UTC (rev 120759)
+++ trunk/LayoutTests/ChangeLog 2012-06-19 22:30:10 UTC (rev 120760)
@@ -1,3 +1,12 @@
+2012-06-19 Jan Keromnes <[email protected]>
+
+ Web Inspector: extensionPanel.onSearch `action` strings should be enumerated
+ https://bugs.webkit.org/show_bug.cgi?id=89509
+
+ Reviewed by Pavel Feldman.
+
+ * inspector/extensions/extensions-api-expected.txt:
+
2012-06-19 Kenneth Russell <[email protected]>
[Chromium] Unreviewed gardening.
Modified: trunk/LayoutTests/inspector/extensions/extensions-api-expected.txt (120759 => 120760)
--- trunk/LayoutTests/inspector/extensions/extensions-api-expected.txt 2012-06-19 22:18:48 UTC (rev 120759)
+++ trunk/LayoutTests/inspector/extensions/extensions-api-expected.txt 2012-06-19 22:30:10 UTC (rev 120760)
@@ -30,6 +30,12 @@
}
create : <function>
setOpenResourceHandler : <function>
+ SearchAction : {
+ CancelSearch : "cancelSearch"
+ PerformSearch : "performSearch"
+ NextSearchResult : "nextSearchResult"
+ PreviousSearchResult : "previousSearchResult"
+ }
}
network : {
onRequestFinished : {
Modified: trunk/Source/WebCore/ChangeLog (120759 => 120760)
--- trunk/Source/WebCore/ChangeLog 2012-06-19 22:18:48 UTC (rev 120759)
+++ trunk/Source/WebCore/ChangeLog 2012-06-19 22:30:10 UTC (rev 120760)
@@ -1,3 +1,24 @@
+2012-06-19 Jan Keromnes <[email protected]>
+
+ Web Inspector: extensionPanel.onSearch `action` strings should be
+ enumerated.
+ https://bugs.webkit.org/show_bug.cgi?id=89509
+
+ Reviewed by Pavel Feldman.
+
+ Fixed LayoutTests/inspector/extensions/extensions-api-expected.txt
+ accordingly.
+
+ * inspector/front-end/ExtensionAPI.js:
+ (defineCommonExtensionSymbols):
+ (injectedExtensionAPI.Panels.prototype.setOpenResourceHandler):
+ (injectedExtensionAPI.Panels.prototype.get SearchAction):
+ * inspector/front-end/ExtensionPanel.js:
+ (WebInspector.ExtensionPanel.prototype.searchCanceled):
+ (WebInspector.ExtensionPanel.prototype.performSearch):
+ (WebInspector.ExtensionPanel.prototype.jumpToNextSearchResult):
+ (WebInspector.ExtensionPanel.prototype.jumpToPreviousSearchResult):
+
2012-06-19 Dana Jansens <[email protected]>
[chromium] Add an allocation step for CCRenderer before drawing a frame
Modified: trunk/Source/WebCore/inspector/front-end/ExtensionAPI.js (120759 => 120760)
--- trunk/Source/WebCore/inspector/front-end/ExtensionAPI.js 2012-06-19 22:18:48 UTC (rev 120759)
+++ trunk/Source/WebCore/inspector/front-end/ExtensionAPI.js 2012-06-19 22:30:10 UTC (rev 120760)
@@ -32,7 +32,6 @@
{
if (!apiPrivate.audits)
apiPrivate.audits = {};
-
apiPrivate.audits.Severity = {
Info: "info",
Warning: "warning",
@@ -48,6 +47,16 @@
Warning: "warning",
Error: "error"
};
+
+ if (!apiPrivate.panels)
+ apiPrivate.panels = {};
+ apiPrivate.panels.SearchAction = {
+ CancelSearch: "cancelSearch",
+ PerformSearch: "performSearch",
+ NextSearchResult: "nextSearchResult",
+ PreviousSearchResult: "previousSearchResult"
+ };
+
apiPrivate.Events = {
AuditStarted: "audit-started-",
ButtonClicked: "button-clicked-",
@@ -64,6 +73,7 @@
ViewShown: "view-shown-",
ViewHidden: "view-hidden-"
};
+
apiPrivate.Commands = {
AddAuditCategory: "addAuditCategory",
AddAuditResult: "addAuditResult",
@@ -320,6 +330,11 @@
// Only send command if we either removed an existing handler or added handler and had none before.
if (hadHandler === !callback)
extensionServer.sendRequest({ command: commands.SetOpenResourceHandler, "handlerPresent": !!callback });
+ },
+
+ get SearchAction()
+ {
+ return apiPrivate.panels.SearchAction;
}
}
Modified: trunk/Source/WebCore/inspector/front-end/ExtensionPanel.js (120759 => 120760)
--- trunk/Source/WebCore/inspector/front-end/ExtensionPanel.js 2012-06-19 22:18:48 UTC (rev 120759)
+++ trunk/Source/WebCore/inspector/front-end/ExtensionPanel.js 2012-06-19 22:30:10 UTC (rev 120760)
@@ -147,25 +147,25 @@
searchCanceled: function(startingNewSearch)
{
- WebInspector.extensionServer.notifySearchAction(this._id, "cancelSearch");
+ WebInspector.extensionServer.notifySearchAction(this._id, WebInspector.extensionAPI.panels.SearchAction.CancelSearch);
WebInspector.Panel.prototype.searchCanceled.apply(this, arguments);
},
performSearch: function(query)
{
- WebInspector.extensionServer.notifySearchAction(this._id, "performSearch", query);
+ WebInspector.extensionServer.notifySearchAction(this._id, WebInspector.extensionAPI.panels.SearchAction.PerformSearch, query);
WebInspector.Panel.prototype.performSearch.apply(this, arguments);
},
jumpToNextSearchResult: function()
{
- WebInspector.extensionServer.notifySearchAction(this._id, "nextSearchResult");
+ WebInspector.extensionServer.notifySearchAction(this._id, WebInspector.extensionAPI.panels.SearchAction.NextSearchResult);
WebInspector.Panel.prototype.jumpToNextSearchResult.call(this);
},
jumpToPreviousSearchResult: function()
{
- WebInspector.extensionServer.notifySearchAction(this._id, "previousSearchResult");
+ WebInspector.extensionServer.notifySearchAction(this._id, WebInspector.extensionAPI.panels.SearchAction.PreviousSearchResult);
WebInspector.Panel.prototype.jumpToPreviousSearchResult.call(this);
},