OSDN Git Service

PATCH: [ 1445996 ] Fix wrong PgDown scrolling after mousescroll
authorKimmo Varis <kimmov@gmail.com>
Thu, 9 Mar 2006 16:30:07 +0000 (16:30 +0000)
committerKimmo Varis <kimmov@gmail.com>
Thu, 9 Mar 2006 16:30:07 +0000 (16:30 +0000)
Src/Changes.txt
Src/editlib/ccrystaltextview2.cpp

index 34a565e..421c671 100644 (file)
@@ -2,6 +2,10 @@ Src\Changes.txt
 Add new items to top.
 (This summarizes all changes to all files under Src, including Src\Languages.)
 
+2006-03-09 Kimmo
+ PATCH: [ 1445996 ] Fix wrong PgDown scrolling after mousescroll
+  Src/editlib: ccrystaltextview2.cpp
+
 2006-03-08 Kimmo
  PATCH: [ 1441392 ] New Splash Screen
   Submitted by Alexander Skinner
index e9dea86..fac0d92 100644 (file)
@@ -421,15 +421,16 @@ MovePgDn (BOOL bSelect)
                nNewTopSubLine = nSubLineCount - 1;
        if (m_nTopSubLine != nNewTopSubLine)
        {
+               m_ptCursorPos.y = nNewTopSubLine;
                ScrollToSubLine(nNewTopSubLine);
-               UpdateSiblingScrollPos(FALSE);
+        UpdateSiblingScrollPos(FALSE);
        }
 
        // setting cursor
-       CPoint  subLinePos;
+       CPoint subLinePos;
        CharPosToPoint( m_ptCursorPos.y, m_ptCursorPos.x, subLinePos );
 
-       int                     nSubLine = GetSubLineIndex( m_ptCursorPos.y ) + subLinePos.y + GetScreenLines() - 1;
+       int nSubLine = GetSubLineIndex( m_ptCursorPos.y ) + subLinePos.y + GetScreenLines() - 1;
 
        if( nSubLine > nSubLineCount - 1 )
                nSubLine = nSubLineCount - 1;