[gtk+/gtk-style-context: 430/540] GtkAnimationDescription: parse "loop" correctly.
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/gtk-style-context: 430/540] GtkAnimationDescription: parse "loop" correctly.
- Date: Fri, 3 Dec 2010 03:12:16 +0000 (UTC)
commit a17228b32ff9bb249da8a1a4eceb33a7820704e3
Author: Carlos Garnacho <carlosg gnome org>
Date: Mon Nov 22 03:43:56 2010 +0100
GtkAnimationDescription: parse "loop" correctly.
This sscanf parsing needs to go...
gtk/gtkanimationdescription.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/gtk/gtkanimationdescription.c b/gtk/gtkanimationdescription.c
index cef6ade..785018a 100644
--- a/gtk/gtkanimationdescription.c
+++ b/gtk/gtkanimationdescription.c
@@ -84,11 +84,12 @@ gtk_animation_description_from_string (const gchar *str)
{
gchar timing_function[16] = { 0, };
gchar duration_unit[3] = { 0, };
+ gchar loop_str[5] = { 0, };
GtkTimelineProgressType progress_type;
guint duration = 0;
gboolean loop;
- if (sscanf (str, "%d%2s %15s loop", &duration, duration_unit, timing_function) == 3)
+ if (sscanf (str, "%d%2s %15s %5s", &duration, duration_unit, timing_function, loop_str) == 4)
loop = TRUE;
else if (sscanf (str, "%d%2s %15s", &duration, duration_unit, timing_function) == 3)
loop = FALSE;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]