[maemo-commits] [maemo-commits] r12091 - in projects/haf/trunk/hildon-desktop: . debian libhildondesktop src

From: subversion at stage.maemo.org subversion at stage.maemo.org
Date: Mon Jun 4 18:42:31 EEST 2007
Author: jobi
Date: 2007-06-04 18:41:03 +0300 (Mon, 04 Jun 2007)
New Revision: 12091

Modified:
   projects/haf/trunk/hildon-desktop/ChangeLog
   projects/haf/trunk/hildon-desktop/debian/changelog
   projects/haf/trunk/hildon-desktop/debian/control
   projects/haf/trunk/hildon-desktop/libhildondesktop/hildon-desktop-home-item.c
   projects/haf/trunk/hildon-desktop/libhildondesktop/hildon-home-area.c
   projects/haf/trunk/hildon-desktop/src/hd-panel-window.c
Log:

2007-06-04  Johan Bilien  <johan.bilien at nokia.com>

	* src/hd-panel-window.c:
	- Fixed the leak of XRectangle
	* libhildondesktop/hildon-home-area.c:
	- Fixed the leak of a GtkBorder
	* libhildondesktop/hildon-desktop-home-item.c:
	- Reset the delta values on button_press to avoid
	snapping to grid if the applet has not moved



Modified: projects/haf/trunk/hildon-desktop/ChangeLog
===================================================================
--- projects/haf/trunk/hildon-desktop/ChangeLog	2007-06-04 13:18:28 UTC (rev 12090)
+++ projects/haf/trunk/hildon-desktop/ChangeLog	2007-06-04 15:41:03 UTC (rev 12091)
@@ -1,3 +1,13 @@
+2007-06-04  Johan Bilien  <johan.bilien at nokia.com>
+
+	* src/hd-panel-window.c:
+	- Fixed the leak of XRectangle
+	* libhildondesktop/hildon-home-area.c:
+	- Fixed the leak of a GtkBorder
+	* libhildondesktop/hildon-desktop-home-item.c:
+	- Reset the delta values on button_press to avoid
+	snapping to grid if the applet has not moved
+
 2007-06-01  Moises Martinez  <moises.martinez at nokia.com>
 
 	* libhildondesktop/hildon-home-area.c:

Modified: projects/haf/trunk/hildon-desktop/debian/changelog
===================================================================
--- projects/haf/trunk/hildon-desktop/debian/changelog	2007-06-04 13:18:28 UTC (rev 12090)
+++ projects/haf/trunk/hildon-desktop/debian/changelog	2007-06-04 15:41:03 UTC (rev 12091)
@@ -1,3 +1,9 @@
+hildon-desktop (0.0.16-2) sardine; urgency=low
+
+  * restored conflict with maemo-af-deskop[-config]
+
+ -- Johan Bilien <johan.bilien at nokia.com>  Mon,  4 Jun 2007 17:26:14 +0300
+
 hildon-desktop (0.0.16-1) sardine; urgency=low
 
   * src/hd-panel-window.c:

Modified: projects/haf/trunk/hildon-desktop/debian/control
===================================================================
--- projects/haf/trunk/hildon-desktop/debian/control	2007-06-04 13:18:28 UTC (rev 12090)
+++ projects/haf/trunk/hildon-desktop/debian/control	2007-06-04 15:41:03 UTC (rev 12091)
@@ -9,6 +9,7 @@
 Section: x11
 Architecture: any
 Depends:  ${shlibs:Depends}, ${misc:Depends}, ${launcher:Depends}, maemo-af-desktop-l10n-mr | maemo-af-desktop-l10n-mr0
+Conflicts: maemo-af-desktop (<< 3.0.0), maemo-af-desktop-config
 Description: Desktop environment for embedded devices
   Hildon Desktop is a desktop environment for embedded devices. It
   is based on the GNOME platform

Modified: projects/haf/trunk/hildon-desktop/libhildondesktop/hildon-desktop-home-item.c
===================================================================
--- projects/haf/trunk/hildon-desktop/libhildondesktop/hildon-desktop-home-item.c	2007-06-04 13:18:28 UTC (rev 12090)
+++ projects/haf/trunk/hildon-desktop/libhildondesktop/hildon-desktop-home-item.c	2007-06-04 15:41:03 UTC (rev 12091)
@@ -810,44 +810,6 @@
   if (GTK_WIDGET_CLASS (parent_class)->expose_event)
     GTK_WIDGET_CLASS (parent_class)->expose_event (w, event);
 
-  if (0)
-  {
-    GdkDrawable                *drawable;
-    gint                        x_offset, y_offset;
-    XRenderColor                color = {0};
-    XRenderPictFormat          *format;
-    XRenderPictureAttributes    pa;
-    XRectangle                  rect;
-    Picture                     picture;
-
-    gdk_window_get_internal_paint_info (w->window,
-                                        &drawable,
-                                        &x_offset,
-                                        &y_offset);
-
-    format = XRenderFindVisualFormat (GDK_DISPLAY(),
-                                        GDK_VISUAL_XVISUAL (gdk_drawable_get_visual (drawable)));
-
-    pa.subwindow_mode = IncludeInferiors;
-
-    picture = XRenderCreatePicture (GDK_DISPLAY (),
-                                    GDK_DRAWABLE_XID (drawable),
-                                    format,
-                                    CPSubwindowMode,
-                                    &pa);
-
-    rect.x = rect.y = 0;
-    rect.width = w->allocation.width;
-    rect.height = w->allocation.height;
-
-    XRenderFillRectangles (GDK_DISPLAY (),
-                           PictOpSrc,
-                           picture,
-                           &color,
-                           &rect,
-                           1);
-  }
-
   if (w->parent && (priv->layout_mode || priv->layout_mode_sucks))
     {
       /* Draw the rectangle around */
@@ -1146,10 +1108,10 @@
 
   priv = HILDON_DESKTOP_HOME_ITEM_GET_PRIVATE (applet);
   widget = GTK_WIDGET (applet);
-  
+
   if (priv->layout_mode_sucks)
     return;
-  
+
   priv->layout_mode = FALSE;
 
   if (priv->close_button_window)
@@ -1467,6 +1429,8 @@
                         event->time);
 
       priv->old_allocation = w->allocation;
+      priv->delta_x = 0;
+      priv->delta_y = 0;
 
       if (event->window == priv->resize_handle_window)
         {

Modified: projects/haf/trunk/hildon-desktop/libhildondesktop/hildon-home-area.c
===================================================================
--- projects/haf/trunk/hildon-desktop/libhildondesktop/hildon-home-area.c	2007-06-04 13:18:28 UTC (rev 12090)
+++ projects/haf/trunk/hildon-desktop/libhildondesktop/hildon-home-area.c	2007-06-04 15:41:03 UTC (rev 12091)
@@ -757,6 +757,7 @@
       border_width = GTK_CONTAINER (area)->border_width;
 
       gtk_widget_get_child_requisition (child->widget, &child_requisition);
+
       child_allocation.x = widget->allocation.x + child->x + border_width;
       child_allocation.y = widget->allocation.y + child->y + border_width;
 
@@ -1201,10 +1202,6 @@
   if (!GTK_WIDGET_REALIZED (child))
     return;
 
-  gtk_widget_style_get (child,
-                        "background-borders", &borders,
-                        NULL);
-
   gtk_container_child_get (GTK_CONTAINER (area), child,
                            "child-data", &child_data,
                            NULL);
@@ -1221,6 +1218,10 @@
 
   child_data->alpha_mask = None;
 
+  gtk_widget_style_get (child,
+                        "background-borders", &borders,
+                        NULL);
+
   if (borders && child_data->alpha_mask_unscaled)
     {
       Pixmap                    p;
@@ -1233,7 +1234,10 @@
       h = child->allocation.height;
 
       if (w < 0 || h < 0)
-        return;
+        {
+          g_free (borders);
+          return;
+        }
 
       center_w = w - borders->left - borders->right;
       center_h = h - borders->top  - borders->bottom;
@@ -1244,6 +1248,7 @@
       if (scenter_h < 0 || scenter_w < 0)
         {
           g_warning ("Invalid border values, alpha mask will not be applied");
+          g_free (borders);
           return;
         }
 

Modified: projects/haf/trunk/hildon-desktop/src/hd-panel-window.c
===================================================================
--- projects/haf/trunk/hildon-desktop/src/hd-panel-window.c	2007-06-04 13:18:28 UTC (rev 12090)
+++ projects/haf/trunk/hildon-desktop/src/hd-panel-window.c	2007-06-04 15:41:03 UTC (rev 12091)
@@ -432,6 +432,8 @@
                                          TRUE);
            }
         }
+
+      XFree (rects);
     }
 
   return GDK_FILTER_CONTINUE;


More information about the maemo-commits mailing list