move_region_on_impl - shortcut if region is empty

This commit is contained in:
Alexander Larsson 2009-01-20 22:17:06 +01:00 committed by Alexander Larsson
parent ed9cd90b72
commit 6b15e248fa

View File

@ -2523,7 +2523,8 @@ move_region_on_impl (GdkWindowObject *private,
GdkWindowObject *impl_window;
gboolean free_region;
if (dx == 0 && dy == 0)
if ((dx == 0 && dy == 0) ||
gdk_region_empty (region))
{
gdk_region_destroy (region);
return;