search for: swfdecasarray

Displaying 20 results from an estimated 25 matches for "swfdecasarray".

2007 Aug 17
0
2 commits - libswfdec/swfdec_as_array.c test/trace
...4a7..9d245c3 100644 --- a/libswfdec/swfdec_as_array.c +++ b/libswfdec/swfdec_as_array.c @@ -33,6 +33,7 @@ #include "swfdec_as_native_function.h" #include "swfdec_as_strings.h" #include "swfdec_debug.h" +#include "swfdec_player_internal.h" G_DEFINE_TYPE (SwfdecAsArray, swfdec_as_array, SWFDEC_TYPE_AS_OBJECT) @@ -73,7 +74,7 @@ swfdec_as_array_to_index (const char *st } static gint32 -swfdec_as_array_get_length (SwfdecAsObject *object) +swfdec_as_array_get_length_as_integer (SwfdecAsObject *object) { SwfdecAsValue val; gint32 length; @@ -83,6 +84,16 @...
2007 Aug 17
0
Branch 'vivi' - 9 commits - libswfdec/swfdec_as_array.c libswfdec/swfdec_as_function.c libswfdec/swfdec_as_function.h libswfdec/swfdec_as_internal.h libswfdec/swfdec_as_interpret.c libswfdec/swfdec_as_native_function.c
...4a7..9d245c3 100644 --- a/libswfdec/swfdec_as_array.c +++ b/libswfdec/swfdec_as_array.c @@ -33,6 +33,7 @@ #include "swfdec_as_native_function.h" #include "swfdec_as_strings.h" #include "swfdec_debug.h" +#include "swfdec_player_internal.h" G_DEFINE_TYPE (SwfdecAsArray, swfdec_as_array, SWFDEC_TYPE_AS_OBJECT) @@ -73,7 +74,7 @@ swfdec_as_array_to_index (const char *st } static gint32 -swfdec_as_array_get_length (SwfdecAsObject *object) +swfdec_as_array_get_length_as_integer (SwfdecAsObject *object) { SwfdecAsValue val; gint32 length; @@ -83,6 +84,16 @...
2007 Jul 13
0
12 commits - AUTHORS doc/Makefile.am doc/swfdec-docs.sgml doc/swfdec-sections.txt libswfdec/Makefile.am libswfdec/swfdec_as_array.c libswfdec/swfdec_as_array.h libswfdec/swfdec_as_context.c libswfdec/swfdec_as_function.c libswfdec/swfdec_as_function.h
...ocs.sgml b/doc/swfdec-docs.sgml index 2c7787f..553dfb1 100644 --- a/doc/swfdec-docs.sgml +++ b/doc/swfdec-docs.sgml @@ -27,5 +27,6 @@ <xi:include href="xml/SwfdecAsContext.xml"/> <xi:include href="xml/SwfdecAsObject.xml"/> <xi:include href="xml/SwfdecAsArray.xml"/> + <xi:include href="xml/SwfdecAsFunction.xml"/> </chapter> </book> diff --git a/doc/swfdec-sections.txt b/doc/swfdec-sections.txt index fd2f296..7773b37 100644 --- a/doc/swfdec-sections.txt +++ b/doc/swfdec-sections.txt @@ -296,4 +296,35 @@ SWFDEC_A...
2007 Nov 14
0
2 commits - libswfdec/swfdec_as_array.c libswfdec/swfdec_asbroadcaster.c libswfdec/swfdec_as_object.c libswfdec/swfdec_as_string.c libswfdec/swfdec_color_as.c libswfdec/swfdec_initialize.as
...nt32 length; + if (object == NULL) + return; + length = swfdec_as_array_length (object); swfdec_as_object_foreach_rename (object, swfdec_as_array_foreach_reverse, &length); @@ -760,6 +781,9 @@ swfdec_as_array_concat (SwfdecAsContext *cx, SwfdecAsObject *object, guint argc, SwfdecAsArray *array_new; const char *var; + if (object == NULL) + return; + object_new = swfdec_as_array_new (cx); if (object_new == NULL) return; @@ -794,6 +818,9 @@ swfdec_as_array_slice (SwfdecAsContext *cx, SwfdecAsObject *object, guint argc, SwfdecAsObject *object_new; SwfdecAsArr...
2008 Jan 07
0
3 commits - libswfdec-gtk/swfdec_gtk_loader.c libswfdec/swfdec_as_array.c libswfdec/swfdec_asbroadcaster.c libswfdec/swfdec_as_function.c libswfdec/swfdec_as_types.c libswfdec/swfdec_xml.c
...e swfdec_as_double_to_string with swfdec_as_integer_to_string where appropriate diff --git a/libswfdec/swfdec_as_array.c b/libswfdec/swfdec_as_array.c index 61a62e9..f28170c 100644 --- a/libswfdec/swfdec_as_array.c +++ b/libswfdec/swfdec_as_array.c @@ -182,7 +182,7 @@ swfdec_as_array_remove_range (SwfdecAsArray *array, gint32 start_index, // to avoid foreach loop, use special case when removing just one variable if (num == 1) { swfdec_as_object_delete_variable (object, - swfdec_as_double_to_string (object->context, start_index)); + swfdec_as_integer_to_string (object->context, start_index...
2008 Jan 15
0
4 commits - libswfdec/swfdec_as_array.c libswfdec/swfdec_as_types.c test/trace
...fdec/swfdec_as_array.c +++ b/libswfdec/swfdec_as_array.c @@ -33,6 +33,7 @@ #include "swfdec_as_native_function.h" #include "swfdec_as_string.h" #include "swfdec_as_strings.h" +#include "swfdec_movie.h" #include "swfdec_debug.h" G_DEFINE_TYPE (SwfdecAsArray, swfdec_as_array, SWFDEC_TYPE_AS_OBJECT) @@ -590,7 +591,7 @@ swfdec_as_array_join (SwfdecAsContext *cx, SwfdecAsObject *object, guint argc, const char *var, *str, *sep; SwfdecAsValue val; - if (object == NULL) + if (object == NULL || SWFDEC_IS_MOVIE (object)) return; if (argc &g...
2007 Aug 19
0
2 commits - libswfdec/swfdec_as_array.c libswfdec/swfdec_as_object.c libswfdec/swfdec_as_object.h libswfdec/swfdec_as_super.c libswfdec/swfdec_as_with.c libswfdec/swfdec_movie.c libswfdec/swfdec_player.c libswfdec/swfdec_sprite_movie.c
...fdec/swfdec_as_array.c index 9d245c3..a64b165 100644 --- a/libswfdec/swfdec_as_array.c +++ b/libswfdec/swfdec_as_array.c @@ -400,7 +400,7 @@ swfdec_as_array_new (SwfdecAsContext *co return FALSE; ret = g_object_new (SWFDEC_TYPE_AS_ARRAY, NULL); swfdec_as_object_add (ret, context, sizeof (SwfdecAsArray)); - swfdec_as_object_set_constructor (ret, context->Array, FALSE); + swfdec_as_object_set_constructor (ret, context->Array); return ret; } @@ -1052,8 +1052,7 @@ swfdec_as_array_construct (SwfdecAsConte swfdec_as_object_add (object, cx, sizeof (SwfdecAsArray)); swfdec_as_obj...
2007 Jul 02
0
Branch 'as' - 24 commits - configure.ac doc/Makefile.am doc/swfdec-sections.txt libswfdec/Makefile.am libswfdec/swfdec_amf.c libswfdec/swfdec_as_array.c libswfdec/swfdec_as_context.c libswfdec/swfdec_as_context.h libswfdec/swfdec_as_frame.c
...swfdec_as_array.c +++ b/libswfdec/swfdec_as_array.c @@ -29,6 +29,7 @@ #include "swfdec_as_frame.h" #include "swfdec_as_function.h" #include "swfdec_as_native_function.h" +#include "swfdec_as_strings.h" #include "swfdec_debug.h" G_DEFINE_TYPE (SwfdecAsArray, swfdec_as_array, SWFDEC_TYPE_AS_OBJECT) diff --git a/libswfdec/swfdec_as_frame.c b/libswfdec/swfdec_as_frame.c index d05ba82..a5718bd 100644 --- a/libswfdec/swfdec_as_frame.c +++ b/libswfdec/swfdec_as_frame.c @@ -25,6 +25,7 @@ #include "swfdec_as_array.h" #include "swfdec_as_conte...
2007 Aug 22
0
3 commits - libswfdec/swfdec_as_array.c libswfdec/swfdec_as_function.c test/trace
...= SWFDEC_AS_OBJECT_CLASS (klass); - asobject_class->add = swfdec_as_array_add; asobject_class->set = swfdec_as_array_set; } @@ -401,6 +392,7 @@ swfdec_as_array_new (SwfdecAsContext *co ret = g_object_new (SWFDEC_TYPE_AS_ARRAY, NULL); swfdec_as_object_add (ret, context, sizeof (SwfdecAsArray)); swfdec_as_object_set_constructor (ret, context->Array); + swfdec_as_array_set_length (ret, 0); return ret; } @@ -1064,6 +1056,8 @@ swfdec_as_array_construct (SwfdecAsConte swfdec_as_array_set_length (object, l < 0 ? 0 : l); } else if (argc > 0) { swfdec_as_array_a...
2007 Apr 04
0
Branch 'as' - 17 commits - configure.ac doc/Makefile.am doc/swfdec-docs.sgml doc/swfdec-sections.txt doc/swfdec.types libswfdec-gtk/Makefile.am libswfdec-gtk/swfdec-gtk.h libswfdec-gtk/swfdec_gtk_loader.c libswfdec-gtk/swfdec_gtk_loader.h
...treet, Fifth Floor, + * Boston, MA 02110-1301 USA + */ + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#include "swfdec_as_array.h" +#include "swfdec_as_context.h" +#include "swfdec_as_stack.h" +#include "swfdec_debug.h" + +G_DEFINE_TYPE (SwfdecAsArray, swfdec_as_array, SWFDEC_TYPE_AS_OBJECT) + +static void +swfdec_as_array_dispose (GObject *object) +{ + SwfdecAsArray *array = SWFDEC_AS_ARRAY (object); + + g_array_free (array->values, TRUE); + + G_OBJECT_CLASS (swfdec_as_array_parent_class)->dispose (object); +} + +static void +swfdec_as...
2007 Jun 28
0
Branch 'as' - 4 commits - doc/Makefile.am doc/swfdec-docs.sgml doc/swfdec-sections.txt libswfdec/swfdec_as_interpret.c libswfdec/swfdec_as_types.c libswfdec/swfdec_as_types.h
...pes.h b/libswfdec/swfdec_as_types.h index 23502d9..531cf52 100644 --- a/libswfdec/swfdec_as_types.h +++ b/libswfdec/swfdec_as_types.h @@ -35,7 +35,7 @@ typedef enum { SWFDEC_AS_TYPE_STRING, SWFDEC_AS_TYPE_NULL, SWFDEC_AS_TYPE_OBJECT -} SwfdecAsType; +} SwfdecAsValueType; typedef struct _SwfdecAsArray SwfdecAsArray; typedef struct _SwfdecAsContext SwfdecAsContext; @@ -53,7 +53,7 @@ typedef void (* SwfdecAsNative) (SwfdecA /* IMPORTANT: a SwfdecAsValue memset to 0 is a valid undefined value */ struct _SwfdecAsValue { - SwfdecAsType type; + SwfdecAsValueType type; union { gboolean...
2007 Jun 13
0
Branch 'as' - 6 commits - libswfdec/swfdec_as_array.c libswfdec/swfdec_button_movie.c libswfdec/swfdec_morph_movie.c libswfdec/swfdec_movie_asprops.c libswfdec/swfdec_movie.c libswfdec/swfdec_movie.h libswfdec/swfdec_player.c libswfdec/swfdec_sprite.c
...} static void -swfdec_as_array_construct (SwfdecAsObject *object, guint argc, SwfdecAsValue *argv, SwfdecAsValue *ret) +swfdec_as_array_construct (SwfdecAsContext *cx, SwfdecAsObject *object, guint argc, SwfdecAsValue *argv, SwfdecAsValue *ret) { - SwfdecAsContext *cx = object->context; SwfdecAsArray *array; if (!cx->frame->construct) { diff-tree c1678f97c65c068803abb01d9969f38fc4da9171 (from parents) Merge: 8680a64a0a4398d1095f1ff0de40d19eced9934d e7db3c7145922223dbd67702992e5d47df703fa4 Author: Benjamin Otte <otte at gnome.org> Date: Wed Jun 13 15:38:50 2007 +0200 Merg...
2007 Dec 20
0
13 commits - libswfdec/swfdec_as_array.c libswfdec/swfdec_xml.c libswfdec/swfdec_xml_node.c test/trace
...t; Date: Thu Dec 20 11:45:48 2007 +0200 Minor cleanups to the array code diff --git a/libswfdec/swfdec_as_array.c b/libswfdec/swfdec_as_array.c index 151b159..2c89241 100644 --- a/libswfdec/swfdec_as_array.c +++ b/libswfdec/swfdec_as_array.c @@ -181,8 +181,8 @@ swfdec_as_array_remove_range (SwfdecAsArray *array, gint32 start_index, // to avoid foreach loop, use special case when removing just one variable if (num == 1) { - const char *var = swfdec_as_double_to_string (object->context, start_index); - swfdec_as_object_delete_variable (object, var); + swfdec_as_object_delete_varia...
2007 Jun 12
0
Branch 'as' - 3 commits - libswfdec/swfdec_as_array.c libswfdec/swfdec_as_context.c libswfdec/swfdec_as_math.c libswfdec/swfdec_as_native_function.c libswfdec/swfdec_as_number.c libswfdec/swfdec_as_object.c libswfdec/swfdec_as_string.c
...ec_as_object_add_function () or via swfdec_as_native_function_set_object_type (). diff --git a/libswfdec/swfdec_as_array.c b/libswfdec/swfdec_as_array.c index e2071b6..b72e43b 100644 --- a/libswfdec/swfdec_as_array.c +++ b/libswfdec/swfdec_as_array.c @@ -160,9 +160,9 @@ swfdec_as_array_append (SwfdecAsArray *a /*** AS CODE ***/ static void -swfdec_as_array_toString (SwfdecAsObject *object, guint argc, SwfdecAsValue *argv, SwfdecAsValue *ret) +swfdec_as_array_toString (SwfdecAsContext *cx, SwfdecAsObject *object, + guint argc, SwfdecAsValue *argv, SwfdecAsValue *ret) { - SwfdecAsContext *cx =...
2007 May 29
0
Branch 'as' - 8 commits - libswfdec/Makefile.am libswfdec/swfdec_as_array.c libswfdec/swfdec_as_context.c libswfdec/swfdec_as_interpret.c libswfdec/swfdec_as_math.c libswfdec/swfdec_as_math.h libswfdec/swfdec_as_strings.c libswfdec/swfdec_as_types.c
...--- a/libswfdec/swfdec_as_array.c +++ b/libswfdec/swfdec_as_array.c @@ -184,6 +184,15 @@ swfdec_as_array_toString (SwfdecAsObject SWFDEC_AS_VALUE_SET_STRING (ret, str); } +static void +swfdec_as_array_do_push (SwfdecAsObject *object, guint argc, SwfdecAsValue *argv, SwfdecAsValue *ret) +{ + SwfdecAsArray *array = SWFDEC_AS_ARRAY (object); + + swfdec_as_array_append (array, argc, argv); + SWFDEC_AS_VALUE_SET_INT (ret, swfdec_as_array_get_length (object)); +} + void swfdec_as_array_init_context (SwfdecAsContext *context, guint version) { @@ -224,5 +233,6 @@ swfdec_as_array_init_context (SwfdecAs...
2008 Jan 19
0
11 commits - libswfdec/swfdec_as_strings.c libswfdec/swfdec_sprite_movie_as.c libswfdec/swfdec_xml.c libswfdec/swfdec_xml.h libswfdec/swfdec_xml_node.c libswfdec/swfdec_xml_node.h test/image test/swfdec_test.c test/swfdec_test_image.c test/trace
...13 100644 --- a/libswfdec/swfdec_xml_node.h +++ b/libswfdec/swfdec_xml_node.h @@ -71,7 +71,7 @@ struct _SwfdecXmlNode { // visible trough childNodes property, if modified by the user directly, the // changes are not visible in children and will get overwritten by next // internal change - SwfdecAsArray *childNodes; + SwfdecAsArray *child_nodes; }; struct _SwfdecXmlNodeClass { commit e6da5c25955dc814346d12ff7f7ccb7c65531155 Author: Pekka Lampila <pekka.lampila at iki.fi> Date: Thu Jan 17 13:34:32 2008 +0200 Don't let changing ignoreWhite property while parsing XML have an e...
2007 Sep 04
0
5 commits - doc/Makefile.am doc/swfdec-sections.txt libswfdec/swfdec_as_array.c libswfdec/swfdec_as_boolean.c libswfdec/swfdec_asbroadcaster.c libswfdec/swfdec_as_internal.h libswfdec/swfdec_as_native_function.c libswfdec/swfdec_as_native_function.h
...22a..959d906 100644 --- a/libswfdec/swfdec_as_array.c +++ b/libswfdec/swfdec_as_array.c @@ -33,7 +33,6 @@ #include "swfdec_as_native_function.h" #include "swfdec_as_strings.h" #include "swfdec_debug.h" -#include "swfdec_player_internal.h" G_DEFINE_TYPE (SwfdecAsArray, swfdec_as_array, SWFDEC_TYPE_AS_OBJECT) diff --git a/libswfdec/swfdec_as_boolean.c b/libswfdec/swfdec_as_boolean.c index 6764cbe..4645254 100644 --- a/libswfdec/swfdec_as_boolean.c +++ b/libswfdec/swfdec_as_boolean.c @@ -25,10 +25,10 @@ #include "swfdec_as_boolean.h" #include &quot...
2007 Apr 12
0
Branch 'as' - 14 commits - libswfdec-gtk/swfdec_playback_alsa.c libswfdec/swfdec_as_context.c libswfdec/swfdec_as_context.h libswfdec/swfdec_as_frame.c libswfdec/swfdec_as_frame.h libswfdec/swfdec_as_function.c libswfdec/swfdec_as_function.h
...WFDEC_AS_TYPE_UNDEFINED = 0, + SWFDEC_AS_TYPE_BOOLEAN, + SWFDEC_AS_TYPE_INT, /* unimplemented, but reserved if someone wants it */ + SWFDEC_AS_TYPE_NUMBER, + SWFDEC_AS_TYPE_STRING, + SWFDEC_AS_TYPE_NULL, + SWFDEC_AS_TYPE_OBJECT +} SwfdecAsType; -typedef guint8 SwfdecAsType; typedef struct _SwfdecAsArray SwfdecAsArray; typedef struct _SwfdecAsContext SwfdecAsContext; typedef struct _SwfdecAsFrame SwfdecAsFrame; @@ -56,41 +57,41 @@ struct _SwfdecAsValue { #define SWFDEC_IS_AS_VALUE(val) ((val)->type <= SWFDEC_TYPE_AS_OBJECT) -#define SWFDEC_AS_VALUE_IS_UNDEFINED(val) ((val)->type ==...
2007 Jul 13
0
3 commits - doc/Makefile.am doc/swfdec-docs.sgml doc/swfdec-sections.txt libswfdec/Makefile.am libswfdec/swfdec_as_array.c libswfdec/swfdec_as_boolean.c libswfdec/swfdec_as_context.c libswfdec/swfdec_as_context.h libswfdec/swfdec_as_frame.c
...ec_as_interpret.h \ swfdec_as_math.h \ diff --git a/doc/swfdec-docs.sgml b/doc/swfdec-docs.sgml index 553dfb1..e04ade0 100644 --- a/doc/swfdec-docs.sgml +++ b/doc/swfdec-docs.sgml @@ -28,5 +28,6 @@ <xi:include href="xml/SwfdecAsObject.xml"/> <xi:include href="xml/SwfdecAsArray.xml"/> <xi:include href="xml/SwfdecAsFunction.xml"/> + <xi:include href="xml/SwfdecAsFrame.xml"/> </chapter> </book> diff --git a/doc/swfdec-sections.txt b/doc/swfdec-sections.txt index 7773b37..9c0f01c 100644 --- a/doc/swfdec-sections...
2007 Aug 24
0
7 commits - libswfdec/swfdec_as_context.c libswfdec/swfdec_as_interpret.c libswfdec/swfdec_as_object.h libswfdec/swfdec_as_string.c test/trace
...) return; @@ -347,7 +354,7 @@ swfdec_as_string_split_5 (SwfdecAsContex } static void -swfdec_as_string_split (SwfdecAsContext *cx, SwfdecAsObject *object, +swfdec_as_string_split_6 (SwfdecAsContext *cx, SwfdecAsObject *object, guint argc, SwfdecAsValue *argv, SwfdecAsValue *ret) { SwfdecAsArray *arr; @@ -356,7 +363,7 @@ swfdec_as_string_split (SwfdecAsContext int count; guint len; - str = SWFDEC_AS_STRING (object)->string; + str = swfdec_as_object_to_string (cx, object); arr = SWFDEC_AS_ARRAY (swfdec_as_array_new (cx)); if (arr == NULL) return; @@ -402,6 +409,18 @...