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

Unified Diff: remoting/client/plugin/chromoting_scriptable_object.h

Issue 8573024: Clean up client state callback. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 9 years, 1 month 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 | « no previous file | remoting/client/plugin/chromoting_scriptable_object.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/client/plugin/chromoting_scriptable_object.h
diff --git a/remoting/client/plugin/chromoting_scriptable_object.h b/remoting/client/plugin/chromoting_scriptable_object.h
index 1ca45fd932744b5285e1a7c417af8c9e6f8f1102..547b349809a3bebb0b4773b193ef9addfd5997ff 100644
--- a/remoting/client/plugin/chromoting_scriptable_object.h
+++ b/remoting/client/plugin/chromoting_scriptable_object.h
@@ -120,7 +120,11 @@ class ChromotingScriptableObject
: public pp::deprecated::ScriptableObject,
public base::SupportsWeakPtr<ChromotingScriptableObject> {
public:
+ // These state values are duplicated in the JS code. Remember to update both
+ // copies when making changes.
enum ConnectionStatus {
+ // TODO(jamiewalch): Remove STATUS_UNKNOWN once all web-apps that might try
+ // to access it have been upgraded.
STATUS_UNKNOWN = 0,
STATUS_CONNECTING,
STATUS_INITIALIZING,
@@ -129,6 +133,8 @@ class ChromotingScriptableObject
STATUS_FAILED,
};
+ // These state values are duplicated in the JS code. Remember to update both
+ // copies when making changes.
enum ConnectionError {
ERROR_NONE = 0,
ERROR_HOST_IS_OFFLINE,
@@ -197,13 +203,13 @@ class ChromotingScriptableObject
void AddAttribute(const std::string& name, pp::Var attribute);
void AddMethod(const std::string& name, MethodHandler handler);
- void SignalConnectionInfoChange();
+ void SignalConnectionInfoChange(int status, int error);
void SignalDesktopSizeChange();
// Calls to these methods are posted to the plugin thread so that we
// call JavaScript with clean stack. This is necessary because
// JavaScript event handlers may destroy the plugin.
- void DoSignalConnectionInfoChange();
+ void DoSignalConnectionInfoChange(int status, int error);
void DoSignalDesktopSizeChange();
void DoSendIq(const std::string& message_xml);
« no previous file with comments | « no previous file | remoting/client/plugin/chromoting_scriptable_object.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698