[maemo-commits] [maemo-commits] r19102 - in projects/haf/trunk/clutter0.8: clutter debian
From: subversion at stage.maemo.org subversion at stage.maemo.orgDate: Tue Aug 11 09:50:22 EEST 2009
- Previous message: [maemo-commits] r19101 - in projects/haf/trunk/gtk+: . gtk
- Next message: [maemo-commits] r19103 - projects/haf/tags/clutter
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Author: kihamala Date: 2009-08-11 09:50:05 +0300 (Tue, 11 Aug 2009) New Revision: 19102 Modified: projects/haf/trunk/clutter0.8/clutter/clutter-stage.c projects/haf/trunk/clutter0.8/debian/changelog Log: Gordon's patch for NB#131044 Modified: projects/haf/trunk/clutter0.8/clutter/clutter-stage.c =================================================================== --- projects/haf/trunk/clutter0.8/clutter/clutter-stage.c 2009-08-10 20:04:02 UTC (rev 19101) +++ projects/haf/trunk/clutter0.8/clutter/clutter-stage.c 2009-08-11 06:50:05 UTC (rev 19102) @@ -2120,8 +2120,10 @@ clutter_stage_set_damaged_area (ClutterActor *self, ClutterGeometry area) { ClutterStagePrivate *priv = CLUTTER_STAGE (self)->priv; + gint width, height; + clutter_actor_get_size(self, (guint*)&width, (guint*)&height); - /* check if this is invalid */ + /* check if this is invalid, invalidate the stage too */ if (area.width <=0 || area.height <= 0) { priv->damaged_area.x = 0; @@ -2131,6 +2133,34 @@ return; } + /* clip to the screen */ + if (area.x < 0) + { + area.width += area.x; + area.x = 0; + } + if (area.y < 0) + { + area.height += area.y; + area.y = 0; + } + if (area.x > width || area.y > height) + { // offscreen + area.x = 0; + area.y = 0; + area.width = 0; + area.height = 0; + } + if (area.x + area.width > width) + area.width = width - area.x; + if (area.y + area.height > height) + area.height = height - area.y; + + /* if this is invalid *now* (but not earlier), + * it was offscreen - so ignore it */ + if (area.width <=0 || area.height <= 0) + return; + /* check if the stage is invalid */ if (priv->damaged_area.width <=0 || priv->damaged_area.height <= 0) { @@ -2150,14 +2180,16 @@ priv->damaged_area.height += priv->damaged_area.y - area.y; priv->damaged_area.y = area.y; } - if (area.x+area.width > priv->damaged_area.x+priv->damaged_area.width) + if (area.x + area.width > + priv->damaged_area.x + priv->damaged_area.width) { - priv->damaged_area.width = (area.x+area.width) - + priv->damaged_area.width = (area.x + area.width) - priv->damaged_area.x; } - if (area.y+area.height > priv->damaged_area.y+priv->damaged_area.height) + if (area.y + area.height > + priv->damaged_area.y + priv->damaged_area.height) { - priv->damaged_area.height = (area.y+area.height) - + priv->damaged_area.height = (area.y + area.height) - priv->damaged_area.y; } } Modified: projects/haf/trunk/clutter0.8/debian/changelog =================================================================== --- projects/haf/trunk/clutter0.8/debian/changelog 2009-08-10 20:04:02 UTC (rev 19101) +++ projects/haf/trunk/clutter0.8/debian/changelog 2009-08-11 06:50:05 UTC (rev 19102) @@ -1,8 +1,10 @@ -clutter (0.8.2-0maemo43~unreleased) unstable; urgency=low +clutter (0.8.2-0maemo43) unstable; urgency=low - * foo + * clutter/clutter-stage.c (clutter_stage_set_damaged_area): Clip to screen. + * Fixes: NB#131044 - Desktop having bluescreen when sliding it side by side + holding finger over some vidget - -- Gordon Williams <gordon.williams at collabora.co.uk> Wed, 5 Aug 2009 09:35:56 +0300 + -- Gordon Williams <gordon.williams at collabora.co.uk> Tue, 11 Aug 2009 09:46:51 +0300 clutter (0.8.2-0maemo42) unstable; urgency=low
- Previous message: [maemo-commits] r19101 - in projects/haf/trunk/gtk+: . gtk
- Next message: [maemo-commits] r19103 - projects/haf/tags/clutter
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]