aboutsummaryrefslogtreecommitdiffstats
path: root/modules
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2010-10-04 00:08:28 +0800
committerMatthew Barnes <mbarnes@redhat.com>2010-10-04 01:29:20 +0800
commit9675f18d915fcbae59dd4b32b8a2ff36b3d27cc1 (patch)
treeaa1d53c8cedef6dc09455fbadd4b63216f9b7228 /modules
parentc9c3c3be92f3dbf133a5b1b42fb55905a1060d0e (diff)
downloadgsoc2013-evolution-9675f18d915fcbae59dd4b32b8a2ff36b3d27cc1.tar
gsoc2013-evolution-9675f18d915fcbae59dd4b32b8a2ff36b3d27cc1.tar.gz
gsoc2013-evolution-9675f18d915fcbae59dd4b32b8a2ff36b3d27cc1.tar.bz2
gsoc2013-evolution-9675f18d915fcbae59dd4b32b8a2ff36b3d27cc1.tar.lz
gsoc2013-evolution-9675f18d915fcbae59dd4b32b8a2ff36b3d27cc1.tar.xz
gsoc2013-evolution-9675f18d915fcbae59dd4b32b8a2ff36b3d27cc1.tar.zst
gsoc2013-evolution-9675f18d915fcbae59dd4b32b8a2ff36b3d27cc1.zip
Coding style and whitespace cleanup.
Diffstat (limited to 'modules')
-rw-r--r--modules/calendar/e-cal-shell-sidebar.c11
-rw-r--r--modules/calendar/e-cal-shell-view.c8
-rw-r--r--modules/calendar/e-task-shell-view.c6
-rw-r--r--modules/mail/e-mail-shell-view.c15
-rw-r--r--modules/windows-sens/evolution-windows-sens.c8
5 files changed, 33 insertions, 15 deletions
diff --git a/modules/calendar/e-cal-shell-sidebar.c b/modules/calendar/e-cal-shell-sidebar.c
index 3ae662a82f..61f2f639c9 100644
--- a/modules/calendar/e-cal-shell-sidebar.c
+++ b/modules/calendar/e-cal-shell-sidebar.c
@@ -148,16 +148,16 @@ cal_shell_sidebar_backend_error_cb (ECalShellSidebar *cal_shell_sidebar,
EShellView *shell_view;
EShellWindow *shell_window;
EShellSidebar *shell_sidebar;
+ ESourceGroup *source_group;
+ ESource *source;
GtkWidget *dialog;
- const gchar *cal_name;
- const gchar *cal_group;
shell_sidebar = E_SHELL_SIDEBAR (cal_shell_sidebar);
shell_view = e_shell_sidebar_get_shell_view (shell_sidebar);
shell_window = e_shell_view_get_shell_window (shell_view);
- cal_name = e_source_peek_name ( e_cal_get_source ( client ));
- cal_group = e_source_group_peek_name ( e_source_peek_group( e_cal_get_source ( client)));
+ source = e_cal_get_source (client);
+ source_group = e_source_peek_group (source);
/* Translators: This string is displayed in a message dialog when
* our connection to the calendar service detects an
@@ -170,7 +170,8 @@ cal_shell_sidebar_backend_error_cb (ECalShellSidebar *cal_shell_sidebar,
GTK_DIALOG_DESTROY_WITH_PARENT,
GTK_MESSAGE_ERROR, GTK_BUTTONS_OK,
_("Error on %s: %s\n%s"),
- cal_group, cal_name, message);
+ e_source_group_peek_name (source_group),
+ e_source_peek_name (source), message);
gtk_dialog_run (GTK_DIALOG (dialog));
gtk_widget_destroy (dialog);
diff --git a/modules/calendar/e-cal-shell-view.c b/modules/calendar/e-cal-shell-view.c
index f9985f5f6a..6aafdc82a6 100644
--- a/modules/calendar/e-cal-shell-view.c
+++ b/modules/calendar/e-cal-shell-view.c
@@ -63,7 +63,10 @@ cal_shell_view_execute_search (EShellView *shell_view)
EActionComboBox *combo_box;
GnomeCalendar *calendar;
ECalendar *date_navigator;
+ ECalModel *model;
GtkRadioAction *action;
+ icaltimezone *timezone;
+ struct icaltimetype current_time;
time_t start_range;
time_t end_range;
time_t now_time;
@@ -83,7 +86,10 @@ cal_shell_view_execute_search (EShellView *shell_view)
searchbar = e_cal_shell_content_get_searchbar (cal_shell_content);
calendar = e_cal_shell_content_get_calendar (cal_shell_content);
- now_time = time_day_begin (icaltime_as_timet (icaltime_current_time_with_zone (e_cal_model_get_timezone (gnome_calendar_get_model (calendar)))));
+ model = gnome_calendar_get_model (calendar);
+ timezone = e_cal_model_get_timezone (model);
+ current_time = icaltime_current_time_with_zone (timezone);
+ now_time = time_day_begin (icaltime_as_timet (current_time));
action = GTK_RADIO_ACTION (ACTION (CALENDAR_SEARCH_ANY_FIELD_CONTAINS));
value = gtk_radio_action_get_current_value (action);
diff --git a/modules/calendar/e-task-shell-view.c b/modules/calendar/e-task-shell-view.c
index 3bf0eb67f1..b4c6c7db0b 100644
--- a/modules/calendar/e-task-shell-view.c
+++ b/modules/calendar/e-task-shell-view.c
@@ -104,6 +104,8 @@ task_shell_view_execute_search (EShellView *shell_view)
ETaskTable *task_table;
EWebView *web_view;
ECalModel *model;
+ icaltimezone *timezone;
+ struct icaltimetype current_time;
time_t start_range;
time_t end_range;
time_t now_time;
@@ -121,7 +123,9 @@ task_shell_view_execute_search (EShellView *shell_view)
task_shell_content = E_TASK_SHELL_CONTENT (shell_content);
task_table = e_task_shell_content_get_task_table (task_shell_content);
model = e_task_table_get_model (task_table);
- now_time = time_day_begin (icaltime_as_timet (icaltime_current_time_with_zone (e_cal_model_get_timezone (model))));
+ timezone = e_cal_model_get_timezone (model);
+ current_time = icaltime_current_time_with_zone (timezone);
+ now_time = time_day_begin (icaltime_as_timet (current_time));
action = GTK_RADIO_ACTION (ACTION (TASK_SEARCH_ANY_FIELD_CONTAINS));
value = gtk_radio_action_get_current_value (action);
diff --git a/modules/mail/e-mail-shell-view.c b/modules/mail/e-mail-shell-view.c
index 6b6b530b90..817b2db79d 100644
--- a/modules/mail/e-mail-shell-view.c
+++ b/modules/mail/e-mail-shell-view.c
@@ -672,13 +672,15 @@ current_account:
GtkTreeSelection *selection;
GtkTreeModel *model;
GtkTreeIter iter;
-
+
store = NULL;
tree_view = GTK_TREE_VIEW (folder_tree);
selection = gtk_tree_view_get_selection (tree_view);
if (gtk_tree_selection_get_selected (selection, &model, &iter))
- gtk_tree_model_get (model, &iter, COL_POINTER_CAMEL_STORE, &store, -1);
+ gtk_tree_model_get (
+ model, &iter,
+ COL_POINTER_CAMEL_STORE, &store, -1);
}
list = NULL; /* list of CamelFolders */
@@ -686,7 +688,10 @@ current_account:
if (store) {
CamelFolderInfo *root, *fi;
- root = camel_store_get_folder_info_sync (store, NULL, CAMEL_STORE_FOLDER_INFO_RECURSIVE, NULL, NULL);
+ /* FIXME This call blocks the main loop. */
+ root = camel_store_get_folder_info_sync (
+ store, NULL,
+ CAMEL_STORE_FOLDER_INFO_RECURSIVE, NULL, NULL);
fi = root;
while (fi) {
CamelFolderInfo *next;
@@ -694,7 +699,9 @@ current_account:
if ((fi->flags & CAMEL_FOLDER_NOSELECT) == 0) {
CamelFolder *fldr;
- fldr = camel_store_get_folder_sync (store, fi->full_name, 0, NULL, NULL);
+ /* FIXME This call blocks the main loop. */
+ fldr = camel_store_get_folder_sync (
+ store, fi->full_name, 0, NULL, NULL);
if (fldr)
list = g_list_prepend (list, fldr);
}
diff --git a/modules/windows-sens/evolution-windows-sens.c b/modules/windows-sens/evolution-windows-sens.c
index 536ff06ff4..e0f70de4e5 100644
--- a/modules/windows-sens/evolution-windows-sens.c
+++ b/modules/windows-sens/evolution-windows-sens.c
@@ -551,9 +551,9 @@ windows_sens_constructed (GObject *object)
IsNetworkAlive_t pIsNetworkAlive = NULL;
- char *buf = NULL;
- char dummy;
- int n, k;
+ gchar *buf = NULL;
+ gchar dummy;
+ gint n, k;
HMODULE hDLL = NULL;
n = GetSystemDirectory (&dummy, 0);
@@ -563,7 +563,7 @@ windows_sens_constructed (GObject *object)
buf = g_malloc (n + 1 + strlen (SENSAPI_DLL));
k = GetSystemDirectory (buf, n);
-
+
if (k == 0 || k > n)
goto cleanup;