mirror of
https://github.com/brl/mutter.git
synced 2024-12-23 11:32:04 +00:00
2008-05-26 Matthew Allum <mallum@openedhand.com>
* clutter/x11/clutter-stage-x11.c: (clutter_stage_x11_request_coords): Dont allow the window to be resize to 0 dimentions. (fixes #933)
This commit is contained in:
parent
4ef8d3bb5f
commit
94b2d6f664
@ -1,3 +1,8 @@
|
||||
2008-05-26 Matthew Allum <mallum@openedhand.com>
|
||||
|
||||
* clutter/x11/clutter-stage-x11.c: (clutter_stage_x11_request_coords):
|
||||
Dont allow the window to be resize to 0 dimentions. (fixes #933)
|
||||
|
||||
2008-05-23 Emmanuele Bassi <ebassi@openedhand.com>
|
||||
|
||||
Bug #912 - Invalid use of int* as parameter for glGetIntegerv
|
||||
|
@ -176,6 +176,19 @@ clutter_stage_x11_request_coords (ClutterActor *self,
|
||||
new_width = ABS (CLUTTER_UNITS_TO_INT (box->x2 - box->x1));
|
||||
new_height = ABS (CLUTTER_UNITS_TO_INT (box->y2 - box->y1));
|
||||
|
||||
/* X cant resize to 0 dimentions */
|
||||
if (new_height == 0)
|
||||
{
|
||||
box->y2 = box->y1 + 1;
|
||||
new_height = 1;
|
||||
}
|
||||
|
||||
if (new_width == 0)
|
||||
{
|
||||
box->x2 = box->x1 + 1;
|
||||
new_width = 1;
|
||||
}
|
||||
|
||||
if (new_width != stage_x11->xwin_width
|
||||
|| new_height != stage_x11->xwin_height)
|
||||
{
|
||||
@ -197,11 +210,11 @@ clutter_stage_x11_request_coords (ClutterActor *self,
|
||||
if (stage_x11->xwin != None
|
||||
&& !stage_x11->is_foreign_xwin
|
||||
&& !stage_x11->handling_configure)
|
||||
XResizeWindow (stage_x11->xdpy,
|
||||
stage_x11->xwin,
|
||||
stage_x11->xwin_width,
|
||||
stage_x11->xwin_height);
|
||||
|
||||
XResizeWindow (stage_x11->xdpy,
|
||||
stage_x11->xwin,
|
||||
stage_x11->xwin_width,
|
||||
stage_x11->xwin_height);
|
||||
|
||||
clutter_stage_x11_fix_window_size (stage_x11);
|
||||
|
||||
if (stage_x11->xpixmap != None)
|
||||
|
Loading…
Reference in New Issue
Block a user