[clutter] Deprecate clutter_get_timestamp()



commit 66d46fd55e15b7e882cbf99d7525475eb35c4322
Author: Emmanuele Bassi <ebassi linux intel com>
Date:   Tue Nov 15 17:47:00 2011 +0000

    Deprecate clutter_get_timestamp()
    
    This function should have never been made public in the first place; its
    output depends on a configuration option of Clutter, and it's basically
    useful only for internal debugging.

 clutter/clutter-main.c            |   16 ++++++++++++++--
 clutter/clutter-main.h            |    1 -
 clutter/deprecated/clutter-main.h |    3 +++
 3 files changed, 17 insertions(+), 3 deletions(-)
---
diff --git a/clutter/clutter-main.c b/clutter/clutter-main.c
index 3f78bd1..d234f1d 100644
--- a/clutter/clutter-main.c
+++ b/clutter/clutter-main.c
@@ -1417,10 +1417,22 @@ _clutter_context_get_default (void)
 /**
  * clutter_get_timestamp:
  *
- * Returns the approximate number of microseconds passed since clutter was
+ * Returns the approximate number of microseconds passed since Clutter was
  * intialised.
  *
- * Return value: Number of microseconds since clutter_init() was called.
+ * This function shdould not be used by application code.
+ *
+ * The output of this function depends on whether Clutter was configured to
+ * enable its debugging code paths, so it's less useful than intended.
+ *
+ * Since Clutter 1.10, this function is an alias to g_get_monotonic_time()
+ * if Clutter was configured to enable the debugging code paths.
+ *
+ * Return value: Number of microseconds since clutter_init() was called, or
+ *   zero if Clutter was not configured with debugging code paths.
+ *
+ * Deprecated: 1.10: Use #GTimer or g_get_monotonic_time() for a proper
+ *   timing source
  */
 gulong
 clutter_get_timestamp (void)
diff --git a/clutter/clutter-main.h b/clutter/clutter-main.h
index 175356b..622f80d 100644
--- a/clutter/clutter-main.h
+++ b/clutter/clutter-main.h
@@ -100,7 +100,6 @@ void                    clutter_do_event                        (ClutterEvent *e
 /* Debug utility functions */
 gboolean                clutter_get_debug_enabled               (void);
 gboolean                clutter_get_show_fps                    (void);
-gulong                  clutter_get_timestamp                   (void);
 gboolean                clutter_get_accessibility_enabled       (void);
 
 /* Threading functions */
diff --git a/clutter/deprecated/clutter-main.h b/clutter/deprecated/clutter-main.h
index 4ec39b6..2067b3a 100644
--- a/clutter/deprecated/clutter-main.h
+++ b/clutter/deprecated/clutter-main.h
@@ -51,6 +51,9 @@ void                    clutter_ungrab_pointer_for_device       (gint
 CLUTTER_DEPRECATED
 void                    clutter_set_default_frame_rate          (guint             frames_per_sec);
 
+CLUTTER_DEPRECATED
+gulong                  clutter_get_timestamp                   (void);
+
 G_END_DECLS
 
 #endif /* __CLUTTER_MAIN_DEPRECATED_H__ */



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]