Displaying 7 results from an estimated 7 matches for "swfdec_root_action_export".
2007 Jun 06
0
Branch 'as' - libswfdec/Makefile.am libswfdec/swfdec_root_movie.c libswfdec/swfdec_root_sprite.c libswfdec/swfdec_root_sprite.h libswfdec/swfdec_swf_decoder.c libswfdec/swfdec_swf_decoder.h libswfdec/swfdec_tag.c
...ions) {
- for (i = 0; i < sprite->n_frames; i++) {
- GArray *array = root->root_actions[i];
- if (array) {
- for (j = 0; j < array->len; j++) {
- SwfdecSpriteAction *action = &g_array_index (array, SwfdecSpriteAction, j);
-
- switch (action->type) {
- case SWFDEC_ROOT_ACTION_EXPORT:
- {
- SwfdecRootExportData *data = action->data;
- g_free (data->name);
- g_object_unref (data->character);
- g_free (data);
- }
- break;
- case SWFDEC_ROOT_ACTION_INIT_SCRIPT:
- swfdec_script_unref (action->data);
- break;
- default:
- g...
2007 Mar 09
0
libswfdec/swfdec_root_sprite.c libswfdec/swfdec_root_sprite.h
...ions) {
+ for (i = 0; i < sprite->n_frames; i++) {
+ GArray *array = root->root_actions[i];
+ if (array) {
+ for (j = 0; j < array->len; j++) {
+ SwfdecSpriteAction *action = &g_array_index (array, SwfdecSpriteAction, j);
+
+ switch (action->type) {
+ case SWFDEC_ROOT_ACTION_EXPORT:
+ {
+ SwfdecRootExportData *data = action->data;
+ g_free (data->name);
+ g_object_unref (data->character);
+ g_free (data);
+ }
+ break;
+ case SWFDEC_ROOT_ACTION_INIT_SCRIPT:
+ swfdec_script_unref (action->data);
+ break;
+ default:
+ g...
2007 Oct 25
0
6 commits - libswfdec/swfdec_as_interpret.c libswfdec/swfdec_event.c libswfdec/swfdec_event.h libswfdec/swfdec_movie.c libswfdec/swfdec_movie.h libswfdec/swfdec_player.c libswfdec/swfdec_player_internal.h libswfdec/swfdec_resource.c
...decRootAction *action = &g_array_index (array, SwfdecRootAction, i);
- switch (action->type) {
- case SWFDEC_ROOT_ACTION_INIT_SCRIPT:
- swfdec_as_object_run_with_security (SWFDEC_AS_OBJECT (instance->movie),
- action->data, SWFDEC_SECURITY (instance));
- break;
- case SWFDEC_ROOT_ACTION_EXPORT:
- {
- SwfdecRootExportData *data = action->data;
- swfdec_resource_add_export (instance, data->character, data->name);
- }
- break;
- default:
- g_assert_not_reached ();
- }
- }
-}
-
diff --git a/libswfdec/swfdec_resource.h b/libswfdec/swfdec_resource.h
index c5fd4e2..1a38ea0...
2007 Mar 07
0
13 commits - libswfdec/Makefile.am libswfdec/swfdec_js_global.c libswfdec/swfdec_js_movie.c libswfdec/swfdec_root_movie.c libswfdec/swfdec_root_movie.h libswfdec/swfdec_script.c libswfdec/swfdec_sprite.h libswfdec/swfdec_sprite_movie.c
...RootMovie *decoder)
+swfdec_root_movie_init (SwfdecRootMovie *root)
{
+ root->exports = g_hash_table_new (g_str_hash, g_str_equal);
}
void
@@ -240,9 +242,22 @@ swfdec_root_movie_perform_root_actions (
swfdec_script_execute (action->data, SWFDEC_SCRIPTABLE (root));
break;
case SWFDEC_ROOT_ACTION_EXPORT:
+ {
+ SwfdecRootExportData *data = action->data;
+ g_hash_table_insert (root->exports, data->name, data->character);
+ }
break;
default:
g_assert_not_reached ();
}
}
}
+
+gpointer
+swfdec_root_movie_get_export (SwfdecRootMovie *root, const char *name)
+{
+ g_re...
2007 Oct 18
0
18 commits - doc/swfdec-sections.txt libswfdec/Makefile.am libswfdec/swfdec_as_interpret.c libswfdec/swfdec_as_strings.c libswfdec/swfdec_button_movie.c libswfdec/swfdec_event.c libswfdec/swfdec_event.h libswfdec/swfdec_flash_security.c
...tch (action->type) {
case SWFDEC_ROOT_ACTION_INIT_SCRIPT:
- swfdec_as_object_run (SWFDEC_AS_OBJECT (instance->movie), action->data);
+ swfdec_as_object_run_with_security (SWFDEC_AS_OBJECT (instance->movie),
+ action->data, SWFDEC_SECURITY (instance));
break;
case SWFDEC_ROOT_ACTION_EXPORT:
{
diff --git a/libswfdec/swfdec_sprite_movie.c b/libswfdec/swfdec_sprite_movie.c
index 78b1978..68c6fd7 100644
--- a/libswfdec/swfdec_sprite_movie.c
+++ b/libswfdec/swfdec_sprite_movie.c
@@ -55,7 +55,8 @@ swfdec_sprite_movie_remove_child (SwfdecMovie *movie, int depth)
static void
swfdec_sprit...
2007 Jun 18
0
Branch 'as' - 8 commits - libswfdec/swfdec_movie.c libswfdec/swfdec_sprite.c libswfdec/swfdec_sprite.h libswfdec/swfdec_sprite_movie.c libswfdec/swfdec_sprite_movie.h libswfdec/swfdec_swf_decoder.c libswfdec/swfdec_swf_decoder.h
...ray = s->root_actions[i];
if (array) {
for (j = 0; j < array->len; j++) {
- SwfdecSpriteAction *action = &g_array_index (array, SwfdecSpriteAction, j);
+ SwfdecRootAction *action = &g_array_index (array, SwfdecRootAction, j);
switch (action->type) {
case SWFDEC_ROOT_ACTION_EXPORT:
@@ -86,6 +86,7 @@ swfdec_decoder_dispose (GObject *object)
g_hash_table_destroy (s->characters);
g_object_unref (s->main_sprite);
+ g_hash_table_destroy (s->scripts);
if (s->uncompressed_buffer) {
inflateEnd (&s->z);
@@ -379,7 +380,7 @@ swfdec_swf_decoder_clas...
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
...ction *action = &g_array_index (array, SwfdecSpriteAction, i);
switch (action->type) {
case SWFDEC_ROOT_ACTION_INIT_SCRIPT:
- swfdec_script_execute (action->data, SWFDEC_SCRIPTABLE (root));
+ swfdec_as_object_run (SWFDEC_AS_OBJECT (root), action->data);
break;
case SWFDEC_ROOT_ACTION_EXPORT:
{
diff --git a/libswfdec/swfdec_script.c b/libswfdec/swfdec_script.c
index 60b107a..a537953 100644
--- a/libswfdec/swfdec_script.c
+++ b/libswfdec/swfdec_script.c
@@ -25,13 +25,11 @@
#include "swfdec_as_context.h"
#include "swfdec_debug.h"
#include "swfdec_debugger.h&...