Part 5: Configure State Machine
State Machine feature is used for transitioning a screen to others. Here, the display is transitioned by pressing Music and Navigation buttons in the Menu section.
Click the triangular icon beside Solution > State Machines in Solution Explorer. Double-click GlobalStateMachine that is shown after expanding State Machines.

- The State Machine Editor is shown.
- Make sure the checkbox of Is Global on Properties is marked.


Click State on State Machine Editor, and change Name on Properties to Music. Set the Identifier property to Music scene. (see the below)


Add Handle Control State to TextButton_Music and TextButton_Navigatio node in Menu_button group by drag-and-drop operation.

Return to the State Machine Editor panel. Drag and drop a State from the upper right toolbar.

Click that State on State Machine Editor, and change Name on Properties to Navigation. Connect the two States in both directions with a Transition (see figure).

Select each Transition and set the displayed Properties as shown in the table below.
Navigation to Music

| Transition | |
| Sender | Textbutton_Music |
| Event | Clicked |
| Condition | Check Click |
| Condition Parameters | |
| Sender | Textbutton_Music |
| Event | AnyClick |
| Condition | 0 |

| Transition | |
| Sender | Textbutton_Navigation |
| Event | Clicked |
| Condition | Check Click |
| Condition Parameters | |
| Sender | Textbutton_Navigation |
| Event | AnyClick |
| Condition | 0 |
Select Music State and add Transition Request behavior to On Entry Action/On Exit Action. After adding, set each behavior as shown in the table below.

| On Entry Action | |
| Action | Transition Request |
| RequestType | Activate |
| Identifiler | /Scenes/IVI_Sample/Group2D:IVI_Sample/Group2D:Music |
| On Exit Action | |
| Action | Transition Request |
| RequestType | Deactivate |
| Identifiler | /Scenes/IVI_Sample/Group2D:IVI_Sample/Group2D:Music |

| On Entry Action | |
| Action | Transition Request |
| RequestType | Activate |
| Identifiler | /Scenes/IVI_Sample/Group2D:IVI_Sample/Group2D:Navigation |
| On Exit Action | |
| Action | Transition Request |
| RequestType | Deactivate |
| Identifiler | /Scenes/IVI_Sample/Group2D:IVI_Sample/Group2D:Navigation |
Click the Play button in the menu bar to run CGI Player. Click the either button of Music/Navigation on the upper part to transition to other image.
