Return NULL in the case that the control is already present
2001-07-13 Bradford Hovinen <hovinen@ximian.com> * capplet-util.c (create_dialog_cb): Return NULL in the case that the control is already present * capplet-dir.c (capplet_control_launch): Accept window_title parameter and use it as the title (capplet_activate): Pass entry->name to capplet_control_launch (capplet_control_launch): Don't print error and use correct test for control_ref == CORBA_OBJECT_NIL
This commit is contained in:
parent
fa695ff9ee
commit
8459555f65
4 changed files with 10 additions and 3 deletions
|
@ -0,0 +1,5 @@
|
|||
2001-07-13 Bradford Hovinen <hovinen@ximian.com>
|
||||
|
||||
* capplet-util.c (create_dialog_cb): Return NULL in the case that
|
||||
the control is already present
|
||||
|
|
@ -194,7 +194,7 @@ create_dialog_cb (BonoboPropertyControl *property_control, gint page_number)
|
|||
gtk_signal_connect (GTK_OBJECT (control), "destroy",
|
||||
GTK_SIGNAL_FUNC (close_cb), NULL);
|
||||
} else {
|
||||
gtk_widget_show_all (widget);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
return BONOBO_OBJECT (control);
|
||||
|
|
|
@ -3,6 +3,8 @@
|
|||
* capplet-dir.c (capplet_control_launch): Accept window_title
|
||||
parameter and use it as the title
|
||||
(capplet_activate): Pass entry->name to capplet_control_launch
|
||||
(capplet_control_launch): Don't print error and use correct test
|
||||
for control_ref == CORBA_OBJECT_NIL
|
||||
|
||||
2001-07-13 Kai Lahmann <kl@linuxfaqs.de>
|
||||
|
||||
|
|
|
@ -442,8 +442,8 @@ capplet_control_launch (const gchar *capplet_name, gchar *window_title)
|
|||
|
||||
control_ref = Bonobo_PropertyControl_getControl (property_control, 0, &ev);
|
||||
|
||||
if (BONOBO_EX (&ev) || property_control == CORBA_OBJECT_NIL) {
|
||||
g_critical ("Could not extract control from PropertyControl");
|
||||
if (BONOBO_EX (&ev) || control_ref == CORBA_OBJECT_NIL) {
|
||||
/* Capplet is already running in this case */
|
||||
bonobo_object_release_unref (property_control, &ev);
|
||||
g_free (moniker);
|
||||
return NULL;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue