summaryrefslogtreecommitdiff
path: root/data/elementary/themes/edc/elm/actionslider.edc
blob: 655e09a46a5183a986ab151564e3c6879405cabe (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
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
group { name: "elm/actionslider/base/default";
   parts {
      part { name: "bg"; type: RECT; mouse_events: 0;
         scale: 1;
         description { state: "default" 0.0;
            min: 120 20;
            color: 0 0 0 64;
         }
         description { state: "disabled" 0.0;
            inherit: "default" 0.0;
            color: 0 0 0 0;
         }
      }
      part { name: "icon_dragable_area"; type: SPACER;
         description { state: "default" 0.0;
            rel.to: "bg";
         }
      }
      part { name: "elm.text.left"; type: TEXT;
         scale: 1;
         description { state: "default" 0.0;
            color: 160 160 160 255;
            rel1.offset: 4 4;
            rel2.offset: -5 -5;
            text { font: FN; size: 10;
               align: 0.0 0.5;
               min: 1 1;
               ellipsis: -1;
               text_class: "button";
            }
            offscale;
         }
         description { state: "disabled" 0.0;
            inherit: "default" 0.0;
            color: 96 96 96 255;
         }
      }
      part { name: "elm.text.center"; type: TEXT;
         scale: 1;
         description { state: "default" 0.0;
            color: 160 160 160 255;
            rel1.offset: 4 4;
            rel2.offset: -5 -5;
            text { font: FN; size: 10;
               align: 0.5 0.5;
               min: 1 1;
               ellipsis: -1;
               text_class: "button";
            }
            offscale;
         }
         description { state: "disabled" 0.0;
            inherit: "default" 0.0;
            color: 96 96 96 255;
         }
      }
      part { name: "elm.text.right"; type: TEXT;
         scale: 1;
         description { state: "default" 0.0;
            color: 160 160 160 255;
            rel1.offset: 4 4;
            rel2.offset: -5 -5;
            text { font: FN; size: 10;
               align: 1.0 0.5;
               min: 1 1;
               ellipsis: -1;
               text_class: "button";
            }
            offscale;
         }
         description { state: "disabled" 0.0;
            inherit: "default" 0.0;
            color: 96 96 96 255;
         }
      }
      part { name: "elm.drag_button_base"; type: SWALLOW; mouse_events: 0;
         scale: 1;
         description { state: "default" 0.0;
            fixed: 1 1;
            min: 40 20;
            align: 0.5 0.5;
            rel1.to: "icon_dragable_area";
            rel2 {
               relative: 0.0 1.0;
               to: "icon_dragable_area";
            }
         }
         dragable {
            confine: "icon_dragable_area";
            x: 1 1 0;
            y: 0 0 0;
         }
      }
      part { name: "elm.drag_button"; type: RECT;
         scale: 1;
         description { state: "default" 0.0;
            min: 40 20;
            color: 0 0 0 0;
            rel1.to_x: "elm.drag_button_base";
            rel1.to_y: "icon_dragable_area";
            rel2.to_x: "elm.drag_button_base";
            rel2.to_y: "icon_dragable_area";
         }
         dragable {
            events: "elm.drag_button_base";
         }
      }
      part { name: "drag_button"; type: RECT; mouse_events: 0;
         description { state: "default" 0.0;
            rel.to: "elm.drag_button";
            color: 96 96 96 255;
         }
         description { state: "disabled" 0.0;
            inherit: "default" 0.0;
            color: 72 72 72 255;
         }
         description { state: "clicked" 0.0;
            inherit: "default" 0.0;
            color: 51 153 255 255;
         }
      }
      part { name: "elm.text.indicator"; type: TEXT; mouse_events: 0;
         scale: 1;
         description { state: "default" 0.0;
            rel.to: "drag_button";
            rel1.offset: 4 4;
            rel2.offset: -5 -5;
            color: 192 192 192 255;
            text {
               font: FN; size: 10;
               align: 0.5 0.5;
               min: 0 1;
               text_class: "check_off_text";
            }
         }
         description { state: "disabled" 0.0;
            inherit: "default" 0.0;
            color: 96 96 96 255;
         }
         description { state: "clicked" 0.0;
            inherit: "default" 0.0;
            color: 255 255 255 255;
         }
      }
      part { name: "disabler"; type: RECT;
         description { state: "default" 0.0;
            color: 0 0 0 0;
            visible: 0;
         }
         description { state: "disabled" 0.0;
            inherit: "default" 0.0;
            visible: 1;
         }
      }
   }
   programs {
      program { signal: "mouse,up,1"; source: "elm.drag_button";
         action: SIGNAL_EMIT "elm,action,up,drag_button" "elm";
         after: "button_unclick_anim";
      }
      program { name: "button_unclick_anim";
         action: STATE_SET "default" 0.0;
         target: "drag_button";
         target: "elm.text.indicator";
      }
      program { signal: "mouse,down,1*"; source: "elm.drag_button";
         action: SIGNAL_EMIT "elm,action,down,drag_button" "elm";
         after: "button_click_anim";
      }
      program { name: "button_click_anim";
         action: STATE_SET "clicked" 0.0;
         target: "drag_button";
         target: "elm.text.indicator";
      }
      program { signal: "mouse,move"; source: "elm.drag_button_base";
         action: SIGNAL_EMIT "elm,action,move,drag_button" "elm";
      }
      program { signal: "mouse,down,1*"; source: "elm.text.right";
         action: SIGNAL_EMIT "elm,action,down,right" "elm";
      }
     program { signal: "mouse,down,1*"; source: "elm.text.left";
         action: SIGNAL_EMIT "elm,action,down,left" "elm";
      }
     program { signal: "mouse,down,1*"; source: "elm.text.center";
         action: SIGNAL_EMIT "elm,action,down,center" "elm";
      }
      program { signal: "elm,state,disabled"; source: "elm";
         action: STATE_SET "disabled" 0.0;
         target: "bg";
         target: "drag_button";
         target: "disabler";
         target: "elm.text.left";
         target: "elm.text.center";
         target: "elm.text.right";
         target: "elm.text.indicator";
      }
      program { signal: "elm,state,enabled"; source: "elm";
         action: STATE_SET "default" 0.0;
         target: "bg";
         target: "drag_button";
         target: "disabler";
         target: "elm.text.left";
         target: "elm.text.center";
         target: "elm.text.right";
         target: "elm.text.indicator";
      }
   }
}

group { name: "elm/actionslider/base/bar";
   inherit: "elm/actionslider/base/default";
   parts {
      part { name: "bar"; type: RECT; mouse_events: 0;
         insert_before: "elm.drag_button_base";
         description { state: "default" 0.0;
            color: 51 153 255 128;
            rel1.to: "bg";
            rel2 {
               relative: 0.0 1.0;
               to_x: "elm.drag_button_base";
               to_y: "bg";
            }
         }
      }
   }
}