to ensure bitmap is always available: include it in the binary
authorClaus Gittinger <cg@exept.de>
Tue, 05 Aug 2008 15:25:21 +0200
changeset 3687 48b9b4e7ed08
parent 3686 de886bde6f31
child 3688 e266cdde958a
to ensure bitmap is always available: include it in the binary
RadioButton.st
--- a/RadioButton.st	Fri Jul 25 14:02:05 2008 +0200
+++ b/RadioButton.st	Tue Aug 05 15:25:21 2008 +0200
@@ -524,6 +524,11 @@
     ] ifFalse:[
         f := StyleSheet at:#'radioButton.activeImage'.
     ].
+    f isNil ifTrue:[
+        RoundOffForm := StyleSheet isWindowsXPStyle
+                            ifTrue:[ self radioOnIcon_xp ]
+                            ifFalse:[ self radioOnIcon_w95 ]
+    ].
     f notNil ifTrue:[
         RoundOnForm := f onDevice:Display
     ].
@@ -534,6 +539,12 @@
     ] ifFalse:[
         f := StyleSheet at:#'radioButton.passiveImage'.
     ].
+    f isNil ifTrue:[
+        RoundOffForm := StyleSheet isWindowsXPStyle
+                            ifTrue:[ self radioOffIcon_xp ]
+                            ifFalse:[ self radioOffIcon_w95 ]
+    ].
+
     f notNil ifTrue:[
         RoundOffForm := f onDevice:Display
     ].
@@ -545,6 +556,96 @@
     "Modified: / 28.4.1999 / 13:59:00 / cg"
 ! !
 
+!RadioButton class methodsFor:'image specs'!
+
+radioOffIcon_w95
+    "This resource specification was automatically generated
+     by the ImageEditor of ST/X."
+
+    "Do not manually edit this!! If it is corrupted,
+     the ImageEditor may not be able to read the specification."
+
+    "
+     self radioOffIcon_w95 inspect
+     ImageEditor openOnClass:self andSelector:#radioOffIcon_w95
+     Icon flushCachedIcons
+    "
+
+    <resource: #image>
+
+    ^Icon
+        constantNamed:'RadioButton class radioOffIcon_w95'
+        ifAbsentPut:[(Depth8Image new) width: 12; height: 12; photometric:(#palette); bitsPerSample:(#(8)); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'
+A@PDA@DA@PDDA@PDA@PA@P@@@@@A@PPDA@D@@@LC@0L@@@LDA@D@@0LC@0LC@ LD@P@C@0LC@0LC@0HC@P@C@0LC@0LC@0HC@P@C@0LC@0LC@0HC@P@C@0LC
+@0LC@0HCA@D@@0LC@0LC@ LDA@DB@ LC@0LB@ LDA@PC@0HB@ HC@0PDA@PDA@LC@0LDA@PD') ; colorMapFromArray:#[0 0 0 128 128 128 223 223 223 255 255 255 0 0 0]; mask:((ImageMask new) width: 12; height: 12; photometric:(#blackIs0); bitsPerSample:(#[1]); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'C0@?0G? _>C?<O?0??C?<G? _>@?0@<@') ; yourself); yourself]
+!
+
+radioOffIcon_xp
+    "This resource specification was automatically generated
+     by the ImageEditor of ST/X."
+
+    "Do not manually edit this!! If it is corrupted,
+     the ImageEditor may not be able to read the specification."
+
+    "
+     self radioOffIcon_xp inspect
+     ImageEditor openOnClass:self andSelector:#radioOffIcon_xp
+     Icon flushCachedIcons
+    "
+
+    <resource: #image>
+
+    ^Icon
+        constantNamed:'RadioButton class radioOffIcon_xp'
+        ifAbsentPut:[(Depth8Image new) width: 13; height: 13; photometric:(#palette); bitsPerSample:(#(8)); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'
+KB0,A T''G"\EA"0,KB0,B1,OH14%DQ,KKB0,B1 P@BPTE1$&J@,,D1,P@BPTE1$\CB$[D0TO@BPTE1$\C@4+E T''H2PTE1$\C@4+@Q<JG!!4TE1$\C@4+@PL*
+G (%E1$\C@4+@PLHHB\UDQ$\C@4+@PLHA0$ED1,&C@4+@PLHA0P[H"0KJB$+@PLHA0PNB20,KA([E!!<*H@$[B20,KB0,HQT''G (R@"0,K@@a') ; colorMapFromArray:#[224 224 219 247 247 246 221 226 229 249 249 248 188 204 217 164 183 198 222 228 229 253 253 252 251 251 250 112 145 175 90 128 159 180 195 206 241 241 239 243 243 241 96 133 166 100 134 161 166 181 191 104 137 166 164 182 198 222 227 229 229 229 226 164 183 197 110 143 172 232 232 229 85 122 154 236 236 233 179 195 206 33 85 130 239 239 236 218 220 218 36 87 131 185 200 213 188 203 216 222 226 229 222 227 228 167 183 193 226 226 222 171 186 198 178 193 205 90 128 160 91 129 161 181 196 208 242 244 245 245 245 244 0 0 0]; mask:((ImageMask new) width: 13; height: 13; photometric:(#blackIs0); bitsPerSample:(#[1]); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'G<@?8G?0??#?>O?8??#?>O?8??!!?<C? G<@b') ; yourself); yourself]
+!
+
+radioOnIcon_w95
+    "This resource specification was automatically generated
+     by the ImageEditor of ST/X."
+
+    "Do not manually edit this!! If it is corrupted,
+     the ImageEditor may not be able to read the specification."
+
+    "
+     self radioOnIcon_w95 inspect
+     ImageEditor openOnClass:self andSelector:#radioOnIcon_w95
+     Icon flushCachedIcons
+    "
+
+    <resource: #image>
+
+    ^Icon
+        constantNamed:'RadioButton class radioOnIcon_w95'
+        ifAbsentPut:[(Depth8Image new) width: 12; height: 12; photometric:(#palette); bitsPerSample:(#(8)); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'
+A@PDA@DA@PDDA@PDA@PA@P@@@@@A@PPDA@D@@@LC@0L@@@LDA@D@@0LC@0LC@ LD@P@C@0L@@@LC@0HC@P@C@0@@@@@C@0HC@P@C@0@@@@@C@0HC@P@C@0L@
+@@LC@0HCA@D@@0LC@0LC@ LDA@DB@ LC@0LB@ LDA@PC@0HB@ HC@0PDA@PDA@LC@0LDA@PD') ; colorMapFromArray:#[0 0 0 128 128 128 223 223 223 255 255 255 0 0 0]; mask:((ImageMask new) width: 12; height: 12; photometric:(#blackIs0); bitsPerSample:(#[1]); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'C0@?0G? _>C?<O?0??C?<G? _>@?0@<@') ; yourself); yourself]
+!
+
+radioOnIcon_xp
+    "This resource specification was automatically generated
+     by the ImageEditor of ST/X."
+
+    "Do not manually edit this!! If it is corrupted,
+     the ImageEditor may not be able to read the specification."
+
+    "
+     self radioOnIcon_xp inspect
+     ImageEditor openOnClass:self andSelector:#radioOnIcon_xp
+     Icon flushCachedIcons
+    "
+
+    <resource: #image>
+
+    ^Icon
+        constantNamed:'RadioButton class radioOnIcon_xp'
+        ifAbsentPut:[(Depth8Image new) width: 13; height: 13; photometric:(#palette); bitsPerSample:(#(8)); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'
+Q4]GC18MK04^C4]GQ4]GL0T<JD@1PPT3Q4]GL2ABA2(9BQ@AO3MGE UBOQ<7DBMCIA(EE!!8<A1<HL#86K@IDJQ8MJB(7L XQC (&I!!,UK4@9DC8WJ3UE@0LR
+K1T1BRL6Q"8TLC(-M@4"PQACK@(DI1L\C@@^E TAI@H&@3(\B2TEFT\3O1)DI L-CBT;L4]GQ3 EJQ,RM@@EL4]GQ4]GFBHMK1T!!GT]GQ0@a') ; colorMapFromArray:#[112 145 175 178 193 205 245 245 243 249 249 248 36 150 36 33 85 130 85 213 81 224 224 219 226 232 222 232 232 229 154 204 152 253 253 253 253 253 252 90 128 160 41 168 38 222 228 229 236 236 233 67 195 63 242 244 245 238 243 237 19 146 16 90 128 159 222 227 229 66 195 63 222 226 229 222 227 228 181 196 208 185 200 213 252 252 251 221 226 229 164 183 198 231 231 227 85 122 154 164 182 198 164 183 197 239 239 236 243 243 241 188 204 217 247 247 246 152 201 151 167 183 193 110 143 172 226 226 222 56 185 53 232 238 230 251 251 250 34 162 32 36 87 131 152 200 151 171 186 198 169 220 166 180 195 206 188 203 216 33 161 33 160 210 158 234 234 230 179 195 206 229 229 226 250 250 249 96 133 166 100 134 161 229 229 225 77 191 74 91 129 161 218 220 218 104 137 166 166 181 191 241 241 239 245 245 244 38 150 35 42 168 39 0 0 0]; mask:((ImageMask new) width: 13; height: 13; photometric:(#blackIs0); bitsPerSample:(#[1]); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'G<@?8G?0??#?>O?8??#?>O?8??!!?<C? G<@b') ; yourself); yourself]
+! !
+
 !RadioButton methodsFor:'accessing'!
 
 allViewBackground:something if:condition
@@ -807,5 +908,5 @@
 !RadioButton class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libwidg/RadioButton.st,v 1.37 2008-07-18 08:57:06 stefan Exp $'
+    ^ '$Header: /cvs/stx/stx/libwidg/RadioButton.st,v 1.38 2008-08-05 13:25:21 cg Exp $'
 ! !