Title: [141565] trunk/Source/WebCore
Revision
141565
Author
[email protected]
Date
2013-02-01 02:11:24 -0800 (Fri, 01 Feb 2013)

Log Message

Web Inspector: fix cursor location in Source Frame
https://bugs.webkit.org/show_bug.cgi?id=108592

Patch by Andrey Lushnikov <[email protected]> on 2013-02-01
Reviewed by Pavel Feldman.

Normalize range before computing amount of lines in
_updateSourcePosition.

No new tests.

* inspector/front-end/SourceFrame.js:
(WebInspector.SourceFrame.prototype._updateSourcePosition): Normalize text range.
* inspector/front-end/inspector.css: Slightly bigger left padding for the text.
(.source-frame-position):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (141564 => 141565)


--- trunk/Source/WebCore/ChangeLog	2013-02-01 10:09:47 UTC (rev 141564)
+++ trunk/Source/WebCore/ChangeLog	2013-02-01 10:11:24 UTC (rev 141565)
@@ -1,3 +1,20 @@
+2013-02-01  Andrey Lushnikov  <[email protected]>
+
+        Web Inspector: fix cursor location in Source Frame
+        https://bugs.webkit.org/show_bug.cgi?id=108592
+
+        Reviewed by Pavel Feldman.
+
+        Normalize range before computing amount of lines in
+        _updateSourcePosition.
+
+        No new tests.
+
+        * inspector/front-end/SourceFrame.js:
+        (WebInspector.SourceFrame.prototype._updateSourcePosition): Normalize text range.
+        * inspector/front-end/inspector.css: Slightly bigger left padding for the text.
+        (.source-frame-position):
+
 2013-02-01  Kentaro Hara  <[email protected]>
 
         Unreviewed build fix after r141553.

Modified: trunk/Source/WebCore/inspector/front-end/SourceFrame.js (141564 => 141565)


--- trunk/Source/WebCore/inspector/front-end/SourceFrame.js	2013-02-01 10:09:47 UTC (rev 141564)
+++ trunk/Source/WebCore/inspector/front-end/SourceFrame.js	2013-02-01 10:11:24 UTC (rev 141565)
@@ -640,6 +640,7 @@
             this._sourcePositionElement.textContent = WebInspector.UIString("Line %d, Column %d", textRange.endLine + 1, textRange.endColumn + 1);
             return;
         }
+        textRange = textRange.normalize();
 
         var selectedText = this._textEditor.copyRange(textRange);
         if (textRange.startLine === textRange.endLine)

Modified: trunk/Source/WebCore/inspector/front-end/inspector.css (141564 => 141565)


--- trunk/Source/WebCore/inspector/front-end/inspector.css	2013-02-01 10:09:47 UTC (rev 141564)
+++ trunk/Source/WebCore/inspector/front-end/inspector.css	2013-02-01 10:11:24 UTC (rev 141565)
@@ -3058,6 +3058,6 @@
 }
 
 .source-frame-position {
-    padding-left: 2px;
+    padding-left: 6px;
     padding-top: 5px;
 }
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to