Rev 5640 | Rev 5654 | Go to most recent revision | Only display areas with differences | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 5640 | Rev 5651 | ||
---|---|---|---|
1 | //11.03.12 - start! |
1 | //11.03.12 - start! |
2 | 2 | ||
3 | #ifndef AUTOBUILD |
3 | #ifndef AUTOBUILD |
4 | ?include "lang.h--" |
4 | ?include "lang.h--" |
5 | #endif |
5 | #endif |
6 | 6 | ||
7 | #define MEMSIZE 0xFE800 |
7 | #define MEMSIZE 0xFE800 |
8 | #include "..\lib\kolibri.h" |
8 | #include "..\lib\kolibri.h" |
9 | #include "..\lib\mem.h" |
9 | #include "..\lib\mem.h" |
10 | #include "..\lib\strings.h" |
10 | #include "..\lib\strings.h" |
11 | #include "..\lib\dll.h" |
11 | #include "..\lib\dll.h" |
12 | #include "..\lib\file_system.h" |
12 | #include "..\lib\file_system.h" |
13 | #include "..\lib\list_box.h" |
13 | #include "..\lib\list_box.h" |
14 | #include "..\lib\gui.h" |
14 | #include "..\lib\gui.h" |
15 | #include "..\lib\obj\box_lib.h" |
15 | #include "..\lib\obj\box_lib.h" |
16 | 16 | ||
17 | #ifdef LANG_RUS |
17 | #ifdef LANG_RUS |
18 | ?define WINDOW_HEADER "á¯à ¢«¥¨¥ ⥬®©" |
18 | ?define WINDOW_HEADER "á¯à ¢«¥¨¥ ⥬®©" |
19 | ?define T_SKINS " ¥¬ ®ª®" |
19 | ?define T_SKINS " ¥¬ ®ª®" |
20 | ?define T_WALLPAPERS " ¡®¨ à ¡®ç¥£® á⮫ " |
20 | ?define T_WALLPAPERS " ¡®¨ à ¡®ç¥£® á⮫ " |
21 | #else |
21 | #else |
22 | ?define WINDOW_HEADER "Appearance" |
22 | ?define WINDOW_HEADER "Appearance" |
23 | ?define T_SKINS " Skins" |
23 | ?define T_SKINS " Skins" |
24 | ?define T_WALLPAPERS " Wallpappers" |
24 | ?define T_WALLPAPERS " Wallpappers" |
25 | #endif |
25 | #endif |
26 | 26 | ||
27 | unsigned char icons[]= FROM "icons.raw"; |
27 | unsigned char icons[]= FROM "icons.raw"; |
28 | 28 | ||
29 | 29 | ||
30 | #define PANEL_H 30 |
30 | #define PANEL_H 30 |
31 | #define SKINS_STANDART_PATH "/kolibrios/res/skins" |
31 | #define SKINS_STANDART_PATH "/kolibrios/res/skins" |
32 | #define WALP_STANDART_PATH "/kolibrios/res/wallpapers" |
32 | #define WALP_STANDART_PATH "/kolibrios/res/wallpapers" |
33 | 33 | ||
34 | llist list[2]; |
34 | llist list[2]; |
35 | int active; |
35 | int active; |
36 | enum { WALLPAPERS, SKINS }; |
36 | enum { WALLPAPERS, SKINS }; |
37 | 37 | ||
38 | char folder_path[4096]; |
38 | char folder_path[4096]; |
39 | char cur_file_path[4096]; |
39 | char cur_file_path[4096]; |
40 | char temp_filename[4096]; |
40 | char temp_filename[4096]; |
41 | int files_mas[100]; |
41 | int files_mas[100]; |
42 | dword buf; |
42 | dword buf; |
43 | 43 | ||
44 | int cur; |
44 | int cur; |
45 | 45 | ||
46 | system_colors sc; |
46 | system_colors sc; |
47 | proc_info Form; |
47 | proc_info Form; |
48 | 48 | ||
49 | scroll_bar scroll1 = { 18,200,398, 44,18,0,115,15,0,0xeeeeee,0xD2CED0,0x555555,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1}; |
49 | scroll_bar scroll1 = { 18,200,398, 44,18,0,115,15,0,0xeeeeee,0xD2CED0,0x555555,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1}; |
50 | 50 | ||
51 | #include "other.h" |
51 | #include "other.h" |
52 | 52 | ||
53 | //icons configurate, delete from list, delete from disk, make default |
53 | //icons configurate, delete from list, delete from disk, make default |
54 | //remember current |
54 | //remember current |
55 | 55 | ||
56 | void Open_Dir() |
56 | void Open_Dir() |
57 | { |
57 | { |
58 | int j, filesnum; |
58 | int j, filesnum; |
59 | 59 | ||
60 | list[active].count = 0; |
60 | list[active].count = 0; |
61 | free(buf); |
61 | free(buf); |
62 | if (GetDir(#buf, #filesnum, #folder_path, DIRS_ONLYREAL)!=0) return; |
62 | if (GetDir(#buf, #filesnum, #folder_path, DIRS_ONLYREAL)!=0) return; |
63 | 63 | ||
64 | for (j=0; j |
64 | for (j=0; j |
65 | { |
65 | { |
66 | strcpy(#temp_filename, j*304 + buf+72); |
66 | strcpy(#temp_filename, j*304 + buf+72); |
67 | strlwr(#temp_filename); |
67 | strlwr(#temp_filename); |
68 | if (active==SKINS) if (strcmpi(#temp_filename+strlen(#temp_filename)-4,".skn")!=0) continue; |
68 | if (active==SKINS) if (strcmpi(#temp_filename+strlen(#temp_filename)-4,".skn")!=0) continue; |
69 | if (active==WALLPAPERS) if (strcmpi(#temp_filename+strlen(#temp_filename)-4,".txt")==0) continue; |
69 | if (active==WALLPAPERS) if (strcmpi(#temp_filename+strlen(#temp_filename)-4,".txt")==0) continue; |
70 | cur = list[active].count; |
70 | cur = list[active].count; |
71 | files_mas[cur]=j; |
71 | files_mas[cur]=j; |
72 | if (!strcmpi("default.skn",#temp_filename)) files_mas[0]> |
72 | if (!strcmpi("default.skn",#temp_filename)) files_mas[0]> |
73 | list[active].count++; |
73 | list[active].count++; |
74 | } |
74 | } |
75 | Sort_by_Name(0, list[active].count-1); |
75 | Sort_by_Name(0, list[active].count-1); |
76 | } |
76 | } |
77 | 77 | ||
78 | void Draw_List() |
78 | void Draw_List() |
79 | { |
79 | { |
80 | int i; |
80 | int i; |
81 | int yyy; |
81 | int yyy; |
82 | int list_last; |
82 | int list_last; |
83 | list[SKINS].SetSizes(0, PANEL_H, Form.cwidth-scroll1.size_x-1, Form.cheight-PANEL_H, 40, 20); |
83 | list[SKINS].SetSizes(0, PANEL_H, Form.cwidth-scroll1.size_x-1, Form.cheight-PANEL_H, 40, 20); |
84 | list[WALLPAPERS].SetSizes(0, PANEL_H, Form.cwidth-scroll1.size_x-1, Form.cheight-PANEL_H, 40, 20); |
84 | list[WALLPAPERS].SetSizes(0, PANEL_H, Form.cwidth-scroll1.size_x-1, Form.cheight-PANEL_H, 40, 20); |
85 | if (list[active].count > list[active].visible) list_last = list[active].visible; else list_last = list[active].count; |
85 | if (list[active].count > list[active].visible) list_last = list[active].visible; else list_last = list[active].count; |
86 | 86 | ||
87 | for (i=0; i |
87 | for (i=0; i |
88 | { |
88 | { |
89 | cur = list[active].first; |
89 | cur = list[active].first; |
90 | strcpy(#temp_filename, files_mas[i+cur]*304 + buf+72); |
90 | strcpy(#temp_filename, files_mas[i+cur]*304 + buf+72); |
91 | temp_filename[strlen(#temp_filename)-4] = 0; |
91 | temp_filename[strlen(#temp_filename)-4] = 0; |
92 | yyy = i*list[active].line_h+list[active].y; |
92 | yyy = i*list[active].line_h+list[active].y; |
93 | 93 | ||
94 | if (list[active].current-list[active].first==i) |
94 | if (list[active].current-list[active].first==i) |
95 | { |
95 | { |
96 | if (sc.work_button<>sc.work) |
96 | if (sc.work_button<>sc.work) |
97 | { |
97 | { |
98 | DrawBar(0, yyy, list[active].w, list[active].line_h, sc.work_button); |
98 | DrawBar(0, yyy, list[active].w, list[active].line_h, sc.work_button); |
99 | if (i |
99 | if (i |
100 | } |
100 | } |
101 | else |
101 | else |
102 | { |
102 | { |
103 | DrawBar(0, yyy, list[active].w, list[active].line_h, sc.grab_button); |
103 | DrawBar(0, yyy, list[active].w, list[active].line_h, sc.grab_button); |
104 | if (i |
104 | if (i |
105 | } |
105 | } |
106 | } |
106 | } |
107 | else |
107 | else |
108 | { |
108 | { |
109 | DrawBar(0,yyy,list[active].w, list[active].line_h, 0xFFFfff); |
109 | DrawBar(0,yyy,list[active].w, list[active].line_h, 0xFFFfff); |
110 | WriteText(12,yyy+list[active].text_y,0x80,0, #temp_filename); |
110 | WriteText(12,yyy+list[active].text_y,0x80,0, #temp_filename); |
111 | } |
111 | } |
112 | } |
112 | } |
113 | DrawBar(0,list_last*list[active].line_h+list[active].y, list[active].w, -list_last*list[active].line_h+ list[active].h, 0xFFFfff); |
113 | DrawBar(0,list_last*list[active].line_h+list[active].y, list[active].w, -list_last*list[active].line_h+ list[active].h, 0xFFFfff); |
114 | DrawScroller(); |
114 | DrawScroller(); |
115 | } |
115 | } |
116 | 116 | ||
117 | void GetFiles() |
117 | void GetFiles() |
118 | { |
118 | { |
119 | if (list[SKINS].active) |
119 | if (list[SKINS].active) |
120 | { |
120 | { |
121 | strcpy(#folder_path, SKINS_STANDART_PATH); |
121 | strcpy(#folder_path, SKINS_STANDART_PATH); |
122 | Open_Dir(); |
122 | Open_Dir(); |
123 | if (!list[active].count) notify("'No skins were found' -E"); |
123 | if (!list[active].count) notify("'No skins were found' -E"); |
124 | } |
124 | } |
125 | if (list[WALLPAPERS].active) |
125 | if (list[WALLPAPERS].active) |
126 | { |
126 | { |
127 | strcpy(#folder_path, WALP_STANDART_PATH); |
127 | strcpy(#folder_path, WALP_STANDART_PATH); |
128 | Open_Dir(); |
128 | Open_Dir(); |
129 | if (!list[active].count) notify("'No wallpapers were found' -E"); |
129 | if (!list[active].count) notify("'No wallpapers were found' -E"); |
130 | } |
130 | } |
131 | } |
131 | } |
132 | 132 | ||
133 | void Apply() |
133 | void Apply() |
134 | { |
134 | { |
135 | if (list[SKINS].active) |
135 | if (list[SKINS].active) |
136 | { |
136 | { |
137 | strcpy(#cur_file_path, #folder_path); |
137 | strcpy(#cur_file_path, #folder_path); |
138 | cur = list[SKINS].current; |
138 | cur = list[SKINS].current; |
139 | chrcat(#cur_file_path, '/'); |
139 | chrcat(#cur_file_path, '/'); |
140 | strcat(#cur_file_path, files_mas[cur]*304 + buf+72); |
140 | strcat(#cur_file_path, files_mas[cur]*304 + buf+72); |
141 | SetSystemSkin(#cur_file_path); |
141 | SetSystemSkin(#cur_file_path); |
142 | //Draw_List(); |
142 | //Draw_List(); |
143 | } |
143 | } |
144 | if (list[WALLPAPERS].active) |
144 | if (list[WALLPAPERS].active) |
145 | { |
145 | { |
146 | strcpy(#cur_file_path, "\\S__"); |
146 | strcpy(#cur_file_path, "\\S__"); |
147 | strcat(#cur_file_path, #folder_path); |
147 | strcat(#cur_file_path, #folder_path); |
148 | cur = list[WALLPAPERS].current; |
148 | cur = list[WALLPAPERS].current; |
149 | chrcat(#cur_file_path, '/'); |
149 | chrcat(#cur_file_path, '/'); |
150 | strcat(#cur_file_path, files_mas[cur]*304 + buf+72); |
150 | strcat(#cur_file_path, files_mas[cur]*304 + buf+72); |
151 | RunProgram("/sys/media/kiv", #cur_file_path); |
151 | RunProgram("/sys/media/kiv", #cur_file_path); |
152 | Draw_List(); |
152 | Draw_List(); |
153 | } |
153 | } |
154 | } |
154 | } |
155 | 155 | ||
156 | OpenFile() |
156 | OpenFile() |
157 | { |
157 | { |
158 | if (list[SKINS].active) RunProgram("/sys/desktop", #cur_file_path); |
158 | if (list[SKINS].active) RunProgram("/sys/desktop", #cur_file_path); |
159 | if (list[WALLPAPERS].active) RunProgram("/sys/media/kiv", #cur_file_path); |
159 | if (list[WALLPAPERS].active) RunProgram("/sys/media/kiv", #cur_file_path); |
160 | } |
160 | } |
161 | 161 | ||
162 | 162 | ||
163 | void main() |
163 | void main() |
164 | { |
164 | { |
165 | int id, key, mouse_clicked; |
165 | int id, key, mouse_clicked; |
166 | - | ||
167 | mem_Init(); |
166 | |
168 | SetEventMask(0x27); |
167 | SetEventMask(0x27); |
169 | load_dll(boxlib, #box_lib_init,0); |
168 | load_dll(boxlib, #box_lib_init,0); |
170 | list[SKINS].current = list[WALLPAPERS].current = -1; |
169 | list[SKINS].current = list[WALLPAPERS].current = -1; |
171 | list[SKINS].first = list[WALLPAPERS].first = 0; |
170 | list[SKINS].first = list[WALLPAPERS].first = 0; |
172 | TabClick(WALLPAPERS); |
171 | TabClick(WALLPAPERS); |
173 | list[WALLPAPERS].SetSizes(0, 230, 350, 400-PANEL_H, 40, 18); |
172 | list[WALLPAPERS].SetSizes(0, 230, 350, 400-PANEL_H, 40, 18); |
174 | list[SKINS].SetSizes(0, 230, 350, 400-PANEL_H, 40, 18); |
173 | list[SKINS].SetSizes(0, 230, 350, 400-PANEL_H, 40, 18); |
175 | loop() |
174 | loop() |
176 | { |
175 | { |
177 | switch(WaitEvent()) |
176 | switch(WaitEvent()) |
178 | { |
177 | { |
179 | case evMouse: |
178 | case evMouse: |
180 | if (!CheckActiveProcess(Form.ID)) break; |
179 | if (!CheckActiveProcess(Form.ID)) break; |
181 | scrollbar_v_mouse (#scroll1); |
180 | scrollbar_v_mouse (#scroll1); |
182 | if (list[active].first <> scroll1.position) |
181 | if (list[active].first <> scroll1.position) |
183 | { |
182 | { |
184 | list[active].first = scroll1.position; |
183 | list[active].first = scroll1.position; |
185 | Draw_List(); |
184 | Draw_List(); |
186 | break; |
185 | break; |
187 | } |
186 | } |
188 | 187 | ||
189 | mouse.get(); |
188 | mouse.get(); |
190 | 189 | ||
191 | if (mouse.vert) |
190 | if (mouse.vert) |
192 | { |
191 | { |
193 | if (list[SKINS].active) && (list[SKINS].MouseScroll(mouse.vert)) Draw_List(); |
192 | if (list[SKINS].active) && (list[SKINS].MouseScroll(mouse.vert)) Draw_List(); |
194 | if (list[WALLPAPERS].active) && (list[WALLPAPERS].MouseScroll(mouse.vert)) Draw_List(); |
193 | if (list[WALLPAPERS].active) && (list[WALLPAPERS].MouseScroll(mouse.vert)) Draw_List(); |
195 | } |
194 | } |
196 | 195 | ||
197 | if (mouse_clicked) |
196 | if (mouse_clicked) |
198 | { |
197 | { |
199 | if (!mouse.lkm) && (list[SKINS].active) && (list[SKINS].ProcessMouse(mouse.x, mouse.y)) Apply(); |
198 | if (!mouse.lkm) && (list[SKINS].active) && (list[SKINS].ProcessMouse(mouse.x, mouse.y)) Apply(); |
200 | if (!mouse.lkm) && (list[WALLPAPERS].active) && (list[WALLPAPERS].ProcessMouse(mouse.x, mouse.y)) Apply(); |
199 | if (!mouse.lkm) && (list[WALLPAPERS].active) && (list[WALLPAPERS].ProcessMouse(mouse.x, mouse.y)) Apply(); |
201 | mouse_clicked=0; |
200 | mouse_clicked=0; |
202 | } |
201 | } |
203 | if (mouse.lkm) && (list[SKINS].MouseOver(mouse.x, mouse.y)) mouse_clicked=1; |
202 | if (mouse.lkm) && (list[SKINS].MouseOver(mouse.x, mouse.y)) mouse_clicked=1; |
204 | break; |
203 | break; |
205 | 204 | ||
206 | 205 | ||
207 | case evButton: |
206 | case evButton: |
208 | id=GetButtonID(); |
207 | id=GetButtonID(); |
209 | if (id==1) ExitProcess(); |
208 | if (id==1) ExitProcess(); |
210 | if (id==2) TabClick(WALLPAPERS); |
209 | if (id==2) TabClick(WALLPAPERS); |
211 | if (id==3) TabClick(SKINS); |
210 | if (id==3) TabClick(SKINS); |
212 | break; |
211 | break; |
213 | 212 | ||
214 | case evKey: |
213 | case evKey: |
215 | key = GetKey(); |
214 | key = GetKey(); |
216 | if (list[SKINS].active) && (list[SKINS].ProcessKey(key)) Apply(); |
215 | if (list[SKINS].active) && (list[SKINS].ProcessKey(key)) Apply(); |
217 | if (list[WALLPAPERS].active) && (list[WALLPAPERS].ProcessKey(key)) Apply(); |
216 | if (list[WALLPAPERS].active) && (list[WALLPAPERS].ProcessKey(key)) Apply(); |
218 | IF (key==013) OpenFile(); |
217 | IF (key==013) OpenFile(); |
219 | if (key==9) if (list[SKINS].active) TabClick(WALLPAPERS); else TabClick(SKINS); |
218 | if (key==9) if (list[SKINS].active) TabClick(WALLPAPERS); else TabClick(SKINS); |
220 | IF (key==182) //Del |
219 | IF (key==182) //Del |
221 | { |
220 | { |
222 | DeleteFile(#cur_file_path); |
221 | DeleteFile(#cur_file_path); |
223 | Open_Dir(); |
222 | Open_Dir(); |
224 | Apply(); |
223 | Apply(); |
225 | } |
224 | } |
226 | break; |
225 | break; |
227 | 226 | ||
228 | case evReDraw: |
227 | case evReDraw: |
229 | sc.get(); |
228 | sc.get(); |
230 | DefineAndDrawWindow(30,80,list[active].w+9,list[active].h+4+GetSkinHeight(),0x73,0xE4DFE1,WINDOW_HEADER,0); |
229 | DefineAndDrawWindow(30,80,list[active].w+9,list[active].h+4+GetSkinHeight(),0x73,0xE4DFE1,WINDOW_HEADER,0); |
231 | GetProcessInfo(#Form, SelfInfo); |
230 | GetProcessInfo(#Form, SelfInfo); |
232 | IF (Form.status_window>=2) break; |
231 | IF (Form.status_window>=2) break; |
233 | DrawTabs(); |
232 | DrawTabs(); |
234 | Draw_List(); |
233 | Draw_List(); |
235 | } |
234 | } |
236 | } |
235 | } |
237 | } |
236 | } |
238 | 237 | ||
239 | #define BT_PADDING 16 |
238 | #define BT_PADDING 16 |
240 | 239 | ||
241 | void DrawTab(dword x,y, but_id, is_active, text) |
240 | void DrawTab(dword x,y, but_id, is_active, text) |
242 | { |
241 | { |
243 | dword col_bg, col_text; |
242 | dword col_bg, col_text; |
244 | dword w=strlen(text)*6+BT_PADDING, h=21; |
243 | dword w=strlen(text)*6+BT_PADDING, h=21; |
245 | 244 | ||
246 | if (is_active) |
245 | if (is_active) |
247 | { |
246 | { |
248 | col_bg=sc.work_button; |
247 | col_bg=sc.work_button; |
249 | col_text=sc.work_button_text; |
248 | col_text=sc.work_button_text; |
250 | } |
249 | } |
251 | else |
250 | else |
252 | { |
251 | { |
253 | col_bg=sc.work; |
252 | col_bg=sc.work; |
254 | col_text=sc.work_text; |
253 | col_text=sc.work_text; |
255 | } |
254 | } |
256 | DrawRectangle(x,y, w,h, sc.work_graph); |
255 | DrawRectangle(x,y, w,h, sc.work_graph); |
257 | DrawCaptButton(x+1,y+1, w-2,h-1, but_id, col_bg, col_text, text); |
256 | DrawCaptButton(x+1,y+1, w-2,h-1, but_id, col_bg, col_text, text); |
258 | _PutImage(x+6,y+4, 16,15, but_id-2*16*15*3+#icons); |
257 | _PutImage(x+6,y+4, 16,15, but_id-2*16*15*3+#icons); |
259 | } |
258 | } |
260 | 259 | ||
261 | 260 | ||
262 | void DrawTabs() |
261 | void DrawTabs() |
263 | { |
262 | { |
264 | DrawBar(0,0, Form.cwidth, PANEL_H-1, sc.work); |
263 | DrawBar(0,0, Form.cwidth, PANEL_H-1, sc.work); |
265 | 264 | ||
266 | DrawTab(10,7, 2, list[WALLPAPERS].active, T_WALLPAPERS); |
265 | DrawTab(10,7, 2, list[WALLPAPERS].active, T_WALLPAPERS); |
267 | DrawTab(strlen(T_WALLPAPERS)*6+BT_PADDING+21,7, 3, list[SKINS].active, T_SKINS); |
266 | DrawTab(strlen(T_WALLPAPERS)*6+BT_PADDING+21,7, 3, list[SKINS].active, T_SKINS); |
268 | 267 | ||
269 | DrawBar(0,PANEL_H-2, Form.cwidth, 1, sc.work_graph); |
268 | DrawBar(0,PANEL_H-2, Form.cwidth, 1, sc.work_graph); |
270 | DrawBar(0,PANEL_H-1, Form.cwidth, 1, 0xEEEeee); |
269 | DrawBar(0,PANEL_H-1, Form.cwidth, 1, 0xEEEeee); |
271 | } |
270 | } |
272 | 271 | ||
273 | void TabClick(int N) |
272 | void TabClick(int N) |
274 | { |
273 | { |
275 | if (N==SKINS) |
274 | if (N==SKINS) |
276 | { |
275 | { |
277 | list[SKINS].active = 1; |
276 | list[SKINS].active = 1; |
278 | list[WALLPAPERS].active = 0; |
277 | list[WALLPAPERS].active = 0; |
279 | } |
278 | } |
280 | if (N==WALLPAPERS) |
279 | if (N==WALLPAPERS) |
281 | { |
280 | { |
282 | list[SKINS].active = 0; |
281 | list[SKINS].active = 0; |
283 | list[WALLPAPERS].active = 1; |
282 | list[WALLPAPERS].active = 1; |
284 | } |
283 | } |
285 | active = N; |
284 | active = N; |
286 | GetFiles(); |
285 | GetFiles(); |
287 | DrawTabs(); |
286 | DrawTabs(); |
288 | Draw_List(); |
287 | Draw_List(); |
289 | } |
288 | } |
290 | 289 | ||
291 | 290 | ||
292 | void DrawScroller() |
291 | void DrawScroller() |
293 | { |
292 | { |
294 | scroll1.bckg_col = 0xBBBbbb; |
293 | scroll1.bckg_col = 0xBBBbbb; |
295 | scroll1.frnt_col = sc.work; |
294 | scroll1.frnt_col = sc.work; |
296 | scroll1.line_col = sc.work_graph; |
295 | scroll1.line_col = sc.work_graph; |
297 | 296 | ||
298 | scroll1.max_area = list[active].count; |
297 | scroll1.max_area = list[active].count; |
299 | scroll1.cur_area = list[active].visible; |
298 | scroll1.cur_area = list[active].visible; |
300 | scroll1.position = list[active].first; |
299 | scroll1.position = list[active].first; |
301 | 300 | ||
302 | scroll1.all_redraw=1; |
301 | scroll1.all_redraw=1; |
303 | scroll1.start_x = list[active].x + list[active].w; |
302 | scroll1.start_x = list[active].x + list[active].w; |
304 | scroll1.start_y = list[active].y-2; |
303 | scroll1.start_y = list[active].y-2; |
305 | scroll1.size_y = list[active].h+2; |
304 | scroll1.size_y = list[active].h+2; |
306 | 305 | ||
307 | scrollbar_v_draw(#scroll1); |
306 | scrollbar_v_draw(#scroll1); |
308 | } |
307 | } |
309 | 308 | ||
310 | 309 | ||
311 | stop:>> |
310 | stop:>> |
312 | > |
311 | > |