Make full moniker (apply_settings): Release the return value (main):

2001-07-10  Bradford Hovinen  <hovinen@ximian.com>

	* sound-properties-capplet.c (set_moniker_cb): Make full moniker
	(apply_settings): Release the return value
	(main): Support --get-legacy option
	(get_legacy_settings): Implement
	(create_control_cb): Connect apply_cb
	(COPY_FROM_LEGACY): Use bonobo_config_set_...
	(main): Open config database regardless of what operation is
	requested; pass to create_control callback
	(apply_settings): Use bonobo_config_get_...
	(get_legacy_settings):
	(apply_settings): Don't accept CORBA_Environment *ev any more
	(create_control_cb): Store the config database in the property control
	(apply_settings): Use the correct setting name
	(apply_cb): Apply settings and sync
	(apply_settings): Kill esd when requested

	* capplet-dir.c (capplet_ok_cb): Notify property control of apply
	action
	(capplet_control_launch): Store PropertyControl in app
This commit is contained in:
Bradford Hovinen 2001-07-10 18:27:43 +00:00 committed by Bradford Hovinen (Gdict maintainer)
parent dde0a2329b
commit 858feb0824
5 changed files with 144 additions and 40 deletions

View file

@ -384,7 +384,16 @@ get_root_capplet_dir (void)
static void
capplet_ok_cb (GtkWidget *widget, GtkWidget *app)
{
CORBA_Environment ev;
Bonobo_PropertyControl pc;
CORBA_exception_init (&ev);
pc = gtk_object_get_data (GTK_OBJECT (app), "property-control");
Bonobo_PropertyControl_notifyAction (pc, 0, Bonobo_PropertyControl_APPLY, &ev);
gtk_widget_destroy (app);
CORBA_exception_free (&ev);
}
static void
@ -443,6 +452,7 @@ capplet_control_launch (const gchar *capplet_name)
/* FIXME: Use a human-readable capplet name here */
app = gnome_dialog_new (_("Capplet"), GNOME_STOCK_BUTTON_OK,
GNOME_STOCK_BUTTON_CANCEL, NULL);
gtk_object_set_data (GTK_OBJECT (app), "property-control", property_control);
control = bonobo_widget_new_control_from_objref (control_ref, CORBA_OBJECT_NIL);
if (control == NULL) {