source: titan/titan/adjust.h @ 38490

Last change on this file since 38490 was 38473, checked in by obi, 8 years ago

move minitv to skinadjust

File size: 23.6 KB
Line 
1#ifndef ADJUST_H
2#define ADJUST_H
3
4void screenadjust()
5{
6        int rcret = 0;
7        char* tmpstr = NULL;
8       
9        struct skin* adjust = getscreen("adjust");
10        struct skin* listbox = getscreennode(adjust, "listbox");
11        struct skin* volbartimeout = getscreennode(adjust, "volbartimeout");
12        struct skin* infobartimeout = getscreennode(adjust, "infobartimeout");
13        struct skin* infobarsleep = getscreennode(adjust, "infobarsleep");
14        struct skin* secondinfobar = getscreennode(adjust, "secondinfobar");
15        struct skin* spinnerspeed = getscreennode(adjust, "spinnerspeed");
16        struct skin* spinnertime = getscreennode(adjust, "spinnertime");
17        struct skin* hangtime = getscreennode(adjust, "hangtime");
18        struct skin* nozapclear = getscreennode(adjust, "nozapclear");
19        struct skin* fastzap = getscreennode(adjust, "fastzap");
20        struct skin* faststop = getscreennode(adjust, "faststop");
21        struct skin* dirsort = getscreennode(adjust, "dirsort");
22        struct skin* poweraktion = getscreennode(adjust, "poweraktion");
23        struct skin* frontpoweraktion = getscreennode(adjust, "frontpoweraktion");
24        struct skin* virtualzap = getscreennode(adjust, "virtualzap");
25        struct skin* fasttextrender = getscreennode(adjust, "fasttextrender");
26        struct skin* recsplitsize = getscreennode(adjust, "recsplitsize");
27        struct skin* recforerun = getscreennode(adjust, "recforerun");
28        struct skin* recoverrun = getscreennode(adjust, "recoverrun");
29        struct skin* skip13 = getscreennode(adjust, "skip13");
30        struct skin* skip46 = getscreennode(adjust, "skip46");
31        struct skin* skip79 = getscreennode(adjust, "skip79");
32        struct skin* playertype = getscreennode(adjust, "playertype");
33        struct skin* autochangechannelname = getscreennode(adjust, "autochangechannelname");
34        struct skin* def_rectimer_after = getscreennode(adjust, "def_rectimer_after");
35        struct skin* showchanneltimeline = getscreennode(adjust, "showchanneltimeline");
36        struct skin* screenanim = getscreennode(adjust, "screenanim");
37        struct skin* screenanimspeed = getscreennode(adjust, "screenanimspeed");
38        struct skin* channellistview = getscreennode(adjust, "channellistview");
39        struct skin* showlastpos = getscreennode(adjust, "showlastpos");
40        struct skin* recsync = getscreennode(adjust, "recsync");
41        struct skin* recordnamefmt = getscreennode(adjust, "recordnamefmt");
42        struct skin* newsletter = getscreennode(adjust, "newsletter");
43        struct skin* showhiddenfiles = getscreennode(adjust, "showhiddenfiles");
44        struct skin* expertmodus = getscreennode(adjust, "expertmodus");
45        struct skin* infobarprogram = getscreennode(adjust, "infobarprogram");
46        struct skin* crosscontrol = getscreennode(adjust, "crosscontrol");
47        struct skin* emucontrol = getscreennode(adjust, "emucontrol");
48        struct skin* usecec = getscreennode(adjust, "usecec");
49        struct skin* playerbuffersize = getscreennode(adjust, "playerbuffersize");
50        struct skin* playerbufferseektime = getscreennode(adjust, "playerbufferseektime");
51        struct skin* sataswitch = getscreennode(adjust, "sataswitch");
52        struct skin* dualboot = getscreennode(adjust, "dualboot");
53        struct skin* community_user = getscreennode(adjust, "community_user");
54        struct skin* community_pass = getscreennode(adjust, "community_pass");
55        struct skin* debuglevel = getscreennode(adjust, "debuglevel");
56
57        struct skin* tmp = NULL;
58
59        changeinput(volbartimeout, "1\n2\n3\n4\n5\n6\n7\n8\n9\n10");
60        setchoiceboxselection(volbartimeout, getconfig("volbartimeout", NULL));
61
62        changeinput(infobartimeout, "1\n2\n3\n4\n5\n6\n7\n8\n9\n10\n20\n30\n60\n10000");
63        setchoiceboxselection(infobartimeout, getconfig("infobartimeout", NULL));
64
65        changeinput(infobarsleep, "0\n1\n2\n3\n4\n5");
66        setchoiceboxselection(infobarsleep, getconfig("infobarsleep", NULL));
67
68        addchoicebox(secondinfobar, "0", _("no"));
69        addchoicebox(secondinfobar, "1", _("infobar"));
70        addchoicebox(secondinfobar, "2", _("EPG"));
71        addchoicebox(secondinfobar, "3", _("Channel EPG"));
72        setchoiceboxselection(secondinfobar, getconfig("secondinfobar", NULL));
73
74        changeinput(spinnerspeed, "1\n3\n9\n12\n15\n18\n21\n24\n27\n30");
75        setchoiceboxselection(spinnerspeed, getconfig("spinnerspeed", NULL));
76
77        changeinput(spinnertime, "1\n2\n3\n4\n5\n6\n7\n8\n10000");
78        setchoiceboxselection(spinnertime, getconfig("spinnertime", NULL));
79
80        changeinput(hangtime, "5\n10\n15\n30\n60\n120\n10000");
81        setchoiceboxselection(hangtime, getconfig("hangtime", NULL));
82
83        addchoicebox(nozapclear, "0", _("no"));
84        addchoicebox(nozapclear, "1", _("yes"));
85        setchoiceboxselection(nozapclear, getconfig("nozapclear", NULL));
86
87        if(checkbox("ATEMIO7600") == 1)
88                fastzap->hidden = YES;
89        else
90                fastzap->hidden = NO;
91       
92        addchoicebox(fastzap, "0", _("no"));
93        addchoicebox(fastzap, "2", _("medium"));
94        addchoicebox(fastzap, "1", _("fast"));
95        setchoiceboxselection(fastzap, getconfig("fastzap", NULL));
96
97        addchoicebox(faststop, "0", _("no"));
98        addchoicebox(faststop, "1", _("yes"));
99        setchoiceboxselection(faststop, getconfig("faststop", NULL));
100
101        addchoicebox(dirsort, "0", _("alpha"));
102        addchoicebox(dirsort, "1", _("reverse alpha"));
103        addchoicebox(dirsort, "2", _("size"));
104        addchoicebox(dirsort, "3", _("reverse size"));
105        addchoicebox(dirsort, "4", _("date"));
106        addchoicebox(dirsort, "5", _("reverse date"));
107        setchoiceboxselection(dirsort, getconfig("dirsort", NULL));
108
109        addchoicebox(poweraktion, "0", _("Power Menu"));
110        addchoicebox(poweraktion, "1", _("Power Off"));
111        addchoicebox(poweraktion, "2", _("Standby"));
112        addchoicebox(poweraktion, "3", _("Restart"));
113        addchoicebox(poweraktion, "4", _("GUI Restart"));
114        setchoiceboxselection(poweraktion, getconfig("poweraktion", NULL));
115
116        addchoicebox(frontpoweraktion, "1", _("Power Off"));
117        addchoicebox(frontpoweraktion, "2", _("Standby"));
118        setchoiceboxselection(frontpoweraktion, getconfig("frontpoweraktion", NULL));
119
120        addchoicebox(virtualzap, "0", _("deaktiv"));
121        addchoicebox(virtualzap, "1", _("1 sec"));
122        addchoicebox(virtualzap, "2", _("2 sec"));
123        addchoicebox(virtualzap, "9999", _("endless"));
124        setchoiceboxselection(virtualzap, getconfig("virtualzap", NULL));
125       
126        addchoicebox(fasttextrender, "0", _("no"));
127        addchoicebox(fasttextrender, "1", _("yes"));
128        setchoiceboxselection(fasttextrender, getconfig("fasttextrender", NULL));
129
130        addchoicebox(recsplitsize, "0", _("deaktiv"));
131        addchoicebox(recsplitsize, "1", _("1 GB"));
132        addchoicebox(recsplitsize, "2", _("2 GB"));
133        addchoicebox(recsplitsize, "3", _("3 GB"));
134        addchoicebox(recsplitsize, "4", _("4 GB"));
135        setchoiceboxselection(recsplitsize, getconfig("recsplitsize", NULL));
136
137        changeinput(recforerun, "0\n1\n2\n3\n4\n5\n6\n7\n8\n9\n10\n15\n20\n25\n30\n35\n40\n45\n50\n55\n60");
138        setchoiceboxselection(recforerun, getconfig("recforerun", NULL));
139
140        changeinput(recoverrun, "0\n1\n2\n3\n4\n5\n6\n7\n8\n9\n10\n15\n20\n25\n30\n35\n40\n45\n50\n55\n60");
141        setchoiceboxselection(recoverrun, getconfig("recoverrun", NULL));
142
143        changeinput(skip13, "15\n20\n30\n45\n60\n90\n120\n180\n300\n600\n900\n1200");
144        setchoiceboxselection(skip13, getconfig("skip13", NULL));
145
146        changeinput(skip46, "15\n20\n30\n45\n60\n90\n120\n180\n300\n600\n900\n1200");
147        setchoiceboxselection(skip46, getconfig("skip46", NULL));
148
149        changeinput(skip79, "15\n20\n30\n45\n60\n90\n120\n180\n300\n600\n900\n1200");
150        setchoiceboxselection(skip79, getconfig("skip79", NULL));
151       
152        addchoicebox(playertype, "0", _("extern"));
153        addchoicebox(playertype, "1", _("intern"));
154        setchoiceboxselection(playertype, getconfig("playertype", NULL));
155       
156        addchoicebox(autochangechannelname, "0", _("no"));
157        addchoicebox(autochangechannelname, "1", _("yes"));
158        setchoiceboxselection(autochangechannelname, getconfig("autochangechannelname", NULL));
159
160        addchoicebox(def_rectimer_after, "0", _("auto"));
161        addchoicebox(def_rectimer_after, "1", _("nothing"));
162        addchoicebox(def_rectimer_after, "2", _("standby"));
163        addchoicebox(def_rectimer_after, "3", _("power off"));
164        setchoiceboxselection(def_rectimer_after, getconfig("def_rectimer_after", NULL));
165       
166        addchoicebox(showchanneltimeline, "0", _("no"));
167        addchoicebox(showchanneltimeline, "1", _("yes"));
168        setchoiceboxselection(showchanneltimeline, getconfig("showchanneltimeline", NULL));
169       
170        addchoicebox(screenanim, "0", _("no"));
171        addchoicebox(screenanim, "1", _("anim. width"));
172        addchoicebox(screenanim, "2", _("anim. height"));
173        addchoicebox(screenanim, "3", _("anim. both"));
174#ifdef MIPSEL
175        addchoicebox(screenanim, "4", _("left to right"));
176        addchoicebox(screenanim, "5", _("top to bottom"));
177        if(checkbox("DM7020HD") == 1 || checkbox("DM7020HDV2") == 1)
178        {
179                addchoicebox(screenanim, "11", _("slide from left"));
180                addchoicebox(screenanim, "12", _("slide from bottom"));
181        }
182#endif
183        setchoiceboxselection(screenanim, getconfig("screenanim", NULL));
184       
185        addchoicebox(screenanimspeed, "1", _("very fast"));
186        addchoicebox(screenanimspeed, "5", _("fast"));
187        addchoicebox(screenanimspeed, "10", _("normal"));
188        addchoicebox(screenanimspeed, "15", _("slow"));
189        addchoicebox(screenanimspeed, "20", _("very slow"));
190        setchoiceboxselection(screenanimspeed, getconfig("screenanimspeed", NULL));
191
192        addchoicebox(channellistview, "0", _("hidden"));
193        addchoicebox(channellistview, "1", _("show"));
194        setchoiceboxselection(channellistview, getconfig("channellistview", NULL));
195
196        addchoicebox(showlastpos, "0", _("no"));       
197        addchoicebox(showlastpos, "1", _("yes"));
198        setchoiceboxselection(showlastpos, getconfig("showlastpos", NULL));
199
200        addchoicebox(recsync, "0", _("no"));   
201        addchoicebox(recsync, "1", _("yes"));
202        setchoiceboxselection(recsync, getconfig("recsync", NULL));
203
204        addchoicebox(recordnamefmt, "0", _("channel-movie"));
205        addchoicebox(recordnamefmt, "1", _("movie-channel"));
206        setchoiceboxselection(recordnamefmt, getconfig("recordnamefmt", NULL));
207
208        addchoicebox(newsletter, "0", _("no"));
209        addchoicebox(newsletter, "1", _("yes"));
210        setchoiceboxselection(newsletter, getconfig("newsletter", NULL));
211
212        addchoicebox(showhiddenfiles, "0", _("no"));
213        addchoicebox(showhiddenfiles, "1", _("yes"));
214        setchoiceboxselection(showhiddenfiles, getconfig("showhiddenfiles", NULL));
215
216        addchoicebox(expertmodus, "0", _("no"));
217        addchoicebox(expertmodus, "10", _("yes"));
218        if(getconfigint("expertmodus", NULL) == 11)
219                addchoicebox(expertmodus, "11", _("expert (11)"));
220        setchoiceboxselection(expertmodus, getconfig("expertmodus", NULL));
221
222        addchoicebox(infobarprogram, "0", _("no"));
223        addchoicebox(infobarprogram, "1", _("yes"));
224        setchoiceboxselection(infobarprogram, getconfig("infobarprogram", NULL));
225
226        addchoicebox(crosscontrol, "0", _("no"));
227        addchoicebox(crosscontrol, "1", _("yes"));
228        addchoicebox(crosscontrol, "2", _("yes / vzap 1 sec"));
229        addchoicebox(crosscontrol, "3", _("yes / vzap 2 sec"));
230        addchoicebox(crosscontrol, "9999", _("yes / vzap endless"));
231        setchoiceboxselection(crosscontrol, getconfig("crosscontrol", NULL));
232
233        addchoicebox(emucontrol, "0", _("no"));
234        addchoicebox(emucontrol, "1", _("yes"));
235        setchoiceboxselection(emucontrol, getconfig("emucontrol", NULL));
236
237        addchoicebox(usecec, "0", _("no"));
238        addchoicebox(usecec, "1", _("yes"));
239        setchoiceboxselection(usecec, getconfig("usecec", NULL));
240
241        if(!file_exist("/mnt/config/dualboot"))
242        {
243                addchoicebox(dualboot, "0", _("no"));
244                addchoicebox(dualboot, "1", _("yes"));
245        }
246        else
247        {
248                addchoicebox(dualboot, "1", _("yes"));
249                addchoicebox(dualboot, "0", _("no"));
250        }
251        setchoiceboxselection(dualboot, getconfig("dualboot", NULL));
252
253        changemask(community_user, "****");
254        if(getconfig("community_user", NULL) == NULL)
255                changeinput(community_user, getconfig("community_user", NULL));
256        else
257                changeinput(community_pass, "****");
258               
259        changemask(community_pass, "****");
260        if(getconfig("community_pass", NULL) == NULL)
261                changeinput(community_pass, getconfig("community_pass", NULL));
262        else
263                changeinput(community_pass, "****");
264       
265
266// setdebuglevel
267#ifndef BETA
268        debuglevel->hidden = YES;
269#else
270        tmpstr = ostrcat("10 - ", _("Minimal"), 0, 0); 
271        addchoicebox(debuglevel, "10", tmpstr);
272        free(tmpstr), tmpstr = NULL;
273       
274        tmpstr = ostrcat("40 - ", _("MTD Operation/System Update"), 0, 0);     
275        addchoicebox(debuglevel, "40", tmpstr);
276        free(tmpstr), tmpstr = NULL;
277       
278        tmpstr = ostrcat("50 - ", _("MediaCenter"), 0, 0);     
279        addchoicebox(debuglevel, "50", tmpstr);
280        free(tmpstr), tmpstr = NULL;
281       
282        tmpstr = ostrcat("55 - ", _("Network Interface"), 0, 0);       
283        addchoicebox(debuglevel, "55", tmpstr);
284        free(tmpstr), tmpstr = NULL;
285       
286        tmpstr = ostrcat("60 - ", _("Key Actions"), 0, 0);     
287        addchoicebox(debuglevel, "60", tmpstr);
288        free(tmpstr), tmpstr = NULL;
289       
290        tmpstr = ostrcat("70 - ", _("Networkbrowser"), 0, 0);   
291        addchoicebox(debuglevel, "70", tmpstr);
292        free(tmpstr), tmpstr = NULL;
293       
294        tmpstr = ostrcat("77 - ", _("Web Adjust"), 0, 0);       
295        addchoicebox(debuglevel, "77", tmpstr);
296        free(tmpstr), tmpstr = NULL;
297       
298        tmpstr = ostrcat("80 - ", _("Harddisk"), 0, 0);
299        addchoicebox(debuglevel, "80", tmpstr);
300        free(tmpstr), tmpstr = NULL;
301       
302        tmpstr = ostrcat("81 - ", _("MultiImage"), 0, 0);       
303        addchoicebox(debuglevel, "81", tmpstr);
304        free(tmpstr), tmpstr = NULL;
305       
306        tmpstr = ostrcat("90 - ", _("Screensaver"), 0, 0);     
307        addchoicebox(debuglevel, "90", tmpstr);
308        free(tmpstr), tmpstr = NULL;
309       
310        tmpstr = ostrcat("99 - ", _("Tithek/HTTP Header/Community"), 0, 0);     
311        addchoicebox(debuglevel, "99", tmpstr);
312        free(tmpstr), tmpstr = NULL;
313       
314        tmpstr = ostrcat("100 - ", _("Global"), 0, 0); 
315        addchoicebox(debuglevel, "100", tmpstr);
316        free(tmpstr), tmpstr = NULL;
317       
318        tmpstr = ostrcat("110 - ", _("Stringconvert"), 0, 0);   
319        addchoicebox(debuglevel, "110", tmpstr);
320        free(tmpstr), tmpstr = NULL;
321       
322        tmpstr = ostrcat("130 - ", _("TPK"), 0, 0);     
323        addchoicebox(debuglevel, "130", tmpstr);
324        free(tmpstr), tmpstr = NULL;
325       
326        tmpstr = ostrcat("133 - ", _("MediaDB/IMDb/TMDb"), 0, 0);       
327        addchoicebox(debuglevel, "133", tmpstr);
328        free(tmpstr), tmpstr = NULL;
329       
330        tmpstr = ostrcat("150 - ", _("ePlayer"), 0, 0);
331        addchoicebox(debuglevel, "150", tmpstr);
332        free(tmpstr), tmpstr = NULL;
333       
334        tmpstr = ostrcat("200 - ", _("DVB Devices"), 0, 0);     
335        addchoicebox(debuglevel, "200", tmpstr);
336        free(tmpstr), tmpstr = NULL;
337       
338        tmpstr = ostrcat("201 - ", _("CA Device"), 0, 0);       
339        addchoicebox(debuglevel, "201", tmpstr);
340        free(tmpstr), tmpstr = NULL;
341       
342        tmpstr = ostrcat("250 - ", _("HTTP Server/Stream/Record"), 0, 0);       
343        addchoicebox(debuglevel, "250", tmpstr);
344        free(tmpstr), tmpstr = NULL;
345       
346        tmpstr = ostrcat("270 - ", _("Radiotext"), 0, 0);       
347        addchoicebox(debuglevel, "270", tmpstr);
348        free(tmpstr), tmpstr = NULL;
349       
350        tmpstr = ostrcat("278 - ", _("ID3"), 0, 0);     
351        addchoicebox(debuglevel, "278", tmpstr);
352        free(tmpstr), tmpstr = NULL;
353       
354        tmpstr = ostrcat("300 - ", _("Subtitle"), 0, 0);       
355        addchoicebox(debuglevel, "300", tmpstr);
356        free(tmpstr), tmpstr = NULL;
357       
358        tmpstr = ostrcat("307 - ", _("Thumbnails"), 0, 0);     
359        addchoicebox(debuglevel, "307", tmpstr);
360        free(tmpstr), tmpstr = NULL;
361       
362        tmpstr = ostrcat("333 - ", _("DVD Player"), 0, 0);     
363        addchoicebox(debuglevel, "333", tmpstr);
364        free(tmpstr), tmpstr = NULL;
365/*     
366        tmpstr = ostrcat("369 - ", _("Facebook"), 0, 0);       
367        addchoicebox(debuglevel, "369", tmpstr);
368        free(tmpstr), tmpstr = NULL;
369*/     
370        tmpstr = ostrcat("400 - ", _("EPG Task"), 0, 0);       
371        addchoicebox(debuglevel, "400", tmpstr);
372        free(tmpstr), tmpstr = NULL;
373       
374       
375        tmpstr = ostrcat("401 - ", _("Old Entry"), 0, 0);       
376        addchoicebox(debuglevel, "401", tmpstr);
377        free(tmpstr), tmpstr = NULL;
378       
379        tmpstr = ostrcat("427 - ", _("Newsletter"), 0, 0);     
380        addchoicebox(debuglevel, "427", tmpstr);
381        free(tmpstr), tmpstr = NULL;
382       
383        tmpstr = ostrcat("444 - ", _("Framebuffer"), 0, 0);     
384        addchoicebox(debuglevel, "444", tmpstr);
385        free(tmpstr), tmpstr = NULL;
386       
387        tmpstr = ostrcat("500 - ", _("Channel Scan"), 0, 0);   
388        addchoicebox(debuglevel, "500", tmpstr);
389        free(tmpstr), tmpstr = NULL;
390       
391        tmpstr = ostrcat("555 - ", _("Draw Screen"), 0, 0);     
392        addchoicebox(debuglevel, "555", tmpstr);
393        free(tmpstr), tmpstr = NULL;
394       
395        tmpstr = ostrcat("620 - ", _("CA"), 0, 0);     
396        addchoicebox(debuglevel, "620", tmpstr);
397        free(tmpstr), tmpstr = NULL;
398       
399        tmpstr = ostrcat("777 - ", _("MediaDB"), 0, 0);
400        addchoicebox(debuglevel, "777", tmpstr);
401        free(tmpstr), tmpstr = NULL;
402/*     
403        tmpstr = ostrcat("788 - ", _("HbbTV"), 0, 0);   
404        addchoicebox(debuglevel, "788", tmpstr);
405        free(tmpstr), tmpstr = NULL;
406*/     
407        tmpstr = ostrcat("900 - ", _("Mutex"), 0, 0);   
408        addchoicebox(debuglevel, "900", tmpstr);
409        free(tmpstr), tmpstr = NULL;
410       
411        tmpstr = ostrcat("913 - ", _("File Operation"), 0, 0); 
412        addchoicebox(debuglevel, "913", tmpstr);
413        free(tmpstr), tmpstr = NULL;
414       
415        tmpstr = ostrcat("975 - ", _("SMTP"), 0, 0);   
416        addchoicebox(debuglevel, "975", tmpstr);
417        free(tmpstr), tmpstr = NULL;
418       
419        tmpstr = ostrcat("4440 - ", _("PiP"), 0, 0);   
420        addchoicebox(debuglevel, "4440", tmpstr);
421        free(tmpstr), tmpstr = NULL;
422       
423        setchoiceboxselection(debuglevel, getconfig("debuglevel", NULL));
424#endif
425
426
427#ifdef MIPSEL
428        dualboot->hidden = NO;
429        frontpoweraktion->hidden = NO;
430#else
431        dualboot->hidden = YES;
432        frontpoweraktion->hidden = YES;
433#endif
434
435        if(!file_exist("/usr/bin/enigma2"))
436                dualboot->hidden = YES;
437
438        if(status.security == 0 || checkemu() == 0)
439                emucontrol->hidden = YES;
440        else
441                emucontrol->hidden = NO;
442        if(checkbox("ATEMIO510") == 1 || checkbox("UFS912") == 1 || checkbox("UFS913") == 1 || checkbox("ATEMIO7600") == 1 || checkbox("ATEMIO520") == 1 || checkbox("ATEMIO530") == 1 || checkbox("SPARK") == 1 || checkbox("SPARK7162") == 1)
443                usecec->hidden = NO;
444        else
445                usecec->hidden = YES;
446
447        if(checkbox("ATEMIO7600") == 1)
448        {
449                sataswitch->hidden = NO;
450                addchoicebox(sataswitch, "0", _("extern"));
451                addchoicebox(sataswitch, "1", _("intern"));
452                tmpstr = getsataswitch();
453                setchoiceboxselection(sataswitch, tmpstr);
454                free(tmpstr); tmpstr = NULL;
455        }
456        else
457                sataswitch->hidden = YES;
458       
459        addchoicebox(playerbuffersize, "0", _("no"));
460        addchoicebox(playerbuffersize, "524288", "512KB");
461        addchoicebox(playerbuffersize, "1048576", "1MB");
462        addchoicebox(playerbuffersize, "1572864", "1,5MB");
463        addchoicebox(playerbuffersize, "2097152", "2MB");
464        addchoicebox(playerbuffersize, "2621440", "2,5MB");
465        addchoicebox(playerbuffersize, "3145728", "3MB");
466        addchoicebox(playerbuffersize, "3670016", "3,5MB");
467        addchoicebox(playerbuffersize, "4194304", "4MB");
468        addchoicebox(playerbuffersize, "4718592", "4,5MB");
469        addchoicebox(playerbuffersize, "5242880", "5MB");
470        setchoiceboxselection(playerbuffersize, getconfig("playerbuffersize", NULL));
471       
472        addchoicebox(playerbufferseektime, "0", "0");
473        addchoicebox(playerbufferseektime, "1", "1");
474        addchoicebox(playerbufferseektime, "2", "2");
475        addchoicebox(playerbufferseektime, "3", "3");
476        addchoicebox(playerbufferseektime, "4", "4");
477        addchoicebox(playerbufferseektime, "5", "5");
478        addchoicebox(playerbufferseektime, "6", "6");
479        addchoicebox(playerbufferseektime, "7", "7");
480        addchoicebox(playerbufferseektime, "8", "8");
481        addchoicebox(playerbufferseektime, "9", "9");
482        addchoicebox(playerbufferseektime, "10", "10");
483        setchoiceboxselection(playerbufferseektime, getconfig("playerbufferseektime", NULL));
484
485        drawscreen(adjust, 0, 0);
486        addscreenrc(adjust, listbox);
487
488        tmp = listbox->select;
489        while(1)
490        {
491                addscreenrc(adjust, tmp);
492                rcret = waitrc(adjust, 0, 0);
493                tmp = listbox->select;
494
495                if(rcret == getrcconfigint("rcexit", NULL)) break;
496                if(rcret == getrcconfigint("rcok", NULL))
497                {
498                        addconfigscreen("volbartimeout", volbartimeout);
499                        addconfigscreen("infobartimeout", infobartimeout);
500                        addconfigscreen("infobarsleep", infobarsleep);
501                        addconfigscreencheck("secondinfobar", secondinfobar, "0");             
502                        addconfigscreen("spinnerspeed", spinnerspeed);
503                        status.spinnerspeed = getconfigint("spinnerspeed", NULL);
504                        addconfigscreen("spinnertime", spinnertime);
505                        status.spinnertime = getconfigint("spinnertime", NULL);
506                        addconfigscreen("hangtime", hangtime);
507                        status.hangtime = getconfigint("hangtime", NULL);
508                        addconfigscreencheck("nozapclear", nozapclear, "0");
509                        addconfigscreencheck("fastzap", fastzap, "0");
510                        addconfigscreencheck("faststop", faststop, "0");
511                        addconfigscreencheck("dirsort", dirsort, "0");
512                        addconfigscreencheck("poweraktion", poweraktion, "0");
513                        addconfigscreencheck("frontpoweraktion", frontpoweraktion, "0");
514                        addconfigscreencheck("recforerun", recforerun, "0");
515                        addconfigscreencheck("recoverrun", recoverrun, "0");
516                        addconfigscreencheck("virtualzap", virtualzap, "0");
517                        status.virtualzap = getconfigint("virtualzap", NULL);
518                        if(fasttextrender->ret != NULL)
519                        {
520                                addconfigscreencheck("fasttextrender", fasttextrender, "0");
521                                status.fasttextrender = atoi(fasttextrender->ret);
522                        }
523                        if(recsplitsize->ret != NULL)
524                        {
525                                addconfigscreencheck("recsplitsize", recsplitsize, "0");
526                                status.recsplitsize = atoi(recsplitsize->ret);
527                                status.recsplitsize *= 1000 * 1000 * 1000;
528                        }
529                        addconfigscreen("skip13", skip13);
530                        addconfigscreen("skip46", skip46);
531                        addconfigscreen("skip79", skip79);
532                        addconfigscreencheck("playertype", playertype, "1");
533                        addconfigscreencheck("autochangechannelname", autochangechannelname, "0");
534                        status.autochangechannelname = getconfigint("autochangechannelname", NULL);
535                        addconfigscreencheck("def_rectimer_after", def_rectimer_after, "0");
536                        addconfigscreencheck("showchanneltimeline", showchanneltimeline, "0");
537                        status.showchanneltimeline = getconfigint("showchanneltimeline", NULL);
538                        addconfigscreencheck("screenanim", screenanim, "0");
539                        status.screenanim = getconfigint("screenanim", NULL);
540                        addconfigscreencheck("screenanimspeed", screenanimspeed, "1");
541                        status.screenanimspeed = getconfigint("screenanimspeed", NULL);
542                        addconfigscreencheck("channellistview", channellistview, "0");
543                        status.channellistview = getconfigint("channellistview", NULL);
544                        addconfigscreencheck("showlastpos", showlastpos, "0");
545                        addconfigscreencheck("recsync", recsync, "0");
546                        addconfigscreencheck("recordnamefmt", recordnamefmt, "0");
547
548                        addconfigscreen("newsletter", newsletter);
549                        if(newsletter->ret != NULL && ostrcmp(newsletter->ret, "0") == 0)
550                                startnewsletter(0);
551                        else
552                                startnewsletter(1);
553
554                        addconfigscreen("showhiddenfiles", showhiddenfiles);
555                        status.showhiddenfiles = getconfigint("showhiddenfiles", NULL);
556                        addconfigscreencheck("expertmodus", expertmodus, "0");
557                        status.expertmodus = getconfigint("expertmodus", NULL);                                 
558                        addconfigscreencheck("infobarprogram", infobarprogram, "0");
559                        status.infobarprogram = getconfigint("infobarprogram", NULL);
560                        addconfigscreen("crosscontrol", crosscontrol);
561                        //addconfigscreencheck("crosscontrol", crosscontrol, "0");
562                        status.crosscontrol = getconfigint("crosscontrol", NULL);
563                        addconfigscreencheck("emucontrol", emucontrol, "0");
564
565                        if(checkbox("ATEMIO510") == 1 || checkbox("ATEMIO520") == 1 || checkbox("ATEMIO530") == 1 || checkbox("ATEMIO7600") == 1 || checkbox("UFS912") == 1 || checkbox("UFS913") == 1 || checkbox("SPARK") == 1 || checkbox("SPARK7162") == 1)
566                                addconfigscreencheck("usecec", usecec, "0");
567
568                        if(checkbox("ATEMIO7600") == 1)
569                        {
570                                addconfigscreencheck("usecec", usecec, "0");
571                                if(sataswitch->ret != NULL)
572                                {
573                                        addownconfig("sataswitch", sataswitch->ret);
574                                        setsataswitch(sataswitch->ret);
575                                }
576                        }
577
578#ifdef MIPSEL
579                        addconfigscreen("dualboot", dualboot);
580                        if(dualboot->ret != NULL && ostrcmp(dualboot->ret, "0") == 0)
581                                unlink("/mnt/config/dualboot");
582                        else
583                                system("touch /mnt/config/dualboot");
584#endif
585                        addconfigscreen("playerbuffersize", playerbuffersize);
586                        addconfigscreen("playerbufferseektime", playerbufferseektime);
587
588#ifdef BETA
589                        addconfigscreencheck("debuglevel", debuglevel, "0");
590                        setdebuglevel();
591#endif
592                        if(community_user->ret != NULL && ostrcmp(community_user->ret, "****") != 0)
593                        {
594                                debug(99, "community_user: write");
595                                debug(99, "community_user: %s", community_user->ret);
596                                addconfigscreen("community_user", community_user);
597                        }
598                        else
599                        {
600                                debug(99, "community_user: skipped");
601                        }
602                        if(community_pass->ret != NULL && ostrcmp(community_pass->ret, "****") != 0)
603                        {
604                                debug(99, "community_pass: write");
605                                debug(99, "community_pass: %s", community_pass->ret);
606                                addconfigscreen("community_pass", community_pass);
607                        }
608                        else
609                        {
610                                debug(99, "community_pass: skipped");
611                        }
612                        writeallconfig(1);
613
614                        debug(99, "community_user read: %s", getconfig("community_user", NULL));
615                        debug(99, "community_pass read: %s", getconfig("community_pass", NULL));
616
617                        break;
618                }
619        }
620        delownerrc(adjust);
621        clearscreen(adjust);
622}
623
624#endif
Note: See TracBrowser for help on using the repository browser.