Some win32 cleanups
This commit is contained in:
parent
593d5441d4
commit
b1df568239
@ -1883,19 +1883,9 @@ _gdk_windowing_create_cairo_surface (GdkDrawable *drawable,
|
|||||||
gint width,
|
gint width,
|
||||||
gint height)
|
gint height)
|
||||||
{
|
{
|
||||||
GdkDrawableImplWin32 *impl = GDK_DRAWABLE_IMPL_WIN32 (drawable);
|
|
||||||
RECT rect;
|
|
||||||
|
|
||||||
HDC hdc = _gdk_win32_drawable_acquire_dc (drawable);
|
HDC hdc = _gdk_win32_drawable_acquire_dc (drawable);
|
||||||
if (!hdc)
|
if (!hdc)
|
||||||
{
|
return NULL;
|
||||||
return NULL;
|
|
||||||
}
|
|
||||||
|
|
||||||
GetClipBox (hdc, &rect);
|
|
||||||
g_print ("create_cairo_surface(): [%d %d %d %d]\n",
|
|
||||||
rect.left, rect.top, rect.right, rect.bottom);
|
|
||||||
|
|
||||||
return cairo_win32_surface_create (hdc);
|
return cairo_win32_surface_create (hdc);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1939,7 +1929,6 @@ _gdk_windowing_set_cairo_surface_size (cairo_surface_t *surface,
|
|||||||
gint height)
|
gint height)
|
||||||
{
|
{
|
||||||
// Do nothing. The surface size is determined by the DC
|
// Do nothing. The surface size is determined by the DC
|
||||||
g_print ("*** set_cairo_surface_size()\n");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static gint
|
static gint
|
||||||
|
@ -1557,29 +1557,6 @@ handle_wm_paint (MSG *msg,
|
|||||||
|
|
||||||
EndPaint (msg->hwnd, &paintstruct);
|
EndPaint (msg->hwnd, &paintstruct);
|
||||||
|
|
||||||
/* HB: don't generate GDK_EXPOSE events for InputOnly
|
|
||||||
* windows -> backing store now works!
|
|
||||||
*/
|
|
||||||
if (((GdkWindowObject *) window)->input_only)
|
|
||||||
{
|
|
||||||
DeleteObject (hrgn);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!(((GdkWindowObject *) window)->event_mask & GDK_EXPOSURE_MASK))
|
|
||||||
{
|
|
||||||
GDK_NOTE (EVENTS, g_print (" (ignored)"));
|
|
||||||
DeleteObject (hrgn);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
#if 0 /* we need to process exposes even with GDK_NO_BG
|
|
||||||
* Otherwise The GIMP canvas update is broken ....
|
|
||||||
*/
|
|
||||||
if (((GdkWindowObject *) window)->bg_pixmap == GDK_NO_BG)
|
|
||||||
break;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
if ((paintstruct.rcPaint.right == paintstruct.rcPaint.left) ||
|
if ((paintstruct.rcPaint.right == paintstruct.rcPaint.left) ||
|
||||||
(paintstruct.rcPaint.bottom == paintstruct.rcPaint.top))
|
(paintstruct.rcPaint.bottom == paintstruct.rcPaint.top))
|
||||||
{
|
{
|
||||||
@ -1621,12 +1598,8 @@ handle_wm_paint (MSG *msg,
|
|||||||
}
|
}
|
||||||
|
|
||||||
update_region = _gdk_win32_hrgn_to_region (hrgn);
|
update_region = _gdk_win32_hrgn_to_region (hrgn);
|
||||||
|
if (!gdk_region_empty (update_region))
|
||||||
|
_gdk_window_invalidate_for_expose (window, update_region);
|
||||||
//_gdk_win32_windowing_window_get_offsets (window, &xoffset, &yoffset);
|
|
||||||
//gdk_region_offset (update_region, xoffset, yoffset);
|
|
||||||
|
|
||||||
_gdk_window_process_expose (window, update_region);
|
|
||||||
gdk_region_destroy (update_region);
|
gdk_region_destroy (update_region);
|
||||||
|
|
||||||
DeleteObject (hrgn);
|
DeleteObject (hrgn);
|
||||||
|
@ -114,26 +114,6 @@ _gdk_window_move_resize_child (GdkWindow *window,
|
|||||||
_gdk_win32_window_tmp_reset_bg (window, TRUE);
|
_gdk_win32_window_tmp_reset_bg (window, TRUE);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
|
||||||
_gdk_window_process_expose (GdkWindow *window,
|
|
||||||
GdkRegion *invalidate_region)
|
|
||||||
{
|
|
||||||
GdkWindowImplWin32 *impl;
|
|
||||||
//GdkRegion *clip_region;
|
|
||||||
impl = GDK_WINDOW_IMPL_WIN32 (GDK_WINDOW_OBJECT (window)->impl);
|
|
||||||
|
|
||||||
GDK_NOTE (EVENTS, g_print ("_gdk_window_process_expose: %p %s\n",
|
|
||||||
GDK_WINDOW_HWND (window),
|
|
||||||
_gdk_win32_gdkregion_to_string (invalidate_region)));
|
|
||||||
|
|
||||||
if (!gdk_region_empty (invalidate_region))
|
|
||||||
_gdk_window_invalidate_for_expose (window, invalidate_region);
|
|
||||||
else
|
|
||||||
g_print ("process_expose(), empty region\n");
|
|
||||||
|
|
||||||
//gdk_region_destroy (invalidate_region);
|
|
||||||
}
|
|
||||||
|
|
||||||
void
|
void
|
||||||
_gdk_win32_window_tmp_unset_bg (GdkWindow *window,
|
_gdk_win32_window_tmp_unset_bg (GdkWindow *window,
|
||||||
gboolean recurse)
|
gboolean recurse)
|
||||||
|
@ -234,9 +234,6 @@ void _gdk_win32_windowing_window_get_offsets (GdkWindow *window,
|
|||||||
gint *y_offset);
|
gint *y_offset);
|
||||||
|
|
||||||
|
|
||||||
void _gdk_window_process_expose (GdkWindow *window,
|
|
||||||
GdkRegion *invalidate_region);
|
|
||||||
|
|
||||||
void _gdk_win32_selection_init (void);
|
void _gdk_win32_selection_init (void);
|
||||||
void _gdk_win32_dnd_exit (void);
|
void _gdk_win32_dnd_exit (void);
|
||||||
|
|
||||||
|
@ -3609,6 +3609,7 @@ _gdk_win32_window_queue_translation (GdkWindow *window,
|
|||||||
gint dx,
|
gint dx,
|
||||||
gint dy)
|
gint dy)
|
||||||
{
|
{
|
||||||
|
/* TODO: Get current updateregion, move any part of it that intersects area by dx,dy */
|
||||||
g_print ("queue_translation\n");
|
g_print ("queue_translation\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user