diff --git a/content/httpmonitor/remote/connection.js b/content/httpmonitor/remote/connection.js index f856c47..eb7ccbd 100644 --- a/content/httpmonitor/remote/connection.js +++ b/content/httpmonitor/remote/connection.js @@ -13,7 +13,7 @@ var Cu = Components.utils; try { - Cu["import"]("resource:///modules/devtools/dbg-client.jsm"); + Cu["import"]("resource://gre/modules/devtools/dbg-client.jsm"); } catch (err) { diff --git a/content/httpmonitor/remote/protocol.js b/content/httpmonitor/remote/protocol.js index d02a499..2be4f39 100644 --- a/content/httpmonitor/remote/protocol.js +++ b/content/httpmonitor/remote/protocol.js @@ -95,11 +95,6 @@ Protocol.prototype = return this.currentTab ? this.currentTab.actor : null; }, - getNetActor: function(tabActor, callback) - { - this.connection.sendPacket(tabActor, "networkMonitorActor", true, callback); - }, - subscribe: function(netActor, callback) { if (this.currentNetActor) @@ -139,13 +134,10 @@ Protocol.prototype = // A tab has been selected so, subscribe to the Net monitor actor. The callback // will receive events about any HTTP traffic within the target tab. - this.getNetActor(tabActor.id, function(packet) - { - self.subscribe(packet.actor, netEvent); + self.subscribe(tabActor.networkMonitorActor, netEvent); - // Also register callback for 'tabNavigated' events. - self.connection.addCallback(tabActor.id, tabNavigated, false); - }); + // Also register callback for 'tabNavigated' events. + self.connection.addCallback(tabActor.id, tabNavigated, false); }, onTabUnselected: function(tabActor) diff --git a/content/httpmonitor/remote/remoteProxy.js b/content/httpmonitor/remote/remoteProxy.js index 34b31e9..5968c7a 100644 --- a/content/httpmonitor/remote/remoteProxy.js +++ b/content/httpmonitor/remote/remoteProxy.js @@ -25,9 +25,11 @@ RemoteProxy.prototype = Obj.extend(Proxy, if (FBTrace.DBG_REMOTENETMONITOR) FBTrace.sysout("remotenet; RemoteProxy.getTabs()"); + var self = this; this.protocol.getTabList(function(packet) { var result = []; + self.protocol.traceActor = packet.traceActor; var tabs = packet.tabs; for (var i=0; i