x11: adjust size to minimal size when realizing
If you execute the following sequence : stage = clutter_stage_new (); clutter_actor_set_size (stage, 1280, 800); clutter_actor_realize (stage); Then you end up creating an onscreen buffer of size 1280x800 but ClutterStageX11 storing the stage size at 640x480. This patch resync the 2 implementation by using the ClutterStage's size in both classes when realizing. Signed-off-by: Lionel Landwerlin <llandwerlin@gmail.com> https://bugzilla.gnome.org/show_bug.cgi?id=667540
This commit is contained in:
parent
b1ff53d980
commit
d31bd6fe92
@ -435,6 +435,11 @@ clutter_stage_x11_realize (ClutterStageWindow *stage_window)
|
||||
stage_cogl->onscreen = cogl_onscreen_new (backend->cogl_context,
|
||||
width, height);
|
||||
|
||||
/* We just created a window of the size of the actor. No need to fix
|
||||
the size of the stage, just update it. */
|
||||
stage_x11->xwin_width = width;
|
||||
stage_x11->xwin_height = height;
|
||||
|
||||
if (stage_x11->xwin != None)
|
||||
{
|
||||
cogl_x11_onscreen_set_foreign_window_xid (stage_cogl->onscreen,
|
||||
@ -500,7 +505,6 @@ clutter_stage_x11_realize (ClutterStageWindow *stage_window)
|
||||
stage_cogl->wrapper,
|
||||
event_flags);
|
||||
|
||||
/* no user resize.. */
|
||||
clutter_stage_x11_fix_window_size (stage_x11,
|
||||
stage_x11->xwin_width,
|
||||
stage_x11->xwin_height);
|
||||
|
Loading…
Reference in New Issue
Block a user