diff options
author | Christi Scarborough <christi@coraline.org> | 2005-11-18 15:33:05 +0000 |
---|---|---|
committer | Christi Scarborough <christi@coraline.org> | 2005-11-18 15:33:05 +0000 |
commit | 32a43e2ee688bf8b3c930685400a52910c512a1e (patch) | |
tree | 8675fddb2d926f0dabb65adb798033036a22c18d /wps | |
parent | e16ebf1a50b9692e93f44633138903418ef93526 (diff) | |
download | rockbox-32a43e2ee688bf8b3c930685400a52910c512a1e.tar.gz rockbox-32a43e2ee688bf8b3c930685400a52910c512a1e.zip |
When fixing things is it better to do it in a way that causes them to actually work. Some more bugs in wpsbuild.pl squashed. Also, themes moved to the main menu. Resetting to default themes now works properly.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7965 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'wps')
-rw-r--r-- | wps/WPSLIST | 6 | ||||
-rw-r--r-- | wps/iAmp.rwps | 4 | ||||
-rwxr-xr-x | wps/wpsbuild.pl | 20 |
3 files changed, 19 insertions, 11 deletions
diff --git a/wps/WPSLIST b/wps/WPSLIST index e4375cdd96..4862da01ba 100644 --- a/wps/WPSLIST +++ b/wps/WPSLIST | |||
@@ -58,7 +58,7 @@ Width: 160 | |||
58 | <wps> | 58 | <wps> |
59 | Name: engineeer2.wps | 59 | Name: engineeer2.wps |
60 | Author: Magnus Westerlund | 60 | Author: Magnus Westerlund |
61 | Font: Nedore-8.fnt | 61 | Font: nedore-8.fnt |
62 | Statusbar: Off | 62 | Statusbar: Off |
63 | Height: 128 | 63 | Height: 128 |
64 | Width: 160 | 64 | Width: 160 |
@@ -68,7 +68,7 @@ Width: 160 | |||
68 | Name: iAmp.wps | 68 | Name: iAmp.wps |
69 | RWPS: iAmp.rwps | 69 | RWPS: iAmp.rwps |
70 | Author: Raymond Hoh | 70 | Author: Raymond Hoh |
71 | Font: Nimbus-12.fnt | 71 | Font: nimbus-12.fnt |
72 | Statusbar: Off | 72 | Statusbar: Off |
73 | Height: 128 | 73 | Height: 128 |
74 | Width: 160 | 74 | Width: 160 |
@@ -95,7 +95,7 @@ Width: 128 | |||
95 | <rwps> | 95 | <rwps> |
96 | Name: iAmp.rwps | 96 | Name: iAmp.rwps |
97 | Author: Raymond Hoh | 97 | Author: Raymond Hoh |
98 | Font: Nimbus-12.fnt | 98 | Font: nimbus-12.fnt |
99 | Statusbar: Off | 99 | Statusbar: Off |
100 | Height: 64 | 100 | Height: 64 |
101 | Width: 128 | 101 | Width: 128 |
diff --git a/wps/iAmp.rwps b/wps/iAmp.rwps index ac944526f8..d0d6e0a0c9 100644 --- a/wps/iAmp.rwps +++ b/wps/iAmp.rwps | |||
@@ -2,7 +2,7 @@ | |||
2 | %s%?ia<%ia|%d1> | 2 | %s%?ia<%ia|%d1> |
3 | %s%?it<%?in<%in. >%it|%fn> | 3 | %s%?it<%?in<%in. >%it|%fn> |
4 | %pb | 4 | %pb |
5 | %xl|H|i/a5.bmp|102|48| | 5 | %xl|H|a5.bmp|102|48| |
6 | %xl|o|m1.bmp|102|48| | 6 | %xl|o|m1.bmp|102|48| |
7 | %xl|p|m2.bmp|102|48| | 7 | %xl|p|m2.bmp|102|48| |
8 | %xl|q|m3.bmp|102|48| | 8 | %xl|q|m3.bmp|102|48| |
@@ -47,4 +47,4 @@ | |||
47 | %xl|C|z.bmp|74|48| | 47 | %xl|C|z.bmp|74|48| |
48 | %?mp<||%xdA|%xdB|%xdC> | 48 | %?mp<||%xdA|%xdB|%xdC> |
49 | %x|v|pb.bmp|96|40| | 49 | %x|v|pb.bmp|96|40| |
50 | # letters to use: b, M-Z \ No newline at end of file | 50 | # letters to use: b, M-Z |
diff --git a/wps/wpsbuild.pl b/wps/wpsbuild.pl index fc7be294a3..d6cff68d3a 100755 --- a/wps/wpsbuild.pl +++ b/wps/wpsbuild.pl | |||
@@ -90,7 +90,7 @@ sub mkdirs { | |||
90 | my $wpsdir = $wps; | 90 | my $wpsdir = $wps; |
91 | $wpsdir =~ s/\.(r|)wps//; | 91 | $wpsdir =~ s/\.(r|)wps//; |
92 | mkdir ".rockbox/wps", 0777; | 92 | mkdir ".rockbox/wps", 0777; |
93 | mkdir ".rockbox/theme", 0777; | 93 | mkdir ".rockbox/themes", 0777; |
94 | 94 | ||
95 | if( -d ".rockbox/wps/$wpsdir") { | 95 | if( -d ".rockbox/wps/$wpsdir") { |
96 | #print STDERR "wpsbuild warning: directory wps/$wpsdir already exists!\n"; | 96 | #print STDERR "wpsbuild warning: directory wps/$wpsdir already exists!\n"; |
@@ -140,7 +140,7 @@ MOO | |||
140 | if($statusbar) { | 140 | if($statusbar) { |
141 | push @out, "statusbar: $statusbar\n"; | 141 | push @out, "statusbar: $statusbar\n"; |
142 | } | 142 | } |
143 | if($rwps && !$isrwps) { | 143 | if($rwps && $has_remote ) { |
144 | push @out, "rwps: /.rockbox/wps/$rwps\n"; | 144 | push @out, "rwps: /.rockbox/wps/$rwps\n"; |
145 | } | 145 | } |
146 | 146 | ||
@@ -148,7 +148,7 @@ MOO | |||
148 | print STDERR "wpsbuild warning: wps/$cfg already exists!\n"; | 148 | print STDERR "wpsbuild warning: wps/$cfg already exists!\n"; |
149 | } | 149 | } |
150 | else { | 150 | else { |
151 | open(CFG, ">.rockbox/theme/$cfg"); | 151 | open(CFG, ">.rockbox/themes/$cfg"); |
152 | print CFG @out; | 152 | print CFG @out; |
153 | close(CFG); | 153 | close(CFG); |
154 | } | 154 | } |
@@ -158,6 +158,8 @@ MOO | |||
158 | my ($main_height, $main_width) = getlcdsizes(); | 158 | my ($main_height, $main_width) = getlcdsizes(); |
159 | my ($remote_height, $remote_width) = getlcdsizes(1); | 159 | my ($remote_height, $remote_width) = getlcdsizes(1); |
160 | 160 | ||
161 | $has_remote = true if ($remote_height && $remote_width); | ||
162 | |||
161 | open(WPS, "<$wpslist"); | 163 | open(WPS, "<$wpslist"); |
162 | while(<WPS>) { | 164 | while(<WPS>) { |
163 | my $l = $_; | 165 | my $l = $_; |
@@ -168,6 +170,14 @@ while(<WPS>) { | |||
168 | if($l =~ /^ *<(r|)wps>/i) { | 170 | if($l =~ /^ *<(r|)wps>/i) { |
169 | $isrwps = $1; | 171 | $isrwps = $1; |
170 | $within = 1; | 172 | $within = 1; |
173 | # undef is a unary operator (!) | ||
174 | undef $wps; | ||
175 | undef $rwps; | ||
176 | undef $width; | ||
177 | undef $height; | ||
178 | undef $font; | ||
179 | undef $statusbar; | ||
180 | undef $author; | ||
171 | next; | 181 | next; |
172 | } | 182 | } |
173 | if($within) { | 183 | if($within) { |
@@ -184,6 +194,7 @@ while(<WPS>) { | |||
184 | if(!$rheight || !$rwidth) { | 194 | if(!$rheight || !$rwidth) { |
185 | printf STDERR "wpsbuild notice: No %sLCD size, skipping $wps\n", | 195 | printf STDERR "wpsbuild notice: No %sLCD size, skipping $wps\n", |
186 | $isrwps?"remote ":""; | 196 | $isrwps?"remote ":""; |
197 | $within = 0; | ||
187 | next; | 198 | next; |
188 | } | 199 | } |
189 | 200 | ||
@@ -196,7 +207,6 @@ while(<WPS>) { | |||
196 | # WPS | 207 | # WPS |
197 | # | 208 | # |
198 | #print "Size requirement is fine!\n"; | 209 | #print "Size requirement is fine!\n"; |
199 | |||
200 | mkdirs(); | 210 | mkdirs(); |
201 | if(!$isrwps) { | 211 | if(!$isrwps) { |
202 | # We only make .cfg files for <wps> sections: | 212 | # We only make .cfg files for <wps> sections: |
@@ -208,8 +218,6 @@ while(<WPS>) { | |||
208 | #print "Skip $wps due to size restraints\n"; | 218 | #print "Skip $wps due to size restraints\n"; |
209 | } | 219 | } |
210 | $within = 0; | 220 | $within = 0; |
211 | |||
212 | undef $wps, $rwps, $width, $height, $font, $statusbar, $author; | ||
213 | } | 221 | } |
214 | elsif($l =~ /^Name: (.*)/i) { | 222 | elsif($l =~ /^Name: (.*)/i) { |
215 | # Note that in the case this is within <rwps>, $wps will contain the | 223 | # Note that in the case this is within <rwps>, $wps will contain the |