validate:scenario: Properly handle ASYNC action execution in the API
authorThibault Saunier <tsaunier@gnome.org>
Sun, 9 Nov 2014 18:08:52 +0000 (19:08 +0100)
committerThibault Saunier <tsaunier@gnome.org>
Tue, 25 Nov 2014 18:41:00 +0000 (19:41 +0100)
commitcdfa1ee61b8154dfd2a6d0e11c7f03fd7ca2d5eb
tree74f085205a1574470ab028d10a6c08f0b2298648
parent4cbcb97258236025cc7133a5dfe7f63178e9c446
validate:scenario: Properly handle ASYNC action execution in the API

The ->execute function now return a GstValidateExecuteActionReturn
which can be set as ASYNC in order to tell the scenario that the action
will be executed asynchronously, when the action is done, the caller is
responsible for calling gst_validate_action_set_done(); so that the
scenario keeps going on.

In this commit we make sure that the old API keeps working as
GST_VALIDATE_EXECUTE_ACTION_ERROR == FALSE and
GST_VALIDATE_EXECUTE_ACTION_OK == TRUE

Morevover GstValidateExecuteActionReturn is just a define

API:
    + gst_validate_action_set_done
    + GstValidateExecuteActionReturn

https://bugzilla.gnome.org/show_bug.cgi?id=739854
validate/gst/validate/gst-validate-internal.h
validate/gst/validate/gst-validate-scenario.c
validate/gst/validate/gst-validate-scenario.h