If the shell fails to display all of the requested URIs, fall back to
the default URI (Summary). svn path=/trunk/; revision=16404
This commit is contained in:
@ -1,7 +1,8 @@
|
||||
2002-04-09 Dan Winship <danw@ximian.com>
|
||||
|
||||
* main.c (idle_cb): Check for "default:" URIs and treat them the
|
||||
same way as "evolution:" URIs.
|
||||
same way as "evolution:" URIs. If the shell fails to display all
|
||||
of the requested URIs, fall back to the default URI (Summary).
|
||||
|
||||
* e-shell.c (impl_Shell_handleURI): Handle "default:" URIs by
|
||||
looking up the default folders in the config db.
|
||||
|
30
shell/main.c
30
shell/main.c
@ -191,6 +191,7 @@ idle_cb (void *data)
|
||||
GSList *p;
|
||||
gboolean have_evolution_uri;
|
||||
gboolean display_default;
|
||||
gboolean displayed_any;
|
||||
|
||||
CORBA_exception_init (&ev);
|
||||
|
||||
@ -271,7 +272,23 @@ idle_cb (void *data)
|
||||
}
|
||||
}
|
||||
|
||||
if (display_default) {
|
||||
displayed_any = FALSE;
|
||||
for (p = uri_list; p != NULL; p = p->next) {
|
||||
const char *uri;
|
||||
|
||||
uri = (const char *) p->data;
|
||||
GNOME_Evolution_Shell_handleURI (corba_shell, uri, &ev);
|
||||
if (ev._major == CORBA_NO_EXCEPTION)
|
||||
displayed_any = TRUE;
|
||||
else {
|
||||
g_warning ("CORBA exception %s when requesting URI -- %s", ev._repo_id, uri);
|
||||
CORBA_exception_free (&ev);
|
||||
}
|
||||
}
|
||||
|
||||
g_slist_free (uri_list);
|
||||
|
||||
if (display_default || !displayed_any) {
|
||||
const char *uri;
|
||||
|
||||
uri = E_SHELL_VIEW_DEFAULT_URI;
|
||||
@ -280,17 +297,6 @@ idle_cb (void *data)
|
||||
g_warning ("CORBA exception %s when requesting URI -- %s", ev._repo_id, uri);
|
||||
}
|
||||
|
||||
for (p = uri_list; p != NULL; p = p->next) {
|
||||
const char *uri;
|
||||
|
||||
uri = (const char *) p->data;
|
||||
GNOME_Evolution_Shell_handleURI (corba_shell, uri, &ev);
|
||||
if (ev._major != CORBA_NO_EXCEPTION)
|
||||
g_warning ("CORBA exception %s when requesting URI -- %s", ev._repo_id, uri);
|
||||
}
|
||||
|
||||
g_slist_free (uri_list);
|
||||
|
||||
CORBA_Object_release (corba_shell, &ev);
|
||||
|
||||
CORBA_exception_free (&ev);
|
||||
|
Reference in New Issue
Block a user