mirror of
https://github.com/brl/mutter.git
synced 2025-08-08 17:34:52 +00:00
core: Convert GET_FRAME_WIDTH / GET_FRAME_HEIGHT to GET_FRAME_RECT
Since we're going to be calling meta_window_get_frame_rect in here soon, I'd rather it be one method call, rather than two. We can't put it at the toplevel, since that might cause infinite recursion (e.g. meta_core_get calls meta_window_get_frame_rect calls meta_ui_get_frame_borders calls meta_core_get, ...)
This commit is contained in:
@@ -120,11 +120,8 @@ meta_core_get (Display *xdisplay,
|
||||
case META_CORE_GET_ICON:
|
||||
*((GdkPixbuf**)answer) = window->icon;
|
||||
break;
|
||||
case META_CORE_GET_FRAME_WIDTH:
|
||||
*((gint*)answer) = window->frame->rect.width;
|
||||
break;
|
||||
case META_CORE_GET_FRAME_HEIGHT:
|
||||
*((gint*)answer) = window->frame->rect.height;
|
||||
case META_CORE_GET_FRAME_RECT:
|
||||
*((MetaRectangle*)answer) = window->frame->rect;
|
||||
break;
|
||||
case META_CORE_GET_THEME_VARIANT:
|
||||
*((char**)answer) = window->gtk_theme_variant;
|
||||
|
@@ -37,8 +37,7 @@ typedef enum
|
||||
META_CORE_GET_FRAME_TYPE,
|
||||
META_CORE_GET_MINI_ICON,
|
||||
META_CORE_GET_ICON,
|
||||
META_CORE_GET_FRAME_WIDTH,
|
||||
META_CORE_GET_FRAME_HEIGHT,
|
||||
META_CORE_GET_FRAME_RECT,
|
||||
META_CORE_GET_THEME_VARIANT,
|
||||
} MetaCoreGetType;
|
||||
|
||||
|
Reference in New Issue
Block a user