summaryrefslogtreecommitdiff
path: root/src/nautilus-component-adapter-factory.c
diff options
context:
space:
mode:
authorMaciej Stachowiak <mstachow@src.gnome.org>2000-11-13 16:22:19 +0000
committerMaciej Stachowiak <mstachow@src.gnome.org>2000-11-13 16:22:19 +0000
commitfe3a8f5e6f741b3b019fa355b5a4459ee42a62a6 (patch)
treecbf90ce867ee862829ffed4eefa0b9ed6c7b2aa1 /src/nautilus-component-adapter-factory.c
parent5777ef2437db9cc2c34c44bc613995e5f22c91ad (diff)
downloadnautilus-fe3a8f5e6f741b3b019fa355b5a4459ee42a62a6.tar.gz
Updated based on running check-THANKS.pl Fixed some typos in people's
* THANKS: Updated based on running check-THANKS.pl * AUTHORS, ChangeLog-200001018: Fixed some typos in people's email addresses. Fix bugs 3641 (text preview gets garbled when switching files in the middle of a load) and 3479 (Nautilus crashes if nautilus-adapter* missing). * components/adapter/nautilus-adapter-progressive-load-strategy.c (call_when_stopped, load_and_free_uri, declare_done_loading, stop_loading, nautilus_adapter_progressive_load_strategy_load_location): Make sure previous load is completely stopped before ever starting a new load. * components/adapter/nautilus-adapter.c: (nautilus_adapter_destroy, nautilus_adapter_new): Avoid reporting signals to the view frame while in the middle of destroying the adapter. * src/nautilus-component-adapter-factory.c (nautilus_component_adapter_factory_get): Return NULL when loading the adapter factory component fails. (nautilus_component_adapter_factory_initialize, component_adapter_factory_at_exit_destructor): Changes required by the above. * src/nautilus-view-frame.c (nautilus_view_frame_set_to_component): report failure if we can't load the adapter factory. * src/nautilus-window-manage-views.c (report_content_view_failure_to_user, load_content_view, handle_view_failure, nautilus_window_set_sidebar_panels): Do a somewhat better job of reporting view load failures.
Diffstat (limited to 'src/nautilus-component-adapter-factory.c')
-rw-r--r--src/nautilus-component-adapter-factory.c14
1 files changed, 11 insertions, 3 deletions
diff --git a/src/nautilus-component-adapter-factory.c b/src/nautilus-component-adapter-factory.c
index 000cef471..0445b7dbb 100644
--- a/src/nautilus-component-adapter-factory.c
+++ b/src/nautilus-component-adapter-factory.c
@@ -72,8 +72,6 @@ nautilus_component_adapter_factory_initialize (NautilusComponentAdapterFactory *
(BONOBO_OBJECT (object_client), "IDL:Nautilus/ComponentAdapterFactory:1.0");
bonobo_object_unref (BONOBO_OBJECT (object_client));
}
-
- /* FIXME: Since corba_factory could now be NULL, what do we do in that case? */
}
@@ -98,7 +96,11 @@ static NautilusComponentAdapterFactory *global_component_adapter_factory = NULL;
static void
component_adapter_factory_at_exit_destructor (void)
{
- gtk_object_unref (GTK_OBJECT (global_component_adapter_factory));
+ if (global_component_adapter_factory != NULL) {
+ gtk_object_unref (GTK_OBJECT (global_component_adapter_factory));
+ }
+
+ global_component_adapter_factory = NULL;
}
@@ -114,6 +116,12 @@ nautilus_component_adapter_factory_get (void)
g_atexit (component_adapter_factory_at_exit_destructor);
}
+
+ if (global_component_adapter_factory->details->corba_factory == CORBA_OBJECT_NIL) {
+ gtk_object_unref (GTK_OBJECT (global_component_adapter_factory));
+ global_component_adapter_factory = NULL;
+ }
+
return global_component_adapter_factory;
}