+2005-07-29 Tor Lillqvist <tml@novell.com>
+
+ * gdk/win32/gdkdrawable-win32.c (blit_inside_drawable): Rename
+ from blit_inside_window(), as it now does blitting inside a
+ bitmap, too. No code change, still just call BitBlt().
+ (_gdk_win32_blit): Check for source equalling destination
+ first. (#169508, #131977)
+ Do away with the superfluous local draw_impl variable, the
+ parameter to this function is already a GdkDrawableImplWin32*, no
+ need to copy and cast it.
+
2005-07-28 Robert Ögren <gtk@roboros.com>
Avoid spurious core pointer events when the tablet pen is lifted.
+2005-07-29 Tor Lillqvist <tml@novell.com>
+
+ * gdk/win32/gdkdrawable-win32.c (blit_inside_drawable): Rename
+ from blit_inside_window(), as it now does blitting inside a
+ bitmap, too. No code change, still just call BitBlt().
+ (_gdk_win32_blit): Check for source equalling destination
+ first. (#169508, #131977)
+ Do away with the superfluous local draw_impl variable, the
+ parameter to this function is already a GdkDrawableImplWin32*, no
+ need to copy and cast it.
+
2005-07-28 Robert Ögren <gtk@roboros.com>
Avoid spurious core pointer events when the tablet pen is lifted.
+2005-07-29 Tor Lillqvist <tml@novell.com>
+
+ * gdk/win32/gdkdrawable-win32.c (blit_inside_drawable): Rename
+ from blit_inside_window(), as it now does blitting inside a
+ bitmap, too. No code change, still just call BitBlt().
+ (_gdk_win32_blit): Check for source equalling destination
+ first. (#169508, #131977)
+ Do away with the superfluous local draw_impl variable, the
+ parameter to this function is already a GdkDrawableImplWin32*, no
+ need to copy and cast it.
+
2005-07-28 Robert Ögren <gtk@roboros.com>
Avoid spurious core pointer events when the tablet pen is lifted.
}
static void
-blit_inside_window (HDC hdc,
- GdkGCWin32 *gcwin32,
- gint xsrc,
- gint ysrc,
- gint xdest,
- gint ydest,
- gint width,
- gint height)
+blit_inside_drawable (HDC hdc,
+ GdkGCWin32 *gcwin32,
+ gint xsrc,
+ gint ysrc,
+ gint xdest,
+ gint ydest,
+ gint width,
+ gint height)
{
- GDK_NOTE (MISC, g_print ("blit_inside_window\n"));
+ GDK_NOTE (MISC, g_print ("blit_inside_drawable\n"));
GDI_CALL (BitBlt, (hdc, xdest, ydest, width, height,
hdc, xsrc, ysrc, rop2_to_rop3 (gcwin32->rop2)));
void
_gdk_win32_blit (gboolean use_fg_bg,
- GdkDrawableImplWin32 *drawable,
+ GdkDrawableImplWin32 *draw_impl,
GdkGC *gc,
GdkDrawable *src,
gint xsrc,
HDC hdc;
HRGN src_rgn, draw_rgn, outside_rgn;
RECT r;
- GdkDrawableImplWin32 *draw_impl;
GdkDrawableImplWin32 *src_impl = NULL;
gint src_width, src_height;
" dst:%s @%+d%+d use_fg_bg=%d\n",
_gdk_win32_drawable_description (src),
width, height, xsrc, ysrc,
- _gdk_win32_drawable_description ((GdkDrawable *) drawable),
+ _gdk_win32_drawable_description (&draw_impl->parent_instance),
xdest, ydest,
use_fg_bg));
ysrc -= _gdk_offset_y;
}
- draw_impl = (GdkDrawableImplWin32 *) drawable;
-
if (GDK_IS_DRAWABLE_IMPL_WIN32 (src))
src_impl = (GdkDrawableImplWin32 *) src;
else if (GDK_IS_WINDOW (src))
else
g_assert_not_reached ();
- hdc = gdk_win32_hdc_get ((GdkDrawable *) drawable, gc, GDK_GC_FOREGROUND);
+ hdc = gdk_win32_hdc_get (&draw_impl->parent_instance, gc, GDK_GC_FOREGROUND);
gdk_drawable_get_size (src, &src_width, &src_height);
GDI_CALL (DeleteObject, (draw_rgn));
}
- if (GDK_IS_PIXMAP_IMPL_WIN32 (src_impl))
+ if (draw_impl->handle == src_impl->handle)
+ blit_inside_drawable (hdc, GDK_GC_WIN32 (gc), xsrc, ysrc, xdest, ydest, width, height);
+ else if (GDK_IS_PIXMAP_IMPL_WIN32 (src_impl))
blit_from_pixmap (use_fg_bg, draw_impl, hdc,
(GdkPixmapImplWin32 *) src_impl, gc,
xsrc, ysrc, xdest, ydest, width, height);
- else if (draw_impl->handle == src_impl->handle)
- blit_inside_window (hdc, GDK_GC_WIN32 (gc), xsrc, ysrc, xdest, ydest, width, height);
else
blit_from_window (hdc, GDK_GC_WIN32 (gc), src_impl, xsrc, ysrc, xdest, ydest, width, height);
- gdk_win32_hdc_release ((GdkDrawable *) drawable, gc, GDK_GC_FOREGROUND);
+ gdk_win32_hdc_release (&draw_impl->parent_instance, gc, GDK_GC_FOREGROUND);
}
static void