Index: content/public/browser/web_ui_message_handler.h |
diff --git a/content/public/browser/web_ui_message_handler.h b/content/public/browser/web_ui_message_handler.h |
index ed0117931f59bc8cc8db1b135a2c606aea0c2015..b088c07030cc7b3a87d807f556baea3ab963a11e 100644 |
--- a/content/public/browser/web_ui_message_handler.h |
+++ b/content/public/browser/web_ui_message_handler.h |
@@ -77,6 +77,18 @@ class CONTENT_EXPORT WebUIMessageHandler { |
// to deregister or disabled observers that push JavaScript calls to the page. |
virtual void OnJavascriptDisallowed() {} |
+ // Helper method for responding to JS requests initiated with |
Charlie Reis
2016/06/06 21:19:52
nit: Javascript
dpapad
2016/06/06 21:28:53
Done.
|
+ // cr.sendWithPromise(), for the case where the returned promise should be |
Charlie Reis
2016/06/06 21:19:52
What is cr?
dpapad
2016/06/06 21:28:53
'cr' is simply a namespace used by cr.js (where th
|
+ // resolved (request succeeded). |
+ void ResolveJavascriptCallback(const base::Value& callback_id, |
+ const base::Value& response); |
+ |
+ // Helper method for responding to JS requests initiated with |
Charlie Reis
2016/06/06 21:19:52
(Same comments)
dpapad
2016/06/06 21:28:53
Done. See previous comment.
|
+ // cr.sendWithPromise(), for the case where the returned promise should be |
+ // rejected (request failed). |
+ void RejectJavascriptCallback(const base::Value& callback_id, |
+ const base::Value& response); |
+ |
// Call a Javascript function by sending its name and arguments down to |
// the renderer. This is asynchronous; there's no way to get the result |
// of the call, and should be thought of more like sending a message to |