3 * Copyright 2012 Samsung Electronics Co., Ltd
5 * Licensed under the Flora License, Version 1.0 (the "License");
6 * you may not use this file except in compliance with the License.
7 * You may obtain a copy of the License at
9 * http://floralicense.org/license/
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
18 // Main view tab layout
19 group { name, "main/tab";
22 image, CALENDAR_TAB COMP;
23 image, CALENDAR_TAB_FOCUS_BG COMP;
24 image, CALENDAR_TAB_PRESS COMP;
25 image, CALENDAR_TODAY_ICON COMP;
26 image, CALENDAR_TODAY_ICON_PRESS COMP;
27 image, TAB_FOCUS COMP;
29 image, TAB_DEFAULT COMP;
30 image, TAB_PRESS COMP;
42 part { name, "tab/bg";
45 rel1 { relative, 0.0 0.0; to, base; }
46 rel2 { relative, 1.0 1.0; offset, 0 0; to, base; }
51 #define PART_TAB(_name, x1, x2) \
52 part { name, "tab/"_name"/bg"; \
54 state, "default" 0.0; \
55 rel1 { relative, x1 0.0; to, "tab/bg"; } \
56 rel2 { relative, x2 1.0; to, "tab/bg"; } \
57 image.normal, "P01_tab_default.png"; \
60 state, "default" 1.0; \
61 inherit, "default" 0.0; \
62 image.normal, "P01_tab_press.png"; \
65 state, "selected" 0.0; \
66 inherit, "default" 0.0; \
67 image.normal, TAB_FOCUS; \
70 part { name, "tab/"_name"/text"; \
74 state, "default" 0.0; \
75 rel1.to, "tab/"_name"/bg"; \
76 rel2.to, "tab/"_name"/bg"; \
77 color, COLOR_OF_TEXT_FOR_MAIN_TAB; \
79 font, "SLP:style=Medium"; \
85 state, "default" 1.0; \
86 inherit, "default" 0.0; \
87 color, COLOR_OF_TEXT_DEFAULT_FOR_MAIN_TAB; \
90 state, "selected" 0.0; \
91 inherit, "default" 0.0; \
92 color, COLOR_OF_TEXT_SELECTED_FOR_MAIN_TAB; \
95 part { name, "tab/"_name"/evt"; \
98 state, "default" 0.0; \
99 rel1 { to_x, "tab/"_name"/bg"; to_y, "tab/bg"; } \
100 rel2 { to_x, "tab/"_name"/bg"; to_y, "tab/bg"; } \
105 PART_TAB("year", (0/4), (1/4))
106 PART_TAB("month", (1/4), (2/4))
107 PART_TAB("day", (2/4), (3/4))
108 PART_TAB("list", (3/4), (4/4))
112 program { name, "tab/reset";
115 action, STATE_SET "default" 0.0;
116 target, "tab/year/bg";
117 target, "tab/year/text";
118 target, "tab/month/bg";
119 target, "tab/month/text";
120 target, "tab/day/bg";
121 target, "tab/day/text";
122 target, "tab/list/bg";
123 target, "tab/list/text";
126 #define PROG_TAB(_name) \
127 program { name, "tab/"_name"/down"; \
128 signal, "mouse,down,1"; \
129 source, "tab/"_name"/evt"; \
130 filter, "tab/"_name"/bg" "default"; \
131 action, STATE_SET "default" 1.0; \
132 target, "tab/"_name"/bg"; \
133 target, "tab/"_name"/text"; \
135 program { name, "tab/"_name"/up"; \
136 signal, "mouse,up,1"; \
137 source, "tab/"_name"/evt"; \
138 filter, "tab/"_name"/bg" "default"; \
139 action, STATE_SET "default" 0.0; \
140 target, "tab/"_name"/bg"; \
141 target, "tab/"_name"/text"; \
143 program { name, "tab/"_name"/clicked"; \
144 signal, "mouse,clicked,1"; \
145 filter, "tab/"_name"/bg" "default"; \
146 source, "tab/"_name"/evt"; \
147 action, SIGNAL_EMIT _name "tab"; \
149 program { name, "tab/"_name"/select"; \
150 signal, "select,"_name; \
152 action, STATE_SET "selected" 0.0; \
153 target, "tab/"_name"/bg"; \
154 target, "tab/"_name"/text"; \