equal
deleted
inserted
replaced
165 !SettingsDialog class methodsFor:'defaults'! |
165 !SettingsDialog class methodsFor:'defaults'! |
166 |
166 |
167 expandParents |
167 expandParents |
168 |
168 |
169 ^ true |
169 ^ true |
|
170 ! |
|
171 |
|
172 resourcePackName |
|
173 ^ AbstractLauncherApplication resourcePackName |
170 ! ! |
174 ! ! |
171 |
175 |
172 !SettingsDialog class methodsFor:'interface specs'! |
176 !SettingsDialog class methodsFor:'interface specs'! |
173 |
177 |
174 windowSpec |
178 windowSpec |
600 ]. |
604 ]. |
601 locClass autoload. |
605 locClass autoload. |
602 |
606 |
603 (locIcon isNil and:[locClass respondsTo:#defaultIcon]) ifTrue:[ locIcon := locClass defaultIcon]. |
607 (locIcon isNil and:[locClass respondsTo:#defaultIcon]) ifTrue:[ locIcon := locClass defaultIcon]. |
604 applicationLabel := (aName asCollectionOfSubstringsSeparatedBy:$/) last. |
608 applicationLabel := (aName asCollectionOfSubstringsSeparatedBy:$/) last. |
605 ^ self createItemName:aName label:applicationLabel class:locClass icon:locIcon expandParent:doExpand replaceExisting:false |
609 |
|
610 ^ self createItemName:aName label:(resources string:applicationLabel) class:locClass icon:locIcon expandParent:doExpand replaceExisting:false |
606 ! |
611 ! |
607 |
612 |
608 addIcon:aIcon forCategory:aCategoryName |
613 addIcon:aIcon forCategory:aCategoryName |
609 |
614 |
610 " add a new category Icon for a categorie " |
615 " add a new category Icon for a categorie " |
876 |
881 |
877 createItemName:aNameString label:aLabel class:aClass icon:aIcon expandParent:expandParent replaceExisting:doReplaceExisting |
882 createItemName:aNameString label:aLabel class:aClass icon:aIcon expandParent:expandParent replaceExisting:doReplaceExisting |
878 |
883 |
879 " create an application item in my application list |
884 " create an application item in my application list |
880 " |
885 " |
881 | newItem parent locIcon item| |
886 | newItem parentsName parent locIcon item| |
882 |
887 |
883 aNameString ~= aLabel ifTrue:[ |
888 (aNameString includes:$/) ifTrue:[ |
884 parent := self getItemForName:(aNameString copyTo:(aNameString size - aLabel size - 1)). |
889 parentsName := aNameString copyTo:(aNameString lastIndexOf:$/)-1. |
|
890 parent := self getItemForName:parentsName. |
885 ]. |
891 ]. |
886 parent isNil ifTrue:[ |
892 parent isNil ifTrue:[ |
887 parent := self applicationList root. |
893 parent := self applicationList root. |
888 ]. |
894 ]. |
889 |
895 |
890 doReplaceExisting ifTrue:[ |
896 doReplaceExisting ifTrue:[ |
891 parent children notNil ifTrue:[ |
897 parent children notNil ifTrue:[ |
892 (item := parent children detect:[ :aItem | aItem label = aLabel] ifNone:[nil]) notNil ifTrue:[ |
898 (item := parent children detect:[ :anItem | anItem nameString = aNameString] ifNone:[nil]) notNil ifTrue:[ |
893 ^ item. |
899 ^ item. |
894 ] |
900 ] |
895 ] |
901 ] |
896 ]. |
902 ]. |
897 |
903 |
1287 ! ! |
1293 ! ! |
1288 |
1294 |
1289 !SettingsDialog class methodsFor:'documentation'! |
1295 !SettingsDialog class methodsFor:'documentation'! |
1290 |
1296 |
1291 version |
1297 version |
1292 ^ '$Header: /cvs/stx/stx/libtool/SettingsDialog.st,v 1.47 2004-01-29 23:48:41 ca Exp $' |
1298 ^ '$Header: /cvs/stx/stx/libtool/SettingsDialog.st,v 1.48 2004-02-24 16:48:52 cg Exp $' |
1293 ! ! |
1299 ! ! |
1294 |
1300 |
1295 SettingsDialog initialize! |
1301 SettingsDialog initialize! |