Reviewed by Darin
authorkocienda <kocienda@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 17 Sep 2004 16:44:24 +0000 (16:44 +0000)
committerkocienda <kocienda@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 17 Sep 2004 16:44:24 +0000 (16:44 +0000)
        Fix for this bug:

        <rdar://problem/3780245> REGRESSION (Mail): some lines are skipped when doing arrow navigation

        * khtml/xml/dom_position.cpp:
        (DOM::Position::previousLinePosition): One-line fix. Make sure that BRs at the end of blocks
        are not skipped.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@7590 268f45cc-cd09-0410-ab3c-d52691b4dbfc

WebCore/ChangeLog-2005-08-23
WebCore/khtml/xml/dom_position.cpp

index 06d63c5e418d65b0b7aaeab8423c2c7d012476ab..5666b5ca58c9dd24a3c6ad7c778918654e8fd009 100644 (file)
@@ -1,3 +1,15 @@
+2004-09-17  Ken Kocienda  <kocienda@apple.com>
+
+        Reviewed by Darin
+
+        Fix for this bug:
+        
+        <rdar://problem/3780245> REGRESSION (Mail): some lines are skipped when doing arrow navigation
+
+        * khtml/xml/dom_position.cpp:
+        (DOM::Position::previousLinePosition): One-line fix. Make sure that BRs at the end of blocks
+        are not skipped.
+
 2004-09-17  Ken Kocienda  <kocienda@apple.com>
 
         Reviewed by Darin
 2004-09-17  Ken Kocienda  <kocienda@apple.com>
 
         Reviewed by Darin
index 3c7ddf1dacfcc833d28490d10342778d80638a1b..a39190a45af01b1a29678710b38deefd00042fd4 100644 (file)
@@ -546,7 +546,7 @@ Position Position::previousLinePosition(int x) const
         while (n) {
             if (!n->inSameRootEditableElement(node()))
                 break;
         while (n) {
             if (!n->inSameRootEditableElement(node()))
                 break;
-            Position pos(n, n->caretMaxOffset());
+            Position pos(n, n->caretMinOffset());
             if (pos.inRenderedContent()) {
                 ASSERT(n->renderer());
                 box = n->renderer()->inlineBox(n->caretMaxOffset());
             if (pos.inRenderedContent()) {
                 ASSERT(n->renderer());
                 box = n->renderer()->inlineBox(n->caretMaxOffset());