mirror of
https://github.com/brl/mutter.git
synced 2024-11-25 01:20:42 -05:00
Maintain the size of the window.
Thu Mar 16 14:55:18 2006 Søren Sandmann <sandmann@redhat.com> * src/c-screen.c (struct WindowInfo): Maintain the size of the window.
This commit is contained in:
parent
ad2c7c6ce3
commit
01cd31f7f4
@ -1,3 +1,8 @@
|
|||||||
|
Thu Mar 16 14:55:18 2006 Søren Sandmann <sandmann@redhat.com>
|
||||||
|
|
||||||
|
* src/c-screen.c (struct WindowInfo): Maintain the size of the
|
||||||
|
window.
|
||||||
|
|
||||||
Wed Mar 15 16:30:09 2006 Søren Sandmann <sandmann@redhat.com>
|
Wed Mar 15 16:30:09 2006 Søren Sandmann <sandmann@redhat.com>
|
||||||
|
|
||||||
* src/compositor.c (set_geometry): Use set_target_rect() instead
|
* src/compositor.c (set_geometry): Use set_target_rect() instead
|
||||||
|
@ -36,6 +36,8 @@ struct WindowInfo
|
|||||||
Window xwindow;
|
Window xwindow;
|
||||||
CmNode *node;
|
CmNode *node;
|
||||||
gboolean updates;
|
gboolean updates;
|
||||||
|
|
||||||
|
WsRectangle size;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct MetaScreenInfo
|
struct MetaScreenInfo
|
||||||
@ -108,8 +110,10 @@ repaint (gpointer data)
|
|||||||
info->meta_screen->rect.width,
|
info->meta_screen->rect.width,
|
||||||
info->meta_screen->rect.height);
|
info->meta_screen->rect.height);
|
||||||
|
|
||||||
glClearColor (1.0, 0.8, 0.8, 0.0);
|
#if 0
|
||||||
|
glClearColor (1.0, 1.0, 0.8, 0.0);
|
||||||
glClear (GL_COLOR_BUFFER_BIT);
|
glClear (GL_COLOR_BUFFER_BIT);
|
||||||
|
#endif
|
||||||
|
|
||||||
ws_window_raise (info->gl_window);
|
ws_window_raise (info->gl_window);
|
||||||
|
|
||||||
@ -373,15 +377,23 @@ meta_screen_info_set_size (MetaScreenInfo *info,
|
|||||||
|
|
||||||
ws_display_begin_error_trap (display);
|
ws_display_begin_error_trap (display);
|
||||||
|
|
||||||
|
#if 0
|
||||||
g_print ("meta screen info set: %d %d %d %d\n",
|
g_print ("meta screen info set: %d %d %d %d\n",
|
||||||
x, y, width, height);
|
x, y, width, height);
|
||||||
|
#endif
|
||||||
|
|
||||||
cm_drawable_node_set_geometry (CM_DRAWABLE_NODE (node), &rect);
|
cm_drawable_node_set_geometry (CM_DRAWABLE_NODE (node), &rect);
|
||||||
shape = ws_window_get_output_shape (window);
|
shape = ws_window_get_output_shape (window);
|
||||||
cm_drawable_node_set_shape (node, shape);
|
cm_drawable_node_set_shape (node, shape);
|
||||||
ws_region_destroy (shape);
|
ws_region_destroy (shape);
|
||||||
|
|
||||||
cm_drawable_node_update_pixmap (node);
|
if (rect.width != winfo->size.width ||
|
||||||
|
rect.height != winfo->size.height)
|
||||||
|
{
|
||||||
|
cm_drawable_node_update_pixmap (node);
|
||||||
|
}
|
||||||
|
|
||||||
|
winfo->size = rect;
|
||||||
|
|
||||||
ws_display_end_error_trap (display);
|
ws_display_end_error_trap (display);
|
||||||
}
|
}
|
||||||
@ -442,6 +454,12 @@ meta_screen_info_add_window (MetaScreenInfo *info,
|
|||||||
|
|
||||||
if (ws_window_query_input_only (WS_WINDOW (drawable)))
|
if (ws_window_query_input_only (WS_WINDOW (drawable)))
|
||||||
goto out;
|
goto out;
|
||||||
|
|
||||||
|
if (WS_WINDOW (drawable) == info->gl_window)
|
||||||
|
{
|
||||||
|
g_print ("gl window\n");
|
||||||
|
goto out;
|
||||||
|
}
|
||||||
|
|
||||||
ws_drawable_query_geometry (drawable, &geometry);
|
ws_drawable_query_geometry (drawable, &geometry);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user