Skip to content

Commit

Permalink
update user control template and add on frame complete event handler
Browse files Browse the repository at this point in the history
  • Loading branch information
GorgonMeducer committed Sep 6, 2024
1 parent 20520bc commit a07faf8
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 2 deletions.
4 changes: 2 additions & 2 deletions ARM.Arm-2D.pdsc
Original file line number Diff line number Diff line change
Expand Up @@ -256,8 +256,8 @@
<file category="other" name="ReleaseNote.md" />

<!-- the template for user controls -->
<file category="header" name="examples/common/controls/template/user_control_template.h" attr="template" select="User Control Template" version="1.2.2"/>
<file category="sourceC" name="examples/common/controls/template/user_control_template.c" attr="template" select="User Control Template" version="1.2.2"/>
<file category="header" name="examples/common/controls/template/user_control_template.h" attr="template" select="User Control Template" version="1.2.3"/>
<file category="sourceC" name="examples/common/controls/template/user_control_template.c" attr="template" select="User Control Template" version="1.2.3"/>

<!-- the template for scenes -->
<file category="sourceC" name="Helper/template/arm_2d_scene_template.c" attr="template" select="User Scene Template" version="1.3.3" />
Expand Down
7 changes: 7 additions & 0 deletions examples/common/controls/template/user_control_template.c
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,13 @@ void <control_name>_on_frame_start( user_<control_name>_t *ptThis)

}

ARM_NONNULL(1)
void <control_name>_on_frame_complete( user_<control_name>_t *ptThis)
{
assert(NULL != ptThis);

}

ARM_NONNULL(1)
void <control_name>_show( user_<control_name>_t *ptThis,
const arm_2d_tile_t *ptTile,
Expand Down
4 changes: 4 additions & 0 deletions examples/common/controls/template/user_control_template.h
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,10 @@ extern
ARM_NONNULL(1)
void <control_name>_on_frame_start( user_<control_name>_t *ptThis);

extern
ARM_NONNULL(1)
void <control_name>_on_frame_complete( user_<control_name>_t *ptThis);

extern
ARM_NONNULL(1)
void <control_name>_show( user_<control_name>_t *ptThis,
Expand Down

0 comments on commit a07faf8

Please sign in to comment.