aboutsummaryrefslogtreecommitdiffstats
path: root/calendar
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2012-08-06 08:59:18 +0800
committerMatthew Barnes <mbarnes@redhat.com>2012-08-06 10:12:26 +0800
commit07be2453e059c1cf0a5a2f8f7883e7de84411e97 (patch)
treea35669cf5ea51b57da5635b0fdc30ee81f488c5f /calendar
parent74d33d365d99684b279088f2a24b53896b51f899 (diff)
downloadgsoc2013-evolution-07be2453e059c1cf0a5a2f8f7883e7de84411e97.tar.gz
gsoc2013-evolution-07be2453e059c1cf0a5a2f8f7883e7de84411e97.tar.zst
gsoc2013-evolution-07be2453e059c1cf0a5a2f8f7883e7de84411e97.zip
Remove all GDK threads usage.
According to [1], we don't need to worry about GDK's global lock since we don't call gdk_threads_init() or gdk_threads_set_lock_functions(). The GDK threads API is being aggressively deprecated by GTK+ developers so let's just abandon it entirely. I've never really understood when you're supposed to use it or not use it anyway, so it's good to be rid of this confusion. [1] https://mail.gnome.org/archives/desktop-devel-list/2012-August/msg00005.html
Diffstat (limited to 'calendar')
-rw-r--r--calendar/gui/e-day-view.c4
-rw-r--r--calendar/gui/e-meeting-time-sel.c11
2 files changed, 2 insertions, 13 deletions
diff --git a/calendar/gui/e-day-view.c b/calendar/gui/e-day-view.c
index 620b664f11..c2b7fc78fd 100644
--- a/calendar/gui/e-day-view.c
+++ b/calendar/gui/e-day-view.c
@@ -7131,11 +7131,8 @@ e_day_view_auto_scroll_handler (gpointer data)
day_view = E_DAY_VIEW (data);
- GDK_THREADS_ENTER ();
-
if (day_view->auto_scroll_delay > 0) {
day_view->auto_scroll_delay--;
- GDK_THREADS_LEAVE ();
return TRUE;
}
@@ -7189,7 +7186,6 @@ e_day_view_auto_scroll_handler (gpointer data)
}
}
- GDK_THREADS_LEAVE ();
return TRUE;
}
diff --git a/calendar/gui/e-meeting-time-sel.c b/calendar/gui/e-meeting-time-sel.c
index 79acc1887a..eb7a1fc67e 100644
--- a/calendar/gui/e-meeting-time-sel.c
+++ b/calendar/gui/e-meeting-time-sel.c
@@ -2794,13 +2794,9 @@ e_meeting_time_selector_timeout_handler (gpointer data)
mts = E_MEETING_TIME_SELECTOR (data);
- GDK_THREADS_ENTER ();
-
/* Return if we don't need to scroll yet. */
- if (mts->scroll_count-- > 0) {
- GDK_THREADS_LEAVE ();
+ if (mts->scroll_count-- > 0)
return TRUE;
- }
/* Get the x coords of visible part of the canvas. */
gnome_canvas_get_scroll_offsets (GNOME_CANVAS (mts->display_main),
@@ -2871,10 +2867,8 @@ e_meeting_time_selector_timeout_handler (gpointer data)
time_to_set = &mts->meeting_end_time;
/* If the time is unchanged, just return. */
- if (e_meeting_time_compare_times (time_to_set, &drag_time) == 0) {
- GDK_THREADS_LEAVE ();
+ if (e_meeting_time_compare_times (time_to_set, &drag_time) == 0)
goto scroll;
- }
/* Don't let an empty occur for all day events */
if (mts->all_day
@@ -2929,7 +2923,6 @@ e_meeting_time_selector_timeout_handler (gpointer data)
gnome_canvas_scroll_to (GNOME_CANVAS (mts->display_top),
scroll_x, scroll_y);
- GDK_THREADS_LEAVE ();
return TRUE;
}