Title: [121981] trunk/Source/WebCore
Revision
121981
Author
[email protected]
Date
2012-07-06 09:54:04 -0700 (Fri, 06 Jul 2012)

Log Message

Web Inspector: text editor scrolls 2px horizontally as one navigates the source code.
https://bugs.webkit.org/show_bug.cgi?id=90682

Reviewed by Vsevolod Vlasov.

Removing the hack that is glueing the scroller to the left.

* inspector/front-end/TextEditor.js:
(WebInspector.TextEditor.prototype._updatePanelOffsets):
(WebInspector.TextEditorChunkedPanel.prototype._scroll):
* inspector/front-end/textEditor.css:

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (121980 => 121981)


--- trunk/Source/WebCore/ChangeLog	2012-07-06 16:41:00 UTC (rev 121980)
+++ trunk/Source/WebCore/ChangeLog	2012-07-06 16:54:04 UTC (rev 121981)
@@ -1,3 +1,17 @@
+2012-07-06  Pavel Feldman  <[email protected]>
+
+        Web Inspector: text editor scrolls 2px horizontally as one navigates the source code.
+        https://bugs.webkit.org/show_bug.cgi?id=90682
+
+        Reviewed by Vsevolod Vlasov.
+
+        Removing the hack that is glueing the scroller to the left.
+
+        * inspector/front-end/TextEditor.js:
+        (WebInspector.TextEditor.prototype._updatePanelOffsets):
+        (WebInspector.TextEditorChunkedPanel.prototype._scroll):
+        * inspector/front-end/textEditor.css:
+
 2012-07-06  Andrey Kosyakov  <[email protected]>
 
         Web Inspector: get rid of cancellable records in Timeline, manage frame records explicitly

Modified: trunk/Source/WebCore/inspector/front-end/TextEditor.js (121980 => 121981)


--- trunk/Source/WebCore/inspector/front-end/TextEditor.js	2012-07-06 16:41:00 UTC (rev 121980)
+++ trunk/Source/WebCore/inspector/front-end/TextEditor.js	2012-07-06 16:54:04 UTC (rev 121981)
@@ -252,7 +252,7 @@
     {
         var lineNumbersWidth = this._gutterPanel.element.offsetWidth;
         if (lineNumbersWidth)
-            this._mainPanel.element.style.setProperty("left", lineNumbersWidth + "px");
+            this._mainPanel.element.style.setProperty("left", (lineNumbersWidth + 2) + "px");
         else
             this._mainPanel.element.style.removeProperty("left"); // Use default value set in CSS.
     },
@@ -654,10 +654,6 @@
 
     _scroll: function()
     {
-        // FIXME: Replace the "2" with the padding-left value from CSS.
-        if (this.element.scrollLeft <= 2)
-            this.element.scrollLeft = 0;
-
         this._scheduleRepaintAll();
         if (this._syncScrollListener)
             this._syncScrollListener();

Modified: trunk/Source/WebCore/inspector/front-end/textEditor.css (121980 => 121981)


--- trunk/Source/WebCore/inspector/front-end/textEditor.css	2012-07-06 16:41:00 UTC (rev 121980)
+++ trunk/Source/WebCore/inspector/front-end/textEditor.css	2012-07-06 16:54:04 UTC (rev 121981)
@@ -121,10 +121,6 @@
     margin-right: -10px;
 }
 
-.webkit-line-content {
-    padding-left: 2px;
-}
-
 .webkit-breakpoint .webkit-line-number-outer {
     color: white;
     border-width: 0 14px 0px 2px;
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to