From 2b6586f64d4c49a3a3858ce52182610d5b77fbd0 Mon Sep 17 00:00:00 2001 From: Matthias Melcher Date: Mon, 12 Sep 2005 23:03:34 +0000 Subject: STR #1007: Applied second patch by hand. OP: could you please check if all changes were made correctly? Thanks! git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@4563 ea41ed52-d2ee-0310-a9c1-e6b18d33e121 --- src/Fl_Bitmap.cxx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/Fl_Bitmap.cxx') diff --git a/src/Fl_Bitmap.cxx b/src/Fl_Bitmap.cxx index 372578633..3b39ce472 100644 --- a/src/Fl_Bitmap.cxx +++ b/src/Fl_Bitmap.cxx @@ -11,7 +11,7 @@ // version 2 of the License, or (at your option) any later version. // // This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of +// but WITHOUT ANY WARRANTY; without even 79the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU // Library General Public License for more details. // @@ -372,10 +372,12 @@ void Fl_Bitmap::draw(int XP, int YP, int WP, int HP, int cx, int cy) { if (!id) id = fl_create_bitmap(w(), h(), array); HDC tempdc = CreateCompatibleDC(fl_gc); + int save = SaveDC(tempdc); SelectObject(tempdc, (HGDIOBJ)id); SelectObject(fl_gc, fl_brush()); // secret bitblt code found in old MSWindows reference manual: BitBlt(fl_gc, X, Y, W, H, tempdc, cx, cy, 0xE20746L); + RestoreDC(tempdc, save); DeleteDC(tempdc); #elif defined(__APPLE_QD__) if (!id) id = fl_create_bitmask(w(), h(), array); -- cgit v1.2.3