Make the default priority for idle sources G_PRIORITY_DEFAULT_IDLE as
authorOwen Taylor <otaylor@redhat.com>
Thu, 7 Aug 2003 18:19:23 +0000 (18:19 +0000)
committerOwen Taylor <otaylor@src.gnome.org>
Thu, 7 Aug 2003 18:19:23 +0000 (18:19 +0000)
Thu Aug  7 14:15:44 2003  Owen Taylor  <otaylor@redhat.com>

        * glib/gmain.c (g_idle_source_new): Make the default priority
        for idle sources G_PRIORITY_DEFAULT_IDLE as anybody would
        expect and document that. (#114461, reported by Andy Wingo)

ChangeLog
ChangeLog.pre-2-10
ChangeLog.pre-2-12
ChangeLog.pre-2-4
ChangeLog.pre-2-6
ChangeLog.pre-2-8
glib/gmain.c

index c6b8a6d..ceb47c3 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+Thu Aug  7 14:15:44 2003  Owen Taylor  <otaylor@redhat.com>
+
+       * glib/gmain.c (g_idle_source_new): Make the default priority
+       for idle sources G_PRIORITY_DEFAULT_IDLE as anybody would
+       expect and document that. (#114461, reported by Andy Wingo)
+
 2003-08-06  Noah Levitt  <nlevitt@columbia.edu>
 
        * tests/casemap.txt:
index c6b8a6d..ceb47c3 100644 (file)
@@ -1,3 +1,9 @@
+Thu Aug  7 14:15:44 2003  Owen Taylor  <otaylor@redhat.com>
+
+       * glib/gmain.c (g_idle_source_new): Make the default priority
+       for idle sources G_PRIORITY_DEFAULT_IDLE as anybody would
+       expect and document that. (#114461, reported by Andy Wingo)
+
 2003-08-06  Noah Levitt  <nlevitt@columbia.edu>
 
        * tests/casemap.txt:
index c6b8a6d..ceb47c3 100644 (file)
@@ -1,3 +1,9 @@
+Thu Aug  7 14:15:44 2003  Owen Taylor  <otaylor@redhat.com>
+
+       * glib/gmain.c (g_idle_source_new): Make the default priority
+       for idle sources G_PRIORITY_DEFAULT_IDLE as anybody would
+       expect and document that. (#114461, reported by Andy Wingo)
+
 2003-08-06  Noah Levitt  <nlevitt@columbia.edu>
 
        * tests/casemap.txt:
index c6b8a6d..ceb47c3 100644 (file)
@@ -1,3 +1,9 @@
+Thu Aug  7 14:15:44 2003  Owen Taylor  <otaylor@redhat.com>
+
+       * glib/gmain.c (g_idle_source_new): Make the default priority
+       for idle sources G_PRIORITY_DEFAULT_IDLE as anybody would
+       expect and document that. (#114461, reported by Andy Wingo)
+
 2003-08-06  Noah Levitt  <nlevitt@columbia.edu>
 
        * tests/casemap.txt:
index c6b8a6d..ceb47c3 100644 (file)
@@ -1,3 +1,9 @@
+Thu Aug  7 14:15:44 2003  Owen Taylor  <otaylor@redhat.com>
+
+       * glib/gmain.c (g_idle_source_new): Make the default priority
+       for idle sources G_PRIORITY_DEFAULT_IDLE as anybody would
+       expect and document that. (#114461, reported by Andy Wingo)
+
 2003-08-06  Noah Levitt  <nlevitt@columbia.edu>
 
        * tests/casemap.txt:
index c6b8a6d..ceb47c3 100644 (file)
@@ -1,3 +1,9 @@
+Thu Aug  7 14:15:44 2003  Owen Taylor  <otaylor@redhat.com>
+
+       * glib/gmain.c (g_idle_source_new): Make the default priority
+       for idle sources G_PRIORITY_DEFAULT_IDLE as anybody would
+       expect and document that. (#114461, reported by Andy Wingo)
+
 2003-08-06  Noah Levitt  <nlevitt@columbia.edu>
 
        * tests/casemap.txt:
index fccdae1..699c68b 100644 (file)
@@ -3250,14 +3250,21 @@ g_idle_dispatch (GSource    *source,
  *
  * The source will not initially be associated with any #GMainContext
  * and must be added to one with g_source_attach() before it will be
- * executed.
+ * executed. Note that the default priority for idle sources is
+ * %G_PRIORITY_DEFAULT_IDLE, as compared to other sources which
+ * have a default priority of %G_PRIORITY_DEFAULT.
  * 
  * Return value: the newly-created idle source
  **/
 GSource *
 g_idle_source_new (void)
 {
-  return g_source_new (&g_idle_funcs, sizeof (GSource));
+  GSource *source;
+
+  source = g_source_new (&g_idle_funcs, sizeof (GSource));
+  g_source_set_priority (source, G_PRIORITY_DEFAULT_IDLE);
+
+  return source;
 }
 
 /**
@@ -3287,7 +3294,7 @@ g_idle_add_full (gint           priority,
 
   source = g_idle_source_new ();
 
-  if (priority != G_PRIORITY_DEFAULT)
+  if (priority != G_PRIORITY_DEFAULT_IDLE)
     g_source_set_priority (source, priority);
 
   g_source_set_callback (source, function, data, notify);