#include <libsswf.h>
Inheritance diagram for sswf::ActionGoto:
Public Member Functions | |
ActionGoto (TagBase *tag, action_t action=ACTION_GOTO_FRAME) | |
Initializes the ActionGoto action. | |
void | SetFrameName (const char *frame_name) |
Set the name of the frame to go to. | |
void | SetPlay (bool play) |
Set whether the animation continues to play after the goto. | |
Private Member Functions | |
virtual Action * | Duplicate (void) const |
Create a duplicate of this action goto. | |
virtual ErrorManager::error_code_t | SaveData (Data &data, Data &nested_data) |
Save the extraneous information of the ActionGoto. | |
Private Attributes | |
char * | f_frame_name |
bool | f_play |
This function initializes the ActionGoto. This means the frame name is set to NULL and the playback flag is set to false (i.e. go to that frame and stop playing.)
The valid actions are:
Action * ActionGoto::Duplicate | ( | void | ) | const [private, virtual] |
Create a new ActionGoto object copy the frame name and whether to continue or stop playback.
Reimplemented from sswf::Action.
ErrorManager::error_code_t ActionGoto::SaveData | ( | Data & | data, | |
Data & | nested_data | |||
) | [private, virtual] |
Save the label information of the ActionGoto object.
[in] | data | The Data buffer where the ActionGoto is to be saved |
[in] | nested_data | There is no nested data in an ActionGoto |
Reimplemented from sswf::Action.
void ActionGoto::SetFrameName | ( | const char * | frame_name | ) |
It is possible to give a name to a frame. This action can then be used to go to that frame. You need to use an ACTION_GOTO_FRAME or ACTION_GOTO_LABEL for this purpose. The ACTION_GOTO_EXPRESSION uses the last string on the stack instead.
In case of an ACTION_GOTO_FRAME, the name can actually be a frame number in ASCII (i.e. "15"), otherwise it is the SSWF label name of a frame.
In case of an ACTION_GOTO_LABEL, whether the label exists in the movie is not being tested by the library.
[in] | frame_name | The name of the frame you want to go to |
void sswf::ActionGoto::SetPlay | ( | bool | play | ) | [inline] |
This function is used to define whether the animation should continue to play after it jumped to the specified frame.
By default, the action says that the animation should stop playing.
[in] | play | The flag to tell whether it should play (true) or not (false) |
char* sswf::ActionGoto::f_frame_name [private] |
bool sswf::ActionGoto::f_play [private] |