evolution r37294 - in branches/kill-bonobo: addressbook/gui/component calendar/modules doc/reference/shell/tmpl mail shell smime/gui
- From: mbarnes svn gnome org
- To: svn-commits-list gnome org
- Subject: evolution r37294 - in branches/kill-bonobo: addressbook/gui/component calendar/modules doc/reference/shell/tmpl mail shell smime/gui
- Date: Thu, 19 Feb 2009 06:22:32 +0000 (UTC)
Author: mbarnes
Date: Thu Feb 19 06:22:32 2009
New Revision: 37294
URL: http://svn.gnome.org/viewvc/evolution?rev=37294&view=rev
Log:
Documentation tweaks.
Have e_shell_get_preferences_window() take an EShell argument.
Modified:
branches/kill-bonobo/addressbook/gui/component/autocompletion-config.c
branches/kill-bonobo/calendar/modules/e-cal-shell-module.c
branches/kill-bonobo/doc/reference/shell/tmpl/e-shell.sgml
branches/kill-bonobo/mail/e-mail-shell-module.c
branches/kill-bonobo/shell/e-shell-window-actions.c
branches/kill-bonobo/shell/e-shell-window.c
branches/kill-bonobo/shell/e-shell.c
branches/kill-bonobo/shell/e-shell.h
branches/kill-bonobo/smime/gui/certificate-manager.c
Modified: branches/kill-bonobo/addressbook/gui/component/autocompletion-config.c
==============================================================================
--- branches/kill-bonobo/addressbook/gui/component/autocompletion-config.c (original)
+++ branches/kill-bonobo/addressbook/gui/component/autocompletion-config.c Thu Feb 19 06:22:32 2009
@@ -99,6 +99,7 @@
GtkWidget *scrolled_window;
GtkWidget *source_selector;
GtkWidget *preferences_window;
+ EShell *shell;
source_list = e_source_list_new_for_gconf_default (
"/apps/evolution/addressbook/sources");
@@ -124,7 +125,8 @@
initialize_selection (E_SOURCE_SELECTOR (source_selector));
- preferences_window = e_shell_get_preferences_window ();
+ shell = e_shell_get_default ();
+ preferences_window = e_shell_get_preferences_window (shell);
e_preferences_window_add_page (
E_PREFERENCES_WINDOW (preferences_window),
Modified: branches/kill-bonobo/calendar/modules/e-cal-shell-module.c
==============================================================================
--- branches/kill-bonobo/calendar/modules/e-cal-shell-module.c (original)
+++ branches/kill-bonobo/calendar/modules/e-cal-shell-module.c Thu Feb 19 06:22:32 2009
@@ -431,8 +431,10 @@
cal_module_init_preferences (void)
{
GtkWidget *preferences_window;
+ EShell *shell;
- preferences_window = e_shell_get_preferences_window ();
+ shell = e_shell_get_default ();
+ preferences_window = e_shell_get_preferences_window (shell);
e_preferences_window_add_page (
E_PREFERENCES_WINDOW (preferences_window),
Modified: branches/kill-bonobo/doc/reference/shell/tmpl/e-shell.sgml
==============================================================================
--- branches/kill-bonobo/doc/reference/shell/tmpl/e-shell.sgml (original)
+++ branches/kill-bonobo/doc/reference/shell/tmpl/e-shell.sgml Thu Feb 19 06:22:32 2009
@@ -247,6 +247,7 @@
</para>
+ shell:
@Returns:
Modified: branches/kill-bonobo/mail/e-mail-shell-module.c
==============================================================================
--- branches/kill-bonobo/mail/e-mail-shell-module.c (original)
+++ branches/kill-bonobo/mail/e-mail-shell-module.c Thu Feb 19 06:22:32 2009
@@ -483,7 +483,7 @@
{
GtkWidget *preferences_window;
- preferences_window = e_shell_get_preferences_window ();
+ preferences_window = e_shell_get_preferences_window (shell);
e_preferences_window_add_page (
E_PREFERENCES_WINDOW (preferences_window),
Modified: branches/kill-bonobo/shell/e-shell-window-actions.c
==============================================================================
--- branches/kill-bonobo/shell/e-shell-window-actions.c (original)
+++ branches/kill-bonobo/shell/e-shell-window-actions.c Thu Feb 19 06:22:32 2009
@@ -888,9 +888,12 @@
action_preferences_cb (GtkAction *action,
EShellWindow *shell_window)
{
+ EShell *shell;
GtkWidget *preferences_window;
- preferences_window = e_shell_get_preferences_window ();
+ shell = e_shell_window_get_shell (shell_window);
+ preferences_window = e_shell_get_preferences_window (shell);
+
gtk_window_set_transient_for (
GTK_WINDOW (preferences_window),
GTK_WINDOW (shell_window));
Modified: branches/kill-bonobo/shell/e-shell-window.c
==============================================================================
--- branches/kill-bonobo/shell/e-shell-window.c (original)
+++ branches/kill-bonobo/shell/e-shell-window.c Thu Feb 19 06:22:32 2009
@@ -490,9 +490,8 @@
*
* An #EShellWindow creates a #GtkRadioAction for each registered subclass
* of #EShellView. This action gets passed to the #EShellSwitcher, which
- * displays a button that proxies the action. The icon at the top of the
- * sidebar also proxies the action. When the #EShellView named @view_name
- * is active, the action's icon becomes the @shell_window icon.
+ * displays a button that proxies the action. When the #EShellView named
+ * @view_name is active, the action's icon becomes the @shell_window icon.
*
* Returns: the switcher action for the #EShellView named @view_name,
* or %NULL if no such shell view exists
Modified: branches/kill-bonobo/shell/e-shell.c
==============================================================================
--- branches/kill-bonobo/shell/e-shell.c (original)
+++ branches/kill-bonobo/shell/e-shell.c Thu Feb 19 06:22:32 2009
@@ -41,6 +41,7 @@
GList *watched_windows;
EShellSettings *settings;
GConfClient *gconf_client;
+ GtkWidget *preferences_window;
/* Shell Modules */
GList *loaded_modules;
@@ -465,6 +466,11 @@
priv->gconf_client = NULL;
}
+ if (priv->preferences_window != NULL) {
+ g_object_unref (priv->preferences_window);
+ priv->preferences_window = NULL;
+ }
+
g_list_foreach (
priv->loaded_modules,
(GFunc) g_type_module_unuse, NULL);
@@ -771,7 +777,7 @@
* EShell::window-destroyed
* @shell: the #EShell which emitted the signal
*
- * Emitted when an #EShellWindow is destroyed.
+ * Emitted when a watched is destroyed.
**/
signals[WINDOW_DESTROYED] = g_signal_new (
"window-destroyed",
@@ -837,6 +843,7 @@
shell->priv->settings = g_object_new (E_TYPE_SHELL_SETTINGS, NULL);
shell->priv->gconf_client = gconf_client_get_default ();
+ shell->priv->preferences_window = e_preferences_window_new ();
shell->priv->modules_by_name = modules_by_name;
shell->priv->modules_by_scheme = modules_by_scheme;
shell->priv->safe_mode = e_file_lock_exists ();
@@ -1333,15 +1340,20 @@
shell_prepare_for_offline (shell);
}
+/**
+ * e_shell_get_preferences_window:
+ * @shell: an #EShell
+ *
+ * Returns the Evolution Preferences window.
+ *
+ * Returns: the preferences window
+ **/
GtkWidget *
-e_shell_get_preferences_window (void)
+e_shell_get_preferences_window (EShell *shell)
{
- static GtkWidget *preferences_window = NULL;
-
- if (G_UNLIKELY (preferences_window == NULL))
- preferences_window = e_preferences_window_new ();
+ g_return_val_if_fail (E_IS_SHELL (shell), NULL);
- return preferences_window;
+ return shell->priv->preferences_window;
}
/**
Modified: branches/kill-bonobo/shell/e-shell.h
==============================================================================
--- branches/kill-bonobo/shell/e-shell.h (original)
+++ branches/kill-bonobo/shell/e-shell.h Thu Feb 19 06:22:32 2009
@@ -102,7 +102,7 @@
gboolean e_shell_get_online (EShell *shell);
void e_shell_set_online (EShell *shell,
gboolean online);
-GtkWidget * e_shell_get_preferences_window (void);
+GtkWidget * e_shell_get_preferences_window (EShell *shell);
void e_shell_event (EShell *shell,
const gchar *event_name,
gpointer event_data);
Modified: branches/kill-bonobo/smime/gui/certificate-manager.c
==============================================================================
--- branches/kill-bonobo/smime/gui/certificate-manager.c (original)
+++ branches/kill-bonobo/smime/gui/certificate-manager.c Thu Feb 19 06:22:32 2009
@@ -982,6 +982,7 @@
CertificateManagerData *cfm_data;
GtkWidget *preferences_window;
GtkWidget *widget;
+ EShell *shell;
char *gladefile;
/* We need to peek the db here to make sure it (and NSS) are fully initialized. */
@@ -1030,7 +1031,8 @@
gtk_widget_set_sensitive(cfm_data->backup_your_button, FALSE);
gtk_widget_set_sensitive(cfm_data->backup_all_your_button, FALSE);
- preferences_window = e_shell_get_preferences_window ();
+ shell = e_shell_get_default ();
+ preferences_window = e_shell_get_preferences_window (shell);
e_preferences_window_add_page (
E_PREFERENCES_WINDOW (preferences_window),
"certificates",
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]