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

Unified Diff: remoting/webapp/crd/js/host_daemon_facade.js

Issue 1272833002: Pass error messages from native messaging to web-app. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added IT2Me support. Created 5 years, 4 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
Index: remoting/webapp/crd/js/host_daemon_facade.js
diff --git a/remoting/webapp/crd/js/host_daemon_facade.js b/remoting/webapp/crd/js/host_daemon_facade.js
index 544abd39683d617c787e344caa5695f963b32a6a..62ae4ee2f79eb66d30c8345393acbe01c5213648 100644
--- a/remoting/webapp/crd/js/host_daemon_facade.js
+++ b/remoting/webapp/crd/js/host_daemon_facade.js
@@ -50,6 +50,10 @@ remoting.HostDaemonFacade = function() {
/** @private */
this.onDisconnectCallback_ = this.onDisconnect_.bind(this);
+ /** @private */
+ this.debugMessageHandler_ =
+ new remoting.NativeMessageHostDebugMessageHandler();
+
this.initialize_();
};
@@ -180,6 +184,10 @@ remoting.HostDaemonFacade.prototype.postMessageInternal_ = function(message) {
* @private
*/
remoting.HostDaemonFacade.prototype.onIncomingMessage_ = function(message) {
+ if (this.debugMessageHandler_.handleMessage(message)) {
+ return;
+ }
+
/** @type {number} */
var id = message['id'];
if (typeof(id) != 'number') {

Powered by Google App Engine
This is Rietveld 408576698