926 ]. |
1011 ]. |
927 self updateListOfStartupClassesInProject |
1012 self updateListOfStartupClassesInProject |
928 ]. |
1013 ]. |
929 ! |
1014 ! |
930 |
1015 |
931 classVariableNames:'' |
1016 doAddClassToProject |
932 poolDictionaries:'' |
1017 <resource: #uiCallback> |
933 category:'Applications'. |
|
934 CodeGeneratorTool createStartupCodeFor:newStartupClass forStartOf:selectedApplication. |
|
935 ]. |
|
936 self updateListOfStartupClassesInProject |
|
937 ]. |
|
938 ! |
|
939 |
|
940 #uiCallback> |
|
941 |
1018 |
942 Transcript showCR:self class name, ': action for doAddClassToProject ...'. |
1019 Transcript showCR:self class name, ': action for doAddClassToProject ...'. |
943 self halt. |
1020 self halt. |
944 ! |
1021 ! |
945 |
1022 |
946 <resource: #uiCallback> |
1023 doBrowseApplication |
|
1024 <resource: #uiCallback> |
947 |
1025 |
948 |appClass| |
1026 |appClass| |
949 |
1027 |
950 self hasApplicationSelected ifTrue:[ |
1028 self hasApplicationSelected ifTrue:[ |
951 appClass := self listOfApplicationsInProject value at:(self selectedApplicationIndexHolder value). |
1029 appClass := self listOfApplicationsInProject value at:(self selectedApplicationIndexHolder value). |
952 UserPreferences systemBrowserClass |
1030 UserPreferences systemBrowserClass |
953 openInClass:appClass class selector:#windowSpec. |
1031 openInClass:appClass class selector:#windowSpec. |
954 ]. |
1032 ]. |
955 ! |
1033 ! |
956 |
1034 |
957 ]. |
1035 doBrowseProject |
958 ! |
1036 <resource: #uiCallback> |
959 |
1037 |
960 emBrowserClass |
1038 UserPreferences systemBrowserClass openOnPackage:selectedProjectDefinition package. |
|
1039 ! |
|
1040 |
|
1041 doBrowseProjectDefinitionClass |
|
1042 <resource: #uiCallback> |
|
1043 |
|
1044 |defClass| |
|
1045 |
|
1046 self hasProjectSelected ifTrue:[ |
|
1047 defClass := self selectedProjectDefinition. |
|
1048 UserPreferences systemBrowserClass |
961 openInClass:defClass class selector:#classNamesAndAttributes. |
1049 openInClass:defClass class selector:#classNamesAndAttributes. |
962 ]. |
1050 ]. |
963 ! |
1051 ! |
964 |
1052 |
965 ibutes. |
1053 doBrowseStartupClass |
966 ]. |
1054 <resource: #uiCallback> |
967 ! |
1055 |
968 |
1056 |startupClass| |
969 UserPreferences systemBrowserClass |
1057 |
|
1058 self hasStartupClassSelected ifTrue:[ |
|
1059 startupClass := self listOfStartupClassesInProject value at:(self selectedStartupClassIndexHolder value). |
|
1060 UserPreferences systemBrowserClass |
970 openInClass:startupClass class selector:#main:. |
1061 openInClass:startupClass class selector:#main:. |
971 ]. |
1062 ]. |
|
1063 ! |
|
1064 |
|
1065 doGenerateProjectContentsDefinition |
|
1066 self generatePackageContentsMethods |
|
1067 ! |
|
1068 |
|
1069 doLaunchApplication |
|
1070 <resource: #uiCallback> |
|
1071 |
|
1072 |appClass| |
|
1073 |
|
1074 self hasApplicationSelected ifTrue:[ |
|
1075 appClass := self listOfApplicationsInProject value at:(self selectedApplicationIndexHolder value). |
|
1076 appClass open. |
|
1077 ]. |
|
1078 ! |
|
1079 |
|
1080 doOpenExplorer |
|
1081 OperatingSystem |
|
1082 openApplicationForDocument:(projectBuilder packageBuildDirectory) operation:#explore. |
972 ! |
1083 ! |
973 |
1084 |
974 doStartMakeAll |
1085 doStartMakeAll |
975 <resource: #uiCallback> |
1086 <resource: #uiCallback> |
976 |
1087 |
1073 projectBuilder buildWithColorizedOutputTo:makeOutputWindow. |
1187 projectBuilder buildWithColorizedOutputTo:makeOutputWindow. |
1074 ]. |
1188 ]. |
1075 ]. |
1189 ]. |
1076 ! |
1190 ! |
1077 |
1191 |
1078 (p := makeProcess) notNil ifTrue:[ |
1192 selectedApplicationChanged |
1079 makeProcess := nil. |
1193 |idx| |
1080 p terminate. |
1194 |
1081 p waitUntilTerminated. |
1195 ((idx := self selectedApplicationIndexHolder value) isNil |
1082 |
1196 or:[idx == 0]) ifTrue:[ |
1083 makeOutputWindow endEntry. |
1197 selectedApplication := nil. |
1084 makeOutputWindow cr. |
1198 ] ifFalse:[ |
1085 makeOutputWindow nextPutLine:('Make Cancelled' colorizeAllWith:Color white on:Color red). |
1199 selectedApplication := self listOfApplicationsInProject value at:idx. |
1086 makeOutputWindow endEntry. |
1200 ]. |
1087 ]. |
1201 self hasApplicationSelectedHolder value:(selectedApplication notNil). |
1088 ! |
1202 |
1089 |
1203 "/ selectedApplication notNil ifTrue:[ |
1090 akeOutputWindow nextPutLine:(ex messageText colorizeAllWith:Color white on:Color blue). |
1204 "/ "/ generate startupClass code |
1091 makeOutputWindow endEntry. |
1205 "/ CodeGeneratorTool |
1092 ]. |
|
1093 ex proceed. |
|
1094 ] do:[ |
|
1095 projectBuilder := ProjectBuilder new. |
|
1096 projectBuilder package:(selectedProjectDefinition package). |
|
1097 what = 'exe' ifTrue:[ |
|
1098 projectBuilder makeExeOnly:true |
|
1099 ] ifFalse:[ |
|
1100 projectBuilder makeExeOnly:false |
|
1101 ]. |
|
1102 |
|
1103 Error handle:[:ex | |
|
1104 makeOutputWindow endEntry. |
|
1105 makeOutputWindow cr. |
|
1106 makeOutputWindow nextPutLine:(ex messageText colorizeAllWith:Color white on:Color red). |
|
1107 makeOutputWindow endEntry. |
|
1108 ] do:[ |
|
1109 projectBuilder buildWithColorizedOutputTo:makeOutputWindow. |
|
1110 ]. |
|
1111 ]. |
|
1112 ! |
|
1113 |
|
1114 Error handle:[:ex | |
|
1115 makeOutputWindow endEntry. |
|
1116 makeOutputWindow cr. |
|
1117 makeOutputWindow nextPutLine:(ex messageText colorizeAllWith:Color white on:Color red). |
|
1118 makeOutputWindow endEntry. |
|
1119 ] do:[ |
|
1120 projectBuilder buildWithColorizedOutputTo:makeOutputWindow. |
|
1121 ]. |
|
1122 ]. |
|
1123 ! ! |
|
1124 |
|
1125 !ProjectBuilderAssistantApplication methodsFor:'aspects'! |
|
1126 |
|
1127 CodeGeneratorTool |
|
1128 "/ compile:(selectedProjectDefinition startupClassName_codeFor:(selectedApplication name)) |
1206 "/ compile:(selectedProjectDefinition startupClassName_codeFor:(selectedApplication name)) |
1129 "/ forClass:selectedProjectDefinition theMetaclass |
1207 "/ forClass:selectedProjectDefinition theMetaclass |
1130 "/ inCategory:'description - startup'. |
1208 "/ inCategory:'description - startup'. |
1131 "/ ]. |
1209 "/ ]. |
1132 self updateApplicationComment. |
1210 self updateApplicationComment. |
1133 self updateButtonEnableState. |
1211 self updateButtonEnableState. |
1134 ! |
1212 ! |
1135 |
1213 |
1136 onsInProject. |
1214 selectedProjectChanged |
|
1215 self selectedProjectIndexHolder value isNil ifTrue:[ |
|
1216 selectedProjectDefinition := nil. |
|
1217 ] ifFalse:[ |
|
1218 selectedProjectDefinition := self listOfMatchingProjects value at:(self selectedProjectIndexHolder value). |
|
1219 ]. |
|
1220 self hasProjectSelectedHolder value:(selectedProjectDefinition notNil). |
|
1221 |
|
1222 self updateComment. |
|
1223 self updateListOfApplicationsInProject. |
1137 self updateButtonEnableState. |
1224 self updateButtonEnableState. |
1138 ! |
1225 ! |
1139 |
1226 |
1140 StartupClassesInProject value at:(self selectedStartupClassIndexHolder value). |
1227 selectedStartupClassChanged |
|
1228 self selectedStartupClassIndexHolder value isNil ifTrue:[ |
|
1229 selectedStartupClass := nil. |
|
1230 ] ifFalse:[ |
|
1231 selectedStartupClass := self listOfStartupClassesInProject value at:(self selectedStartupClassIndexHolder value). |
1141 ]. |
1232 ]. |
1142 self hasStartupClassSelectedHolder value:(selectedStartupClass notNil). |
1233 self hasStartupClassSelectedHolder value:(selectedStartupClass notNil). |
1143 |
1234 |
1144 selectedStartupClass notNil ifTrue:[ |
1235 selectedStartupClass notNil ifTrue:[ |
1145 "/ generate startupClass code |
1236 "/ generate startupClass code |
1185 buildDirectoryHolder value: buildDirectory. |
1264 buildDirectoryHolder value: buildDirectory. |
1186 ]. |
1265 ]. |
1187 ^ buildDirectoryHolder. |
1266 ^ buildDirectoryHolder. |
1188 ! |
1267 ! |
1189 |
1268 |
1190 s::ProjectBuilder previousBuildDirectory. |
1269 fileBrowserInstance |
1191 buildDirectory isNil ifTrue:[ |
1270 |targetDirectory browser| |
1192 buildDirectory := UserPreferences current buildDirectory. |
1271 |
1193 buildDirectory isNil ifTrue:[ |
1272 targetDirectory := projectBuilder packageBuildDirectory. |
1194 buildDirectory := Filename tempDirectory construct:'stx_build'. |
1273 |
1195 ]. |
1274 browser := FileBrowserV2 new. |
1196 ]. |
|
1197 buildDirectoryHolder value: buildDirectory. |
|
1198 ]. |
|
1199 ^ buildDirectoryHolder. |
|
1200 ! |
|
1201 |
|
1202 ]. |
|
1203 ]. |
|
1204 buildDirectoryHolder value: buildDirectory. |
|
1205 ]. |
|
1206 ^ buildDirectoryHolder. |
|
1207 ! |
|
1208 |
|
1209 rowser := FileBrowserV2 new. |
|
1210 browser onDirectory:targetDirectory. |
1275 browser onDirectory:targetDirectory. |
1211 browser filter:'*.exe'. |
1276 browser filter:'*.exe'. |
1212 ^ browser. |
1277 ^ browser. |
1213 ! |
1278 ! |
1214 |
1279 |
1215 r isNil ifTrue:[ |
1280 hasApplicationSelectedHolder |
|
1281 <resource: #uiAspect> |
|
1282 |
|
1283 hasApplicationSelectedHolder isNil ifTrue:[ |
1216 hasApplicationSelectedHolder := nil asValue. |
1284 hasApplicationSelectedHolder := nil asValue. |
1217 ]. |
1285 ]. |
1218 ^ hasApplicationSelectedHolder. |
1286 ^ hasApplicationSelectedHolder. |
1219 ! |
1287 ! |
1220 |
1288 |
1221 electedHolder isNil ifTrue:[ |
1289 hasProjectSelectedHolder |
|
1290 <resource: #uiAspect> |
|
1291 |
|
1292 hasProjectSelectedHolder isNil ifTrue:[ |
1222 hasProjectSelectedHolder := nil asValue. |
1293 hasProjectSelectedHolder := nil asValue. |
1223 ]. |
1294 ]. |
1224 ^ hasProjectSelectedHolder. |
1295 ^ hasProjectSelectedHolder. |
1225 ! |
1296 ! |
1226 |
1297 |
1227 sStartupClassSelectedHolder isNil ifTrue:[ |
1298 hasStartupClassSelectedHolder |
|
1299 <resource: #uiAspect> |
|
1300 |
|
1301 hasStartupClassSelectedHolder isNil ifTrue:[ |
1228 hasStartupClassSelectedHolder := nil asValue. |
1302 hasStartupClassSelectedHolder := nil asValue. |
1229 ]. |
1303 ]. |
1230 ^ hasStartupClassSelectedHolder. |
1304 ^ hasStartupClassSelectedHolder. |
1231 ! |
1305 ! |
1232 |
1306 |
1233 rApplicationClasses isNil ifTrue:[ |
1307 hideOtherApplicationClasses |
|
1308 <resource: #uiAspect> |
|
1309 |
|
1310 hideOtherApplicationClasses isNil ifTrue:[ |
1234 hideOtherApplicationClasses := true asValue. |
1311 hideOtherApplicationClasses := true asValue. |
1235 hideOtherApplicationClasses onChangeSend:#updateListOfApplicationsInProject to:self. |
1312 hideOtherApplicationClasses onChangeSend:#updateListOfApplicationsInProject to:self. |
1236 ]. |
1313 ]. |
1237 ^ hideOtherApplicationClasses. |
1314 ^ hideOtherApplicationClasses. |
1238 ! |
1315 ! |
1239 |
1316 |
1240 oject to:self. |
1317 hideOtherStartupClasses |
1241 ]. |
1318 <resource: #uiAspect> |
1242 ^ hideOtherApplicationClasses. |
1319 |
1243 ! |
1320 hideOtherStartupClasses isNil ifTrue:[ |
1244 |
1321 hideOtherStartupClasses := true asValue. |
1245 :[ |
1322 hideOtherStartupClasses onChangeSend:#updateListOfStartupClassesInProject to:self. |
|
1323 ]. |
|
1324 ^ hideOtherStartupClasses. |
|
1325 ! |
|
1326 |
|
1327 hideSTXProjects |
|
1328 <resource: #uiAspect> |
|
1329 |
|
1330 hideSTXProjects isNil ifTrue:[ |
|
1331 hideSTXProjects := true asValue. |
|
1332 hideSTXProjects onChangeSend:#updateListOfMatchingProjects to:self. |
|
1333 ]. |
|
1334 ^ hideSTXProjects. |
|
1335 ! |
|
1336 |
|
1337 listOfApplicationsInProject |
|
1338 <resource: #uiAspect> |
|
1339 |
|
1340 listOfApplicationsInProject isNil ifTrue:[ |
1246 listOfApplicationsInProject := ValueHolder new. |
1341 listOfApplicationsInProject := ValueHolder new. |
1247 ]. |
1342 ]. |
1248 ^ listOfApplicationsInProject. |
1343 ^ listOfApplicationsInProject. |
1249 ! |
1344 ! |
1250 |
1345 |
1251 listOfClassesInProject isNil ifTrue:[ |
1346 listOfClassesInProject |
|
1347 <resource: #uiAspect> |
|
1348 |
|
1349 listOfClassesInProject isNil ifTrue:[ |
1252 listOfClassesInProject := ValueHolder new. |
1350 listOfClassesInProject := ValueHolder new. |
1253 ]. |
1351 ]. |
1254 ^ listOfClassesInProject. |
1352 ^ listOfClassesInProject. |
1255 ! |
1353 ! |
1256 |
1354 |
1257 #uiAspect> |
1355 listOfMatchingProjects |
|
1356 <resource: #uiAspect> |
1258 |
1357 |
1259 listOfMatchingProjects isNil ifTrue:[ |
1358 listOfMatchingProjects isNil ifTrue:[ |
1260 listOfMatchingProjects := ValueHolder new. |
1359 listOfMatchingProjects := ValueHolder new. |
1261 ]. |
1360 ]. |
1262 ^ listOfMatchingProjects. |
1361 ^ listOfMatchingProjects. |
1263 ! |
1362 ! |
1264 |
1363 |
1265 <resource: #uiAspect> |
1364 listOfStartupClassesInProject |
|
1365 <resource: #uiAspect> |
|
1366 |
|
1367 listOfStartupClassesInProject isNil ifTrue:[ |
|
1368 listOfStartupClassesInProject := ValueHolder new. |
|
1369 ]. |
|
1370 ^ listOfStartupClassesInProject. |
|
1371 ! |
|
1372 |
|
1373 makeOutputHolder |
|
1374 <resource: #uiAspect> |
1266 |
1375 |
1267 makeOutputHolder isNil ifTrue:[ |
1376 makeOutputHolder isNil ifTrue:[ |
1268 makeOutputHolder := ValueHolder new. |
1377 makeOutputHolder := ValueHolder new. |
1269 ]. |
1378 ]. |
1270 ^ makeOutputHolder. |
1379 ^ makeOutputHolder. |
1271 ! |
1380 ! |
1272 |
1381 |
1273 below: |
1382 newApplicationsName |
|
1383 <resource: #uiAspect> |
|
1384 |
|
1385 "automatically generated by UIPainter ..." |
|
1386 |
|
1387 "*** the code below creates a default model when invoked." |
|
1388 "*** (which may not be the one you wanted)" |
|
1389 "*** Please change as required and accept it in the browser." |
|
1390 "*** (and replace this comment by something more useful ;-)" |
|
1391 |
|
1392 newApplicationsName isNil ifTrue:[ |
|
1393 newApplicationsName := ValueHolder new. |
|
1394 "/ if your app needs to be notified of changes, uncomment one of the lines below: |
1274 "/ newApplicationsName addDependent:self. |
1395 "/ newApplicationsName addDependent:self. |
1275 "/ newApplicationsName onChangeSend:#newApplicationsNameChanged to:self. |
1396 "/ newApplicationsName onChangeSend:#newApplicationsNameChanged to:self. |
1276 ]. |
1397 ]. |
1277 ^ newApplicationsName. |
1398 ^ newApplicationsName. |
1278 ! |
1399 ! |
1279 |
1400 |
1280 wProjectsName isNil ifTrue:[ |
1401 newProjectsName |
|
1402 <resource: #uiAspect> |
|
1403 |
|
1404 newProjectsName isNil ifTrue:[ |
1281 newProjectsName := nil asValue. |
1405 newProjectsName := nil asValue. |
1282 ]. |
1406 ]. |
1283 ^ newProjectsName. |
1407 ^ newProjectsName. |
1284 ! |
1408 ! |
1285 |
1409 |
1286 ^ newProjectsName. |
1410 newStartupClassName |
1287 ! |
1411 <resource: #uiAspect> |
1288 |
1412 |
1289 ype |
1413 newStartupClassName isNil ifTrue:[ |
|
1414 newStartupClassName := ValueHolder new. |
|
1415 ]. |
|
1416 ^ newStartupClassName. |
|
1417 ! |
|
1418 |
|
1419 projectType |
|
1420 self projectTypeHolder value == #libraryType ifTrue:[ |
|
1421 ^ ProjectDefinition libraryType |
1290 ]. |
1422 ]. |
1291 self projectTypeHolder value == #guiApplicationType ifTrue:[ |
1423 self projectTypeHolder value == #guiApplicationType ifTrue:[ |
1292 ^ ProjectDefinition guiApplicationType |
1424 ^ ProjectDefinition guiApplicationType |
1293 ]. |
1425 ]. |
1294 self projectTypeHolder value == #nonGuiApplicationType ifTrue:[ |
1426 self projectTypeHolder value == #nonGuiApplicationType ifTrue:[ |
1295 ^ ProjectDefinition nonGuiApplicationType |
1427 ^ ProjectDefinition nonGuiApplicationType |
1296 ]. |
1428 ]. |
1297 self error. |
1429 self error. |
1298 ! |
1430 ! |
1299 |
1431 |
1300 True:[ |
1432 projectType:aProjectTypeSymbol |
|
1433 |pType| |
|
1434 |
|
1435 self assert:(ProjectDefinition projectTypes includes:aProjectTypeSymbol). |
|
1436 aProjectTypeSymbol == ProjectDefinition libraryType ifTrue:[ |
|
1437 pType := #libraryType |
|
1438 ] ifFalse:[ |
|
1439 aProjectTypeSymbol == ProjectDefinition guiApplicationType ifTrue:[ |
|
1440 pType := #guiApplicationType |
|
1441 ] ifFalse:[ |
|
1442 aProjectTypeSymbol == ProjectDefinition nonGuiApplicationType ifTrue:[ |
1301 pType := #nonGuiApplicationType |
1443 pType := #nonGuiApplicationType |
1302 ] ifFalse:[ |
1444 ] ifFalse:[ |
1303 self error. |
1445 self error. |
1304 ]. |
1446 ]. |
1305 ] |
1447 ] |
1306 ]. |
1448 ]. |
1307 self projectTypeHolder value:aProjectTypeSymbol |
1449 self projectTypeHolder value:aProjectTypeSymbol |
1308 ! |
1450 ! |
1309 |
1451 |
1310 self error. |
1452 projectTypeHolder |
1311 ]. |
1453 <resource: #uiAspect> |
1312 ] |
1454 |
1313 ]. |
1455 projectTypeHolder isNil ifTrue:[ |
1314 self projectTypeHolder value:aProjectTypeSymbol |
1456 projectTypeHolder := RadioButtonGroup new. |
1315 ! |
1457 projectTypeHolder value:#guiApplicationType. |
1316 |
|
1317 tionType. |
|
1318 ]. |
1458 ]. |
1319 ^ projectTypeHolder. |
1459 ^ projectTypeHolder. |
1320 ! |
1460 ! |
1321 |
1461 |
1322 selectedApplicationIndexHolder isNil ifTrue:[ |
1462 projectTypeIsNotLibrary |
|
1463 ^ self projectTypeHolder value ~~ #libraryType |
|
1464 ! |
|
1465 |
|
1466 selectedApplicationIndexHolder |
|
1467 <resource: #uiAspect> |
|
1468 |
|
1469 selectedApplicationIndexHolder isNil ifTrue:[ |
1323 selectedApplicationIndexHolder := ValueHolder new. |
1470 selectedApplicationIndexHolder := ValueHolder new. |
1324 selectedApplicationIndexHolder onChangeSend:#selectedApplicationChanged to:self. |
1471 selectedApplicationIndexHolder onChangeSend:#selectedApplicationChanged to:self. |
1325 ]. |
1472 ]. |
1326 ^ selectedApplicationIndexHolder. |
1473 ^ selectedApplicationIndexHolder. |
1327 ! |
1474 ! |
1328 |
1475 |
1329 tomatically generated by UIPainter ..." |
1476 selectedApplicationsComment |
|
1477 <resource: #uiAspect> |
|
1478 |
|
1479 "automatically generated by UIPainter ..." |
1330 |
1480 |
1331 "*** the code below creates a default model when invoked." |
1481 "*** the code below creates a default model when invoked." |
1332 "*** (which may not be the one you wanted)" |
1482 "*** (which may not be the one you wanted)" |
1333 "*** Please change as required and accept it in the browser." |
1483 "*** Please change as required and accept it in the browser." |
1334 "*** (and replace this comment by something more useful ;-)" |
1484 "*** (and replace this comment by something more useful ;-)" |
1340 "/ selectedApplicationsComment onChangeSend:#selectedApplicationsCommentChanged to:self. |
1490 "/ selectedApplicationsComment onChangeSend:#selectedApplicationsCommentChanged to:self. |
1341 ]. |
1491 ]. |
1342 ^ selectedApplicationsComment. |
1492 ^ selectedApplicationsComment. |
1343 ! |
1493 ! |
1344 |
1494 |
1345 d and accept it in the browser." |
1495 selectedProjectDefinition |
1346 "*** (and replace this comment by something more useful ;-)" |
1496 <resource: #uiAspect> |
1347 |
1497 |
1348 selectedApplicationsComment isNil ifTrue:[ |
1498 ^ selectedProjectDefinition. |
1349 selectedApplicationsComment := '' asValue. |
1499 ! |
1350 "/ if your app needs to be notified of changes, uncomment one of the lines below: |
1500 |
1351 "/ selectedApplicationsComment addDependent:self. |
1501 selectedProjectIndexHolder |
1352 "/ selectedApplicationsComment onChangeSend:#selectedApplicationsCommentChanged to:self. |
1502 <resource: #uiAspect> |
1353 ]. |
|
1354 ^ selectedApplicationsComment. |
|
1355 ! ! |
|
1356 |
|
1357 !ProjectBuilderAssistantApplication methodsFor:'initialization & release'! |
|
1358 |
|
1359 the lines below: |
|
1360 "/ selectedApplicationsComment addDependent:self. |
|
1361 "/ selectedApplicationsComment onChangeSend:#selectedApplicationsCommentChanged to:self. |
|
1362 ]. |
|
1363 ^ selectedApplicationsComment. |
|
1364 ! |
|
1365 |
|
1366 self. |
|
1367 "/ selectedApplicationsComment onChangeSend:#selectedApplicationsCommentChanged to:self. |
|
1368 ]. |
|
1369 ^ selectedApplicationsComment. |
|
1370 ! |
|
1371 |
|
1372 ment. |
|
1373 ! ! |
|
1374 |
|
1375 !ProjectBuilderAssistantApplication methodsFor:'menu actions'! |
|
1376 |
|
1377 <resource: #uiAspect> |
|
1378 |
1503 |
1379 selectedProjectIndexHolder isNil ifTrue:[ |
1504 selectedProjectIndexHolder isNil ifTrue:[ |
1380 selectedProjectIndexHolder := ValueHolder new. |
1505 selectedProjectIndexHolder := ValueHolder new. |
1381 selectedProjectIndexHolder onChangeSend:#selectedProjectChanged to:self. |
1506 selectedProjectIndexHolder onChangeSend:#selectedProjectChanged to:self. |
1382 ]. |
1507 ]. |
1383 ^ selectedProjectIndexHolder. |
1508 ^ selectedProjectIndexHolder. |
|
1509 ! |
|
1510 |
|
1511 selectedProjectsComment |
|
1512 <resource: #uiAspect> |
|
1513 |
|
1514 selectedProjectsComment isNil ifTrue:[ |
|
1515 selectedProjectsComment := '' asValue. |
|
1516 ]. |
|
1517 ^ selectedProjectsComment. |
|
1518 ! |
|
1519 |
|
1520 selectedStartupClassIndexHolder |
|
1521 <resource: #uiAspect> |
|
1522 |
|
1523 selectedStartupClassIndexHolder isNil ifTrue:[ |
|
1524 selectedStartupClassIndexHolder := ValueHolder new. |
|
1525 selectedStartupClassIndexHolder onChangeSend:#selectedStartupClassChanged to:self. |
|
1526 ]. |
|
1527 ^ selectedStartupClassIndexHolder. |
|
1528 ! |
|
1529 |
|
1530 startMakeButtonEnabled |
|
1531 <resource: #uiAspect> |
|
1532 |
|
1533 startMakeButtonEnabled isNil ifTrue:[ |
|
1534 startMakeButtonEnabled := true asValue. |
|
1535 ]. |
|
1536 ^ startMakeButtonEnabled. |
|
1537 ! |
|
1538 |
|
1539 stopMakeButtonVisible |
|
1540 <resource: #uiAspect> |
|
1541 |
|
1542 stopMakeButtonVisible isNil ifTrue:[ |
|
1543 stopMakeButtonVisible := false asValue. |
|
1544 ]. |
|
1545 ^ stopMakeButtonVisible. |
1384 ! ! |
1546 ! ! |
1385 |
1547 |
|
1548 !ProjectBuilderAssistantApplication methodsFor:'initialization & release'! |
|
1549 |
|
1550 postBuildMakeOutputWindow:aView |
|
1551 makeOutputWindow := aView |
|
1552 ! |
|
1553 |
|
1554 postBuildWith:aBuilder |
|
1555 super postBuildWith:aBuilder. |
|
1556 self updateListOfMatchingProjects. |
|
1557 |
|
1558 Smalltalk addDependent:self. |
|
1559 ! |
|
1560 |
|
1561 release |
|
1562 Smalltalk removeDependent:self. |
|
1563 super release |
|
1564 ! ! |
|
1565 |
|
1566 !ProjectBuilderAssistantApplication methodsFor:'menu actions'! |
|
1567 |
|
1568 openDocumentation |
|
1569 self openHTMLDocument:'tools/misc/TOP.html#PACKAGER'. |
|
1570 ! ! |
|
1571 |
1386 !ProjectBuilderAssistantApplication methodsFor:'private'! |
1572 !ProjectBuilderAssistantApplication methodsFor:'private'! |
1387 |
1573 |
1388 ProjectIndexHolder onChangeSend:#selectedProjectChanged to:self. |
1574 commentFromClass:aClass |
1389 ]. |
1575 |docMethod comment indents minIndent maxLineLength| |
1390 ^ selectedProjectIndexHolder. |
|
1391 ! |
|
1392 |
|
1393 akeButtonVisible. |
|
1394 ! |
|
1395 |
|
1396 ntApplication methodsFor:'private' |
|
1397 ! |
|
1398 |
|
1399 t indents minIndent maxLineLength| |
|
1400 |
1576 |
1401 docMethod := aClass class compiledMethodAt:#documentation. |
1577 docMethod := aClass class compiledMethodAt:#documentation. |
1402 docMethod notNil ifTrue:[ |
1578 docMethod notNil ifTrue:[ |
1403 comment := docMethod comment. |
1579 comment := docMethod comment. |
1404 comment := comment asStringCollection |
1580 comment := comment asStringCollection |
1415 comment := comment asString. |
1591 comment := comment asString. |
1416 ]. |
1592 ]. |
1417 ^ comment |
1593 ^ comment |
1418 ! |
1594 ! |
1419 |
1595 |
1420 documentation. |
1596 generatePackageContentsMethods |
1421 docMethod notNil ifTrue:[ |
1597 <resource: #uiCallback> |
1422 comment := docMethod comment. |
1598 |
1423 comment := comment asStringCollection |
1599 Class packageQuerySignal answer:(selectedProjectDefinition package) |
1424 collect:[:line | line withoutTrailingSeparators]. |
1600 do:[ |
1425 [comment notEmpty and:[comment first isBlank]] whileTrue:[ comment removeFirst ]. |
1601 selectedProjectDefinition |
1426 maxLineLength := (comment collect:[:line | line size]) max. |
1602 forEachContentsMethodsCodeToCompileDo:[:code :category | |
1427 indents := comment collect:[:line | |
1603 CodeGeneratorTool |
1428 line isEmptyOrNil |
1604 compile:code |
1429 ifTrue:[maxLineLength] |
1605 forClass:selectedProjectDefinition theMetaclass |
1430 ifFalse:[ line findFirst:[:ch | ch isSeparator not]]]. |
1606 inCategory:category. |
1431 (minIndent := indents min) > 1 ifTrue:[ |
1607 ] |
1432 comment := comment collect:[:line | line copyFrom:minIndent]. |
1608 ignoreOldDefinition:true |
1433 ]. |
1609 ]. |
1434 comment := comment asString. |
1610 self updateListOfClassesInProject |
1435 ]. |
1611 ! |
1436 ^ comment |
1612 |
1437 ! |
1613 hasApplicationSelected |
1438 |
1614 ^ self selectedApplicationIndexHolder value notNil |
1439 comment := docMethod comment. |
1615 ! |
1440 comment := comment asStringCollection |
1616 |
1441 collect:[:line | line withoutTrailingSeparators]. |
1617 hasBuildDirectorySpecified |
1442 [comment notEmpty and:[comment first isBlank]] whileTrue:[ comment removeFirst ]. |
1618 ^ self buildDirectoryHolder value notEmptyOrNil |
1443 maxLineLength := (comment collect:[:line | line size]) max. |
1619 ! |
1444 indents := comment collect:[:line | |
1620 |
1445 line isEmptyOrNil |
1621 hasProjectBuilder |
1446 ifTrue:[maxLineLength] |
1622 ^ projectBuilder notNil |
1447 ifFalse:[ line findFirst:[:ch | ch isSeparator not]]]. |
1623 ! |
1448 (minIndent := indents min) > 1 ifTrue:[ |
1624 |
1449 comment := comment collect:[:line | line copyFrom:minIndent]. |
1625 hasProjectSelected |
1450 ]. |
1626 ^ self selectedProjectIndexHolder value notNil |
1451 comment := comment asString. |
1627 ! |
1452 ]. |
1628 |
1453 ^ comment |
1629 hasStartupClassSelected |
1454 ! |
1630 ^ self selectedStartupClassIndexHolder value notNil |
1455 |
|
1456 n |
|
1457 collect:[:line | line withoutTrailingSeparators]. |
|
1458 [comment notEmpty and:[comment first isBlank]] whileTrue:[ comment removeFirst ]. |
|
1459 maxLineLength := (comment collect:[:line | line size]) max. |
|
1460 indents := comment collect:[:line | |
|
1461 line isEmptyOrNil |
|
1462 ifTrue:[maxLineLength] |
|
1463 ifFalse:[ line findFirst:[:ch | ch isSeparator not]]]. |
|
1464 (minIndent := indents min) > 1 ifTrue:[ |
|
1465 comment := comment collect:[:line | line copyFrom:minIndent]. |
|
1466 ]. |
|
1467 comment := comment asString. |
|
1468 ]. |
|
1469 ^ comment |
|
1470 ! ! |
1631 ! ! |
1471 |
1632 |
1472 !ProjectBuilderAssistantApplication methodsFor:'queries'! |
1633 !ProjectBuilderAssistantApplication methodsFor:'queries'! |
1473 |
1634 |
1474 ent removeFirst ]. |
1635 canEnterApplicationSelection |
1475 maxLineLength := (comment collect:[:line | line size]) max. |
1636 ^ self hasProjectSelected |
1476 indents := comment collect:[:line | |
1637 ! |
1477 line isEmptyOrNil |
1638 |
1478 ifTrue:[maxLineLength] |
1639 canEnterBuild |
1479 ifFalse:[ line findFirst:[:ch | ch isSeparator not]]]. |
1640 ^ self hasBuildDirectorySpecified |
1480 (minIndent := indents min) > 1 ifTrue:[ |
|
1481 comment := comment collect:[:line | line copyFrom:minIndent]. |
|
1482 ]. |
|
1483 comment := comment asString. |
|
1484 ]. |
|
1485 ^ comment |
|
1486 ! |
|
1487 |
|
1488 ne | line size]) max. |
|
1489 indents := comment collect:[:line | |
|
1490 line isEmptyOrNil |
|
1491 ifTrue:[maxLineLength] |
|
1492 ifFalse:[ line findFirst:[:ch | ch isSeparator not]]]. |
|
1493 (minIndent := indents min) > 1 ifTrue:[ |
|
1494 comment := comment collect:[:line | line copyFrom:minIndent]. |
|
1495 ]. |
|
1496 comment := comment asString. |
|
1497 ]. |
|
1498 ^ comment |
|
1499 ! |
1641 ! |
1500 |
1642 |
1501 canEnterContentsSelection |
1643 canEnterContentsSelection |
1502 ^ self hasProjectSelected |
1644 ^ self hasProjectSelected |
1503 and:[ true "self hasApplicationSelected" |
1645 and:[ true "self hasApplicationSelected" |
1504 and:[ self hasStartupClassSelected ]] |
1646 and:[ self hasStartupClassSelected ]] |
1505 ! |
1647 ! |
1506 |
1648 |
1507 ifFalse:[ line findFirst:[:ch | ch isSeparator not]]]. |
1649 canEnterDeploy |
1508 (minIndent := indents min) > 1 ifTrue:[ |
1650 ^ self hasProjectBuilder |
1509 comment := comment collect:[:line | line copyFrom:minIndent]. |
1651 ! |
1510 ]. |
1652 |
1511 comment := comment asString. |
1653 canEnterStartupClassSelection |
1512 ]. |
1654 ^ self hasProjectSelected "and:[ self hasApplicationSelected ]" |
1513 ^ comment |
|
1514 ! |
|
1515 |
|
1516 ndFirst:[:ch | ch isSeparator not]]]. |
|
1517 (minIndent := indents min) > 1 ifTrue:[ |
|
1518 comment := comment collect:[:line | line copyFrom:minIndent]. |
|
1519 ]. |
|
1520 comment := comment asString. |
|
1521 ]. |
|
1522 ^ comment |
|
1523 ! ! |
1655 ! ! |
1524 |
1656 |
1525 !ProjectBuilderAssistantApplication methodsFor:'specs'! |
1657 !ProjectBuilderAssistantApplication methodsFor:'specs'! |
1526 |
1658 |
1527 ]. |
1659 assistantSpec |
1528 comment := comment asString. |
1660 ^ #(Array |
1529 ]. |
1661 ( AssistantPageSpec |
1530 ^ comment |
1662 pageTitle: 'Project Type Selection' |
1531 ! ! |
1663 windowSpecSelector: page1_projectTypeSelectionSpec |
1532 |
1664 enterCallbackSelector: updateListOfMatchingProjects |
1533 !ProjectBuilderAssistantApplication methodsFor:'update'! |
1665 infoText: 'Choose the type of project you are about to build.' |
1534 |
1666 ) |
1535 ecifyBuildDirectorySpec |
1667 |
|
1668 (AssistantPageSpec |
|
1669 pageTitle: 'Project Selection' |
|
1670 windowSpecSelector: page2_projectSelectionSpec |
|
1671 enterCallbackSelector: updateListOfMatchingProjects |
|
1672 infoText: 'Choose an existing project or create a new one. |
|
1673 These are subclasses of <I>ProjectDefinition</I> and define the |
|
1674 type and contents of a project.' |
|
1675 ) |
|
1676 |
|
1677 (AssistantPageSpec |
|
1678 pageTitle: 'Application Selection' |
|
1679 windowSpecSelector: page3_applicationSelectionSpec |
|
1680 isEnabledQuerySelector: #projectTypeIsNotLibrary |
|
1681 canEnterQuerySelector: #canEnterApplicationSelection |
|
1682 enterCallbackSelector: updateListOfApplicationsInProject |
|
1683 infoText: 'Choose an existing application or create a new one. |
|
1684 These are subclasses of <I>ApplicationModel</I> and define |
|
1685 the GUI and control flow inside the application. |
|
1686 Can also be left blank if the startup class does it all (stx build).' |
|
1687 ) |
|
1688 |
|
1689 (AssistantPageSpec |
|
1690 pageTitle: 'Startup Class Selection' |
|
1691 windowSpecSelector: page4_startupClassSelectionSpec |
|
1692 isEnabledQuerySelector: #projectTypeIsNotLibrary |
|
1693 canEnterQuerySelector: #canEnterStartupClassSelection |
|
1694 enterCallbackSelector: updateListOfStartupClassesInProject |
|
1695 infoText: 'Choose an existing startup-class or create a new one. |
|
1696 These are subclasses of <I>StandaloneStartup</I> and |
|
1697 start the application. Command line arguments can be |
|
1698 interpreted there.' |
|
1699 ) |
|
1700 |
|
1701 (AssistantPageSpec |
|
1702 pageTitle: 'Specify Contents' |
|
1703 windowSpecSelector: page5_specifyIncludedClasses |
|
1704 enterCallbackSelector: updateListOfClassesInProject |
|
1705 canEnterQuerySelector: #canEnterContentsSelection |
|
1706 infoText: 'Define which (other) classes are to be included. |
|
1707 Press "<I>Scan</I>" to include all classes of the package; |
|
1708 browse to edit the contents manually.' |
|
1709 ) |
|
1710 |
|
1711 (AssistantPageSpec |
|
1712 pageTitle: 'Specify Build Directory' |
|
1713 windowSpecSelector: page6_specifyBuildDirectorySpec |
1536 infoText: 'Define where the build-process is to be performed. |
1714 infoText: 'Define where the build-process is to be performed. |
1537 All generated files are created below that directory. |
1715 All generated files are created below that directory. |
1538 After deployment, the build directory is no longer needed |
1716 After deployment, the build directory is no longer needed |
1539 (but you can keep it for a faster compile the next time).' |
1717 (but you can keep it for a faster compile the next time).' |
1540 ) |
1718 ) |
1559 You can open a WindowsExplorer there to copy the files for |
1737 You can open a WindowsExplorer there to copy the files for |
1560 deployment. After that, the build directory is no longer needed |
1738 deployment. After that, the build directory is no longer needed |
1561 (but you can keep it for a faster compile the next time).' |
1739 (but you can keep it for a faster compile the next time).' |
1562 ) |
1740 ) |
1563 ) decodeAsLiteralArray. |
1741 ) decodeAsLiteralArray. |
1564 ! |
1742 ! ! |
1565 |
1743 |
1566 rformed. |
1744 !ProjectBuilderAssistantApplication methodsFor:'update'! |
1567 All generated files are created below that directory. |
1745 |
1568 After deployment, the build directory is no longer needed |
1746 rememberMakeOutputsContents |
1569 (but you can keep it for a faster compile the next time).' |
1747 makeOutputHolder value:(makeOutputWindow contents) |
1570 ) |
1748 ! |
1571 |
1749 |
1572 (AssistantPageSpec |
1750 restoreMakeOutputsContents |
1573 pageTitle: 'Build' |
1751 makeOutputWindow contents:makeOutputHolder value |
1574 windowSpecSelector: page7_buildSpec |
1752 ! |
1575 canEnterQuerySelector: #canEnterBuild |
1753 |
1576 enterCallbackSelector: #restoreMakeOutputsContents |
1754 update:something with:anArgument from:changedObject |
1577 leaveCallbackSelector: #rememberMakeOutputsContents |
1755 changedObject == Smalltalk ifTrue:[ |
1578 infoText: 'Start the build-process. This will run make/bcc to compile |
1756 (something == #newClass |
1579 all required classes and nsis to generate a self-installable |
1757 or:[something == #classRemove |
1580 executable. You must have the borland-cc and NullSoft NSIS |
1758 or:[something == #projectOrganization]]) ifTrue:[ |
1581 packages installed for this to work.' |
1759 self updateListOfMatchingProjects. |
1582 ) |
1760 ^ self. |
1583 |
1761 ]. |
1584 (AssistantPageSpec |
1762 ^ self. |
1585 pageTitle: 'Deploy' |
1763 ]. |
1586 windowSpecSelector: page8_deploySpec |
1764 super update:something with:anArgument from:changedObject |
1587 canEnterQuerySelector: #canEnterDeploy |
1765 ! |
1588 infoText: 'Find the installer to be deployed (or test-run the binary). |
1766 |
1589 You can open a WindowsExplorer there to copy the files for |
1767 updateApplicationComment |
1590 deployment. After that, the build directory is no longer needed |
1768 |comment| |
1591 (but you can keep it for a faster compile the next time).' |
1769 |
1592 ) |
1770 self selectedApplicationIndexHolder value notNil ifTrue:[ |
1593 ) decodeAsLiteralArray. |
1771 comment := self commentFromClass:selectedApplication. |
1594 ! |
1772 comment isNil ifTrue:[ |
1595 |
1773 comment := 'Application has no comment' allItalic colorizeAllWith:Color lightGrey. |
1596 After deployment, the build directory is no longer needed |
1774 ]. |
1597 (but you can keep it for a faster compile the next time).' |
1775 ] ifFalse:[ |
1598 ) |
1776 comment := 'Please select an Application' allItalic colorizeAllWith:Color lightGrey. |
1599 |
1777 ]. |
1600 (AssistantPageSpec |
1778 self selectedApplicationsComment value:comment. |
1601 pageTitle: 'Build' |
1779 ! |
1602 windowSpecSelector: page7_buildSpec |
1780 |
1603 canEnterQuerySelector: #canEnterBuild |
1781 updateComment |
1604 enterCallbackSelector: #restoreMakeOutputsContents |
1782 |comment| |
1605 leaveCallbackSelector: #rememberMakeOutputsContents |
1783 |
1606 infoText: 'Start the build-process. This will run make/bcc to compile |
1784 self selectedProjectIndexHolder value notNil ifTrue:[ |
1607 all required classes and nsis to generate a self-installable |
1785 comment := self commentFromClass:selectedProjectDefinition. |
1608 executable. You must have the borland-cc and NullSoft NSIS |
1786 comment isNil ifTrue:[ |
1609 packages installed for this to work.' |
1787 comment := 'Project has no comment' allItalic colorizeAllWith:Color lightGrey. |
1610 ) |
1788 ]. |
1611 |
1789 ] ifFalse:[ |
1612 (AssistantPageSpec |
1790 comment := 'Please select a Project' allItalic colorizeAllWith:Color lightGrey. |
1613 pageTitle: 'Deploy' |
1791 ]. |
1614 windowSpecSelector: page8_deploySpec |
1792 self selectedProjectsComment value:comment. |
1615 canEnterQuerySelector: #canEnterDeploy |
1793 ! |
1616 infoText: 'Find the installer to be deployed (or test-run the binary). |
1794 |
1617 You can open a WindowsExplorer there to copy the files for |
1795 updateListOfApplicationsInProject |
1618 deployment. After that, the build directory is no longer needed |
1796 |oldList applicationClasses package appClass appClassIndex| |
1619 (but you can keep it for a faster compile the next time).' |
|
1620 ) |
|
1621 ) decodeAsLiteralArray. |
|
1622 ! |
|
1623 |
|
1624 ts |
|
1625 leaveCallbackSelector: #rememberMakeOutputsContents |
|
1626 infoText: 'Start the build-process. This will run make/bcc to compile |
|
1627 all required classes and nsis to generate a self-installable |
|
1628 executable. You must have the borland-cc and NullSoft NSIS |
|
1629 packages installed for this to work.' |
|
1630 ) |
|
1631 |
|
1632 (AssistantPageSpec |
|
1633 pageTitle: 'Deploy' |
|
1634 windowSpecSelector: page8_deploySpec |
|
1635 canEnterQuerySelector: #canEnterDeploy |
|
1636 infoText: 'Find the installer to be deployed (or test-run the binary). |
|
1637 You can open a WindowsExplorer there to copy the files for |
|
1638 deployment. After that, the build directory is no longer needed |
|
1639 (but you can keep it for a faster compile the next time).' |
|
1640 ) |
|
1641 ) decodeAsLiteralArray. |
|
1642 ! |
|
1643 |
|
1644 : page8_deploySpec |
|
1645 canEnterQuerySelector: #canEnterDeploy |
|
1646 infoText: 'Find the installer to be deployed (or test-run the binary). |
|
1647 You can open a WindowsExplorer there to copy the files for |
|
1648 deployment. After that, the build directory is no longer needed |
|
1649 (but you can keep it for a faster compile the next time).' |
|
1650 ) |
|
1651 ) decodeAsLiteralArray. |
|
1652 ! |
|
1653 |
|
1654 tBuilderAssistantApplication methodsFor:'update' |
|
1655 ! |
|
1656 |
|
1657 lassIndex| |
|
1658 |
1797 |
1659 appClassIndex := nil. |
1798 appClassIndex := nil. |
1660 |
1799 |
1661 selectedProjectDefinition isNil ifTrue:[ |
1800 selectedProjectDefinition isNil ifTrue:[ |
1662 applicationClasses := #() |
1801 applicationClasses := #() |
1691 self listOfApplicationsInProject value:applicationClasses. |
1830 self listOfApplicationsInProject value:applicationClasses. |
1692 self selectedApplicationIndexHolder value:appClassIndex. |
1831 self selectedApplicationIndexHolder value:appClassIndex. |
1693 ]. |
1832 ]. |
1694 ! |
1833 ! |
1695 |
1834 |
1696 s := #() |
1835 updateListOfClassesInProject |
|
1836 self listOfClassesInProject value:(selectedProjectDefinition classNames). |
|
1837 ! |
|
1838 |
|
1839 updateListOfMatchingProjects |
|
1840 |matching projectType idx| |
|
1841 |
|
1842 projectType := self projectType. |
|
1843 matching := ProjectDefinition allSubclasses |
|
1844 select:[:defClass | |
|
1845 |match| |
|
1846 |
|
1847 match := false. |
|
1848 defClass isAbstract ifFalse:[ |
|
1849 (self hideSTXProjects value not |
|
1850 or:[ defClass package asPackageId module ~= 'stx' ]) |
|
1851 ifTrue:[ |
|
1852 projectType == ProjectDefinition libraryType ifTrue:[ |
|
1853 match := defClass isLibraryDefinition |
|
1854 ] ifFalse:[ |
|
1855 projectType == ProjectDefinition guiApplicationType ifTrue:[ |
|
1856 match := defClass isGUIApplication |
|
1857 ] ifFalse:[ |
|
1858 projectType == ProjectDefinition nonGuiApplicationType ifTrue:[ |
|
1859 match := defClass isConsoleApplication |
|
1860 ] ifFalse:[ |
|
1861 self error. |
|
1862 ]. |
|
1863 ]. |
|
1864 ]. |
|
1865 ]. |
|
1866 ]. |
|
1867 ]. |
|
1868 matching sort:[:a :b | a name < b name]. |
|
1869 self listOfMatchingProjects value:matching. |
|
1870 |
|
1871 idx := matching indexOf:selectedProjectDefinition. |
|
1872 idx == 0 ifTrue:[ |
|
1873 self selectedProjectIndexHolder value:nil. |
1697 ] ifFalse:[ |
1874 ] ifFalse:[ |
1698 package := selectedProjectDefinition package. |
1875 self selectedProjectIndexHolder value:idx. |
1699 |
|
1700 applicationClasses := Smalltalk allClasses |
|
1701 select:[:cls | |
|
1702 ((cls isSubclassOf:ApplicationModel) |
|
1703 and:[ self hideOtherApplicationClasses value not |
|
1704 or:[ cls package = package ]]) |
|
1705 ]. |
|
1706 applicationClasses := applicationClasses asOrderedCollection. |
|
1707 applicationClasses sort:[:a :b | a name < b name]. |
|
1708 |
|
1709 "/ startUpClassName := [ selectedProjectDefinition startupClassName ] ifError:[ nil ]. |
|
1710 "/ startUpClassName notNil ifTrue:[ |
|
1711 "/ startUpClass := Smalltalk classNamed:startUpClassName. |
|
1712 "/ startUpClass notNil ifTrue:[ |
|
1713 "/ appClassIndex := applicationClasses indexOf:startUpClass. |
|
1714 "/ appClassIndex == 0 ifTrue:[ appClassIndex := nil ]. |
|
1715 "/ ]. |
|
1716 "/ ]. |
|
1717 ]. |
|
1718 |
|
1719 oldList := self listOfApplicationsInProject value. |
|
1720 oldList = applicationClasses ifFalse:[ |
|
1721 appClass := selectedApplication. |
|
1722 appClassIndex := applicationClasses indexOf:appClass. |
|
1723 appClassIndex == 0 ifTrue:[ appClassIndex := nil ]. |
|
1724 |
|
1725 self listOfApplicationsInProject value:applicationClasses. |
|
1726 self selectedApplicationIndexHolder value:appClassIndex. |
|
1727 ]. |
1876 ]. |
1728 ! |
1877 ! |
1729 |
1878 |
1730 updateListOfStartupClassesInProject |
1879 updateListOfStartupClassesInProject |
1731 |startupClasses package startUpClassName startUpClass startupClassIndex| |
1880 |startupClasses package startUpClassName startUpClass startupClassIndex| |