From 2593383aec61d0b1f2f8950e5301f30176d2cbce Mon Sep 17 00:00:00 2001 From: Michael Meeks Date: Mon, 12 Apr 2010 14:50:44 +0100 Subject: Detect MeeGo, and propagate settings variously. Adapt widget naming on MeeGo for theming etc. --- shell/main.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'shell/main.c') diff --git a/shell/main.c b/shell/main.c index e3d69412a6..5a9855b402 100644 --- a/shell/main.c +++ b/shell/main.c @@ -49,6 +49,7 @@ #include "e-shell.h" #include "e-shell-migrate.h" +#include "e-shell-meego.h" #include "e-config-upgrade.h" #include "es-event.h" @@ -371,6 +372,7 @@ create_default_shell (void) gboolean online = TRUE; const gchar *key; GError *error = NULL; + gboolean is_meego = FALSE, small_screen = FALSE; client = gconf_client_get_default (); @@ -405,6 +407,9 @@ create_default_shell (void) if (!express_mode) express_mode = gconf_client_get_bool (client, key, &error); + if (express_mode) + e_shell_detect_meego (&is_meego, &small_screen); + if (error != NULL) { g_warning ("%s", error->message); g_clear_error (&error); @@ -415,7 +420,9 @@ create_default_shell (void) "name", "org.gnome.Evolution", "geometry", geometry, "module-directory", EVOLUTION_MODULEDIR, + "meego-mode", is_meego, "express-mode", express_mode, + "small-screen-mode", small_screen, "online", online, NULL); -- cgit v1.2.3 From a650f15f0090d68a503b5b11561bfb3cdb4663dc Mon Sep 17 00:00:00 2001 From: Srinivasa Ragavan Date: Thu, 22 Apr 2010 17:27:20 +0530 Subject: Store the initial view request and use that to decide whether to show startup wizard or not. Show only for mail and not calendar. --- shell/main.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'shell/main.c') diff --git a/shell/main.c b/shell/main.c index 5a9855b402..e327065f43 100644 --- a/shell/main.c +++ b/shell/main.c @@ -576,6 +576,11 @@ main (gint argc, gchar **argv) e_plugin_load_plugins (); } + if (requested_view) + e_shell_set_startup_view(shell, requested_view); + else if (express_mode) + e_shell_set_startup_view(shell, "mail"); + /* Attempt migration -after- loading all modules and plugins, * as both shell backends and certain plugins hook into this. */ e_shell_migrate_attempt (shell); -- cgit v1.2.3 From cc87be2984b6d4d76b257c148e5a3d7ed8ec2771 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fridrich=20=C5=A0trba?= Date: Mon, 10 May 2010 22:51:11 +0200 Subject: [win32] Set patch to evolution's bindir because some child processes need it in some situations. --- shell/main.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'shell/main.c') diff --git a/shell/main.c b/shell/main.c index e3d69412a6..3ab0e9a709 100644 --- a/shell/main.c +++ b/shell/main.c @@ -435,6 +435,8 @@ main (gint argc, gchar **argv) GError *error = NULL; #ifdef G_OS_WIN32 + gchar *path; + if (fileno (stdout) != -1 && _get_osfhandle (fileno (stdout)) != -1) { /* stdout is fine, presumably redirected to a file or pipe */ } else { @@ -451,6 +453,13 @@ main (gint argc, gchar **argv) dup2 (fileno (stderr), 2); } } + + path = g_build_path (";", _e_get_bindir (), g_getenv ("PATH"), NULL); + + if (!g_setenv ("PATH", path, TRUE)) + g_warning ("Could not set PATH for Evolution and its child processes"); + + g_free (path); #endif /* Make ElectricFence work. */ -- cgit v1.2.3 From ba5a33b6f19d2cdb747757408b08c5ae4ade3d86 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fridrich=20=C5=A0trba?= Date: Mon, 17 May 2010 09:07:50 +0200 Subject: [win32] Don't call glib functions before g_thread_init was called and register evolution as capable to handle mailto: protocol on startup --- shell/main.c | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) (limited to 'shell/main.c') diff --git a/shell/main.c b/shell/main.c index 3ab0e9a709..b3fdc7ad55 100644 --- a/shell/main.c +++ b/shell/main.c @@ -60,6 +60,9 @@ #include "e-util/e-profile-event.h" #include "e-util/e-util-private.h" #include "e-util/e-util.h" +#ifdef G_OS_WIN32 +#include "e-util/e-win32-defaults.h" +#endif #include #include @@ -453,13 +456,6 @@ main (gint argc, gchar **argv) dup2 (fileno (stderr), 2); } } - - path = g_build_path (";", _e_get_bindir (), g_getenv ("PATH"), NULL); - - if (!g_setenv ("PATH", path, TRUE)) - g_warning ("Could not set PATH for Evolution and its child processes"); - - g_free (path); #endif /* Make ElectricFence work. */ @@ -485,6 +481,15 @@ main (gint argc, gchar **argv) dbus_g_thread_init (); #ifdef G_OS_WIN32 + path = g_build_path (";", _e_get_bindir (), g_getenv ("PATH"), NULL); + + if (!g_setenv ("PATH", path, TRUE)) + g_warning ("Could not set PATH for Evolution and its child processes"); + + g_free (path); + + _e_win32_register_mailer (); + if (strcmp (gettext (""), "") == 0) { /* No message catalog installed for the current locale * language, so don't bother with the localisations -- cgit v1.2.3 From 02564bb45b4a4ceac0bdb27ff80a26e65590d220 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fridrich=20=C5=A0trba?= Date: Tue, 18 May 2010 16:57:11 +0200 Subject: [win32] Implement --reinstall, --show-icons, --hide-icons options to be used by windows default application setting dialogue --- shell/main.c | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) (limited to 'shell/main.c') diff --git a/shell/main.c b/shell/main.c index b3fdc7ad55..f5d9061d1a 100644 --- a/shell/main.c +++ b/shell/main.c @@ -80,6 +80,11 @@ #endif /* Command-line options. */ +#ifdef G_OS_WIN32 +static gboolean reinstall = FALSE; +static gboolean show_icons = FALSE; +static gboolean hide_icons = FALSE; +#endif /* G_OS_WIN32 */ static gboolean express_mode = FALSE; static gboolean start_online = FALSE; static gboolean start_offline = FALSE; @@ -321,6 +326,14 @@ setup_segv_redirect (void) #endif static GOptionEntry entries[] = { +#ifdef G_OS_WIN32 + { "--reinstall", '\0', G_OPTION_FLAG_HIDDEN, G_OPTION_ARG_NONE, &reinstall, + NULL, NULL }, + { "--show-icons", '\0', G_OPTION_FLAG_HIDDEN, G_OPTION_ARG_NONE, &show_icons, + NULL, NULL }, + { "--hide-icons", '\0', G_OPTION_FLAG_HIDDEN, G_OPTION_ARG_NONE, &hide_icons, + NULL, NULL }, +#endif /* G_OS_WIN32 */ { "component", 'c', 0, G_OPTION_ARG_STRING, &requested_view, N_("Start Evolution activating the specified component"), NULL }, { "geometry", 'g', 0, G_OPTION_ARG_STRING, &geometry, @@ -490,6 +503,21 @@ main (gint argc, gchar **argv) _e_win32_register_mailer (); + if (reinstall) { + _e_win32_set_default_mailer (); + exit (0); + } + + if (show_icons) { + _e_win32_set_default_mailer (); + exit (0); + } + + if (hide_icons) { + _e_win32_unset_default_mailer (); + exit (0); + } + if (strcmp (gettext (""), "") == 0) { /* No message catalog installed for the current locale * language, so don't bother with the localisations -- cgit v1.2.3 From b995d99498160db3006cb4288b5048f3396d1d88 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Tue, 18 May 2010 20:08:25 -0400 Subject: Bug 619010 - Mailer's crash avoidance features are broken --- shell/main.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'shell/main.c') diff --git a/shell/main.c b/shell/main.c index f5d9061d1a..0ee9478858 100644 --- a/shell/main.c +++ b/shell/main.c @@ -555,6 +555,9 @@ main (gint argc, gchar **argv) key = "/apps/evolution/addressbook/display/show_preview"; gconf_client_set_bool (client, key, FALSE, NULL); + key = "/apps/evolution/calendar/display/show_memo_preview"; + gconf_client_set_bool (client, key, FALSE, NULL); + key = "/apps/evolution/calendar/display/show_task_preview"; gconf_client_set_bool (client, key, FALSE, NULL); } -- cgit v1.2.3 From 38711248e319902e7396e41e1c64c732b1645bec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fridrich=20=C5=A0trba?= Date: Wed, 19 May 2010 10:20:36 +0200 Subject: [win32] Try to get the default application registration right --- shell/main.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'shell/main.c') diff --git a/shell/main.c b/shell/main.c index 0ee9478858..41ca79eac8 100644 --- a/shell/main.c +++ b/shell/main.c @@ -327,11 +327,11 @@ setup_segv_redirect (void) static GOptionEntry entries[] = { #ifdef G_OS_WIN32 - { "--reinstall", '\0', G_OPTION_FLAG_HIDDEN, G_OPTION_ARG_NONE, &reinstall, + { "reinstall", '\0', G_OPTION_FLAG_HIDDEN, G_OPTION_ARG_NONE, &reinstall, NULL, NULL }, - { "--show-icons", '\0', G_OPTION_FLAG_HIDDEN, G_OPTION_ARG_NONE, &show_icons, + { "show-icons", '\0', G_OPTION_FLAG_HIDDEN, G_OPTION_ARG_NONE, &show_icons, NULL, NULL }, - { "--hide-icons", '\0', G_OPTION_FLAG_HIDDEN, G_OPTION_ARG_NONE, &hide_icons, + { "hide-icons", '\0', G_OPTION_FLAG_HIDDEN, G_OPTION_ARG_NONE, &hide_icons, NULL, NULL }, #endif /* G_OS_WIN32 */ { "component", 'c', 0, G_OPTION_ARG_STRING, &requested_view, -- cgit v1.2.3 From 3e1b34841d3a699f77848f5de019f18ccb2d1ca1 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Tue, 25 May 2010 09:41:48 -0400 Subject: Fix compiler warnings. --- shell/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'shell/main.c') diff --git a/shell/main.c b/shell/main.c index 02bc094480..f342f35588 100644 --- a/shell/main.c +++ b/shell/main.c @@ -258,7 +258,7 @@ idle_cb (gchar **uris) gtk_main_quit (); } else { if (express_mode && requested_view == NULL) - requested_view = "mail"; + requested_view = (gchar *) "mail"; e_shell_create_shell_window (shell, requested_view); } -- cgit v1.2.3 From 96538878911586a9e9ca26b81e1916c04e538980 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Tue, 25 May 2010 10:15:32 -0400 Subject: Coding style and whitespace cleanup. --- shell/main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'shell/main.c') diff --git a/shell/main.c b/shell/main.c index f342f35588..c41071a349 100644 --- a/shell/main.c +++ b/shell/main.c @@ -507,9 +507,9 @@ main (gint argc, gchar **argv) g_warning ("Could not set PATH for Evolution and its child processes"); g_free (path); - + _e_win32_register_mailer (); - + if (reinstall) { _e_win32_set_default_mailer (); exit (0); -- cgit v1.2.3