Permalink
Browse files

Properly update object-staus-path when mutation happens

  • Loading branch information...
1 parent d66eba8 commit e260cd7ce023591aa3cee7eb7daeadcfbe8fc97a @janodvarko janodvarko committed May 29, 2012
Showing with 18 additions and 3 deletions.
  1. +18 −3 extension/content/firebug/html/htmlPanel.js
@@ -540,7 +540,10 @@ Firebug.HTMLPanel.prototype = Obj.extend(WalkingPanel,
// Reselect if the element was selected before.
if (this.selection && (!this.selection.parentNode || parent == this.selection))
- this.ioBox.select(parent, true);
+ {
+ Firebug.chrome.clearStatusPath();
+ this.select(parent, true);
+ }
var nodeText = HTMLLib.getTextElementTextBox(newParentNodeBox);
if (!nodeText.firstChild)
@@ -656,6 +659,12 @@ Firebug.HTMLPanel.prototype = Obj.extend(WalkingPanel,
this.ioBox.insertChildBoxBefore(parentNodeBox, target, nextSibling) :
this.ioBox.appendChildBox(parentNodeBox, target);
+ if (this.selection && (!this.selection.parentNode || parent == this.selection))
+ {
+ Firebug.chrome.clearStatusPath();
+ this.select(parent, true);
+ }
+
this.highlightMutation(objectBox, objectBox, "mutated");
}
}
@@ -665,7 +674,10 @@ Firebug.HTMLPanel.prototype = Obj.extend(WalkingPanel,
parentNodeBox.parentNode.replaceChild(newParentNodeBox, parentNodeBox);
if (this.selection && (!this.selection.parentNode || parent == this.selection))
- this.ioBox.select(parent, true);
+ {
+ Firebug.chrome.clearStatusPath();
+ this.select(parent, true);
+ }
this.highlightMutation(newParentNodeBox, newParentNodeBox, "mutated");
@@ -686,7 +698,10 @@ Firebug.HTMLPanel.prototype = Obj.extend(WalkingPanel,
this.ioBox.toggleObjectBox(newParentNodeBox, true);
if (this.selection && (!this.selection.parentNode || parent == this.selection))
- this.ioBox.select(parent, true);
+ {
+ Firebug.chrome.clearStatusPath();
+ this.select(parent, true);
+ }
this.highlightMutation(newParentNodeBox, newParentNodeBox, "mutated");

0 comments on commit e260cd7

Please sign in to comment.