[evolution] Minor efficiency tweak in cal_shell_view_user_created_cb().
- From: Matthew Barnes <mbarnes src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution] Minor efficiency tweak in cal_shell_view_user_created_cb().
- Date: Sat, 1 Jun 2013 14:23:48 +0000 (UTC)
commit 585745a2bf46d08ff55c9c16b3dd8d83ad8cb335
Author: Matthew Barnes <mbarnes redhat com>
Date: Sat Jun 1 09:29:02 2013 -0400
Minor efficiency tweak in cal_shell_view_user_created_cb().
Call e_cal_shell_sidebar_add_client() instead of add_source().
No point asynchronously obtaining the client if we already have it.
modules/calendar/e-cal-shell-view-private.c | 10 +++-------
1 files changed, 3 insertions(+), 7 deletions(-)
---
diff --git a/modules/calendar/e-cal-shell-view-private.c b/modules/calendar/e-cal-shell-view-private.c
index 5322ad0..99de61c 100644
--- a/modules/calendar/e-cal-shell-view-private.c
+++ b/modules/calendar/e-cal-shell-view-private.c
@@ -377,18 +377,14 @@ cal_shell_view_taskpad_popup_event_cb (EShellView *shell_view,
static void
cal_shell_view_user_created_cb (ECalShellView *cal_shell_view,
- ECalClient *where_was_created,
+ ECalClient *client,
ECalendarView *calendar_view)
{
ECalShellSidebar *cal_shell_sidebar;
- ESource *source;
-
- g_return_if_fail (where_was_created != NULL);
-
- source = e_client_get_source (E_CLIENT (where_was_created));
cal_shell_sidebar = cal_shell_view->priv->cal_shell_sidebar;
- e_cal_shell_sidebar_add_source (cal_shell_sidebar, source);
+
+ e_cal_shell_sidebar_add_client (cal_shell_sidebar, E_CLIENT (client));
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]