[Xfce4-commits] <xfce4-panel:master> Delay connecting the provider-signal in 4.6 plugins.
Nick Schermer
noreply at xfce.org
Mon May 10 22:52:03 CEST 2010
Updating branch refs/heads/master
to 5714d3af6c0281917462f36494edf8c18bb8d18e (commit)
from fef3e03524e957851643160017eab75728aef516 (commit)
commit 5714d3af6c0281917462f36494edf8c18bb8d18e
Author: Nick Schermer <nick at xfce.org>
Date: Mon May 10 22:51:18 2010 +0200
Delay connecting the provider-signal in 4.6 plugins.
libxfce4panel/xfce-panel-macros-46.h | 11 +++++++----
1 files changed, 7 insertions(+), 4 deletions(-)
diff --git a/libxfce4panel/xfce-panel-macros-46.h b/libxfce4panel/xfce-panel-macros-46.h
index e29acad..482f614 100644
--- a/libxfce4panel/xfce-panel-macros-46.h
+++ b/libxfce4panel/xfce-panel-macros-46.h
@@ -422,13 +422,18 @@ enum /*< skip >*/
} \
\
static void \
- _xpp_realize (XfcePanelPlugin *xpp) \
+ _xpp_realize (XfcePanelPlugin *xpp, \
+ GtkPlug *plug) \
{ \
g_return_if_fail (XFCE_IS_PANEL_PLUGIN (xpp)); \
+ g_return_if_fail (GTK_IS_PLUG (plug)); \
\
g_signal_handlers_disconnect_by_func (G_OBJECT (xpp), \
G_CALLBACK (_xpp_realize), NULL); \
\
+ g_signal_connect (G_OBJECT (xpp), "provider-signal", \
+ G_CALLBACK (_xpp_provider_signal), plug); \
+ \
((XfcePanelPluginFunc) construct_func) (xpp); \
} \
\
@@ -585,11 +590,9 @@ enum /*< skip >*/
"arguments", argv + PLUGIN_ARGV_ARGUMENTS, NULL); \
gtk_container_add (GTK_CONTAINER (plug), xpp); \
g_signal_connect_after (G_OBJECT (xpp), "realize", \
- G_CALLBACK (_xpp_realize), NULL); \
+ G_CALLBACK (_xpp_realize), plug); \
g_signal_connect_after (G_OBJECT (xpp), "destroy", \
G_CALLBACK (_xpp_quit_main_loop), NULL); \
- g_signal_connect (G_OBJECT (xpp), "provider-signal", \
- G_CALLBACK (_xpp_provider_signal), plug); \
gtk_widget_show (xpp); \
\
if (*argv[PLUGIN_ARGV_BACKGROUND_IMAGE] != '\0') \
More information about the Xfce4-commits
mailing list