mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-12-25 13:11:13 +00:00
Call ReleaseDC() on DCs acquired with GetDC() (for windows), and
2006-06-09 Tor Lillqvist <tml@novell.com> * gdk/win32/gdkdrawable-win32.c (_gdk_win32_drawable_release_dc): Call ReleaseDC() on DCs acquired with GetDC() (for windows), and DeleteDC() on DCs acquired with CreateCompatibleDC() (for bitmaps). According to MSDN, this is the correct thing to do, even if always using DeleteDC() seems to have worked fine in practice. (#337491)
This commit is contained in:
parent
ada7aa635e
commit
225d9caf7c
@ -1,3 +1,12 @@
|
||||
2006-06-09 Tor Lillqvist <tml@novell.com>
|
||||
|
||||
* gdk/win32/gdkdrawable-win32.c (_gdk_win32_drawable_release_dc):
|
||||
Call ReleaseDC() on DCs acquired with GetDC() (for windows), and
|
||||
DeleteDC() on DCs acquired with CreateCompatibleDC() (for
|
||||
bitmaps). According to MSDN, this is the correct thing to do, even
|
||||
if always using DeleteDC() seems to have worked fine in
|
||||
practice. (#337491)
|
||||
|
||||
2006-06-08 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* tests/testprint.c: Update for api changes.
|
||||
|
@ -1,3 +1,12 @@
|
||||
2006-06-09 Tor Lillqvist <tml@novell.com>
|
||||
|
||||
* gdk/win32/gdkdrawable-win32.c (_gdk_win32_drawable_release_dc):
|
||||
Call ReleaseDC() on DCs acquired with GetDC() (for windows), and
|
||||
DeleteDC() on DCs acquired with CreateCompatibleDC() (for
|
||||
bitmaps). According to MSDN, this is the correct thing to do, even
|
||||
if always using DeleteDC() seems to have worked fine in
|
||||
practice. (#337491)
|
||||
|
||||
2006-06-08 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* tests/testprint.c: Update for api changes.
|
||||
|
@ -1889,7 +1889,10 @@ _gdk_win32_drawable_release_dc (GdkDrawable *drawable)
|
||||
|
||||
if (impl->hdc)
|
||||
{
|
||||
GDI_CALL (DeleteDC, (impl->hdc));
|
||||
if (GDK_IS_PIXMAP_IMPL_WIN32 (impl))
|
||||
GDI_CALL (DeleteDC, (impl->hdc));
|
||||
else
|
||||
GDI_CALL (ReleaseDC, (impl->handle, impl->hdc));
|
||||
impl->hdc = NULL;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user