diff options
Diffstat (limited to 'shell')
-rw-r--r-- | shell/e-shell-searchbar.c | 34 | ||||
-rw-r--r-- | shell/e-shell-settings.c | 2 | ||||
-rw-r--r-- | shell/e-shell-switcher.c | 2 | ||||
-rw-r--r-- | shell/e-shell-window-actions.c | 3 | ||||
-rw-r--r-- | shell/e-shell-window.c | 10 | ||||
-rw-r--r-- | shell/e-shell.c | 2 | ||||
-rw-r--r-- | shell/main.c | 6 |
7 files changed, 34 insertions, 25 deletions
diff --git a/shell/e-shell-searchbar.c b/shell/e-shell-searchbar.c index 002fc35f0a..4c7e670881 100644 --- a/shell/e-shell-searchbar.c +++ b/shell/e-shell-searchbar.c @@ -513,7 +513,8 @@ shell_searchbar_resize_idle_cb (gpointer user_data) column = 0; } - gtk_container_child_get (GTK_CONTAINER (widget), child, + gtk_container_child_get ( + GTK_CONTAINER (widget), child, "left-attach", &child_left, "top-attach", &child_top, NULL); @@ -866,7 +867,7 @@ shell_searchbar_map (GtkWidget *widget) static void shell_searchbar_size_allocate (GtkWidget *widget, - GdkRectangle *allocation) + GdkRectangle *allocation) { EShellSearchbar *searchbar; @@ -880,8 +881,8 @@ shell_searchbar_size_allocate (GtkWidget *widget, static void shell_searchbar_get_preferred_width (GtkWidget *widget, - gint *minimum_width, - gint *natural_width) + gint *minimum_width, + gint *natural_width) { GList *children, *iter; gint max_minimum = 0, max_natural = 0; @@ -1079,7 +1080,8 @@ e_shell_searchbar_init (EShellSearchbar *searchbar) grid = GTK_GRID (searchbar); widget = gtk_grid_new (); - g_object_set (G_OBJECT (widget), + g_object_set ( + G_OBJECT (widget), "orientation", GTK_ORIENTATION_HORIZONTAL, "column-spacing", 3, "valign", GTK_ALIGN_CENTER, @@ -1121,7 +1123,8 @@ e_shell_searchbar_init (EShellSearchbar *searchbar) grid = GTK_GRID (searchbar); widget = gtk_grid_new (); - g_object_set (G_OBJECT (widget), + g_object_set ( + G_OBJECT (widget), "orientation", GTK_ORIENTATION_HORIZONTAL, "column-spacing", 3, "valign", GTK_ALIGN_CENTER, @@ -1154,7 +1157,8 @@ e_shell_searchbar_init (EShellSearchbar *searchbar) widget = gtk_entry_new (); gtk_label_set_mnemonic_widget (label, widget); - g_object_set (G_OBJECT (widget), + g_object_set ( + G_OBJECT (widget), "halign", GTK_ALIGN_FILL, "hexpand", TRUE, NULL); @@ -1197,7 +1201,8 @@ e_shell_searchbar_init (EShellSearchbar *searchbar) grid = GTK_GRID (searchbar); widget = gtk_grid_new (); - g_object_set (G_OBJECT (widget), + g_object_set ( + G_OBJECT (widget), "orientation", GTK_ORIENTATION_HORIZONTAL, "column-spacing", 3, "valign", GTK_ALIGN_CENTER, @@ -1250,7 +1255,8 @@ e_shell_searchbar_new (EShellView *shell_view) { g_return_val_if_fail (E_IS_SHELL_VIEW (shell_view), NULL); - return g_object_new (E_TYPE_SHELL_SEARCHBAR, + return g_object_new ( + E_TYPE_SHELL_SEARCHBAR, "shell-view", shell_view, "orientation", GTK_ORIENTATION_HORIZONTAL, NULL); @@ -1286,7 +1292,7 @@ e_shell_searchbar_set_express_mode (EShellSearchbar *searchbar, { g_return_if_fail (E_IS_SHELL_SEARCHBAR (searchbar)); - if ((searchbar->priv->express_mode ? 1 : 0) == (express_mode ? 1 : 0)) + if (searchbar->priv->express_mode == express_mode) return; searchbar->priv->express_mode = express_mode; @@ -1326,7 +1332,7 @@ e_shell_searchbar_set_labels_visible (EShellSearchbar *searchbar, { g_return_if_fail (E_IS_SHELL_SEARCHBAR (searchbar)); - if ((searchbar->priv->labels_visible ? 1 : 0) == (labels_visible ? 1 : 0)) + if (searchbar->priv->labels_visible == labels_visible) return; searchbar->priv->labels_visible = labels_visible; @@ -1352,7 +1358,7 @@ e_shell_searchbar_set_filter_visible (EShellSearchbar *searchbar, { g_return_if_fail (E_IS_SHELL_SEARCHBAR (searchbar)); - if ((searchbar->priv->filter_visible ? 1 : 0) == (filter_visible ? 1 : 0)) + if (searchbar->priv->filter_visible == filter_visible) return; searchbar->priv->filter_visible = filter_visible; @@ -1482,7 +1488,7 @@ e_shell_searchbar_set_search_visible (EShellSearchbar *searchbar, { g_return_if_fail (E_IS_SHELL_SEARCHBAR (searchbar)); - if ((searchbar->priv->search_visible ? 1 : 0) == (search_visible ? 1 : 0)) + if (searchbar->priv->search_visible == search_visible) return; searchbar->priv->search_visible = search_visible; @@ -1526,7 +1532,7 @@ e_shell_searchbar_set_scope_visible (EShellSearchbar *searchbar, { g_return_if_fail (E_IS_SHELL_SEARCHBAR (searchbar)); - if ((searchbar->priv->scope_visible ? 1 : 0) == (scope_visible ? 1 : 0)) + if (searchbar->priv->scope_visible == scope_visible) return; searchbar->priv->scope_visible = scope_visible; diff --git a/shell/e-shell-settings.c b/shell/e-shell-settings.c index 22ba9c8e5e..3b971b6ab1 100644 --- a/shell/e-shell-settings.c +++ b/shell/e-shell-settings.c @@ -90,7 +90,7 @@ shell_settings_value_equal (const GValue *v1, return g_value_get_double (v1) == g_value_get_double (v2); } else if (G_VALUE_HOLDS_BOOLEAN (v1) && G_VALUE_HOLDS_BOOLEAN (v2)) { - return (g_value_get_boolean (v1) ? 1 : 0) == (g_value_get_boolean (v2) ? 1 : 0); + return g_value_get_boolean (v1) == g_value_get_boolean (v2); } else if (G_VALUE_HOLDS_POINTER (v1) && G_VALUE_HOLDS_POINTER (v2)) { return g_value_get_pointer (v1) == g_value_get_pointer (v2); diff --git a/shell/e-shell-switcher.c b/shell/e-shell-switcher.c index b2830cac02..195dc7c896 100644 --- a/shell/e-shell-switcher.c +++ b/shell/e-shell-switcher.c @@ -773,7 +773,7 @@ e_shell_switcher_set_visible (EShellSwitcher *switcher, g_return_if_fail (E_IS_SHELL_SWITCHER (switcher)); - if ((switcher->priv->toolbar_visible ? 1 : 0) == (visible ? 1 : 0)) + if (switcher->priv->toolbar_visible == visible) return; switcher->priv->toolbar_visible = visible; diff --git a/shell/e-shell-window-actions.c b/shell/e-shell-window-actions.c index ece1c24d8b..cecc168345 100644 --- a/shell/e-shell-window-actions.c +++ b/shell/e-shell-window-actions.c @@ -1222,7 +1222,8 @@ action_submit_bug_cb (GtkAction *action, g_spawn_command_line_async (command_line, &error); if (error != NULL) { - e_notice (shell_window, GTK_MESSAGE_ERROR, + e_notice ( + shell_window, GTK_MESSAGE_ERROR, error->code == G_SPAWN_ERROR_NOENT ? _("Bug Buddy is not installed.") : _("Bug Buddy could not be run.")); diff --git a/shell/e-shell-window.c b/shell/e-shell-window.c index 8193b52da3..2202757bb1 100644 --- a/shell/e-shell-window.c +++ b/shell/e-shell-window.c @@ -1390,7 +1390,7 @@ e_shell_window_set_safe_mode (EShellWindow *shell_window, { g_return_if_fail (E_IS_SHELL_WINDOW (shell_window)); - if ((shell_window->priv->safe_mode ? 1 : 0) == (safe_mode ? 1 : 0)) + if (shell_window->priv->safe_mode == safe_mode) return; shell_window->priv->safe_mode = safe_mode; @@ -1456,7 +1456,7 @@ e_shell_window_set_sidebar_visible (EShellWindow *shell_window, { g_return_if_fail (E_IS_SHELL_WINDOW (shell_window)); - if ((shell_window->priv->sidebar_visible ? 1 : 0) == (sidebar_visible ? 1 : 0)) + if (shell_window->priv->sidebar_visible == sidebar_visible) return; shell_window->priv->sidebar_visible = sidebar_visible; @@ -1493,7 +1493,7 @@ e_shell_window_set_switcher_visible (EShellWindow *shell_window, { g_return_if_fail (E_IS_SHELL_WINDOW (shell_window)); - if ((shell_window->priv->switcher_visible ? 1 : 0) == (switcher_visible ? 1 : 0)) + if (shell_window->priv->switcher_visible == switcher_visible) return; shell_window->priv->switcher_visible = switcher_visible; @@ -1530,7 +1530,7 @@ e_shell_window_set_taskbar_visible (EShellWindow *shell_window, { g_return_if_fail (E_IS_SHELL_WINDOW (shell_window)); - if ((shell_window->priv->taskbar_visible ? 1 : 0) == (taskbar_visible ? 1 : 0)) + if (shell_window->priv->taskbar_visible == taskbar_visible) return; shell_window->priv->taskbar_visible = taskbar_visible; @@ -1567,7 +1567,7 @@ e_shell_window_set_toolbar_visible (EShellWindow *shell_window, { g_return_if_fail (E_IS_SHELL_WINDOW (shell_window)); - if ((shell_window->priv->toolbar_visible ? 1 : 0) == (toolbar_visible ? 1 : 0)) + if (shell_window->priv->toolbar_visible == toolbar_visible) return; shell_window->priv->toolbar_visible = toolbar_visible; diff --git a/shell/e-shell.c b/shell/e-shell.c index 2f7cdcc8b5..b96cbb9a29 100644 --- a/shell/e-shell.c +++ b/shell/e-shell.c @@ -1701,7 +1701,7 @@ e_shell_set_network_available (EShell *shell, if (shell->priv->network_available_locked) return; - if ((network_available ? 1 : 0) == (shell->priv->network_available ? 1 : 0)) + if (shell->priv->network_available == network_available) return; shell->priv->network_available = network_available; diff --git a/shell/main.c b/shell/main.c index e1237cccbd..0869ef6f05 100644 --- a/shell/main.c +++ b/shell/main.c @@ -422,8 +422,10 @@ create_default_shell (void) /* Failure to register is fatal. */ if (error != NULL) { - e_notice (NULL, GTK_MESSAGE_ERROR, - _("Cannot start Evolution, other instance is probably running and is unresponsive. System error: %s"), + e_notice ( + NULL, GTK_MESSAGE_ERROR, + _("Cannot start Evolution. Another Evolution " + "instance may be unresponsive. System error: %s"), error->message); g_clear_error (&error); } |