[ros-diffs] [weiden] 19720: also scroll the selection

weiden at svn.reactos.com weiden at svn.reactos.com
Mon Nov 28 12:00:17 CET 2005


also scroll the selection
Modified: trunk/reactos/subsys/csrss/win32csr/guiconsole.c
  _____  

Modified: trunk/reactos/subsys/csrss/win32csr/guiconsole.c
--- trunk/reactos/subsys/csrss/win32csr/guiconsole.c	2005-11-28
10:38:04 UTC (rev 19719)
+++ trunk/reactos/subsys/csrss/win32csr/guiconsole.c	2005-11-28
11:00:01 UTC (rev 19720)
@@ -502,6 +502,25 @@

       ScrollRect.right = Console->Size.X * GuiData->CharWidth;
       ScrollRect.bottom = Region->top * GuiData->CharHeight;
 
+      if (GuiData->Selection.left != -1)
+      {
+          /* scroll the selection */
+          if (GuiData->Selection.top > ScrolledLines)
+          {
+              GuiData->Selection.top -= ScrolledLines;
+              GuiData->Selection.bottom -= ScrolledLines;
+          }
+          else if (GuiData->Selection.bottom < ScrolledLines)
+          {
+              GuiData->Selection.left = -1;
+          }
+          else
+          {
+              GuiData->Selection.top = 0;
+              GuiData->Selection.bottom -= ScrolledLines;
+          }
+      }
+
       ScrollWindowEx(Console->hWindow,
                      0,
                      -(ScrolledLines * GuiData->CharHeight),
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.reactos.org/pipermail/ros-diffs/attachments/20051128/e9d48a4b/attachment.html


More information about the Ros-diffs mailing list