Bug 912213 - Fix conflicts between two ContentTabActor classes r=paul
authorAlexandre Poirot <poirot.alex@gmail.com>
Wed, 11 Sep 2013 05:45:00 +0200
changeset 159591 e19b14609e526b718e340b85837b38d106087d88
parent 159590 9fb279a95ce179bd283f230a38962f984a9e1287
child 159592 2a0b716e7be492516af6133775cd5eae2db45934
push id2961
push userlsblakk@mozilla.com
push dateMon, 28 Oct 2013 21:59:28 +0000
treeherdermozilla-beta@73ef4f13486f [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerspaul
bugs912213
milestone26.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 912213 - Fix conflicts between two ContentTabActor classes r=paul
toolkit/devtools/server/actors/childtab.js
toolkit/devtools/server/child.js
toolkit/devtools/server/main.js
--- a/toolkit/devtools/server/actors/childtab.js
+++ b/toolkit/devtools/server/actors/childtab.js
@@ -7,62 +7,62 @@
 /**
  * Tab actor for documents living in a child process.
  *
  * Depends on BrowserTabActor, defined in webbrowser.js actor.
  */
 
 /**
  * Creates a tab actor for handling requests to the single tab, like
- * attaching and detaching. ContentTabActor respects the actor factories
+ * attaching and detaching. ContentAppActor respects the actor factories
  * registered with DebuggerServer.addTabActor.
  *
  * @param connection DebuggerServerConnection
  *        The conection to the client.
  * @param browser browser
  *        The browser instance that contains this tab.
  */
-function ContentTabActor(connection, browser)
+function ContentAppActor(connection, browser)
 {
   BrowserTabActor.call(this, connection, browser);
 }
 
-ContentTabActor.prototype = Object.create(BrowserTabActor.prototype);
+ContentAppActor.prototype = Object.create(BrowserTabActor.prototype);
 
-ContentTabActor.prototype.constructor = ContentTabActor;
+ContentAppActor.prototype.constructor = ContentAppActor;
 
-Object.defineProperty(ContentTabActor.prototype, "title", {
+Object.defineProperty(ContentAppActor.prototype, "title", {
   get: function() {
     return this.browser.title;
   },
   enumerable: true,
   configurable: false
 });
 
-Object.defineProperty(ContentTabActor.prototype, "url", {
+Object.defineProperty(ContentAppActor.prototype, "url", {
   get: function() {
     return this.browser.document.documentURI;
   },
   enumerable: true,
   configurable: false
 });
 
-Object.defineProperty(ContentTabActor.prototype, "window", {
+Object.defineProperty(ContentAppActor.prototype, "window", {
   get: function() {
     return this.browser;
   },
   enumerable: true,
   configurable: false
 });
 
 // Override grip just to rename this._tabActorPool to this._tabActorPool2
 // in order to prevent it to be cleaned on detach.
-// We have to keep tab actors alive as we keep the ContentTabActor
+// We have to keep tab actors alive as we keep the ContentAppActor
 // alive after detach and reuse it for multiple debug sessions.
-ContentTabActor.prototype.grip = function () {
+ContentAppActor.prototype.grip = function () {
   let response = {
     'actor': this.actorID,
     'title': this.title,
     'url': this.url
   };
 
   // Walk over tab actors added by extensions and add them to a new ActorPool.
   let actorPool = new ActorPool(this.conn);
--- a/toolkit/devtools/server/child.js
+++ b/toolkit/devtools/server/child.js
@@ -16,17 +16,17 @@ let onConnect = DevToolsUtils.makeInfall
   removeMessageListener("debug:connect", onConnect);
 
   let mm = msg.target;
 
   let prefix = msg.data.prefix + docShell.appId;
 
   let conn = DebuggerServer.connectToParent(prefix, mm);
 
-  let actor = new DebuggerServer.ContentTabActor(conn, content);
+  let actor = new DebuggerServer.ContentAppActor(conn, content);
   let actorPool = new ActorPool(conn);
   actorPool.addActor(actor);
   conn.addActorPool(actorPool);
 
   sendAsyncMessage("debug:actor", {actor: actor.grip(),
                                    appId: docShell.appId,
                                    prefix: prefix});
 });
--- a/toolkit/devtools/server/main.js
+++ b/toolkit/devtools/server/main.js
@@ -380,17 +380,17 @@ var DebuggerServer = {
     if (!("BrowserTabActor" in this)) {
       this.addActors("resource://gre/modules/devtools/server/actors/webbrowser.js");
       this.addActors("resource://gre/modules/devtools/server/actors/script.js");
       this.addActors("resource://gre/modules/devtools/server/actors/webconsole.js");
       this.addActors("resource://gre/modules/devtools/server/actors/gcli.js");
       this.addActors("resource://gre/modules/devtools/server/actors/styleeditor.js");
       this.registerModule("devtools/server/actors/inspector");
     }
-    if (!("ContentTabActor" in DebuggerServer)) {
+    if (!("ContentAppActor" in DebuggerServer)) {
       this.addActors("resource://gre/modules/devtools/server/actors/childtab.js");
     }
   },
 
   /**
    * Listens on the given port or socket file for remote debugger connections.
    *
    * @param aPortOrPath int, string