Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

do not loose console scrollpostion when switching tabs

  • Loading branch information...
commit 0e0de76f486dc40d559863f68436f425a65d5d25 1 parent 755351d
Harutyun Amirjanyan authored August 03, 2012 SebastianZ committed August 07, 2012
4  extension/content/firebug/console/consolePanel.js
@@ -155,12 +155,12 @@ Firebug.ConsolePanel.prototype = Obj.extend(Firebug.ActivablePanel,
155 155
         if (state)
156 156
             wasScrolledToBottom = state.wasScrolledToBottom;
157 157
 
158  
-        if (typeof(wasScrolledToBottom) == "boolean")
  158
+        if (typeof wasScrolledToBottom == "boolean")
159 159
         {
160 160
             this.wasScrolledToBottom = wasScrolledToBottom;
161 161
             delete state.wasScrolledToBottom;
162 162
         }
163  
-        else
  163
+        else if (typeof this.wasScrolledToBottom != "boolean")
164 164
         {
165 165
             // If the previous state doesn't says where to scroll,
166 166
             // scroll to the bottom by default.
2  extension/content/firebug/firebug.js
@@ -1719,9 +1719,11 @@ Firebug.Panel = Obj.extend(new Firebug.Listener(),
1719 1719
 
1720 1720
         if (this.panelNode)
1721 1721
         {
  1722
+            var scrollTop = this.panelNode.scrollTop;
1722 1723
             this.panelNode = doc.adoptNode(this.panelNode, true);
1723 1724
             this.panelNode.ownerPanel = this;
1724 1725
             doc.body.appendChild(this.panelNode);
  1726
+            this.panelNode.scrollTop = scrollTop;
1725 1727
         }
1726 1728
     },
1727 1729
 

0 notes on commit 0e0de76

Please sign in to comment.
Something went wrong with that request. Please try again.