~ubuntu-branches/ubuntu/precise/clutter-1.0/precise

« back to all changes in this revision

Viewing changes to clutter/clutter-timeout-pool.c

  • Committer: Bazaar Package Importer
  • Author(s): Emilio Pozuelo Monfort
  • Date: 2010-03-21 13:27:56 UTC
  • mto: (2.1.3 experimental) (1.3.1 upstream)
  • mto: This revision was merged to the branch mainline in revision 8.
  • Revision ID: james.westby@ubuntu.com-20100321132756-nf8yd30yxo3zzwcm
Tags: upstream-1.2.2
ImportĀ upstreamĀ versionĀ 1.2.2

Show diffs side-by-side

added added

removed removed

Lines of Context:
18
18
 * Lesser General Public License for more details.
19
19
 *
20
20
 * You should have received a copy of the GNU Lesser General Public
21
 
 * License along with this library; if not, write to the
22
 
 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
23
 
 * Boston, MA 02111-1307, USA.
 
21
 * License along with this library. If not, see <http://www.gnu.org/licenses/>.
 
22
 *
 
23
 *
24
24
 *
25
25
 * ClutterTimeoutPool: pool of timeout functions using the same slice of
26
26
 *                     the GLib main loop
209
209
clutter_timeout_pool_check (GSource *source)
210
210
{
211
211
  ClutterTimeoutPool *pool = (ClutterTimeoutPool *) source;
212
 
  GList *l = pool->timeouts;
 
212
  GList *l;
213
213
 
214
214
  clutter_threads_enter ();
215
215
 
359
359
 * always sorted, so that the extraction of the next timeout function is
360
360
 * a constant time operation.
361
361
 *
362
 
 * Inside Clutter, every #ClutterTimeline share the same timeout pool, unless
363
 
 * the CLUTTER_TIMELINE=no-pool environment variable is set.
364
 
 *
365
 
 * #ClutterTimeoutPool is part of the #ClutterTimeline implementation
366
 
 * and should not be used by application developers.
367
 
 *
368
362
 * Return value: the newly created #ClutterTimeoutPool. The created pool
369
363
 *   is owned by the GLib default context and will be automatically
370
364
 *   destroyed when the context is destroyed. It is possible to force
412
406
 * won't be called again. If @notify is not %NULL, the @notify function
413
407
 * will be called. The first call to @func will be at the end of @interval.
414
408
 *
415
 
 * Since version 0.8 this will try to compensate for delays. For
 
409
 * Since Clutter 0.8 this will try to compensate for delays. For
416
410
 * example, if @func takes half the interval time to execute then the
417
411
 * function will be called again half the interval time after it
418
412
 * finished. Before version 0.8 it would not fire until a full
478
472
                                    clutter_timeout_find_by_id)))
479
473
    {
480
474
      clutter_timeout_unref (l->data);
481
 
      pool->dispatched_timeouts
482
 
        = g_list_delete_link (pool->dispatched_timeouts, l);
 
475
 
 
476
      pool->dispatched_timeouts =
 
477
        g_list_delete_link (pool->dispatched_timeouts, l);
483
478
    }
484
479
}