mirror of
https://gitee.com/zlgopen/awtk.git
synced 2024-11-30 02:58:26 +08:00
fix widget_do_exec
This commit is contained in:
parent
590f89100d
commit
39678db0eb
@ -1289,7 +1289,7 @@ ret_t widget_paint(widget_t* widget, canvas_t* c) {
|
||||
static const widget_cmd_t s_widget_cmds[] = {{"start_animator", widget_start_animator},
|
||||
{"stop_animator", widget_stop_animator},
|
||||
{"pause_animator", widget_pause_animator},
|
||||
{"pause_animator", widget_destroy_animator}};
|
||||
{"destroy_animator", widget_destroy_animator}};
|
||||
|
||||
static ret_t widget_do_exec(widget_t* widget, const char* cmd, const char* args) {
|
||||
uint32_t i = 0;
|
||||
|
@ -1189,6 +1189,7 @@ TEST(Widget, exec) {
|
||||
ASSERT_EQ(widget_set_prop_str(w, WIDGET_PROP_EXEC, "pause_animator:move"), RET_OK);
|
||||
ASSERT_EQ(widget_set_prop_str(w, WIDGET_PROP_EXEC, "stop_animator:move"), RET_OK);
|
||||
ASSERT_EQ(widget_set_prop_str(w, WIDGET_PROP_EXEC, "start_animator:move"), RET_OK);
|
||||
ASSERT_EQ(widget_set_prop_str(w, WIDGET_PROP_EXEC, "destroy_animator:move"), RET_OK);
|
||||
ASSERT_EQ(widget_set_prop_str(w, WIDGET_PROP_EXEC, "not found"), RET_NOT_FOUND);
|
||||
ASSERT_EQ(widget_set_prop_str(w, WIDGET_PROP_EXEC, NULL), RET_NOT_FOUND);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user