aboutsummaryrefslogtreecommitdiffstats
path: root/policy_manager/stm/zipc/StateTransitionor/AppsLayer/ZAPL_Apps_func.c
blob: 8d14bf316f793716db604f37eef47e5fdd94d4e7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
/************************************************************/
/*     ZAPL_Apps_func.c                                     */
/*     Function and variable source file                    */
/*     ZIPC Designer Version 1.2.1                          */
/************************************************************/
#include "../ZST_include.h"

/*************************************************************
    Function definition
*************************************************************/

/*
 * @name stm_apl_start_activity_none
 */
void stm_apl_start_activity_none() {
    g_stm_crr_state.layer[StmLayerNoApps].state = StmLayoutNoNone;
    g_stm_crr_state.layer[StmLayerNoApps].changed = STM_TRUE;
}

/*
 * @name stm_apl_start_activity_map
 */
void stm_apl_start_activity_map() {
    g_stm_crr_state.layer[StmLayerNoApps].state = StmLayoutNoMapNml;
    g_stm_crr_state.layer[StmLayerNoApps].changed = STM_TRUE;

    if ((g_stm_event == StmEvtNoActivate)
    		&& (g_stm_category == StmCtgNoMap)) {
    	g_stm_map_is_activated = STM_TRUE;
    }
}

/*
 * @name stm_apl_start_activity_map_split
 */
void stm_apl_start_activity_map_split() {
    g_stm_crr_state.layer[StmLayerNoApps].state = StmLayoutNoMapSpl;
    g_stm_crr_state.layer[StmLayerNoApps].changed = STM_TRUE;

    if ((g_stm_event == StmEvtNoActivate)
    		&& (g_stm_category == StmCtgNoMap)) {
    	g_stm_map_is_activated = STM_TRUE;
    }
}

/*
 * @name stm_apl_start_activity_map_fullscreen
 */
void stm_apl_start_activity_map_fullscreen() {
    g_stm_crr_state.layer[StmLayerNoApps].state = StmLayoutNoMapFll;
    g_stm_crr_state.layer[StmLayerNoApps].changed = STM_TRUE;

    if ((g_stm_event == StmEvtNoActivate)
    		&& (g_stm_category == StmCtgNoMap)) {
    	g_stm_map_is_activated = STM_TRUE;
    }
}

/*
 * @name stm_apl_start_activity_splitable_normal
 */
void stm_apl_start_activity_splitable_normal() {
    g_stm_crr_state.layer[StmLayerNoApps].state = StmLayoutNoSplNml;
    g_stm_crr_state.layer[StmLayerNoApps].changed = STM_TRUE;
}

/*
 * @name stm_apl_start_activity_splitable_split
 */
void stm_apl_start_activity_splitable_split() {
    g_stm_crr_state.layer[StmLayerNoApps].state = StmLayoutNoSplSpl;
    g_stm_crr_state.layer[StmLayerNoApps].changed = STM_TRUE;
}

/*
 * @name stm_apl_start_activity_general
 */
void stm_apl_start_activity_general() {
    g_stm_crr_state.layer[StmLayerNoApps].state = StmLayoutNoGenNml;
    g_stm_crr_state.layer[StmLayerNoApps].changed = STM_TRUE;
}

/*
 * @name stm_apl_start_activity_system
 */
void stm_apl_start_activity_system() {
    g_stm_crr_state.layer[StmLayerNoApps].state = StmLayoutNoSysNml;
    g_stm_crr_state.layer[StmLayerNoApps].changed = STM_TRUE;
}

/*
 * @name stm_apl_start_activity_launcher
 */
void stm_apl_start_activity_launcher() {
    g_stm_crr_state.layer[StmLayerNoApps].state = StmLayoutNoLchNml;
    g_stm_crr_state.layer[StmLayerNoApps].changed = STM_TRUE;
}

/*
 * @name stm_apl_start_activity_launcher_fullscreen
 */
void stm_apl_start_activity_launcher_fullscreen() {
    g_stm_crr_state.layer[StmLayerNoApps].state = StmLayoutNoLchFll;
    g_stm_crr_state.layer[StmLayerNoApps].changed = STM_TRUE;
}

/*
 * @name stm_apl_event_restriction_mode_off
 */
void stm_apl_event_restriction_mode_off() {
	 g_stm_crr_state.layer[StmLayerNoApps].state = g_prv_apps_state_car_stop;
	 g_stm_crr_state.layer[StmLayerNoApps].changed = STM_TRUE;
}

/*
 * @name stm_apl_event_restriction_mode_on
 */
void stm_apl_event_restriction_mode_on() {
	g_prv_apps_state_car_stop = g_stm_prv_state.layer[StmLayerNoApps].state;
}

/*
 * @name stm_apl_initialize_variable
 */
void stm_apl_initialize_variable() {
	g_stm_prv_state.layer[StmLayerNoApps].state = StmLayoutNoNone;
	g_stm_prv_state.layer[StmLayerNoApps].changed = STM_FALSE;

	g_stm_crr_state.layer[StmLayerNoApps].state = StmLayoutNoNone;
	g_stm_crr_state.layer[StmLayerNoApps].changed = STM_FALSE;
}

/*
 * @name stm_apl_start_stm
 */
void stm_apl_start_stm() {
	if (g_stm_event == StmEvtNoUndo) {
		// nop
	}
	else {
		g_stm_prv_state.layer[StmLayerNoApps].state = g_stm_crr_state.layer[StmLayerNoApps].state;
	}
	g_stm_crr_state.layer[StmLayerNoApps].changed = STM_FALSE;
}