Carlo Bramini (carlo DOT bramix AT libero DOT it):
authorColin Finck <colin@reactos.org>
Thu, 15 May 2008 14:06:19 +0000 (14:06 +0000)
committerColin Finck <colin@reactos.org>
Thu, 15 May 2008 14:06:19 +0000 (14:06 +0000)
- Simplify blitting the screen bitmap to the main window.

This also hides a ROS GDI bug, for which I'm going to open a new bug report.
See issue #3241 for more details.

svn path=/trunk/; revision=33528

rosapps/magnify/magnifier.c

index 7f0600a..b8900ed 100644 (file)
@@ -257,8 +257,9 @@ void Draw(HDC aDc)
                rop = NOTSRCCOPY;\r
        }\r
 \r
                rop = NOTSRCCOPY;\r
        }\r
 \r
+       /* Blast the stretched image from memory DC to window DC.*/\r
        StretchBlt(\r
        StretchBlt(\r
-               HdcStrech,\r
+               aDc,\r
                0,\r
                0,\r
                AppWidth,\r
                0,\r
                0,\r
                AppWidth,\r
@@ -270,18 +271,6 @@ void Draw(HDC aDc)
                blitAreaHeight,\r
                rop);\r
 \r
                blitAreaHeight,\r
                rop);\r
 \r
-       /* Blast the image from memory DC to client DC.*/\r
-       BitBlt (\r
-               aDc,\r
-               0 ,\r
-               0 ,\r
-               AppWidth ,\r
-               AppHeight ,\r
-               HdcStrech ,\r
-               0 ,\r
-               0 ,\r
-               SRCCOPY);\r
-\r
        /* Cleanup.*/\r
        SelectObject (HdcStrech, hOld);\r
        DeleteObject (HbmpStrech);\r
        /* Cleanup.*/\r
        SelectObject (HdcStrech, hOld);\r
        DeleteObject (HbmpStrech);\r