Fix the clipping checks in TuiFillArea.
Modified: trunk/reactos/boot/freeldr/freeldr/ui/tui.c
_____
Modified: trunk/reactos/boot/freeldr/freeldr/ui/tui.c
--- trunk/reactos/boot/freeldr/freeldr/ui/tui.c 2005-11-13 08:21:41 UTC
(rev 19201)
+++ trunk/reactos/boot/freeldr/freeldr/ui/tui.c 2005-11-13 08:24:15 UTC
(rev 19202)
@@ -190,19 +190,18 @@
ULONG i, j;
// Clip the area to the screen
- // FIXME: This code seems to have problems... Uncomment and view
;-)
- /*if ((Left >= UiScreenWidth) || (Top >= UiScreenHeight))
+ if ((Left >= UiScreenWidth) || (Top >= UiScreenHeight))
{
return;
}
- if ((Left + Right) >= UiScreenWidth)
+ if (Right >= UiScreenWidth)
{
- Right = UiScreenWidth - Left;
+ Right = UiScreenWidth - 1;
}
- if ((Top + Bottom) >= UiScreenHeight)
+ if (Bottom >= UiScreenHeight)
{
- Bottom = UiScreenHeight - Top;
- }*/
+ Bottom = UiScreenHeight - 1;
+ }
// Loop through each line and fill it in
for (i=Top; i<=Bottom; i++)