Tools__ProjectDefinitionEditor.st
author Patrik Svestka <patrik.svestka@gmail.com>
Wed, 14 Nov 2018 12:07:51 +0100
branchjv
changeset 3630 5e718e0a754e
parent 2727 e5f434daebb5
child 3523 25fa267c550a
permissions -rw-r--r--
Issue #239: Fix all Smalltak/X source files to be in unicode (UTF8 without BOM) and prefixed by "{ Encoding: utf8 }" when any unicode character is present

- All source *.st files are now Unicode UTF8 without BOM
Files are in two groups (fileOut works this way in Smalltalk/X):
- containing a unicode character have "{ Encoding: utf8 }" at the header
- ASCII only are without the header
     1 "{ Package: 'stx:libtool2' }"
     2 
     3 "{ NameSpace: Tools }"
     4 
     5 ResourceSpecEditor subclass:#ProjectDefinitionEditor
     6 	instanceVariableNames:'definitionClass classList extensionsList selectedClassIndexHolder
     7 		classesTableColumns revisionNrHolder companyNameHolder
     8 		fileMajorVersionNrHolder minorVersionNrHolder iconFileNameHolder
     9 		fileReleaseNrHolder productNameHolder majorVersionNrHolder
    10 		fileRevisionNrHolder fileDescriptionHolder releaseNrHolder
    11 		fileMinorVersionNrHolder descriptionHolder legalCopyrightHolder
    12 		isApplicationDefinitionHolder isNonGUIApplicationHolder
    13 		startSinglethreadedHolder hasConsoleHolder shownHasConsoleHolder
    14 		startupClassNameHolder startupSelectorHolder prerequisitesList
    15 		classListHolder extensionsListHolder prerequisitesListHolder
    16 		documentExtensionsListStringHolder stcOptimizationFlagsHolder
    17 		ccOptimizationFlagsHolder'
    18 	classVariableNames:''
    19 	poolDictionaries:''
    20 	category:'Interface-Tools'
    21 !
    22 
    23 Object subclass:#ClassListEntry
    24 	instanceVariableNames:'className autoloaded win32 unix'
    25 	classVariableNames:''
    26 	poolDictionaries:''
    27 	privateIn:ProjectDefinitionEditor
    28 !
    29 
    30 Object subclass:#ExtensionsListEntry
    31 	instanceVariableNames:'className selector'
    32 	classVariableNames:''
    33 	poolDictionaries:''
    34 	privateIn:ProjectDefinitionEditor
    35 !
    36 
    37 Object subclass:#PrerequisitesListEntry
    38 	instanceVariableNames:'package'
    39 	classVariableNames:''
    40 	poolDictionaries:''
    41 	privateIn:ProjectDefinitionEditor
    42 !
    43 
    44 !ProjectDefinitionEditor class methodsFor:'documentation'!
    45 
    46 documentation
    47 "
    48     unfinished app-definition editor
    49 
    50     [author:]
    51 	cg (cg@FUSI)
    52 
    53     [instance variables:]
    54 
    55     [class variables:]
    56 
    57     [see also:]
    58 
    59 "
    60 !
    61 
    62 examples
    63 "
    64   Starting the application:
    65 								[exBegin]
    66     (ProjectDefinitionEditor new
    67 	definitionClass:stx_libbasic) open
    68 								[exEnd]
    69 
    70 								[exBegin]
    71     (ProjectDefinitionEditor new
    72 	definitionClass:bosch_dapasx_application) open
    73 								[exEnd]
    74 "
    75 ! !
    76 
    77 !ProjectDefinitionEditor class methodsFor:'help specs'!
    78 
    79 flyByHelpSpec
    80     "This resource specification was automatically generated
    81      by the UIHelpTool of ST/X."
    82 
    83     "Do not manually edit this!! If it is corrupted,
    84      the UIHelpTool may not be able to read the specification."
    85 
    86     "
    87      UIHelpTool openOnClass:Tools::ProjectDefinitionEditor    
    88     "
    89 
    90     <resource: #help>
    91 
    92     ^ super flyByHelpSpec addPairsFrom:#(
    93 
    94 #documentExtensions
    95 '";"-separated list of file extensions'
    96 
    97 )
    98 
    99     "Created: / 15-10-2006 / 14:34:57 / cg"
   100 !
   101 
   102 helpSpec
   103     "This resource specification was automatically generated
   104      by the UIHelpTool of ST/X."
   105 
   106     "Do not manually edit this!! If it is corrupted,
   107      the UIHelpTool may not be able to read the specification."
   108 
   109     "
   110      UIHelpTool openOnClass:Tools::ProjectDefinitionEditor    
   111     "
   112 
   113     <resource: #help>
   114 
   115     ^ super helpSpec addPairsFrom:#(
   116 
   117 #documentExtensions
   118 '";"-separated list of file extensions'
   119 
   120 )
   121 ! !
   122 
   123 !ProjectDefinitionEditor class methodsFor:'interface specs'!
   124 
   125 classesSpec
   126     "This resource specification was automatically generated
   127      by the UIPainter of ST/X."
   128 
   129     "Do not manually edit this!! If it is corrupted,
   130      the UIPainter may not be able to read the specification."
   131 
   132     "
   133      UIPainter new openOnClass:Tools::ProjectDefinitionEditor andSelector:#classesSpec
   134      Tools::ProjectDefinitionEditor new openInterface:#classesSpec
   135     "
   136 
   137     <resource: #canvas>
   138 
   139     ^
   140      #(FullSpec
   141 	name: classesSpec
   142 	window:
   143        (WindowSpec
   144 	  label: 'NewApplication'
   145 	  name: 'NewApplication'
   146 	  min: (Point 0 0)
   147 	  bounds: (Rectangle 0 0 300 300)
   148 	)
   149 	component:
   150        (SpecCollection
   151 	  collection: (
   152 	   (DataSetSpec
   153 	      name: 'ClassesTable'
   154 	      layout: (LayoutFrame 0 0 0 0 0 1 0 1)
   155 	      model: selectedClassIndexHolder
   156 	      menu: classListMenu
   157 	      hasHorizontalScrollBar: true
   158 	      hasVerticalScrollBar: true
   159 	      dataList: classListHolder
   160 	      columnHolder: classesTableColumns
   161 	    )
   162 	   )
   163 
   164 	)
   165       )
   166 
   167     "Modified: / 07-09-2006 / 11:35:14 / cg"
   168 !
   169 
   170 compilationSpec
   171     "This resource specification was automatically generated
   172      by the UIPainter of ST/X."
   173 
   174     "Do not manually edit this!! If it is corrupted,
   175      the UIPainter may not be able to read the specification."
   176 
   177     "
   178      UIPainter new openOnClass:Tools::ProjectDefinitionEditor andSelector:#compilationSpec
   179      Tools::ProjectDefinitionEditor new openInterface:#compilationSpec
   180     "
   181 
   182     <resource: #canvas>
   183 
   184     ^ 
   185      #(FullSpec
   186         name: compilationSpec
   187         window: 
   188        (WindowSpec
   189           label: 'NewApplication'
   190           name: 'NewApplication'
   191           min: (Point 0 0)
   192           bounds: (Rectangle 0 0 433 300)
   193         )
   194         component: 
   195        (SpecCollection
   196           collection: (
   197            (FramedBoxSpec
   198               label: 'Optimization'
   199               name: 'FramedBox1'
   200               layout: (LayoutFrame 0 0 0 0 0 1 93 0)
   201               labelPosition: topLeft
   202               translateLabel: true
   203               component: 
   204              (SpecCollection
   205                 collection: (
   206                  (LabelSpec
   207                     label: 'STC Optimization Flags:'
   208                     name: 'Label1'
   209                     layout: (LayoutFrame 0 0.0 7 0 160 0 29 0)
   210                     translateLabel: true
   211                     adjust: right
   212                   )
   213                  (ComboBoxSpec
   214                     name: 'STCOptimizationFlagsComboBox'
   215                     layout: (LayoutFrame 162 0.0 5 0 0 1.0 27 0)
   216                     model: stcOptimizationFlagsHolder
   217                     acceptOnPointerLeave: false
   218                     comboList: stcOptimizationFlagList
   219                     postBuildCallback: flagHolderBuilt:
   220                   )
   221                  (LabelSpec
   222                     label: 'CC Optimization Flags:'
   223                     name: 'Label2'
   224                     layout: (LayoutFrame 0 0.0 35 0 160 0 57 0)
   225                     translateLabel: true
   226                     adjust: right
   227                   )
   228                  (ComboBoxSpec
   229                     name: 'CCOptimizationFlagsComboBox'
   230                     layout: (LayoutFrame 162 0.0 33 0 0 1.0 55 0)
   231                     model: ccOptimizationFlagsHolder
   232                     acceptOnPointerLeave: false
   233                     comboList: ccOptimizationFlagList
   234                     postBuildCallback: flagHolderBuilt:
   235                   )
   236                  )
   237                
   238               )
   239             )
   240            (FramedBoxSpec
   241               label: 'Includes'
   242               name: 'FramedBox2'
   243               layout: (LayoutFrame 0 0 98 0 0 1 160 0)
   244               labelPosition: topLeft
   245               translateLabel: true
   246               component: 
   247              (SpecCollection
   248                 collection: (
   249                  (LabelSpec
   250                     label: 'Additional Includes:'
   251                     name: 'Label3'
   252                     layout: (LayoutFrame 0 0.0 7 0 160 0 29 0)
   253                     translateLabel: true
   254                     adjust: right
   255                   )
   256                  (InputFieldSpec
   257                     name: 'IncludeFlagsEntryField'
   258                     layout: (LayoutFrame 162 0.0 5 0 0 1.0 27 0)
   259                     model: includeFlagsHolder
   260                     acceptOnReturn: true
   261                     acceptOnTab: true
   262                     acceptOnLostFocus: true
   263                     acceptOnPointerLeave: false
   264                   )
   265                  )
   266                
   267               )
   268             )
   269            )
   270          
   271         )
   272       )
   273 !
   274 
   275 descriptionSpec
   276     "This resource specification was automatically generated
   277      by the UIPainter of ST/X."
   278 
   279     "Do not manually edit this!! If it is corrupted,
   280      the UIPainter may not be able to read the specification."
   281 
   282     "
   283      UIPainter new openOnClass:ApplicationDefinitionBuilder andSelector:#descriptionSpec
   284      ApplicationDefinitionBuilder new openInterface:#descriptionSpec
   285     "
   286 
   287     <resource: #canvas>
   288 
   289     ^
   290      #(FullSpec
   291         name: descriptionSpec
   292         window:
   293        (WindowSpec
   294           label: 'NewApplication'
   295           name: 'NewApplication'
   296           min: (Point 0 0)
   297           bounds: (Rectangle 0 0 433 300)
   298         )
   299         component:
   300        (SpecCollection
   301           collection: (
   302            (LabelSpec
   303               label: 'Company:'
   304               name: 'CompanyLabel'
   305               layout: (LayoutFrame 2 0.0 13 0 160 0 35 0)
   306               translateLabel: true
   307               adjust: right
   308             )
   309            (InputFieldSpec
   310               name: 'CompanyEntryField'
   311               layout: (LayoutFrame 162 0.0 12 0 -2 1.0 34 0)
   312               model: companyNameHolder
   313               acceptOnReturn: true
   314               acceptOnTab: true
   315               acceptOnLostFocus: true
   316               acceptOnPointerLeave: false
   317             )
   318            (LabelSpec
   319               label: 'Description:'
   320               name: 'DescriptionLabel'
   321               layout: (LayoutFrame 2 0.0 39 0 160 0 61 0)
   322               translateLabel: true
   323               adjust: right
   324             )
   325            (InputFieldSpec
   326               name: 'DescriptionEntryField'
   327               layout: (LayoutFrame 162 0.0 38 0 -2 1.0 60 0)
   328               model: descriptionHolder
   329               acceptOnReturn: true
   330               acceptOnTab: true
   331               acceptOnLostFocus: true
   332               acceptOnPointerLeave: false
   333             )
   334            (LabelSpec
   335               label: 'ProductName:'
   336               name: 'ProductNameLabel'
   337               layout: (LayoutFrame 2 0.0 65 0 160 0 87 0)
   338               translateLabel: true
   339               adjust: right
   340             )
   341            (InputFieldSpec
   342               name: 'ProductNameEntryField'
   343               layout: (LayoutFrame 162 0.0 64 0 -2 1.0 86 0)
   344               model: productNameHolder
   345               acceptOnReturn: true
   346               acceptOnTab: true
   347               acceptOnLostFocus: true
   348               acceptOnPointerLeave: false
   349             )
   350            (LabelSpec
   351               label: 'ProductVersion:'
   352               name: 'ProductVersionLabel'
   353               layout: (LayoutFrame 2 0.0 91 0 160 0 113 0)
   354               translateLabel: true
   355               adjust: right
   356             )
   357            (InputFieldSpec
   358               name: 'MajorVersionNrEntryField'
   359               layout: (LayoutFrame 162 0.0 90 0 182 0.0 112 0)
   360               model: majorVersionNrHolder
   361               type: number
   362               acceptOnReturn: true
   363               acceptOnTab: true
   364               acceptOnLostFocus: true
   365               acceptOnPointerLeave: false
   366             )
   367            (InputFieldSpec
   368               name: 'MinorVersionNrEntryField'
   369               layout: (LayoutFrame 184 0.0 90 0 204 0.0 112 0)
   370               model: minorVersionNrHolder
   371               type: numberOrNil
   372               acceptOnReturn: true
   373               acceptOnTab: true
   374               acceptOnLostFocus: true
   375               acceptOnPointerLeave: false
   376             )
   377            (InputFieldSpec
   378               name: 'RevisionNrEntryField'
   379               layout: (LayoutFrame 206 0.0 90 0 226 0.0 112 0)
   380               model: revisionNrHolder
   381               type: number
   382               acceptOnReturn: true
   383               acceptOnTab: true
   384               acceptOnLostFocus: true
   385               acceptOnPointerLeave: false
   386             )
   387            (InputFieldSpec
   388               name: 'ReleaseNrEntryField'
   389               layout: (LayoutFrame 228 0.0 90 0 248 0.0 112 0)
   390               model: releaseNrHolder
   391               type: number
   392               acceptOnReturn: true
   393               acceptOnTab: true
   394               acceptOnLostFocus: true
   395               acceptOnPointerLeave: false
   396             )
   397            (LabelSpec
   398               label: 'LegalCopyright:'
   399               name: 'LegalCopyrightLabel'
   400               layout: (LayoutFrame 2 0.0 119 0 160 0 141 0)
   401               translateLabel: true
   402               adjust: right
   403             )
   404            (InputFieldSpec
   405               name: 'LegalCopyrightEntryField'
   406               layout: (LayoutFrame 162 0.0 118 0 -2 1.0 140 0)
   407               model: legalCopyrightHolder
   408               acceptOnReturn: true
   409               acceptOnTab: true
   410               acceptOnLostFocus: true
   411               acceptOnPointerLeave: false
   412             )
   413            (LabelSpec
   414               label: 'FileDescriptionDescription:'
   415               name: 'FileDescriptionLabel'
   416               layout: (LayoutFrame 2 0.0 161 0 160 0 183 0)
   417               translateLabel: true
   418               adjust: right
   419             )
   420            (InputFieldSpec
   421               name: 'FileDescriptionEntryField'
   422               layout: (LayoutFrame 162 0.0 160 0 -2 1.0 182 0)
   423               model: fileDescriptionHolder
   424               acceptOnReturn: true
   425               acceptOnTab: true
   426               acceptOnLostFocus: true
   427               acceptOnPointerLeave: false
   428             )
   429            (LabelSpec
   430               label: 'FileVersion:'
   431               name: 'FileVersionLabel'
   432               layout: (LayoutFrame 2 0.0 187 0 160 0 209 0)
   433               translateLabel: true
   434               adjust: right
   435             )
   436            (InputFieldSpec
   437               name: 'FileMajorVersionNrEntryField'
   438               layout: (LayoutFrame 162 0.0 186 0 182 0.0 208 0)
   439               model: fileMajorVersionNrHolder
   440               type: number
   441               acceptOnReturn: true
   442               acceptOnTab: true
   443               acceptOnLostFocus: true
   444               acceptOnPointerLeave: false
   445             )
   446            (InputFieldSpec
   447               name: 'FileMinorVersionNrEntryField'
   448               layout: (LayoutFrame 184 0.0 186 0 204 0.0 208 0)
   449               model: fileMinorVersionNrHolder
   450               type: number
   451               acceptOnReturn: true
   452               acceptOnTab: true
   453               acceptOnLostFocus: true
   454               acceptOnPointerLeave: false
   455             )
   456            (InputFieldSpec
   457               name: 'FileRevisionNrEntryField'
   458               layout: (LayoutFrame 206 0.0 186 0 226 0.0 208 0)
   459               model: fileRevisionNrHolder
   460               type: number
   461               acceptOnReturn: true
   462               acceptOnTab: true
   463               acceptOnLostFocus: true
   464               acceptOnPointerLeave: false
   465             )
   466            (InputFieldSpec
   467               name: 'FileReleaseNrEntryField'
   468               layout: (LayoutFrame 228 0.0 186 0 248 0.0 208 0)
   469               model: fileReleaseNrHolder
   470               type: number
   471               acceptOnReturn: true
   472               acceptOnTab: true
   473               acceptOnLostFocus: true
   474               acceptOnPointerLeave: false
   475             )
   476            (LabelSpec
   477               label: 'Icon Filename:'
   478               name: 'IconFileNameLabel'
   479               layout: (LayoutFrame 2 0.0 236 0 160 0 258 0)
   480               visibilityChannel: isApplicationDefinitionHolder
   481               translateLabel: true
   482               adjust: right
   483             )
   484            (InputFieldSpec
   485               name: 'IconFileNameEntryField'
   486               layout: (LayoutFrame 162 0.0 234 0 -2 1.0 256 0)
   487               visibilityChannel: isApplicationDefinitionHolder
   488               model: iconFileNameHolder
   489               acceptOnReturn: true
   490               acceptOnTab: true
   491               acceptOnLostFocus: true
   492               acceptOnPointerLeave: false
   493             )
   494            )
   495 
   496         )
   497       )
   498 !
   499 
   500 extensionsSpec
   501     "This resource specification was automatically generated
   502      by the UIPainter of ST/X."
   503 
   504     "Do not manually edit this!! If it is corrupted,
   505      the UIPainter may not be able to read the specification."
   506 
   507     "
   508      UIPainter new openOnClass:ApplicationDefinitionEditor andSelector:#extensionsSpec
   509      ApplicationDefinitionEditor new openInterface:#extensionsSpec
   510     "
   511 
   512     <resource: #canvas>
   513 
   514     ^
   515      #(FullSpec
   516 	name: extensionsSpec
   517 	window:
   518        (WindowSpec
   519 	  label: 'NewApplication'
   520 	  name: 'NewApplication'
   521 	  min: (Point 0 0)
   522 	  bounds: (Rectangle 0 0 300 300)
   523 	)
   524 	component:
   525        (SpecCollection
   526 	  collection: (
   527 	   (DataSetSpec
   528 	      name: 'ExtensionsTable'
   529 	      layout: (LayoutFrame 0 0 0 0 0 1 0 1)
   530 	      model: selectedExtensionIndexHolder
   531 	      hasHorizontalScrollBar: true
   532 	      hasVerticalScrollBar: true
   533 	      dataList: extensionsListHolder
   534 	      columnHolder: extensionsTableColumns
   535 	    )
   536 	   )
   537 
   538 	)
   539       )
   540 
   541     "Modified: / 07-09-2006 / 11:35:17 / cg"
   542 !
   543 
   544 prerequisitesSpec
   545     "This resource specification was automatically generated
   546      by the UIPainter of ST/X."
   547 
   548     "Do not manually edit this!! If it is corrupted,
   549      the UIPainter may not be able to read the specification."
   550 
   551     "
   552      UIPainter new openOnClass:ApplicationDefinitionEditor andSelector:#extensionsSpec
   553      ApplicationDefinitionEditor new openInterface:#extensionsSpec
   554     "
   555 
   556     <resource: #canvas>
   557 
   558     ^
   559      #(FullSpec
   560 	name: extensionsSpec
   561 	window:
   562        (WindowSpec
   563 	  label: 'NewApplication'
   564 	  name: 'NewApplication'
   565 	  min: (Point 0 0)
   566 	  bounds: (Rectangle 0 0 300 300)
   567 	)
   568 	component:
   569        (SpecCollection
   570 	  collection: (
   571 	   (DataSetSpec
   572 	      name: 'ExtensionsTable'
   573 	      layout: (LayoutFrame 0 0 0 0 0 1 0 1)
   574 	      model: selectedPrerequisitesIndexHolder
   575 	      hasHorizontalScrollBar: true
   576 	      hasVerticalScrollBar: true
   577 	      dataList: prerequisitesListHolder
   578 	      columnHolder: prerequisitesTableColumns
   579 	    )
   580 	   )
   581 
   582 	)
   583       )
   584 
   585     "Created: / 05-09-2006 / 13:21:32 / cg"
   586     "Modified: / 07-09-2006 / 11:35:20 / cg"
   587 !
   588 
   589 startupSpec
   590     "This resource specification was automatically generated
   591      by the UIPainter of ST/X."
   592 
   593     "Do not manually edit this!! If it is corrupted,
   594      the UIPainter may not be able to read the specification."
   595 
   596     "
   597      UIPainter new openOnClass:Tools::ProjectDefinitionEditor andSelector:#startupSpec
   598      Tools::ProjectDefinitionEditor new openInterface:#startupSpec
   599     "
   600 
   601     <resource: #canvas>
   602 
   603     ^ 
   604      #(FullSpec
   605         name: startupSpec
   606         window: 
   607        (WindowSpec
   608           label: 'NewApplication'
   609           name: 'NewApplication'
   610           min: (Point 0 0)
   611           bounds: (Rectangle 0 0 433 300)
   612         )
   613         component: 
   614        (SpecCollection
   615           collection: (
   616            (FramedBoxSpec
   617               label: 'Startup'
   618               name: 'StartupFrame'
   619               layout: (LayoutFrame 0 0 0 0 0 1 93 0)
   620               labelPosition: topLeft
   621               translateLabel: true
   622               component: 
   623              (SpecCollection
   624                 collection: (
   625                  (LabelSpec
   626                     label: 'Startup Class:'
   627                     name: 'Label1'
   628                     layout: (LayoutFrame 0 0.0 7 0 160 0 29 0)
   629                     translateLabel: true
   630                     adjust: right
   631                   )
   632                  (InputFieldSpec
   633                     name: 'StartupClassEntryField'
   634                     layout: (LayoutFrame 162 0.0 5 0 0 1.0 27 0)
   635                     model: startupClassNameHolder
   636                     acceptOnReturn: true
   637                     acceptOnTab: true
   638                     acceptOnLostFocus: true
   639                     acceptOnPointerLeave: false
   640                   )
   641                  (LabelSpec
   642                     label: 'Startup Selector:'
   643                     name: 'Label2'
   644                     layout: (LayoutFrame 0 0.0 35 0 160 0 57 0)
   645                     translateLabel: true
   646                     adjust: right
   647                   )
   648                  (InputFieldSpec
   649                     name: 'StartupSelectorEntryField'
   650                     layout: (LayoutFrame 162 0.0 33 0 0 1.0 55 0)
   651                     model: startupSelectorHolder
   652                     acceptOnReturn: true
   653                     acceptOnTab: true
   654                     acceptOnLostFocus: true
   655                     acceptOnPointerLeave: false
   656                   )
   657                  )
   658                
   659               )
   660             )
   661            (FramedBoxSpec
   662               label: 'Execution'
   663               name: 'ExecutionFrame'
   664               layout: (LayoutFrame 0 0 94 0 0 1 176 0)
   665               labelPosition: topLeft
   666               translateLabel: true
   667               component: 
   668              (SpecCollection
   669                 collection: (
   670                  (CheckBoxSpec
   671                     label: 'Non-GUI Application'
   672                     name: 'Non-GUI CheckBox'
   673                     layout: (LayoutFrame 0 0.0 7 0 0 0.5 29 0)
   674                     model: isNonGUIApplicationHolder
   675                     translateLabel: true
   676                   )
   677                  (CheckBoxSpec
   678                     label: 'Singlethreaded'
   679                     name: 'SinglethreadedCheckBox'
   680                     layout: (LayoutFrame 0 0.5 7 0 0 1 29 0)
   681                     enableChannel: isNonGUIApplicationHolder
   682                     model: startSinglethreadedHolder
   683                     translateLabel: true
   684                   )
   685                  (CheckBoxSpec
   686                     label: 'Has Console'
   687                     name: 'HasConsoleCheckBox1'
   688                     layout: (LayoutFrame 0 0.5 34 0 0 1 56 0)
   689                     enableChannel: isGUIApplicationHolder
   690                     model: shownHasConsoleHolder
   691                     translateLabel: true
   692                   )
   693                  )
   694                
   695               )
   696             )
   697            (FramedBoxSpec
   698               label: 'File Extensions'
   699               name: 'FileExtensionsFrame'
   700               layout: (LayoutFrame 0 0 177 0 0 1 237 0)
   701               labelPosition: topLeft
   702               translateLabel: true
   703               component: 
   704              (SpecCollection
   705                 collection: (
   706                  (LabelSpec
   707                     label: 'Document Extensions:'
   708                     name: 'Label3'
   709                     layout: (LayoutFrame 0 0.0 7 0 160 0 29 0)
   710                     activeHelpKey: documentExtensions
   711                     translateLabel: true
   712                     adjust: right
   713                   )
   714                  (InputFieldSpec
   715                     activeHelpKey: documentExtensions
   716                     name: 'EntryField1'
   717                     layout: (LayoutFrame 162 0.0 5 0 0 1.0 27 0)
   718                     model: documentExtensionsListStringHolder
   719                     type: string
   720                     acceptOnReturn: true
   721                     acceptOnTab: true
   722                     acceptOnLostFocus: true
   723                     acceptOnPointerLeave: false
   724                   )
   725                  )
   726                
   727               )
   728             )
   729            )
   730          
   731         )
   732       )
   733 
   734     "Modified: / 15-10-2006 / 14:35:12 / cg"
   735 !
   736 
   737 windowSpec
   738     "This resource specification was automatically generated
   739      by the UIPainter of ST/X."
   740 
   741     "Do not manually edit this!! If it is corrupted,
   742      the UIPainter may not be able to read the specification."
   743 
   744     "
   745      UIPainter new openOnClass:ApplicationDefinitionBuilder andSelector:#windowSpec
   746      ApplicationDefinitionBuilder new openInterface:#windowSpec
   747      ApplicationDefinitionBuilder open
   748     "
   749 
   750     <resource: #canvas>
   751 
   752     ^
   753      #(FullSpec
   754 	name: windowSpec
   755 	window:
   756        (WindowSpec
   757 	  label: 'ApplicationDefinitionBuilder'
   758 	  name: 'ApplicationDefinitionBuilder'
   759 	  min: (Point 10 10)
   760 	  max: (Point 1024 768)
   761 	  bounds: (Rectangle 0 0 596 339)
   762 	  menu: mainMenu
   763 	)
   764 	component:
   765        (SpecCollection
   766 	  collection: (
   767 	   (NoteBookViewSpec
   768 	      name: 'NoteBook1'
   769 	      layout: (LayoutFrame 0 0 0 0 0 1 0 1)
   770 	      model: selectedTabIndexHolder
   771 	      menu: tabList
   772 	      useIndex: true
   773 	    )
   774 	   )
   775 
   776 	)
   777       )
   778 
   779     "Modified: / 03-09-2006 / 10:57:33 / cg"
   780 ! !
   781 
   782 !ProjectDefinitionEditor class methodsFor:'list specs'!
   783 
   784 tabList
   785 ^ self  tabListForApplication.
   786 
   787     "Created: / 06-09-2006 / 13:38:03 / cg"
   788 !
   789 
   790 tabListForApplication
   791     "This resource specification was automatically generated
   792      by the TabListEditor of ST/X."
   793 
   794     "Do not manually edit this!! If it is corrupted,
   795      the TabListEditor may not be able to read the specification."
   796 
   797     "
   798      TabListEditor new openOnClass: self andSelector:#tabList
   799     "
   800 
   801     <resource: #tabList>
   802 
   803     ^     #(
   804        (TabItem
   805 	  label: 'Description'
   806 	  minorKey: descriptionSpec
   807 	)
   808        (TabItem
   809 	  label: 'Classes'
   810 	  createNewBuilder: false
   811 	  translateLabel: true
   812 	  minorKey: classesSpec
   813 	)
   814        (TabItem
   815 	  label: 'Extensions'
   816 	  minorKey: extensionsSpec
   817 	)
   818        (TabItem
   819 	  label: 'Prerequisites'
   820 	  minorKey: prerequisitesSpec
   821 	)
   822        (TabItem
   823 	  label: 'Compilation'
   824 	  minorKey: compilationSpec
   825 	)
   826        (TabItem
   827 	  label: 'Startup'
   828 	  minorKey: startupSpec
   829 	)
   830        )
   831 
   832       collect:[:aTab| TabItem new fromLiteralArrayEncoding:aTab ]
   833 
   834     "Created: / 05-09-2006 / 16:24:48 / cg"
   835     "Modified: / 06-09-2006 / 18:44:34 / cg"
   836 !
   837 
   838 tabListForLibrary
   839     "This resource specification was automatically generated
   840      by the TabListEditor of ST/X."
   841 
   842     "Do not manually edit this!! If it is corrupted,
   843      the TabListEditor may not be able to read the specification."
   844 
   845     "
   846      TabListEditor new openOnClass: self andSelector:#tabList
   847     "
   848 
   849     <resource: #tabList>
   850 
   851     ^     #(
   852        (TabItem
   853 	  label: 'Description'
   854 	  minorKey: descriptionSpec
   855 	)
   856        (TabItem
   857 	  label: 'Classes'
   858 	  createNewBuilder: false
   859 	  translateLabel: true
   860 	  minorKey: classesSpec
   861 	)
   862        (TabItem
   863 	  label: 'Extensions'
   864 	  minorKey: extensionsSpec
   865 	)
   866        (TabItem
   867 	  label: 'Prerequisites'
   868 	  minorKey: prerequisitesSpec
   869 	)
   870        (TabItem
   871 	  label: 'Compilation'
   872 	  minorKey: compilationSpec
   873 	)
   874        )
   875 
   876       collect:[:aTab| TabItem new fromLiteralArrayEncoding:aTab ]
   877 
   878     "Created: / 05-09-2006 / 16:24:52 / cg"
   879     "Modified: / 06-09-2006 / 18:44:38 / cg"
   880 ! !
   881 
   882 !ProjectDefinitionEditor class methodsFor:'menu specs'!
   883 
   884 classListMenu
   885     "This resource specification was automatically generated
   886      by the MenuEditor of ST/X."
   887 
   888     "Do not manually edit this!! If it is corrupted,
   889      the MenuEditor may not be able to read the specification."
   890 
   891     "
   892      MenuEditor new openOnClass:Tools::ProjectDefinitionEditor andSelector:#classListMenu
   893      (Menu new fromLiteralArrayEncoding:(Tools::ProjectDefinitionEditor classListMenu)) startUp
   894     "
   895 
   896     <resource: #menu>
   897 
   898     ^
   899      #(Menu
   900 	(
   901 	 (MenuItem
   902 	    enabled: hasDefinitionClassHolder
   903 	    label: 'Generate'
   904 	    itemValue: menuGenerateClassList
   905 	    translateLabel: true
   906 	  )
   907 	 (MenuItem
   908 	    label: '-'
   909 	  )
   910 	 (MenuItem
   911 	    enabled: hasDefinitionClassHolder
   912 	    label: 'Add...'
   913 	    itemValue: menuAddClass
   914 	    translateLabel: true
   915 	  )
   916 	 (MenuItem
   917 	    enabled: hasDefinitionClassHolder
   918 	    label: 'Remove...'
   919 	    itemValue: menuRemoveClass
   920 	    translateLabel: true
   921 	  )
   922 	 )
   923 	nil
   924 	nil
   925       )
   926 !
   927 
   928 extensionsListMenu
   929     "This resource specification was automatically generated
   930      by the MenuEditor of ST/X."
   931 
   932     "Do not manually edit this!! If it is corrupted,
   933      the MenuEditor may not be able to read the specification."
   934 
   935     "
   936      MenuEditor new openOnClass:Tools::ProjectDefinitionEditor andSelector:#extensionsListMenu
   937      (Menu new fromLiteralArrayEncoding:(Tools::ProjectDefinitionEditor extensionsListMenu)) startUp
   938     "
   939 
   940     <resource: #menu>
   941 
   942     ^
   943      #(Menu
   944 	(
   945 	 (MenuItem
   946 	    enabled: hasDefinitionClassHolder
   947 	    label: 'Generate'
   948 	    itemValue: menuGenerateExtensionsList
   949 	    translateLabel: true
   950 	  )
   951 	 (MenuItem
   952 	    label: '-'
   953 	  )
   954 	 (MenuItem
   955 	    enabled: hasDefinitionClassHolder
   956 	    label: 'Add...'
   957 	    itemValue: menuAddExtension
   958 	    translateLabel: true
   959 	  )
   960 	 (MenuItem
   961 	    enabled: hasDefinitionClassHolder
   962 	    label: 'Remove...'
   963 	    itemValue: menuRemoveExtension
   964 	    translateLabel: true
   965 	  )
   966 	 )
   967 	nil
   968 	nil
   969       )
   970 !
   971 
   972 mainMenu
   973     "This resource specification was automatically generated
   974      by the MenuEditor of ST/X."
   975 
   976     "Do not manually edit this!! If it is corrupted,
   977      the MenuEditor may not be able to read the specification."
   978 
   979     "
   980      MenuEditor new openOnClass:Tools::ProjectDefinitionEditor andSelector:#mainMenu
   981      (Menu new fromLiteralArrayEncoding:(Tools::ProjectDefinitionEditor mainMenu)) startUp
   982     "
   983 
   984     <resource: #menu>
   985 
   986     ^ 
   987      #(Menu
   988         (
   989          (MenuItem
   990             label: 'File'
   991             translateLabel: true
   992             submenu: 
   993            (Menu
   994               (
   995                (MenuItem
   996                   label: 'New Library'
   997                   itemValue: menuNewLibraryDefinition
   998                   translateLabel: true
   999                 )
  1000                (MenuItem
  1001                   label: 'New Application'
  1002                   itemValue: menuNewApplicationDefinition
  1003                   translateLabel: true
  1004                 )
  1005                (MenuItem
  1006                   label: '-'
  1007                 )
  1008                (MenuItem
  1009                   label: 'Open...'
  1010                   itemValue: menuOpen
  1011                   translateLabel: true
  1012                 )
  1013                (MenuItem
  1014                   label: '-'
  1015                 )
  1016                (MenuItem
  1017                   enabled: hasDefinitionClassHolder
  1018                   label: 'Save'
  1019                   itemValue: menuSave
  1020                   translateLabel: true
  1021                 )
  1022                (MenuItem
  1023                   enabled: hasDefinitionClassHolder
  1024                   label: 'Save As...'
  1025                   itemValue: menuSaveAs
  1026                   translateLabel: true
  1027                 )
  1028                (MenuItem
  1029                   label: '-'
  1030                 )
  1031                (MenuItem
  1032                   label: 'Exit'
  1033                   itemValue: closeRequest
  1034                   translateLabel: true
  1035                 )
  1036                )
  1037               nil
  1038               nil
  1039             )
  1040           )
  1041          (MenuItem
  1042             label: 'Definition'
  1043             translateLabel: true
  1044             submenu: 
  1045            (Menu
  1046               (
  1047                (MenuItem
  1048                   enabled: hasDefinitionClassHolder
  1049                   label: 'Generate Definitions'
  1050                   itemValue: menuGenerateProjectDefinitions
  1051                   translateLabel: true
  1052                 )
  1053                )
  1054               nil
  1055               nil
  1056             )
  1057           )
  1058          (MenuItem
  1059             label: 'Classes'
  1060             translateLabel: true
  1061             isVisible: classesMenuVisibleHolder
  1062             submenuChannel: classListMenu
  1063             keepLinkedMenu: true
  1064           )
  1065          (MenuItem
  1066             label: 'Extensions'
  1067             translateLabel: true
  1068             isVisible: extensionsMenuVisibleHolder
  1069             submenuChannel: extensionsListMenu
  1070             keepLinkedMenu: true
  1071           )
  1072          (MenuItem
  1073             label: 'Prerequisites'
  1074             translateLabel: true
  1075             isVisible: prerequisitesMenuVisibleHolder
  1076             submenuChannel: prerequisitesListMenu
  1077             keepLinkedMenu: true
  1078           )
  1079          (MenuItem
  1080             label: 'MENU_Help'
  1081             translateLabel: true
  1082             startGroup: conditionalRight
  1083             submenu: 
  1084            (Menu
  1085               (
  1086                (MenuItem
  1087                   label: 'Documentation'
  1088                   itemValue: openDocumentation
  1089                   translateLabel: true
  1090                 )
  1091                (MenuItem
  1092                   label: '-'
  1093                 )
  1094                (MenuItem
  1095                   label: 'About this Application...'
  1096                   itemValue: openAboutThisApplication
  1097                   translateLabel: true
  1098                 )
  1099                )
  1100               nil
  1101               nil
  1102             )
  1103           )
  1104          )
  1105         nil
  1106         nil
  1107       )
  1108 !
  1109 
  1110 prerequisitesListMenu
  1111     "This resource specification was automatically generated
  1112      by the MenuEditor of ST/X."
  1113 
  1114     "Do not manually edit this!! If it is corrupted,
  1115      the MenuEditor may not be able to read the specification."
  1116 
  1117     "
  1118      MenuEditor new openOnClass:Tools::ProjectDefinitionEditor andSelector:#prerequisitesListMenu
  1119      (Menu new fromLiteralArrayEncoding:(Tools::ProjectDefinitionEditor prerequisitesListMenu)) startUp
  1120     "
  1121 
  1122     <resource: #menu>
  1123 
  1124     ^
  1125      #(Menu
  1126 	(
  1127 	 (MenuItem
  1128 	    enabled: hasDefinitionClassHolder
  1129 	    label: 'Generate'
  1130 	    itemValue: menuGeneratePrerequisitesList
  1131 	    translateLabel: true
  1132 	  )
  1133 	 (MenuItem
  1134 	    label: '-'
  1135 	  )
  1136 	 (MenuItem
  1137 	    enabled: hasDefinitionClassHolder
  1138 	    label: 'Add...'
  1139 	    itemValue: menuAddPrerequisite
  1140 	    translateLabel: true
  1141 	  )
  1142 	 (MenuItem
  1143 	    enabled: hasDefinitionClassHolder
  1144 	    label: 'Remove...'
  1145 	    itemValue: menuRemovePrerequisite
  1146 	    translateLabel: true
  1147 	  )
  1148 	 )
  1149 	nil
  1150 	nil
  1151       )
  1152 ! !
  1153 
  1154 !ProjectDefinitionEditor class methodsFor:'tableColumns specs'!
  1155 
  1156 classesTableColumns
  1157     "This resource specification was automatically generated
  1158      by the DataSetBuilder of ST/X."
  1159 
  1160     "Do not manually edit this!! If it is corrupted,
  1161      the DataSetBuilder may not be able to read the specification."
  1162 
  1163     "
  1164      DataSetBuilder new openOnClass:Tools::ProjectDefinitionEditor andSelector:#classesTableColumns
  1165     "
  1166 
  1167     <resource: #tableColumns>
  1168 
  1169     ^#(
  1170       (DataSetColumnSpec
  1171          label: 'Class'
  1172          labelAlignment: left
  1173          labelButtonType: Button
  1174          model: className
  1175          canSelect: false
  1176        )
  1177       (DataSetColumnSpec
  1178          label: 'Auto'
  1179          labelButtonType: Button
  1180          editorType: CheckToggle
  1181          rendererType: CheckToggle
  1182          model: autoloaded
  1183        )
  1184       (DataSetColumnSpec
  1185          label: 'Win32'
  1186          labelButtonType: Button
  1187          editorType: CheckToggle
  1188          rendererType: CheckToggle
  1189          model: win32
  1190        )
  1191       (DataSetColumnSpec
  1192          label: 'Unix'
  1193          labelButtonType: Button
  1194          editorType: CheckToggle
  1195          rendererType: CheckToggle
  1196          model: unix
  1197        )
  1198       )
  1199     
  1200 !
  1201 
  1202 extensionsTableColumns
  1203     "This resource specification was automatically generated
  1204      by the DataSetBuilder of ST/X."
  1205 
  1206     "Do not manually edit this!! If it is corrupted,
  1207      the DataSetBuilder may not be able to read the specification."
  1208 
  1209     "
  1210      DataSetBuilder new openOnClass:Tools::ProjectDefinitionEditor andSelector:#extensionsTableColumns
  1211     "
  1212 
  1213     <resource: #tableColumns>
  1214 
  1215     ^#(
  1216       (DataSetColumnSpec
  1217 	 label: 'Class'
  1218 	 labelAlignment: left
  1219 	 labelButtonType: Button
  1220 	 model: className
  1221 	 canSelect: false
  1222        )
  1223       (DataSetColumnSpec
  1224 	 label: 'Selector'
  1225 	 labelAlignment: left
  1226 	 labelButtonType: Button
  1227 	 model: selector
  1228 	 canSelect: false
  1229        )
  1230       )
  1231 
  1232 !
  1233 
  1234 prerequisitesTableColumns
  1235     "This resource specification was automatically generated
  1236      by the DataSetBuilder of ST/X."
  1237 
  1238     "Do not manually edit this!! If it is corrupted,
  1239      the DataSetBuilder may not be able to read the specification."
  1240 
  1241     "
  1242      DataSetBuilder new openOnClass:Tools::ProjectDefinitionEditor andSelector:#prerequisitesTableColumns
  1243     "
  1244 
  1245     <resource: #tableColumns>
  1246 
  1247     ^#(
  1248       (DataSetColumnSpec
  1249 	 label: 'Package'
  1250 	 labelAlignment: left
  1251 	 labelButtonType: Button
  1252 	 model: package
  1253        )
  1254       )
  1255 
  1256 ! !
  1257 
  1258 !ProjectDefinitionEditor methodsFor:'accessing'!
  1259 
  1260 definitionClass
  1261     ^ definitionClass
  1262 
  1263     "Created: / 04-09-2006 / 16:30:09 / cg"
  1264 !
  1265 
  1266 definitionClass:aClass
  1267     definitionClass := aClass.
  1268     self refetchDefinitionValues.
  1269 
  1270     "Created: / 04-09-2006 / 16:30:18 / cg"
  1271     "Modified: / 07-09-2006 / 12:26:57 / cg"
  1272 !
  1273 
  1274 specClass:aClass
  1275     super specClass:aClass.
  1276     self definitionClass:aClass theNonMetaclass.
  1277 
  1278     "Created: / 06-09-2006 / 19:24:10 / cg"
  1279 ! !
  1280 
  1281 !ProjectDefinitionEditor methodsFor:'aspects'!
  1282 
  1283 ccOptimizationFlagList
  1284     ^ #(
  1285         '-O'
  1286         '-g'
  1287     )
  1288 
  1289     "Created: / 15-10-2006 / 15:14:39 / cg"
  1290 !
  1291 
  1292 ccOptimizationFlagsHolder
  1293     ccOptimizationFlagsHolder isNil ifTrue:[
  1294         ccOptimizationFlagsHolder := ValueHolder new.
  1295     ].
  1296     ^ ccOptimizationFlagsHolder
  1297 
  1298     "Created: / 15-10-2006 / 15:13:14 / cg"
  1299 !
  1300 
  1301 classListHolder
  1302     classListHolder isNil ifTrue:[
  1303 	classListHolder := #() asValue.
  1304     ].
  1305     ^ classListHolder.
  1306 
  1307     "Created: / 07-09-2006 / 11:34:35 / cg"
  1308 !
  1309 
  1310 classesTableColumns
  1311     classesTableColumns isNil ifTrue:[
  1312 	classesTableColumns := self class classesTableColumns asValue.
  1313     ].
  1314     ^ classesTableColumns.
  1315 
  1316     "Modified: / 04-09-2006 / 17:58:09 / cg"
  1317 !
  1318 
  1319 companyNameHolder
  1320     companyNameHolder isNil ifTrue:[
  1321 	companyNameHolder := ValueHolder new.
  1322     ].
  1323     ^ companyNameHolder.
  1324 
  1325     "Created: / 04-09-2006 / 17:58:02 / cg"
  1326 !
  1327 
  1328 descriptionHolder
  1329     descriptionHolder isNil ifTrue:[
  1330 	descriptionHolder := ValueHolder new.
  1331     ].
  1332     ^ descriptionHolder.
  1333 
  1334     "Modified: / 04-09-2006 / 17:58:15 / cg"
  1335 !
  1336 
  1337 documentExtensionsListStringHolder
  1338     documentExtensionsListStringHolder isNil ifTrue:[
  1339         documentExtensionsListStringHolder := '' asValue.
  1340     ].
  1341     ^ documentExtensionsListStringHolder.
  1342 
  1343     "Created: / 15-10-2006 / 14:32:29 / cg"
  1344 !
  1345 
  1346 extensionsListHolder
  1347     extensionsListHolder isNil ifTrue:[
  1348 	extensionsListHolder := #() asValue.
  1349     ].
  1350     ^ extensionsListHolder.
  1351 
  1352     "Created: / 07-09-2006 / 11:34:50 / cg"
  1353 !
  1354 
  1355 fileDescriptionHolder
  1356     fileDescriptionHolder isNil ifTrue:[
  1357 	fileDescriptionHolder := ValueHolder new.
  1358     ].
  1359     ^ fileDescriptionHolder.
  1360 
  1361     "Modified: / 04-09-2006 / 17:58:19 / cg"
  1362 !
  1363 
  1364 fileMajorVersionNrHolder
  1365     "automatically generated by UIPainter ..."
  1366 
  1367     "*** the code below creates a default model when invoked."
  1368     "*** (which may not be the one you wanted)"
  1369     "*** Please change as required and accept it in the browser."
  1370     "*** (and replace this comment by something more useful ;-)"
  1371 
  1372     fileMajorVersionNrHolder isNil ifTrue:[
  1373 	fileMajorVersionNrHolder := ValueHolder new.
  1374 "/ if your app needs to be notified of changes, uncomment one of the lines below:
  1375 "/       fileMajorVersionNrHolder addDependent:self.
  1376 "/       fileMajorVersionNrHolder onChangeSend:#fileMajorVersionNrHolderChanged to:self.
  1377     ].
  1378     ^ fileMajorVersionNrHolder.
  1379 !
  1380 
  1381 fileMinorVersionNrHolder
  1382     "automatically generated by UIPainter ..."
  1383 
  1384     "*** the code below creates a default model when invoked."
  1385     "*** (which may not be the one you wanted)"
  1386     "*** Please change as required and accept it in the browser."
  1387     "*** (and replace this comment by something more useful ;-)"
  1388 
  1389     fileMinorVersionNrHolder isNil ifTrue:[
  1390 	fileMinorVersionNrHolder := ValueHolder new.
  1391 "/ if your app needs to be notified of changes, uncomment one of the lines below:
  1392 "/       fileMinorVersionNrHolder addDependent:self.
  1393 "/       fileMinorVersionNrHolder onChangeSend:#fileMinorVersionNrHolderChanged to:self.
  1394     ].
  1395     ^ fileMinorVersionNrHolder.
  1396 !
  1397 
  1398 fileReleaseNrHolder
  1399     "automatically generated by UIPainter ..."
  1400 
  1401     "*** the code below creates a default model when invoked."
  1402     "*** (which may not be the one you wanted)"
  1403     "*** Please change as required and accept it in the browser."
  1404     "*** (and replace this comment by something more useful ;-)"
  1405 
  1406     fileReleaseNrHolder isNil ifTrue:[
  1407 	fileReleaseNrHolder := ValueHolder new.
  1408 "/ if your app needs to be notified of changes, uncomment one of the lines below:
  1409 "/       fileReleaseNrHolder addDependent:self.
  1410 "/       fileReleaseNrHolder onChangeSend:#fileReleaseNrHolderChanged to:self.
  1411     ].
  1412     ^ fileReleaseNrHolder.
  1413 !
  1414 
  1415 fileRevisionNrHolder
  1416     "automatically generated by UIPainter ..."
  1417 
  1418     "*** the code below creates a default model when invoked."
  1419     "*** (which may not be the one you wanted)"
  1420     "*** Please change as required and accept it in the browser."
  1421     "*** (and replace this comment by something more useful ;-)"
  1422 
  1423     fileRevisionNrHolder isNil ifTrue:[
  1424 	fileRevisionNrHolder := ValueHolder new.
  1425 "/ if your app needs to be notified of changes, uncomment one of the lines below:
  1426 "/       fileRevisionNrHolder addDependent:self.
  1427 "/       fileRevisionNrHolder onChangeSend:#fileRevisionNrHolderChanged to:self.
  1428     ].
  1429     ^ fileRevisionNrHolder.
  1430 !
  1431 
  1432 hasConsoleHolder
  1433     hasConsoleHolder isNil ifTrue:[
  1434         hasConsoleHolder := false asValue
  1435     ].
  1436     ^ hasConsoleHolder.
  1437 
  1438     "Created: / 20-09-2006 / 14:39:18 / cg"
  1439 !
  1440 
  1441 iconFileNameHolder
  1442     iconFileNameHolder isNil ifTrue:[
  1443 	iconFileNameHolder := ValueHolder new.
  1444     ].
  1445     ^ iconFileNameHolder.
  1446 
  1447     "Created: / 04-09-2006 / 18:01:22 / cg"
  1448 !
  1449 
  1450 isApplicationDefinitionHolder
  1451     isApplicationDefinitionHolder isNil ifTrue:[
  1452 	isApplicationDefinitionHolder := false asValue
  1453     ].
  1454     ^ isApplicationDefinitionHolder.
  1455 
  1456     "Created: / 04-09-2006 / 19:22:47 / cg"
  1457 !
  1458 
  1459 isGUIApplicationHolder
  1460     ^ BlockValue forLogicalNot:self isNonGUIApplicationHolder
  1461 
  1462     "Created: / 20-09-2006 / 14:38:32 / cg"
  1463 !
  1464 
  1465 isNonGUIApplicationHolder
  1466     isNonGUIApplicationHolder isNil ifTrue:[
  1467         isNonGUIApplicationHolder := false asValue.
  1468         isNonGUIApplicationHolder addDependent:self.
  1469     ].
  1470     ^ isNonGUIApplicationHolder.
  1471 
  1472     "Created: / 05-09-2006 / 13:34:31 / cg"
  1473     "Modified: / 15-10-2006 / 14:00:03 / cg"
  1474 !
  1475 
  1476 legalCopyrightHolder
  1477     "automatically generated by UIPainter ..."
  1478 
  1479     "*** the code below creates a default model when invoked."
  1480     "*** (which may not be the one you wanted)"
  1481     "*** Please change as required and accept it in the browser."
  1482     "*** (and replace this comment by something more useful ;-)"
  1483 
  1484     legalCopyrightHolder isNil ifTrue:[
  1485 	legalCopyrightHolder := ValueHolder new.
  1486 "/ if your app needs to be notified of changes, uncomment one of the lines below:
  1487 "/       legalCopyrightHolder addDependent:self.
  1488 "/       legalCopyrightHolder onChangeSend:#legalCopyrightHolderChanged to:self.
  1489     ].
  1490     ^ legalCopyrightHolder.
  1491 !
  1492 
  1493 majorVersionNrHolder
  1494     "automatically generated by UIPainter ..."
  1495 
  1496     "*** the code below creates a default model when invoked."
  1497     "*** (which may not be the one you wanted)"
  1498     "*** Please change as required and accept it in the browser."
  1499     "*** (and replace this comment by something more useful ;-)"
  1500 
  1501     majorVersionNrHolder isNil ifTrue:[
  1502 	majorVersionNrHolder := ValueHolder new.
  1503 "/ if your app needs to be notified of changes, uncomment one of the lines below:
  1504 "/       majorVersionNrHolder addDependent:self.
  1505 "/       majorVersionNrHolder onChangeSend:#majorVersionNrHolderChanged to:self.
  1506     ].
  1507     ^ majorVersionNrHolder.
  1508 !
  1509 
  1510 minorVersionNrHolder
  1511     "automatically generated by UIPainter ..."
  1512 
  1513     "*** the code below creates a default model when invoked."
  1514     "*** (which may not be the one you wanted)"
  1515     "*** Please change as required and accept it in the browser."
  1516     "*** (and replace this comment by something more useful ;-)"
  1517 
  1518     minorVersionNrHolder isNil ifTrue:[
  1519 	minorVersionNrHolder := ValueHolder new.
  1520 "/ if your app needs to be notified of changes, uncomment one of the lines below:
  1521 "/       minorVersionNrHolder addDependent:self.
  1522 "/       minorVersionNrHolder onChangeSend:#minorVersionNrHolderChanged to:self.
  1523     ].
  1524     ^ minorVersionNrHolder.
  1525 !
  1526 
  1527 prerequisitesListHolder
  1528     prerequisitesListHolder isNil ifTrue:[
  1529 	prerequisitesListHolder := #() asValue.
  1530     ].
  1531     ^ prerequisitesListHolder.
  1532 
  1533     "Created: / 07-09-2006 / 11:35:03 / cg"
  1534 !
  1535 
  1536 productNameHolder
  1537     "automatically generated by UIPainter ..."
  1538 
  1539     "*** the code below creates a default model when invoked."
  1540     "*** (which may not be the one you wanted)"
  1541     "*** Please change as required and accept it in the browser."
  1542     "*** (and replace this comment by something more useful ;-)"
  1543 
  1544     productNameHolder isNil ifTrue:[
  1545 	productNameHolder := ValueHolder new.
  1546 "/ if your app needs to be notified of changes, uncomment one of the lines below:
  1547 "/       productNameHolder addDependent:self.
  1548 "/       productNameHolder onChangeSend:#productNameHolderChanged to:self.
  1549     ].
  1550     ^ productNameHolder.
  1551 !
  1552 
  1553 releaseNrHolder
  1554     "automatically generated by UIPainter ..."
  1555 
  1556     "*** the code below creates a default model when invoked."
  1557     "*** (which may not be the one you wanted)"
  1558     "*** Please change as required and accept it in the browser."
  1559     "*** (and replace this comment by something more useful ;-)"
  1560 
  1561     releaseNrHolder isNil ifTrue:[
  1562 	releaseNrHolder := ValueHolder new.
  1563 "/ if your app needs to be notified of changes, uncomment one of the lines below:
  1564 "/       releaseNrHolder addDependent:self.
  1565 "/       releaseNrHolder onChangeSend:#releaseNrHolderChanged to:self.
  1566     ].
  1567     ^ releaseNrHolder.
  1568 !
  1569 
  1570 revisionNrHolder
  1571     "automatically generated by UIPainter ..."
  1572 
  1573     "*** the code below creates a default model when invoked."
  1574     "*** (which may not be the one you wanted)"
  1575     "*** Please change as required and accept it in the browser."
  1576     "*** (and replace this comment by something more useful ;-)"
  1577 
  1578     revisionNrHolder isNil ifTrue:[
  1579 	revisionNrHolder := ValueHolder new.
  1580 "/ if your app needs to be notified of changes, uncomment one of the lines below:
  1581 "/       revisionNrHolder addDependent:self.
  1582 "/       revisionNrHolder onChangeSend:#revisionNrHolderChanged to:self.
  1583     ].
  1584     ^ revisionNrHolder.
  1585 !
  1586 
  1587 selectedClassIndexHolder
  1588     "automatically generated by UIPainter ..."
  1589 
  1590     "*** the code below creates a default model when invoked."
  1591     "*** (which may not be the one you wanted)"
  1592     "*** Please change as required and accept it in the browser."
  1593     "*** (and replace this comment by something more useful ;-)"
  1594 
  1595     selectedClassIndexHolder isNil ifTrue:[
  1596 	selectedClassIndexHolder := ValueHolder new.
  1597 "/ if your app needs to be notified of changes, uncomment one of the lines below:
  1598 "/       selectedClassIndexHolder addDependent:self.
  1599 "/       selectedClassIndexHolder onChangeSend:#selectedClassIndexHolderChanged to:self.
  1600     ].
  1601     ^ selectedClassIndexHolder.
  1602 !
  1603 
  1604 shownHasConsoleHolder
  1605     shownHasConsoleHolder isNil ifTrue:[
  1606         shownHasConsoleHolder := IndirectValue for:self hasConsoleHolder.
  1607     ].
  1608     ^ shownHasConsoleHolder
  1609 
  1610     "Created: / 15-10-2006 / 13:59:01 / cg"
  1611 !
  1612 
  1613 shownHasConsoleValue
  1614     ^ BlockValue 
  1615         with:[:m1 :m2 | self isGUIApplicationHolder value not
  1616                         or:[ self hasConsoleHolder value] ]
  1617         argument:(self hasConsoleHolder)
  1618         argument:(self isGUIApplicationHolder).
  1619 
  1620     "Created: / 15-10-2006 / 13:54:16 / cg"
  1621 !
  1622 
  1623 startSinglethreadedHolder
  1624     startSinglethreadedHolder isNil ifTrue:[
  1625 	startSinglethreadedHolder := false asValue.
  1626     ].
  1627     ^ startSinglethreadedHolder.
  1628 
  1629     "Created: / 05-09-2006 / 13:34:54 / cg"
  1630 !
  1631 
  1632 startupClassNameHolder
  1633     startupClassNameHolder isNil ifTrue:[
  1634 	startupClassNameHolder := '' asValue.
  1635     ].
  1636     ^ startupClassNameHolder.
  1637 
  1638     "Created: / 06-09-2006 / 18:41:52 / cg"
  1639 !
  1640 
  1641 startupSelectorHolder
  1642     startupSelectorHolder isNil ifTrue:[
  1643 	startupSelectorHolder := '' asValue.
  1644     ].
  1645     ^ startupSelectorHolder.
  1646 
  1647     "Created: / 05-09-2006 / 13:34:20 / cg"
  1648 !
  1649 
  1650 stcOptimizationFlagList
  1651     ^ #(
  1652         '+optSpace'
  1653         '+optSpace2'
  1654         '+optSpace3'
  1655         '+optInline'
  1656         '-optInline'
  1657         '-inlineNew'
  1658         '-inlineNot'
  1659     )
  1660 
  1661     "Created: / 15-10-2006 / 15:14:29 / cg"
  1662 !
  1663 
  1664 stcOptimizationFlagsHolder
  1665     stcOptimizationFlagsHolder isNil ifTrue:[
  1666         stcOptimizationFlagsHolder := ValueHolder new.
  1667     ].
  1668     ^ stcOptimizationFlagsHolder
  1669 
  1670     "Modified: / 15-10-2006 / 15:13:10 / cg"
  1671 !
  1672 
  1673 tabList
  1674     "Generated by the TabListEditor"
  1675 
  1676     |list|
  1677 
  1678     (list := builder bindingAt:#tabList) isNil ifTrue:[
  1679 	builder aspectAt:#tabList put:(list := self class tabListForApplication asValue).
  1680     ].
  1681     ^ list
  1682 
  1683     "Modified: / 06-09-2006 / 17:58:08 / cg"
  1684 ! !
  1685 
  1686 !ProjectDefinitionEditor methodsFor:'aspects-menu'!
  1687 
  1688 classesMenuVisibleHolder
  1689     ^ builder booleanValueAspectFor:#'classesMenuVisibleHolder'
  1690 
  1691     "Modified: / 03-09-2006 / 10:57:00 / cg"
  1692 !
  1693 
  1694 extensionsMenuVisibleHolder
  1695     ^ builder booleanValueAspectFor:#'extensionsMenuVisibleHolder'
  1696 
  1697     "Created: / 05-09-2006 / 13:03:16 / cg"
  1698 !
  1699 
  1700 hasDefinitionClass
  1701     ^ definitionClass notNil
  1702 
  1703     "Created: / 07-09-2006 / 12:29:10 / cg"
  1704 !
  1705 
  1706 hasDefinitionClassHolder
  1707     ^ [ self hasDefinitionClass ]
  1708 
  1709     "Created: / 07-09-2006 / 12:29:22 / cg"
  1710 !
  1711 
  1712 prerequisitesMenuVisibleHolder
  1713     ^ builder booleanValueAspectFor:#'prerequisitesMenuVisibleHolder'
  1714 
  1715     "Created: / 05-09-2006 / 13:26:45 / cg"
  1716 !
  1717 
  1718 selectedTabIndexHolder
  1719     |h|
  1720 
  1721     h := builder valueAspectFor:#'selectedTabIndexHolder' initialValue:nil.
  1722     h addDependent:self.
  1723     ^ h
  1724 
  1725     "Created: / 03-09-2006 / 10:58:05 / cg"
  1726 ! !
  1727 
  1728 !ProjectDefinitionEditor methodsFor:'change & update'!
  1729 
  1730 fetchClassListEntries
  1731     |entries|
  1732 
  1733     entries := OrderedCollection new.
  1734     definitionClass
  1735         classNamesAndAttributesDo:[:className :attributes |
  1736             |entry|
  1737 
  1738             entry := ClassListEntry new.
  1739             entry
  1740                 className:className
  1741                 autoloaded:(attributes includes:#autoload)
  1742                 win32:(attributes includes:#win32)
  1743                 unix:(attributes includes:#unix).
  1744             entries add:entry.
  1745         ].
  1746     entries sort:[:a :b | a className < b className].
  1747     ^ entries.
  1748 
  1749     "Created: / 05-09-2006 / 12:31:26 / cg"
  1750     "Modified: / 21-11-2006 / 18:04:35 / cg"
  1751 !
  1752 
  1753 fetchExtensionsListEntries
  1754     |entries|
  1755 
  1756     entries := OrderedCollection new.
  1757     definitionClass
  1758 	extensionMethodNames pairWiseDo:[:className :selector |
  1759 	    |entry|
  1760 
  1761 	    entry := ExtensionsListEntry new.
  1762 	    entry className:className selector:selector.
  1763 	    entries add:entry.
  1764 	].
  1765 
  1766     ^ entries.
  1767 
  1768     "Created: / 06-09-2006 / 18:45:15 / cg"
  1769 !
  1770 
  1771 fetchPrerequisitesListEntries
  1772     |entries|
  1773 
  1774     entries := OrderedCollection new.
  1775     definitionClass
  1776 	preRequisites do:[:packageName |
  1777 	    |entry|
  1778 
  1779 	    entry := PrerequisitesListEntry new.
  1780 	    entry package:packageName.
  1781 	    entries add:entry.
  1782 	].
  1783 
  1784     ^ entries.
  1785 
  1786     "Created: / 06-09-2006 / 18:45:15 / cg"
  1787     "Modified: / 07-09-2006 / 12:36:21 / cg"
  1788 !
  1789 
  1790 fetchValues
  1791     |definitionClass isApplicationDefinition startupClassName startupSelector|
  1792 
  1793     definitionClass := self definitionClass.
  1794     definitionClass isNil ifTrue:[^ self ].
  1795 
  1796     isApplicationDefinition := definitionClass isApplicationDefinition.
  1797 
  1798     self isApplicationDefinitionHolder value:isApplicationDefinition.
  1799     self isNonGUIApplicationHolder value:(isApplicationDefinition and:[definitionClass isGUIApplication not]).
  1800     self hasConsoleHolder value:(isApplicationDefinition and:[definitionClass isConsoleApplication]).
  1801     self startSinglethreadedHolder value:(isApplicationDefinition and:[definitionClass isSingleThreadedApplication]).
  1802 
  1803     isApplicationDefinition ifTrue:[
  1804         startupClassName := definitionClass name.
  1805         startupSelector := #start.
  1806 
  1807         Error handle:[:ex | ] do:[ startupClassName := definitionClass startupClassName].
  1808         Error handle:[:ex | ] do:[ startupSelector := definitionClass startupSelector].
  1809         self startupClassNameHolder value:startupClassName.
  1810         self startupSelectorHolder value:startupSelector.
  1811 
  1812         self iconFileNameHolder value:(definitionClass applicationIconFileName).
  1813         self tabList value:(self class tabListForApplication).
  1814         self documentExtensionsListStringHolder value:(definitionClass documentExtensions asStringWith:';').
  1815     ] ifFalse:[
  1816         self tabList value:(self class tabListForLibrary).
  1817     ].
  1818 
  1819     self companyNameHolder value:(definitionClass companyName).
  1820     self descriptionHolder value:(definitionClass description).
  1821     self legalCopyrightHolder value:(definitionClass legalCopyright).
  1822     self productNameHolder value:(definitionClass productName).
  1823     self majorVersionNrHolder value:(definitionClass majorVersionNr asInteger).
  1824     self minorVersionNrHolder value:(definitionClass minorVersionNr asInteger).
  1825     self revisionNrHolder value:(definitionClass revisionNr asInteger).
  1826     self releaseNrHolder value:(definitionClass releaseNr asInteger).
  1827 
  1828     self fileDescriptionHolder value:(definitionClass fileDescription).
  1829     self fileMajorVersionNrHolder value:(definitionClass fileMajorVersionNr asInteger).
  1830     self fileMinorVersionNrHolder value:(definitionClass fileMinorVersionNr asInteger).
  1831     self fileRevisionNrHolder value:(definitionClass fileRevisionNr asInteger).
  1832     self fileReleaseNrHolder value:(definitionClass fileReleaseNr asInteger).
  1833 
  1834     self classListHolder value:(self fetchClassListEntries).
  1835     self extensionsListHolder value:(self fetchExtensionsListEntries).
  1836     self prerequisitesListHolder value:(self fetchPrerequisitesListEntries).
  1837 
  1838     self window notNil ifTrue:[
  1839         self window
  1840             label:(isApplicationDefinition
  1841                     ifTrue:'Application'
  1842                     ifFalse:'Library' )
  1843                         , ' Definition: ',definitionClass name.
  1844     ].
  1845 
  1846     "Created: / 04-09-2006 / 16:34:39 / cg"
  1847     "Modified: / 15-10-2006 / 14:32:45 / cg"
  1848 !
  1849 
  1850 refetchDefinitionValues
  1851     self isApplicationDefinitionHolder value:( definitionClass isApplicationDefinition ).
  1852     self fetchValues.
  1853 
  1854     "Created: / 07-09-2006 / 12:26:54 / cg"
  1855 !
  1856 
  1857 update:something with:parameter from:changedObject
  1858     changedObject == self selectedTabIndexHolder ifTrue:[
  1859         self updateMenuVisibility.
  1860         ^ self.
  1861     ].
  1862     changedObject == self isNonGUIApplicationHolder ifTrue:[
  1863         changedObject value ifTrue:[
  1864             "/ a NON-GUI application - always has a console
  1865             self shownHasConsoleHolder valueHolder:true
  1866         ] ifFalse:[
  1867             "/ a GUI application - sometimes has a console
  1868             self shownHasConsoleHolder valueHolder:(self hasConsoleHolder)
  1869         ].
  1870         ^ self.
  1871     ].
  1872     ^ super update:something with:parameter from:changedObject
  1873 
  1874     "Created: / 03-09-2006 / 10:59:42 / cg"
  1875     "Modified: / 15-10-2006 / 14:08:23 / cg"
  1876 !
  1877 
  1878 updateMenuVisibility
  1879     self classesMenuVisibleHolder value:(self hasClassesTabSelected).
  1880     self extensionsMenuVisibleHolder value:(self hasExtensionsTabSelected).
  1881     self prerequisitesMenuVisibleHolder value:(self hasPrerequisitesTabSelected).
  1882 
  1883     "Created: / 03-09-2006 / 11:01:48 / cg"
  1884     "Modified: / 05-09-2006 / 13:27:10 / cg"
  1885 ! !
  1886 
  1887 !ProjectDefinitionEditor methodsFor:'initialization & release'!
  1888 
  1889 closeRequest
  1890     (self hasUnsavedChanges) ifTrue:[
  1891 	(self confirm:(resources string:'Close without saving ?')) ifFalse:[
  1892 	    ^ self
  1893 	]
  1894     ].
  1895 
  1896     ^ super closeRequest
  1897 
  1898     "Modified: / 03-09-2006 / 10:53:14 / cg"
  1899 !
  1900 
  1901 flagHolderBuilt:aComboBox
  1902     aComboBox menuSelectAction:[:txt |
  1903         self updateFlagsIn:aComboBox from:txt
  1904     ].
  1905 
  1906     "Created: / 15-10-2006 / 15:11:50 / cg"
  1907 !
  1908 
  1909 postBuildWith:aBuilder
  1910     super postBuildWith:aBuilder.
  1911     self selectedTabIndexHolder value:1.
  1912     self updateMenuVisibility.
  1913     self fetchValues.
  1914 
  1915     "Modified: / 04-09-2006 / 16:28:09 / cg"
  1916 !
  1917 
  1918 postOpenWith:aBuilder
  1919     "This is a hook method generated by the Browser.
  1920      It will be invoked right after the applications window has been opened.
  1921      Add any app-specific actions here (starting background processes etc.).
  1922      See also #postBuildWith:, which is invoked before opening."
  1923 
  1924     "/ add any code here ...
  1925 
  1926     ^ super postOpenWith:aBuilder
  1927 ! !
  1928 
  1929 !ProjectDefinitionEditor methodsFor:'menu actions'!
  1930 
  1931 editNew:definitionClass
  1932     |className class newPackage|
  1933 
  1934     self hasUnsavedChanges ifTrue:[
  1935         self halt.
  1936     ].
  1937     className := Dialog
  1938                     requestClassName:'Name of new Definition class'
  1939                     okLabel:'Create'
  1940                     initialAnswer:'private_myProject'.
  1941     className isEmptyOrNil ifTrue:[^ self].
  1942 
  1943     class := Smalltalk classNamed:className.
  1944     class notNil ifTrue:[
  1945         (class isLibraryDefinition == (definitionClass == LibraryDefinition)) ifFalse:[
  1946             Dialog warn:(resources
  1947                             string:'A class named "%1" already exists as %2.'
  1948                             with:className allBold
  1949                             with:(class isLibraryDefinition 
  1950                                     ifTrue:'Library'
  1951                                     ifFalse:'Application')).
  1952             ^ self
  1953         ].
  1954         Dialog warn:(resources
  1955                             string:'A class named "%1" already exists. Editing the existing definition.'
  1956                             with:className allBold).
  1957     ] ifFalse:[
  1958         newPackage := className copy replaceAll:$_ with:$/.
  1959         newPackage replaceAll:$/ with:$:. 
  1960         class := definitionClass newNamed:className package:newPackage.
  1961     ].
  1962     self definitionClass:class.
  1963 
  1964     "Created: / 15-10-2006 / 14:50:15 / cg"
  1965 !
  1966 
  1967 menuGenerateProjectDefinitions
  1968     |action|
  1969 
  1970     action := [:generator :defClass |
  1971 		    defClass theNonMetaclass
  1972 			forEachMethodsCodeToCompileDo:
  1973 			    [:code :category |
  1974 				generator
  1975 				    compile:code
  1976 				    forClass:defClass theMetaclass
  1977 				    inCategory:category.
  1978 			    ]
  1979 			ignoreOldDefinition:true
  1980 	       ].
  1981 
  1982     masterApplication notNil ifTrue:[
  1983 	masterApplication
  1984 	    generateUndoableChange:'Generate Project Definitions'
  1985 	    overClasses:(Array with:self definitionClass)
  1986 	    via:action.
  1987     ] ifFalse:[
  1988 	action value:Compiler value:self definitionClass
  1989     ].
  1990 
  1991     self refetchDefinitionValues
  1992 
  1993     "Created: / 07-09-2006 / 12:26:22 / cg"
  1994 !
  1995 
  1996 menuNew
  1997     "This method was generated by the Browser.
  1998      It will be invoked when the menu-item 'new' is selected."
  1999 
  2000     "/ change below and add any actions as required here ...
  2001     self warn:'no action for ''new'' available.'.
  2002 !
  2003 
  2004 menuNewApplicationDefinition
  2005     self editNew:ApplicationDefinition
  2006 
  2007     "Created: / 15-10-2006 / 14:49:53 / cg"
  2008 !
  2009 
  2010 menuNewLibraryDefinition
  2011     self editNew:LibraryDefinition
  2012 
  2013     "Created: / 15-10-2006 / 14:49:46 / cg"
  2014 !
  2015 
  2016 menuOpen
  2017     |projectID class answer|
  2018 
  2019     projectID := Dialog requestProject:'Project' initialAnswer:'' suggestions:nil.
  2020     class := ProjectDefinition definitionClassForPackage:projectID.
  2021     class isNil ifTrue:[
  2022 	answer := Dialog
  2023 	    confirmWithCancel:(resources string:'No Projectdefinition class exists for "%1".\\Create ?' with:projectID allBold)
  2024 	    labels:(resources array:#('Cancel' 'Create Library' 'Create Application' ))
  2025 	    values:#(nil LibraryDefinition ApplicationDefinition)
  2026 	    default:2
  2027 	    boxLabel:(resources string:'Create Projectdefinition').
  2028 	answer isNil ifTrue:[^ self].
  2029     ].
  2030     answer == #LibraryDefinition ifTrue:[
  2031 	class := LibraryDefinition definitionClassForPackage:projectID createIfAbsent:true
  2032     ] ifFalse:[
  2033 	class := ApplicationDefinition definitionClassForPackage:projectID createIfAbsent:true
  2034     ].
  2035     self definitionClass:class.
  2036 
  2037     "Modified: / 07-09-2006 / 12:19:58 / cg"
  2038 !
  2039 
  2040 menuRemoveClass
  2041     |classListHolder|
  2042 
  2043     classListHolder := self classListHolder.
  2044     classListHolder value removeIndex:(self selectedClassIndexHolder value).
  2045     classListHolder changed.
  2046 
  2047     "Created: / 06-09-2006 / 21:31:05 / cg"
  2048     "Modified: / 07-09-2006 / 11:35:44 / cg"
  2049 !
  2050 
  2051 menuSave
  2052     self menuSaveAs:definitionClass name
  2053 
  2054     "Modified: / 05-09-2006 / 13:48:27 / cg"
  2055 !
  2056 
  2057 menuSaveAs
  2058     |className class newPackage|
  2059 
  2060     className := Dialog
  2061                     requestClassName:'Name of new Definition class'
  2062                     okLabel:'Create'
  2063                     initialAnswer:'private_myProject'.
  2064     className isEmptyOrNil ifTrue:[^ self].
  2065     class := Smalltalk classNamed:className.
  2066     class notNil ifTrue:[
  2067         Dialog warn:(resources
  2068                             string:'A class named %1 already exists'
  2069                             with:className).
  2070         ^ self.
  2071     ].
  2072     newPackage := className copy replaceAll:$_ with:$/.
  2073     newPackage replaceAll:$/ with:$:. 
  2074     class := ApplicationDefinition newNamed:className package:newPackage.
  2075     self menuSaveAs:class.
  2076 
  2077     "Modified: / 15-10-2006 / 14:47:53 / cg"
  2078 !
  2079 
  2080 menuSaveAs:aClassName
  2081     self halt.
  2082 
  2083     "Created: / 05-09-2006 / 13:48:03 / cg"
  2084 !
  2085 
  2086 openAboutThisApplication
  2087     "This method was generated by the Browser.
  2088      It will be invoked when the menu-item 'help-about' is selected."
  2089 
  2090     "/ could open a customized aboutBox here ...
  2091     super openAboutThisApplication
  2092 !
  2093 
  2094 openDocumentation
  2095     "This method was generated by the Browser.
  2096      It will be invoked when the menu-item 'help-documentation' is selected."
  2097 
  2098     "/ change below as required ...
  2099 
  2100     "/ to open an HTML viewer on some document (under 'doc/online/<language>/' ):
  2101     HTMLDocumentView openFullOnDocumentationFile:'TOP.html'.
  2102 
  2103     "/ add application-specific help files under the 'doc/online/<language>/help/appName'
  2104     "/ directory, and open a viewer with:
  2105     "/ HTMLDocumentView openFullOnDocumentationFile:'help/<MyApplication>/TOP.html'.
  2106 !
  2107 
  2108 updateFlagsIn:aComboBox from:flag
  2109     |s flags base negation|
  2110 
  2111     s := aComboBox editor contents.
  2112     flags := s asCollectionOfWords.
  2113     (flags includes:flag) ifFalse:[
  2114         base := (flag copyFrom:2).
  2115         negation := (flag startsWith:'+') 
  2116                         ifTrue:[ ('-',base) ]
  2117                         ifFalse:[ ('+',base) ].
  2118         flags remove:negation ifAbsent:[].
  2119         flags add:flag.
  2120         aComboBox editor contents:(flags asStringWith:' ').
  2121     ].
  2122 
  2123     "Created: / 15-10-2006 / 15:35:53 / cg"
  2124 ! !
  2125 
  2126 !ProjectDefinitionEditor methodsFor:'queries'!
  2127 
  2128 hasClassesTabSelected
  2129     ^ self selectedTabIndex == 2
  2130 
  2131     "Created: / 03-09-2006 / 11:00:39 / cg"
  2132     "Modified: / 06-09-2006 / 21:20:21 / cg"
  2133 !
  2134 
  2135 hasExtensionsTabSelected
  2136     ^ self selectedTabIndex == 3
  2137 
  2138     "Created: / 05-09-2006 / 13:02:26 / cg"
  2139     "Modified: / 06-09-2006 / 21:20:25 / cg"
  2140 !
  2141 
  2142 hasPrerequisitesTabSelected
  2143     ^ self selectedTabIndex == 4
  2144 
  2145     "Created: / 05-09-2006 / 13:27:16 / cg"
  2146     "Modified: / 06-09-2006 / 21:20:33 / cg"
  2147 !
  2148 
  2149 hasUnsavedChanges
  2150      ^ false
  2151 
  2152     "Created: / 03-09-2006 / 10:53:05 / cg"
  2153 !
  2154 
  2155 selectedClass
  2156     |item|
  2157 
  2158     item := self classListHolder value at:(self selectedClassIndexHolder value).
  2159 self halt.
  2160 
  2161     "Created: / 06-09-2006 / 21:32:20 / cg"
  2162     "Modified: / 07-09-2006 / 11:35:48 / cg"
  2163 !
  2164 
  2165 selectedTabIndex
  2166     ^ self selectedTabIndexHolder value
  2167 
  2168     "Created: / 03-09-2006 / 11:00:48 / cg"
  2169 ! !
  2170 
  2171 !ProjectDefinitionEditor::ClassListEntry methodsFor:'accessing'!
  2172 
  2173 autoloaded
  2174     ^ autoloaded
  2175 !
  2176 
  2177 autoloaded:aBoolean
  2178     autoloaded := aBoolean.
  2179 
  2180     "Modified: / 21-11-2006 / 18:05:26 / cg"
  2181 !
  2182 
  2183 className
  2184     ^ className
  2185 !
  2186 
  2187 className:something
  2188     className := something.
  2189 !
  2190 
  2191 className:classNameArg autoloaded:autoloadedArg win32:win32Arg unix:unixArg
  2192     className := classNameArg.
  2193     autoloaded := autoloadedArg.
  2194     win32 := win32Arg.
  2195     unix := unixArg.
  2196 !
  2197 
  2198 unix
  2199     ^ unix
  2200 !
  2201 
  2202 unix:aBoolean
  2203     unix := aBoolean.
  2204 
  2205     "Modified: / 21-11-2006 / 18:05:32 / cg"
  2206 !
  2207 
  2208 win32
  2209     ^ win32
  2210 !
  2211 
  2212 win32:aBoolean
  2213     win32 := aBoolean.
  2214 
  2215     "Modified: / 21-11-2006 / 18:05:35 / cg"
  2216 ! !
  2217 
  2218 !ProjectDefinitionEditor::ExtensionsListEntry methodsFor:'accessing'!
  2219 
  2220 className
  2221     ^ className
  2222 !
  2223 
  2224 className:classNameArg selector:selectorArg
  2225     className := classNameArg.
  2226     selector := selectorArg.
  2227 !
  2228 
  2229 selector
  2230     ^ selector
  2231 ! !
  2232 
  2233 !ProjectDefinitionEditor::PrerequisitesListEntry methodsFor:'accessing'!
  2234 
  2235 package
  2236     ^ package
  2237 
  2238     "Created: / 07-09-2006 / 12:23:17 / cg"
  2239 !
  2240 
  2241 package:something
  2242     package := something.
  2243 
  2244     "Created: / 07-09-2006 / 12:23:19 / cg"
  2245 ! !
  2246 
  2247 !ProjectDefinitionEditor class methodsFor:'documentation'!
  2248 
  2249 version
  2250     ^ '$Header$'
  2251 !
  2252 
  2253 version_CVS
  2254     ^ '$Header$'
  2255 ! !