Only add up native subwindow offsets for gdk_window_quartz_get_origin
This commit is contained in:
committed by
Alexander Larsson
parent
0092c1ebf0
commit
97996ff00c
@ -1678,8 +1678,11 @@ gdk_window_quartz_get_origin (GdkWindow *window,
|
|||||||
|
|
||||||
if (window == _gdk_root)
|
if (window == _gdk_root)
|
||||||
{
|
{
|
||||||
|
if (x)
|
||||||
*x = 0;
|
*x = 0;
|
||||||
|
if (y)
|
||||||
*y = 0;
|
*y = 0;
|
||||||
|
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1694,9 +1697,12 @@ gdk_window_quartz_get_origin (GdkWindow *window,
|
|||||||
tmp_y = _gdk_quartz_window_get_inverted_screen_y (content_rect.origin.y + content_rect.size.height);
|
tmp_y = _gdk_quartz_window_get_inverted_screen_y (content_rect.origin.y + content_rect.size.height);
|
||||||
|
|
||||||
while (private != GDK_WINDOW_OBJECT (toplevel))
|
while (private != GDK_WINDOW_OBJECT (toplevel))
|
||||||
|
{
|
||||||
|
if (_gdk_window_has_impl ((GdkWindow *)private))
|
||||||
{
|
{
|
||||||
tmp_x += private->x;
|
tmp_x += private->x;
|
||||||
tmp_y += private->y;
|
tmp_y += private->y;
|
||||||
|
}
|
||||||
|
|
||||||
private = private->parent;
|
private = private->parent;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user