diff options
author | Leonardo Boshell <leonardop@gentoo.org> | 2003-10-10 15:08:03 +0000 |
---|---|---|
committer | Leonardo Boshell <leonardop@gentoo.org> | 2003-10-10 15:08:03 +0000 |
commit | 84372d08edf8064f526c05258b575c863d8961c2 (patch) | |
tree | fcfdbb22016ef526cd07d929b430d164f88d34ea | |
parent | Patch for bug #30809 (diff) | |
download | gentoo-2-84372d08edf8064f526c05258b575c863d8961c2.tar.gz gentoo-2-84372d08edf8064f526c05258b575c863d8961c2.tar.bz2 gentoo-2-84372d08edf8064f526c05258b575c863d8961c2.zip |
Patch for bug #30809
-rw-r--r-- | gnome-base/gnome-panel/ChangeLog | 8 | ||||
-rw-r--r-- | gnome-base/gnome-panel/Manifest | 4 | ||||
-rw-r--r-- | gnome-base/gnome-panel/files/digest-gnome-panel-2.4.0-r2 | 1 | ||||
-rw-r--r-- | gnome-base/gnome-panel/files/gnome-panel-2.4.0-drawers_fix.patch | 214 | ||||
-rw-r--r-- | gnome-base/gnome-panel/gnome-panel-2.4.0-r2.ebuild | 68 |
5 files changed, 292 insertions, 3 deletions
diff --git a/gnome-base/gnome-panel/ChangeLog b/gnome-base/gnome-panel/ChangeLog index b598c26d4947..b5095c8bd998 100644 --- a/gnome-base/gnome-panel/ChangeLog +++ b/gnome-base/gnome-panel/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for gnome-base/gnome-panel # Copyright 2002-2003 Gentoo Technologies, Inc.; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/gnome-base/gnome-panel/ChangeLog,v 1.55 2003/10/08 15:47:22 obz Exp $ +# $Header: /var/cvsroot/gentoo-x86/gnome-base/gnome-panel/ChangeLog,v 1.56 2003/10/10 15:07:57 leonardop Exp $ + +*gnome-panel-2.4.0-r2 (10 Oct 2003) + + 10 Oct 2003; L. Boshell <leonardop@gentoo.org> gnome-panel-2.4.0-r2.ebuild, + gnome-panel-2.4.0-drawers_fix.patch: + Added patch to fix a problem with the drawers. Related bug: #30809. 08 Oct 2003; Mike Gardiner <obz@gentoo.org> gnome-panel-2.4.0-r1.ebuild: Commented out USE='menu' related patch and IUSE for the moment diff --git a/gnome-base/gnome-panel/Manifest b/gnome-base/gnome-panel/Manifest index 21d70363f4e7..df2d9a0580b1 100644 --- a/gnome-base/gnome-panel/Manifest +++ b/gnome-base/gnome-panel/Manifest @@ -1,8 +1,8 @@ -MD5 e3312cea67923527f2a4c7455f3cdcb0 ChangeLog 7284 +MD5 54e535bbeeb1f1a6464252f538c4615e ChangeLog 7515 MD5 1c41d01742b08320a5080625b7862d11 gnome-panel-1.4.1.ebuild 1774 MD5 1272743bcce046b4520549f4e2c297f3 gnome-panel-2.2.1.ebuild 967 MD5 95daeb28a4a553527a9b88656a058732 gnome-panel-2.2.2.ebuild 975 -MD5 bdd18e3fbf55c75ce8d056b619ee8810 gnome-panel-2.4.0-r2.ebuild 1709 +MD5 a58247f8f04f4496f73328f93ee9ab6c gnome-panel-2.4.0-r2.ebuild 1714 MD5 03ad2e6c4ab41244af1015a8bbb0b39f metadata.xml 158 MD5 623e3c1deaace4f7ecea86edb2de8e71 gnome-panel-2.0.9.ebuild 1264 MD5 eb58dda325007520bcfc41d8f435dd60 gnome-panel-2.2.2.2.ebuild 960 diff --git a/gnome-base/gnome-panel/files/digest-gnome-panel-2.4.0-r2 b/gnome-base/gnome-panel/files/digest-gnome-panel-2.4.0-r2 new file mode 100644 index 000000000000..155f0241468a --- /dev/null +++ b/gnome-base/gnome-panel/files/digest-gnome-panel-2.4.0-r2 @@ -0,0 +1 @@ +MD5 9a81f7ebbb450611a28783900f5f2cbc gnome-panel-2.4.0.tar.bz2 2641373 diff --git a/gnome-base/gnome-panel/files/gnome-panel-2.4.0-drawers_fix.patch b/gnome-base/gnome-panel/files/gnome-panel-2.4.0-drawers_fix.patch new file mode 100644 index 000000000000..703b61f60375 --- /dev/null +++ b/gnome-base/gnome-panel/files/gnome-panel-2.4.0-drawers_fix.patch @@ -0,0 +1,214 @@ +diff -NurB gnome-panel-2.4.0-orig/gnome-panel/button-widget.c gnome-panel-2.4.0/gnome-panel/button-widget.c +--- gnome-panel-2.4.0-orig/gnome-panel/button-widget.c 2003-10-10 08:38:39.000000000 -0500 ++++ gnome-panel-2.4.0/gnome-panel/button-widget.c 2003-10-10 08:39:11.000000000 -0500 +@@ -37,68 +37,6 @@ + + static GObjectClass *parent_class; + +-static void +-translate_to(GtkWidget *from, GtkWidget *to, int *x, int *y) +-{ +- while (from != to) { +- if (!GTK_WIDGET_NO_WINDOW (from)) { +- *x += MAX (from->allocation.x, 0); +- *y += MAX (from->allocation.y, 0); +- } +- from = from->parent; +- } +-} +- +-static void +-calculate_overlay_geometry (PanelWidget *panel, +- GtkWidget *parent, +- GtkWidget *applet, +- int *x, +- int *y, +- int *w, +- int *h) +-{ +- *x = applet->allocation.x; +- *y = applet->allocation.y; +- *w = applet->allocation.width; +- *h = applet->allocation.height; +- +- translate_to (GTK_WIDGET(panel), parent, x, y); +- +- if(panel->orient == GTK_ORIENTATION_HORIZONTAL) { +- if (applet->allocation.x > panel->size) { +- *x = parent->requisition.width + 1; +- *y = parent->requisition.height + 1; +- return; +- } +- +- *y = 0; +- /* we use the requisition, since allocation might have not +- yet happened if we are inside the allocation, anyway +- they are the same for basep */ +- if(*h < parent->requisition.height) +- *h = parent->requisition.height; +- +- if ((*w + applet->allocation.x) > panel->size) { +- *w = panel->size - applet->allocation.x; +- } +- } else { +- if (applet->allocation.y > panel->size) { +- *x = parent->requisition.width + 1; +- *y = parent->requisition.height + 1; +- return; +- } +- +- *x = 0; +- if(*w < parent->requisition.width) +- *w = parent->requisition.width; +- +- if ((*h + applet->allocation.y) > panel->size) { +- *h = panel->size - applet->allocation.y; +- } +- } +-} +- + /* colorshift a pixbuf */ + static void + do_colorshift (GdkPixbuf *dest, GdkPixbuf *src, int shift) +@@ -163,27 +101,19 @@ + GdkWindowAttr attributes; + gint attributes_mask; + GtkButton *button; +- PanelWidget *panel; +- GtkWidget *parent; +- int x,y,w,h; + + g_return_if_fail (widget != NULL); + g_return_if_fail (BUTTON_IS_WIDGET (widget)); + +- panel = PANEL_WIDGET(widget->parent); +- parent = GTK_WIDGET (panel->toplevel); +- +- calculate_overlay_geometry(panel, parent, widget, &x, &y, &w, &h); +- + button = GTK_BUTTON (widget); + + GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + + attributes.window_type = GDK_WINDOW_CHILD; +- attributes.x = x; +- attributes.y = y; +- attributes.width = w; +- attributes.height = h; ++ attributes.x = widget->allocation.x; ++ attributes.y = widget->allocation.y; ++ attributes.width = widget->allocation.width; ++ attributes.height = widget->allocation.height; + attributes.wclass = GDK_INPUT_ONLY; + attributes.event_mask = (GDK_BUTTON_PRESS_MASK | + GDK_BUTTON_RELEASE_MASK | +@@ -194,10 +124,10 @@ + GDK_LEAVE_NOTIFY_MASK); + attributes_mask = GDK_WA_X | GDK_WA_Y; + +- widget->window = gtk_widget_get_parent_window(widget); ++ widget->window = gtk_widget_get_parent_window (widget); + g_object_ref (G_OBJECT (widget->window)); + +- button->event_window = gdk_window_new (parent->window, ++ button->event_window = gdk_window_new (gtk_widget_get_parent_window (widget), + &attributes, + attributes_mask); + gdk_window_set_user_data (button->event_window, widget); +@@ -206,24 +136,26 @@ + } + + static void +-button_widget_parent_set (GtkWidget *widget, +- GtkWidget *previous_parent) ++button_widget_unrealize (GtkWidget *widget) + { ++ GtkButton *button; ++ PanelWidget *panel; + GtkWidget *parent; +- int x, y, w, h; + ++ g_return_if_fail (widget != NULL); + g_return_if_fail (BUTTON_IS_WIDGET (widget)); + +- if (!GTK_WIDGET_REALIZED (widget)|| !widget->parent) +- return; +- +- parent = GTK_WIDGET (PANEL_WIDGET (widget->parent)->toplevel); ++ panel = PANEL_WIDGET (widget->parent); ++ parent = GTK_WIDGET (panel->toplevel); ++ button = GTK_BUTTON (widget); + +- calculate_overlay_geometry ( +- PANEL_WIDGET (widget->parent), parent, widget, &x, &y, &w, &h); ++ if (button->event_window != NULL) { ++ gdk_window_set_user_data (button->event_window, NULL); ++ gdk_window_destroy (button->event_window); ++ button->event_window = NULL; ++ } + +- gdk_window_reparent ( +- GTK_BUTTON (widget)->event_window, parent->window, x, y); ++ GTK_WIDGET_CLASS (parent_class)->unrealize (widget); + } + + static void +@@ -489,10 +421,8 @@ + if (string_empty (file)) + return NULL; + +- if (g_path_is_absolute (file)) +- retval = load_pixbuf (file, PREFERRED_SIZE, error); +- +- if (retval == NULL) { ++ retval = load_pixbuf (file, PREFERRED_SIZE, NULL); ++ if (!retval) { + char *tmp; + + if (error && *error) { +@@ -686,15 +616,14 @@ + + if (GTK_WIDGET_REALIZED (widget)) { + PanelWidget *panel; +- int x, y, w, h; + + panel = PANEL_WIDGET (widget->parent); + +- calculate_overlay_geometry ( +- panel, GTK_WIDGET (panel->toplevel), +- widget, &x, &y, &w, &h); +- +- gdk_window_move_resize (button->event_window, x, y, w, h); ++ gdk_window_move_resize (button->event_window, ++ allocation->x, ++ allocation->y, ++ allocation->width, ++ allocation->height); + } + } + +@@ -731,10 +660,14 @@ + static gboolean + button_widget_enter_notify (GtkWidget *widget, GdkEventCrossing *event) + { ++ gboolean in_button; ++ + g_return_val_if_fail (BUTTON_IS_WIDGET (widget), FALSE); + ++ in_button = GTK_BUTTON (widget)->in_button; + GTK_WIDGET_CLASS (parent_class)->enter_notify_event (widget, event); +- if (GTK_BUTTON (widget)->in_button) ++ if (in_button != GTK_BUTTON (widget)->in_button && ++ panel_global_config_get_highlight_when_over ()) + gtk_widget_queue_draw (widget); + + return FALSE; +@@ -818,7 +751,7 @@ + gobject_class->set_property = button_widget_set_property; + + widget_class->realize = button_widget_realize; +- widget_class->parent_set = button_widget_parent_set; ++ widget_class->unrealize = button_widget_unrealize; + widget_class->size_allocate = button_widget_size_allocate; + widget_class->size_request = button_widget_size_request; + widget_class->button_press_event = button_widget_button_press; diff --git a/gnome-base/gnome-panel/gnome-panel-2.4.0-r2.ebuild b/gnome-base/gnome-panel/gnome-panel-2.4.0-r2.ebuild new file mode 100644 index 000000000000..df8ea9f05208 --- /dev/null +++ b/gnome-base/gnome-panel/gnome-panel-2.4.0-r2.ebuild @@ -0,0 +1,68 @@ +# Copyright 1999-2003 Gentoo Technologies, Inc. +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/gnome-base/gnome-panel/gnome-panel-2.4.0-r2.ebuild,v 1.1 2003/10/10 15:07:57 leonardop Exp $ + +inherit gnome2 eutils + +SLOT="0" + +DESCRIPTION="The Panel for Gnome2" +HOMEPAGE="http://www.gnome.org/" + +LICENSE="GPL-2 FDL-1.1 LGPL-2" +KEYWORDS="~x86 ~ppc ~alpha ~sparc ~hppa ~amd64" + +# IUSE="doc menu" +IUSE="doc" +MAKEOPTS="${MAKEOPTS} -j1" + +RDEPEND=">=x11-libs/gtk+-2.1 + >=x11-libs/libwnck-2.3 + >=gnome-base/ORBit2-2.4 + >=gnome-base/gnome-vfs-2.3 + >=gnome-base/gnome-desktop-2.3 + >=gnome-base/libbonoboui-2.1.1 + >=gnome-base/libglade-2 + >=gnome-base/libgnome-2.1.1 + >=gnome-base/libgnomeui-2.1 + >=gnome-base/gconf-2.3.1 + !gnome-extra/system-tray-applet" + +DEPEND="${RDEPEND} + >=app-text/scrollkeeper-0.3.11 + >=dev-util/pkgconfig-0.12.0 + >=dev-util/intltool-0.21 + doc? ( >=dev-util/gtk-doc-0.9 )" + +DOCS="AUTHORS COPYING* ChangeLog HACKING INSTALL NEWS README" + +src_unpack() { + + unpack ${A} + + cd ${S} + # use menu && epatch ${FILESDIR}/menu-${PV}.patch + # fix initial menu size + epatch ${FILESDIR}/${PN}-2.4-panel_size.patch + + # Fix for drawers problems. (Bug #30809) + epatch ${FILESDIR}/${PN}-${PV}-drawers_fix.patch + + sed -i 's:--load:-v:' gnome-panel/Makefile.am + + WANT_AUTOMAKE=1.4 automake || die + + # FIXME : uh yeah, this is nice + touch gnome-panel/blah + chmod +x gnome-panel/blah +} + +pkg_postinst() { + + gnome2_pkg_postinst + + einfo "setting panel gconf defaults..." + GCONF_CONFIG_SOURCE=`${ROOT}/usr/bin/gconftool-2 --get-default-source` + ${ROOT}/usr/bin/gconftool-2 --direct --config-source ${GCONF_CONFIG_SOURCE} --load=${S}/gnome-panel/panel-default-setup.entries + +} |