[banshee] Call the notify handler from a GLib idle delegate
- From: Rodney Dawes <dobey src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [banshee] Call the notify handler from a GLib idle delegate
- Date: Thu, 27 Oct 2011 19:14:26 +0000 (UTC)
commit 9323f7b5c056ce52128dd4dfdf5b16abff8fb6e9
Author: Rodney Dawes <dobey gnome org>
Date: Thu Oct 27 15:09:22 2011 -0400
Call the notify handler from a GLib idle delegate
Uses a delegate in a glib idle callback to call the nofity handler.
We need to do this to avoid racing on startup with other activities
which can block the main loop, causing the handler to only work
sometimes, or only partially.
Fixes: https://bugzilla.gnome.org/show_bug.cgi?id=662883
.../Banshee.Sources/SourceManager.cs | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/src/Core/Banshee.Services/Banshee.Sources/SourceManager.cs b/src/Core/Banshee.Services/Banshee.Sources/SourceManager.cs
index d0878bd..289f954 100644
--- a/src/Core/Banshee.Services/Banshee.Sources/SourceManager.cs
+++ b/src/Core/Banshee.Services/Banshee.Sources/SourceManager.cs
@@ -411,7 +411,7 @@ namespace Banshee.Sources
if(handler != null) {
SourceEventArgs args = new SourceEventArgs();
args.Source = active_source;
- handler(args);
+ GLib.Idle.Add (delegate { handler(args); return false; });
}
source.Activate();
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]