Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(8580)

Unified Diff: chrome/renderer/resources/extension_process_bindings.js

Issue 115337: TBR Revert "Revert "implemented extensions api windows.update()."" (Closed)
Patch Set: Created 11 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/renderer/renderer_resources.grd ('k') | chrome/test/data/extensions/samples/tabs/tabs_api.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/renderer/resources/extension_process_bindings.js
diff --git a/chrome/renderer/resources/extension_process_bindings.js b/chrome/renderer/resources/extension_process_bindings.js
index 8b17e6376f6b0d35022ca8a44e2474a296586e44..3828ee257ffc9b6f6c86798f97ec80d3314c25e8 100644
--- a/chrome/renderer/resources/extension_process_bindings.js
+++ b/chrome/renderer/resources/extension_process_bindings.js
@@ -14,6 +14,7 @@ var chrome;
native function GetCurrentWindow();
native function GetLastFocusedWindow();
native function CreateWindow();
+ native function UpdateWindow();
native function RemoveWindow();
native function GetAllWindows();
native function GetTab();
@@ -165,7 +166,25 @@ var chrome;
},
chrome.types.optFun
];
-
+
+ chrome.windows.update = function(windowId, updateData, callback) {
+ validate(arguments, arguments.callee.params);
+ sendRequest(UpdateWindow, [windowId, updateData], callback);
+ };
+ chrome.windows.update.params = [
+ chrome.types.pInt,
+ {
+ type: "object",
+ properties: {
+ left: chrome.types.optInt,
+ top: chrome.types.optInt,
+ width: chrome.types.optPInt,
+ height: chrome.types.optPInt
+ },
+ },
+ chrome.types.optFun
+ ];
+
chrome.windows.remove = function(windowId, callback) {
validate(arguments, arguments.callee.params);
sendRequest(RemoveWindow, windowId, callback);
« no previous file with comments | « chrome/renderer/renderer_resources.grd ('k') | chrome/test/data/extensions/samples/tabs/tabs_api.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698