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

Unified Diff: remoting/webapp/crd/js/it2me_host_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: Reviewer feedback. 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/it2me_host_facade.js
diff --git a/remoting/webapp/crd/js/it2me_host_facade.js b/remoting/webapp/crd/js/it2me_host_facade.js
index 64428f34813453cbf0a31926d47f10d0928f9b2b..c9167c84905941f460c73c757468cea0ec2b06db 100644
--- a/remoting/webapp/crd/js/it2me_host_facade.js
+++ b/remoting/webapp/crd/js/it2me_host_facade.js
@@ -61,6 +61,11 @@ remoting.It2MeHostFacade = function() {
/** @private {?function(boolean):void} */
this.onNatPolicyChanged_ = function() {};
+
+ /** @private */
+ this.debugMessageHandler_ =
+ new remoting.NativeMessageHostDebugMessageHandler();
+
};
remoting.It2MeHostFacade.prototype.dispose = function() {
@@ -208,6 +213,10 @@ remoting.It2MeHostFacade.prototype.getClient = function() {
*/
remoting.It2MeHostFacade.prototype.onIncomingMessage_ =
function(message) {
+ if (this.debugMessageHandler_.handleMessage(message)) {
+ return;
+ }
+
var type = base.getStringAttr(message, 'type');
switch (type) {
« no previous file with comments | « remoting/webapp/crd/js/host_daemon_facade.js ('k') | remoting/webapp/crd/js/native_message_host_log_message_handler.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698