packages/PackageDetails.st
author james
Fri, 09 May 2003 14:24:57 +0200
changeset 1268 9dc8d1b8ce9b
parent 1241 3a977bf0d483
child 1443 6dfdf336b472
permissions -rw-r--r--
Lots and lots of changes... I hope now that any changes to Smalltalk does not result in inconsistancy in the packages. I still need to redesign the class Package as it does too much. More of the responsibilities need to be put on PackagedClass and PackagedMethod. The PackageBrowser has got some nice package pictures!
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
     1
"{ Package: 'stx:libbasic3' }"
ab88e78f027c initial checkin
james
parents:
diff changeset
     2
ab88e78f027c initial checkin
james
parents:
diff changeset
     3
"{ NameSpace: Packages }"
ab88e78f027c initial checkin
james
parents:
diff changeset
     4
1268
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
     5
AbstractPackageNotebookApplication subclass:#PackageDetails
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
     6
	instanceVariableNames:''
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
     7
	classVariableNames:''
ab88e78f027c initial checkin
james
parents:
diff changeset
     8
	poolDictionaries:''
ab88e78f027c initial checkin
james
parents:
diff changeset
     9
	category:'Package-Application'
ab88e78f027c initial checkin
james
parents:
diff changeset
    10
!
ab88e78f027c initial checkin
james
parents:
diff changeset
    11
ab88e78f027c initial checkin
james
parents:
diff changeset
    12
AbstractPackageDetails subclass:#Class
ab88e78f027c initial checkin
james
parents:
diff changeset
    13
	instanceVariableNames:'classList selectedClassHolder categoryList selectedCategoryHolder
1268
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
    14
		nonCriticalPrivateProcesses'
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
    15
	classVariableNames:''
ab88e78f027c initial checkin
james
parents:
diff changeset
    16
	poolDictionaries:''
ab88e78f027c initial checkin
james
parents:
diff changeset
    17
	privateIn:PackageDetails
ab88e78f027c initial checkin
james
parents:
diff changeset
    18
!
ab88e78f027c initial checkin
james
parents:
diff changeset
    19
1241
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
    20
LabelAndIcon subclass:#ClassLabelAndIcon
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
    21
	instanceVariableNames:'class'
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
    22
	classVariableNames:''
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
    23
	poolDictionaries:''
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
    24
	privateIn:PackageDetails::Class
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
    25
!
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
    26
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
    27
AbstractPackageDetails subclass:#Comment
ab88e78f027c initial checkin
james
parents:
diff changeset
    28
	instanceVariableNames:'commentTextHolder commentTextModifiedChannel
ab88e78f027c initial checkin
james
parents:
diff changeset
    29
		commentTextAcceptChannel editTextView'
ab88e78f027c initial checkin
james
parents:
diff changeset
    30
	classVariableNames:''
ab88e78f027c initial checkin
james
parents:
diff changeset
    31
	poolDictionaries:''
ab88e78f027c initial checkin
james
parents:
diff changeset
    32
	privateIn:PackageDetails
ab88e78f027c initial checkin
james
parents:
diff changeset
    33
!
ab88e78f027c initial checkin
james
parents:
diff changeset
    34
ab88e78f027c initial checkin
james
parents:
diff changeset
    35
AbstractPackageDetails subclass:#LooseMethod
ab88e78f027c initial checkin
james
parents:
diff changeset
    36
	instanceVariableNames:'methodSelectedHolder currentMethodSourceHolder methodList
ab88e78f027c initial checkin
james
parents:
diff changeset
    37
		tableColumns'
ab88e78f027c initial checkin
james
parents:
diff changeset
    38
	classVariableNames:''
ab88e78f027c initial checkin
james
parents:
diff changeset
    39
	poolDictionaries:''
ab88e78f027c initial checkin
james
parents:
diff changeset
    40
	privateIn:PackageDetails
ab88e78f027c initial checkin
james
parents:
diff changeset
    41
!
ab88e78f027c initial checkin
james
parents:
diff changeset
    42
ab88e78f027c initial checkin
james
parents:
diff changeset
    43
Object subclass:#PackageDetailsRow
ab88e78f027c initial checkin
james
parents:
diff changeset
    44
	instanceVariableNames:'model'
ab88e78f027c initial checkin
james
parents:
diff changeset
    45
	classVariableNames:''
ab88e78f027c initial checkin
james
parents:
diff changeset
    46
	poolDictionaries:''
ab88e78f027c initial checkin
james
parents:
diff changeset
    47
	privateIn:PackageDetails::LooseMethod
ab88e78f027c initial checkin
james
parents:
diff changeset
    48
!
ab88e78f027c initial checkin
james
parents:
diff changeset
    49
ab88e78f027c initial checkin
james
parents:
diff changeset
    50
AbstractPackageDetails subclass:#Prerequisites
ab88e78f027c initial checkin
james
parents:
diff changeset
    51
	instanceVariableNames:''
ab88e78f027c initial checkin
james
parents:
diff changeset
    52
	classVariableNames:''
ab88e78f027c initial checkin
james
parents:
diff changeset
    53
	poolDictionaries:''
ab88e78f027c initial checkin
james
parents:
diff changeset
    54
	privateIn:PackageDetails
ab88e78f027c initial checkin
james
parents:
diff changeset
    55
!
ab88e78f027c initial checkin
james
parents:
diff changeset
    56
ab88e78f027c initial checkin
james
parents:
diff changeset
    57
AbstractPackageDetails subclass:#Scripts
ab88e78f027c initial checkin
james
parents:
diff changeset
    58
	instanceVariableNames:''
ab88e78f027c initial checkin
james
parents:
diff changeset
    59
	classVariableNames:''
ab88e78f027c initial checkin
james
parents:
diff changeset
    60
	poolDictionaries:''
ab88e78f027c initial checkin
james
parents:
diff changeset
    61
	privateIn:PackageDetails
ab88e78f027c initial checkin
james
parents:
diff changeset
    62
!
ab88e78f027c initial checkin
james
parents:
diff changeset
    63
ab88e78f027c initial checkin
james
parents:
diff changeset
    64
ab88e78f027c initial checkin
james
parents:
diff changeset
    65
!PackageDetails::Class class methodsFor:'constant values'!
ab88e78f027c initial checkin
james
parents:
diff changeset
    66
ab88e78f027c initial checkin
james
parents:
diff changeset
    67
applicationName
ab88e78f027c initial checkin
james
parents:
diff changeset
    68
    ^ 'Classes' asSymbol
ab88e78f027c initial checkin
james
parents:
diff changeset
    69
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
    70
ab88e78f027c initial checkin
james
parents:
diff changeset
    71
!PackageDetails::Class class methodsFor:'interface specs'!
ab88e78f027c initial checkin
james
parents:
diff changeset
    72
ab88e78f027c initial checkin
james
parents:
diff changeset
    73
windowSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
    74
    "This resource specification was automatically generated
ab88e78f027c initial checkin
james
parents:
diff changeset
    75
     by the UIPainter of ST/X."
ab88e78f027c initial checkin
james
parents:
diff changeset
    76
ab88e78f027c initial checkin
james
parents:
diff changeset
    77
    "Do not manually edit this!! If it is corrupted,
ab88e78f027c initial checkin
james
parents:
diff changeset
    78
     the UIPainter may not be able to read the specification."
ab88e78f027c initial checkin
james
parents:
diff changeset
    79
ab88e78f027c initial checkin
james
parents:
diff changeset
    80
    "
ab88e78f027c initial checkin
james
parents:
diff changeset
    81
     UIPainter new openOnClass:Packages::PackageDetails::Class andSelector:#windowSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
    82
     Packages::PackageDetails::Class new openInterface:#windowSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
    83
     Packages::PackageDetails::Class open
ab88e78f027c initial checkin
james
parents:
diff changeset
    84
    "
ab88e78f027c initial checkin
james
parents:
diff changeset
    85
ab88e78f027c initial checkin
james
parents:
diff changeset
    86
    <resource: #canvas>
ab88e78f027c initial checkin
james
parents:
diff changeset
    87
ab88e78f027c initial checkin
james
parents:
diff changeset
    88
    ^ 
ab88e78f027c initial checkin
james
parents:
diff changeset
    89
     #(#FullSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
    90
        #name: #windowSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
    91
        #window: 
ab88e78f027c initial checkin
james
parents:
diff changeset
    92
       #(#WindowSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
    93
          #label: 'Packages::PackageDetails::Class'
ab88e78f027c initial checkin
james
parents:
diff changeset
    94
          #name: 'Packages::PackageDetails::Class'
ab88e78f027c initial checkin
james
parents:
diff changeset
    95
          #visibilityChannel: #isVisible
ab88e78f027c initial checkin
james
parents:
diff changeset
    96
          #min: #(#Point 10 10)
ab88e78f027c initial checkin
james
parents:
diff changeset
    97
          #max: #(#Point 1024 768)
ab88e78f027c initial checkin
james
parents:
diff changeset
    98
          #bounds: #(#Rectangle 29 59 329 359)
ab88e78f027c initial checkin
james
parents:
diff changeset
    99
          #menu: #mainMenu
ab88e78f027c initial checkin
james
parents:
diff changeset
   100
        )
ab88e78f027c initial checkin
james
parents:
diff changeset
   101
        #component: 
ab88e78f027c initial checkin
james
parents:
diff changeset
   102
       #(#SpecCollection
ab88e78f027c initial checkin
james
parents:
diff changeset
   103
          #collection: #(
ab88e78f027c initial checkin
james
parents:
diff changeset
   104
           #(#VariableHorizontalPanelSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
   105
              #name: 'VariableHorizontalPanel1'
ab88e78f027c initial checkin
james
parents:
diff changeset
   106
              #layout: #(#LayoutFrame 0 0 0 0 0 1 0 1)
ab88e78f027c initial checkin
james
parents:
diff changeset
   107
              #component: 
ab88e78f027c initial checkin
james
parents:
diff changeset
   108
             #(#SpecCollection
ab88e78f027c initial checkin
james
parents:
diff changeset
   109
                #collection: #(
1241
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   110
                 #(#SequenceViewSpec
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   111
                    #name: 'SelectionInListModelView2'
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
   112
                    #model: #selectedCategoryHolder
ab88e78f027c initial checkin
james
parents:
diff changeset
   113
                    #hasHorizontalScrollBar: true
ab88e78f027c initial checkin
james
parents:
diff changeset
   114
                    #hasVerticalScrollBar: true
1241
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   115
                    #isMultiSelect: true
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
   116
                    #useIndex: false
1241
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   117
                    #sequenceList: #categoryList
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
   118
                  )
1241
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   119
                 #(#SequenceViewSpec
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   120
                    #name: 'SelectedClassView1'
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
   121
                    #model: #selectedClassHolder
ab88e78f027c initial checkin
james
parents:
diff changeset
   122
                    #hasHorizontalScrollBar: true
ab88e78f027c initial checkin
james
parents:
diff changeset
   123
                    #hasVerticalScrollBar: true
1241
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   124
                    #isMultiSelect: true
1268
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   125
                    #doubleClickSelector: #browseClassWithIndexes:
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   126
                    #useIndex: true
1241
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   127
                    #sequenceList: #classList
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
   128
                  )
ab88e78f027c initial checkin
james
parents:
diff changeset
   129
                 )
ab88e78f027c initial checkin
james
parents:
diff changeset
   130
               
ab88e78f027c initial checkin
james
parents:
diff changeset
   131
              )
ab88e78f027c initial checkin
james
parents:
diff changeset
   132
              #handles: #(#Any 0.5 1.0)
ab88e78f027c initial checkin
james
parents:
diff changeset
   133
            )
ab88e78f027c initial checkin
james
parents:
diff changeset
   134
           )
ab88e78f027c initial checkin
james
parents:
diff changeset
   135
         
ab88e78f027c initial checkin
james
parents:
diff changeset
   136
        )
ab88e78f027c initial checkin
james
parents:
diff changeset
   137
      )
ab88e78f027c initial checkin
james
parents:
diff changeset
   138
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
   139
ab88e78f027c initial checkin
james
parents:
diff changeset
   140
!PackageDetails::Class class methodsFor:'menu specs'!
ab88e78f027c initial checkin
james
parents:
diff changeset
   141
ab88e78f027c initial checkin
james
parents:
diff changeset
   142
mainMenu
ab88e78f027c initial checkin
james
parents:
diff changeset
   143
    "This resource specification was automatically generated by the CodeGeneratorTool."
ab88e78f027c initial checkin
james
parents:
diff changeset
   144
ab88e78f027c initial checkin
james
parents:
diff changeset
   145
    "Do not manually edit this!! If it is corrupted,
ab88e78f027c initial checkin
james
parents:
diff changeset
   146
     the MenuEditor may not be able to read the specification."
ab88e78f027c initial checkin
james
parents:
diff changeset
   147
ab88e78f027c initial checkin
james
parents:
diff changeset
   148
    "
ab88e78f027c initial checkin
james
parents:
diff changeset
   149
     MenuEditor new openOnClass:Packages::PackageDetails::Class andSelector:#mainMenu
ab88e78f027c initial checkin
james
parents:
diff changeset
   150
    "
ab88e78f027c initial checkin
james
parents:
diff changeset
   151
ab88e78f027c initial checkin
james
parents:
diff changeset
   152
    <resource: #menu>
ab88e78f027c initial checkin
james
parents:
diff changeset
   153
ab88e78f027c initial checkin
james
parents:
diff changeset
   154
    ^ #(#Menu
ab88e78f027c initial checkin
james
parents:
diff changeset
   155
           #(
ab88e78f027c initial checkin
james
parents:
diff changeset
   156
             #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
   157
                #label: 'File'
ab88e78f027c initial checkin
james
parents:
diff changeset
   158
                #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
   159
                #submenu: 
ab88e78f027c initial checkin
james
parents:
diff changeset
   160
                 #(#Menu
ab88e78f027c initial checkin
james
parents:
diff changeset
   161
                     #(
ab88e78f027c initial checkin
james
parents:
diff changeset
   162
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
   163
                          #label: 'New'
ab88e78f027c initial checkin
james
parents:
diff changeset
   164
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
   165
                          #value: #menuNew
ab88e78f027c initial checkin
james
parents:
diff changeset
   166
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
   167
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
   168
                          #label: '-'
ab88e78f027c initial checkin
james
parents:
diff changeset
   169
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
   170
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
   171
                          #label: 'Open...'
ab88e78f027c initial checkin
james
parents:
diff changeset
   172
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
   173
                          #value: #menuOpen
ab88e78f027c initial checkin
james
parents:
diff changeset
   174
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
   175
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
   176
                          #label: '-'
ab88e78f027c initial checkin
james
parents:
diff changeset
   177
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
   178
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
   179
                          #label: 'Save'
ab88e78f027c initial checkin
james
parents:
diff changeset
   180
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
   181
                          #value: #menuSave
ab88e78f027c initial checkin
james
parents:
diff changeset
   182
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
   183
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
   184
                          #label: 'Save As...'
ab88e78f027c initial checkin
james
parents:
diff changeset
   185
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
   186
                          #value: #menuSaveAs
ab88e78f027c initial checkin
james
parents:
diff changeset
   187
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
   188
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
   189
                          #label: '-'
ab88e78f027c initial checkin
james
parents:
diff changeset
   190
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
   191
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
   192
                          #label: 'Exit'
ab88e78f027c initial checkin
james
parents:
diff changeset
   193
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
   194
                          #value: #closeRequest
ab88e78f027c initial checkin
james
parents:
diff changeset
   195
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
   196
                    ) nil
ab88e78f027c initial checkin
james
parents:
diff changeset
   197
                    nil
ab88e78f027c initial checkin
james
parents:
diff changeset
   198
                )
ab88e78f027c initial checkin
james
parents:
diff changeset
   199
            )
ab88e78f027c initial checkin
james
parents:
diff changeset
   200
             #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
   201
                #label: 'Help'
ab88e78f027c initial checkin
james
parents:
diff changeset
   202
                #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
   203
                #startGroup: #right
ab88e78f027c initial checkin
james
parents:
diff changeset
   204
                #submenu: 
ab88e78f027c initial checkin
james
parents:
diff changeset
   205
                 #(#Menu
ab88e78f027c initial checkin
james
parents:
diff changeset
   206
                     #(
ab88e78f027c initial checkin
james
parents:
diff changeset
   207
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
   208
                          #label: 'Documentation'
ab88e78f027c initial checkin
james
parents:
diff changeset
   209
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
   210
                          #value: #openDocumentation
ab88e78f027c initial checkin
james
parents:
diff changeset
   211
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
   212
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
   213
                          #label: '-'
ab88e78f027c initial checkin
james
parents:
diff changeset
   214
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
   215
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
   216
                          #label: 'About this Application'
ab88e78f027c initial checkin
james
parents:
diff changeset
   217
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
   218
                          #value: #openAboutThisApplication
ab88e78f027c initial checkin
james
parents:
diff changeset
   219
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
   220
                    ) nil
ab88e78f027c initial checkin
james
parents:
diff changeset
   221
                    nil
ab88e78f027c initial checkin
james
parents:
diff changeset
   222
                )
ab88e78f027c initial checkin
james
parents:
diff changeset
   223
            )
ab88e78f027c initial checkin
james
parents:
diff changeset
   224
          ) nil
ab88e78f027c initial checkin
james
parents:
diff changeset
   225
          nil
ab88e78f027c initial checkin
james
parents:
diff changeset
   226
      )
ab88e78f027c initial checkin
james
parents:
diff changeset
   227
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
   228
ab88e78f027c initial checkin
james
parents:
diff changeset
   229
!PackageDetails::Class class methodsFor:'plugIn spec'!
ab88e78f027c initial checkin
james
parents:
diff changeset
   230
ab88e78f027c initial checkin
james
parents:
diff changeset
   231
aspectSelectors
ab88e78f027c initial checkin
james
parents:
diff changeset
   232
    "This resource specification was automatically generated
ab88e78f027c initial checkin
james
parents:
diff changeset
   233
     by the UIPainter of ST/X."
ab88e78f027c initial checkin
james
parents:
diff changeset
   234
ab88e78f027c initial checkin
james
parents:
diff changeset
   235
    "Do not manually edit this. If it is corrupted,
ab88e78f027c initial checkin
james
parents:
diff changeset
   236
     the UIPainter may not be able to read the specification."
ab88e78f027c initial checkin
james
parents:
diff changeset
   237
ab88e78f027c initial checkin
james
parents:
diff changeset
   238
    "Return a description of exported aspects;
ab88e78f027c initial checkin
james
parents:
diff changeset
   239
     these can be connected to aspects of an embedding application
ab88e78f027c initial checkin
james
parents:
diff changeset
   240
     (if this app is embedded in a subCanvas)."
ab88e78f027c initial checkin
james
parents:
diff changeset
   241
ab88e78f027c initial checkin
james
parents:
diff changeset
   242
    ^ #(
ab88e78f027c initial checkin
james
parents:
diff changeset
   243
        #classList
ab88e78f027c initial checkin
james
parents:
diff changeset
   244
        #selectedClassHolder
ab88e78f027c initial checkin
james
parents:
diff changeset
   245
      ).
ab88e78f027c initial checkin
james
parents:
diff changeset
   246
ab88e78f027c initial checkin
james
parents:
diff changeset
   247
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
   248
1268
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   249
!PackageDetails::Class methodsFor:'accessing'!
1241
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   250
1268
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   251
classListAt:idx 
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   252
    ^ self classList at:idx
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   253
!
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
   254
ab88e78f027c initial checkin
james
parents:
diff changeset
   255
declareDependents
ab88e78f027c initial checkin
james
parents:
diff changeset
   256
    super declareDependents
ab88e78f027c initial checkin
james
parents:
diff changeset
   257
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   258
ab88e78f027c initial checkin
james
parents:
diff changeset
   259
privateProcessesAt:aSymbol 
1268
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   260
    ^ (nonCriticalPrivateProcesses at:aSymbol ifAbsentPut:[[nil]fork]).
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
   261
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   262
ab88e78f027c initial checkin
james
parents:
diff changeset
   263
privateProcessesAt:aSymbol put:aProcess
1268
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   264
    ^ (nonCriticalPrivateProcesses at:aSymbol put:aProcess).
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
   265
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
   266
1241
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   267
!PackageDetails::Class methodsFor:'adding'!
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   268
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   269
addPrivateClassLabelAndIconForClass:aClass toClassList:aClassList level:aNumber
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   270
    aClass privateClasses do:[:aPrivateClass |
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   271
        aClassList add:(self newClassLabelAndIconWithClass:aPrivateClass).
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   272
        self addPrivateClassLabelAndIconForClass:aPrivateClass toClassList:aClassList level:(aNumber + 1).
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   273
    ].
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   274
!
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   275
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   276
putClassesNamesIn:aClassList fromPackages:collectionOfPackages inCategories:collectionOfCategoryNames 
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   277
    | classesWithoutPrivateClasses|
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   278
    classesWithoutPrivateClasses := OrderedCollection new.
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   279
    collectionOfCategoryNames do:[:aCategoryName |
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   280
        collectionOfPackages do:[:aPackage |
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   281
            (aPackage classesInCategory:aCategoryName) 
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   282
                do:[:aClass |  aClass isPrivate ifFalse:[
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   283
                                        classesWithoutPrivateClasses add:(self newClassLabelAndIconWithClass:aClass).
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   284
                                ].
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   285
            ].
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   286
        ].
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   287
    ].
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   288
    classesWithoutPrivateClasses sort:[:x :y |
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   289
        x asString < y asString
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   290
    ].
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   291
    classesWithoutPrivateClasses do:[:aLableAndIcon | | aClass |
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   292
        aClass := aLableAndIcon classModel.
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   293
        aClassList add:aLableAndIcon.
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   294
        self addPrivateClassLabelAndIconForClass:aClass toClassList:aClassList level:1
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   295
    ].
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   296
! !
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   297
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
   298
!PackageDetails::Class methodsFor:'aspects'!
ab88e78f027c initial checkin
james
parents:
diff changeset
   299
ab88e78f027c initial checkin
james
parents:
diff changeset
   300
categoryList
ab88e78f027c initial checkin
james
parents:
diff changeset
   301
    "automatically generated by UIPainter ..."
ab88e78f027c initial checkin
james
parents:
diff changeset
   302
ab88e78f027c initial checkin
james
parents:
diff changeset
   303
    "*** the code below creates a default model when invoked."
ab88e78f027c initial checkin
james
parents:
diff changeset
   304
    "*** (which may not be the one you wanted)"
ab88e78f027c initial checkin
james
parents:
diff changeset
   305
    "*** Please change as required and accept it in the browser."
ab88e78f027c initial checkin
james
parents:
diff changeset
   306
    "*** (and replace this comment by something more useful ;-)"
ab88e78f027c initial checkin
james
parents:
diff changeset
   307
ab88e78f027c initial checkin
james
parents:
diff changeset
   308
    categoryList isNil ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
   309
        categoryList := List new.
ab88e78f027c initial checkin
james
parents:
diff changeset
   310
"/ if your app needs to be notified of changes, uncomment one of the lines below:
ab88e78f027c initial checkin
james
parents:
diff changeset
   311
"/       categoryList addDependent:self.
ab88e78f027c initial checkin
james
parents:
diff changeset
   312
"/       categoryList onChangeSend:#categoryListChanged to:self.
ab88e78f027c initial checkin
james
parents:
diff changeset
   313
    ].
ab88e78f027c initial checkin
james
parents:
diff changeset
   314
    ^ categoryList.
ab88e78f027c initial checkin
james
parents:
diff changeset
   315
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   316
ab88e78f027c initial checkin
james
parents:
diff changeset
   317
classList
ab88e78f027c initial checkin
james
parents:
diff changeset
   318
    "automatically generated by UIPainter ..."
ab88e78f027c initial checkin
james
parents:
diff changeset
   319
ab88e78f027c initial checkin
james
parents:
diff changeset
   320
    "*** the code below creates a default model when invoked."
ab88e78f027c initial checkin
james
parents:
diff changeset
   321
    "*** (which may not be the one you wanted)"
ab88e78f027c initial checkin
james
parents:
diff changeset
   322
    "*** Please change as required and accept it in the browser."
ab88e78f027c initial checkin
james
parents:
diff changeset
   323
    "*** (and replace this comment by something more useful ;-)"
ab88e78f027c initial checkin
james
parents:
diff changeset
   324
ab88e78f027c initial checkin
james
parents:
diff changeset
   325
    classList isNil ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
   326
        classList := List new.
ab88e78f027c initial checkin
james
parents:
diff changeset
   327
"/ if your app needs to be notified of changes, uncomment one of the lines below:
ab88e78f027c initial checkin
james
parents:
diff changeset
   328
"/       classList addDependent:self.
ab88e78f027c initial checkin
james
parents:
diff changeset
   329
"/       classList onChangeSend:#classListChanged to:self.
ab88e78f027c initial checkin
james
parents:
diff changeset
   330
    ].
ab88e78f027c initial checkin
james
parents:
diff changeset
   331
    ^ classList.
ab88e78f027c initial checkin
james
parents:
diff changeset
   332
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   333
ab88e78f027c initial checkin
james
parents:
diff changeset
   334
selectedCategoryHolder
ab88e78f027c initial checkin
james
parents:
diff changeset
   335
    "automatically generated by UIPainter ..."
ab88e78f027c initial checkin
james
parents:
diff changeset
   336
ab88e78f027c initial checkin
james
parents:
diff changeset
   337
    "*** the code below creates a default model when invoked."
ab88e78f027c initial checkin
james
parents:
diff changeset
   338
    "*** (which may not be the one you wanted)"
ab88e78f027c initial checkin
james
parents:
diff changeset
   339
    "*** Please change as required and accept it in the browser."
ab88e78f027c initial checkin
james
parents:
diff changeset
   340
    "*** (and replace this comment by something more useful ;-)"
ab88e78f027c initial checkin
james
parents:
diff changeset
   341
ab88e78f027c initial checkin
james
parents:
diff changeset
   342
    selectedCategoryHolder isNil ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
   343
        selectedCategoryHolder := ValueHolder new.
ab88e78f027c initial checkin
james
parents:
diff changeset
   344
"/ if your app needs to be notified of changes, uncomment one of the lines below:
ab88e78f027c initial checkin
james
parents:
diff changeset
   345
       selectedCategoryHolder addDependent:self.
ab88e78f027c initial checkin
james
parents:
diff changeset
   346
"/       selectedCategoryHolder onChangeSend:#selectedCategoryHolderChanged to:self.
ab88e78f027c initial checkin
james
parents:
diff changeset
   347
    ].
ab88e78f027c initial checkin
james
parents:
diff changeset
   348
    ^ selectedCategoryHolder.
ab88e78f027c initial checkin
james
parents:
diff changeset
   349
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   350
ab88e78f027c initial checkin
james
parents:
diff changeset
   351
selectedClassHolder
ab88e78f027c initial checkin
james
parents:
diff changeset
   352
    "automatically generated by UIPainter ..."
ab88e78f027c initial checkin
james
parents:
diff changeset
   353
ab88e78f027c initial checkin
james
parents:
diff changeset
   354
    "*** the code below creates a default model when invoked."
ab88e78f027c initial checkin
james
parents:
diff changeset
   355
    "*** (which may not be the one you wanted)"
ab88e78f027c initial checkin
james
parents:
diff changeset
   356
    "*** Please change as required and accept it in the browser."
ab88e78f027c initial checkin
james
parents:
diff changeset
   357
    "*** (and replace this comment by something more useful ;-)"
ab88e78f027c initial checkin
james
parents:
diff changeset
   358
ab88e78f027c initial checkin
james
parents:
diff changeset
   359
    selectedClassHolder isNil ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
   360
        selectedClassHolder := ValueHolder new.
ab88e78f027c initial checkin
james
parents:
diff changeset
   361
"/ if your app needs to be notified of changes, uncomment one of the lines below:
ab88e78f027c initial checkin
james
parents:
diff changeset
   362
"/       selectedClassHolder addDependent:self.
ab88e78f027c initial checkin
james
parents:
diff changeset
   363
"/       selectedClassHolder onChangeSend:#selectedClassHolderChanged to:self.
ab88e78f027c initial checkin
james
parents:
diff changeset
   364
    ].
ab88e78f027c initial checkin
james
parents:
diff changeset
   365
    ^ selectedClassHolder.
ab88e78f027c initial checkin
james
parents:
diff changeset
   366
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
   367
ab88e78f027c initial checkin
james
parents:
diff changeset
   368
!PackageDetails::Class methodsFor:'aspects - exported'!
ab88e78f027c initial checkin
james
parents:
diff changeset
   369
ab88e78f027c initial checkin
james
parents:
diff changeset
   370
classList:something
ab88e78f027c initial checkin
james
parents:
diff changeset
   371
    "automatically generated by UIPainter ..."
ab88e78f027c initial checkin
james
parents:
diff changeset
   372
ab88e78f027c initial checkin
james
parents:
diff changeset
   373
    "This method is used when I am embedded as subApplication,"
ab88e78f027c initial checkin
james
parents:
diff changeset
   374
    "and the mainApp wants to connect its aspects to mine."
ab88e78f027c initial checkin
james
parents:
diff changeset
   375
ab88e78f027c initial checkin
james
parents:
diff changeset
   376
"/     classList notNil ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
   377
"/        classList removeDependent:self.
ab88e78f027c initial checkin
james
parents:
diff changeset
   378
"/     ].
ab88e78f027c initial checkin
james
parents:
diff changeset
   379
    classList := something.
ab88e78f027c initial checkin
james
parents:
diff changeset
   380
"/     classList notNil ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
   381
"/        classList addDependent:self.
ab88e78f027c initial checkin
james
parents:
diff changeset
   382
"/     ].
ab88e78f027c initial checkin
james
parents:
diff changeset
   383
    ^ self.
ab88e78f027c initial checkin
james
parents:
diff changeset
   384
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   385
ab88e78f027c initial checkin
james
parents:
diff changeset
   386
selectedClassHolder:something
ab88e78f027c initial checkin
james
parents:
diff changeset
   387
    "automatically generated by UIPainter ..."
ab88e78f027c initial checkin
james
parents:
diff changeset
   388
ab88e78f027c initial checkin
james
parents:
diff changeset
   389
    "This method is used when I am embedded as subApplication,"
ab88e78f027c initial checkin
james
parents:
diff changeset
   390
    "and the mainApp wants to connect its aspects to mine."
ab88e78f027c initial checkin
james
parents:
diff changeset
   391
ab88e78f027c initial checkin
james
parents:
diff changeset
   392
"/     selectedClassHolder notNil ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
   393
"/        selectedClassHolder removeDependent:self.
ab88e78f027c initial checkin
james
parents:
diff changeset
   394
"/     ].
ab88e78f027c initial checkin
james
parents:
diff changeset
   395
    selectedClassHolder := something.
ab88e78f027c initial checkin
james
parents:
diff changeset
   396
"/     selectedClassHolder notNil ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
   397
"/        selectedClassHolder addDependent:self.
ab88e78f027c initial checkin
james
parents:
diff changeset
   398
"/     ].
ab88e78f027c initial checkin
james
parents:
diff changeset
   399
    ^ self.
ab88e78f027c initial checkin
james
parents:
diff changeset
   400
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
   401
1268
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   402
!PackageDetails::Class methodsFor:'browsing'!
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   403
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   404
browseClassWithIndexes:aCollectionOfIndexes
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   405
    "An 'adapter method'. Calls #browserClass:. Is only used as there can be
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   406
    private classes with the same name and the selectionList cannot tell the difference
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   407
    otherwise."
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   408
    | classItems |
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   409
    classItems := aCollectionOfIndexes collect:[:idx |
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   410
        self classListAt:idx
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   411
    ].
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   412
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   413
    ^ self browseClasses:classItems
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   414
!
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   415
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   416
browseClasses:aCollection
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   417
    | theClass |
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   418
    theClass := aCollection first classModel.
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   419
    (Smalltalk classNamed:(theClass name)) browse
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   420
! !
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   421
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
   422
!PackageDetails::Class methodsFor:'change & update'!
ab88e78f027c initial checkin
james
parents:
diff changeset
   423
ab88e78f027c initial checkin
james
parents:
diff changeset
   424
selectedCategoryChanged:aCollectionOfCategories 
1241
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   425
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   426
    self withProcessNamed:#selectedCategoryChanged: do:[
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
   427
        classList removeAll.
1241
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   428
        self 
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   429
            putClassesNamesIn:classList 
1268
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   430
            fromPackages:self packagesSelected 
1241
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   431
            inCategories:aCollectionOfCategories.
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   432
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   433
    ].
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
   434
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   435
ab88e78f027c initial checkin
james
parents:
diff changeset
   436
update:something with:aParameter from:changedObject
ab88e78f027c initial checkin
james
parents:
diff changeset
   437
ab88e78f027c initial checkin
james
parents:
diff changeset
   438
    changedObject == selectedCategoryHolder ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
   439
        self selectedCategoryChanged:aParameter        
ab88e78f027c initial checkin
james
parents:
diff changeset
   440
    ].
ab88e78f027c initial checkin
james
parents:
diff changeset
   441
ab88e78f027c initial checkin
james
parents:
diff changeset
   442
    super update:something with:aParameter from:changedObject
ab88e78f027c initial checkin
james
parents:
diff changeset
   443
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   444
ab88e78f027c initial checkin
james
parents:
diff changeset
   445
updateWithPackages:packages
ab88e78f027c initial checkin
james
parents:
diff changeset
   446
    | classCategoryNames |
1268
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   447
    packages size = 1 ifTrue:[
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   448
        packages first ifNil:[
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   449
            ^ self.
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   450
        ]
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
   451
    ].
ab88e78f027c initial checkin
james
parents:
diff changeset
   452
1268
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   453
    self withProcessNamed:#updateWithPackages: do:[ 
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   454
        classList removeAll.
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   455
        categoryList removeAll.
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   456
        classCategoryNames := Set new.
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   457
        packages do:[:aPackage |
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   458
            classCategoryNames addAll:aPackage classCategories   
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   459
        ].
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   460
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   461
        categoryList addAll:classCategoryNames.
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   462
        categoryList sort:[:x :y |
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   463
            x < y
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   464
        ]. 
1241
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   465
    ].
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
   466
"/    packages do:[:aPackage |
ab88e78f027c initial checkin
james
parents:
diff changeset
   467
"/        categoryList addAll:aPackage classCategories   
ab88e78f027c initial checkin
james
parents:
diff changeset
   468
"/    ].
ab88e78f027c initial checkin
james
parents:
diff changeset
   469
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
   470
1241
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   471
!PackageDetails::Class methodsFor:'factory'!
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   472
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   473
labelAndIconClass
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   474
    ^ ClassLabelAndIcon
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   475
!
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   476
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   477
newClassLabelAndIconWithClass:aClass
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   478
"/    aClass isPrivate ifTrue:[self halt.].
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   479
    ^ self labelAndIconClass class:aClass
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   480
! !
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   481
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
   482
!PackageDetails::Class methodsFor:'initialization & release'!
ab88e78f027c initial checkin
james
parents:
diff changeset
   483
ab88e78f027c initial checkin
james
parents:
diff changeset
   484
closeDownViews
ab88e78f027c initial checkin
james
parents:
diff changeset
   485
    "This is a hook method generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
   486
     It will be invoked when your app/dialog-window is really closed.
ab88e78f027c initial checkin
james
parents:
diff changeset
   487
     See also #closeDownViews, which is invoked before and may suppress the close
ab88e78f027c initial checkin
james
parents:
diff changeset
   488
     or ask the user for confirmation."
ab88e78f027c initial checkin
james
parents:
diff changeset
   489
ab88e78f027c initial checkin
james
parents:
diff changeset
   490
    "/ change the code below as required ...
ab88e78f027c initial checkin
james
parents:
diff changeset
   491
    "/ This should cleanup any leftover resources
ab88e78f027c initial checkin
james
parents:
diff changeset
   492
    "/ (for example, temporary files)
ab88e78f027c initial checkin
james
parents:
diff changeset
   493
    "/ super closeRequest will initiate the closeDown
ab88e78f027c initial checkin
james
parents:
diff changeset
   494
ab88e78f027c initial checkin
james
parents:
diff changeset
   495
    "/ add your code here
ab88e78f027c initial checkin
james
parents:
diff changeset
   496
ab88e78f027c initial checkin
james
parents:
diff changeset
   497
    "/ do not remove the one below ...
ab88e78f027c initial checkin
james
parents:
diff changeset
   498
    ^ super closeDownViews
ab88e78f027c initial checkin
james
parents:
diff changeset
   499
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   500
ab88e78f027c initial checkin
james
parents:
diff changeset
   501
closeRequest
ab88e78f027c initial checkin
james
parents:
diff changeset
   502
    "This is a hook method generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
   503
     It will be invoked when your app/dialog-window is about to be
ab88e78f027c initial checkin
james
parents:
diff changeset
   504
     closed (this method has a chance to suppress the close).
ab88e78f027c initial checkin
james
parents:
diff changeset
   505
     See also #closeDownViews, which is invoked when the close is really done."
ab88e78f027c initial checkin
james
parents:
diff changeset
   506
ab88e78f027c initial checkin
james
parents:
diff changeset
   507
    "/ change the code below as required ...
ab88e78f027c initial checkin
james
parents:
diff changeset
   508
    "/ Closing can be suppressed, by simply returning.
ab88e78f027c initial checkin
james
parents:
diff changeset
   509
    "/ The 'super closeRequest' at the end will initiate the real closeDown
ab88e78f027c initial checkin
james
parents:
diff changeset
   510
ab88e78f027c initial checkin
james
parents:
diff changeset
   511
    ("self hasUnsavedChanges" true) ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
   512
        (self confirm:(resources string:'Close without saving ?')) ifFalse:[
ab88e78f027c initial checkin
james
parents:
diff changeset
   513
            ^ self
ab88e78f027c initial checkin
james
parents:
diff changeset
   514
        ]
ab88e78f027c initial checkin
james
parents:
diff changeset
   515
    ].
ab88e78f027c initial checkin
james
parents:
diff changeset
   516
ab88e78f027c initial checkin
james
parents:
diff changeset
   517
    ^ super closeRequest
ab88e78f027c initial checkin
james
parents:
diff changeset
   518
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   519
ab88e78f027c initial checkin
james
parents:
diff changeset
   520
initialize
1268
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   521
    nonCriticalPrivateProcesses := Dictionary new
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
   522
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   523
ab88e78f027c initial checkin
james
parents:
diff changeset
   524
postBuildWith:aBuilder
ab88e78f027c initial checkin
james
parents:
diff changeset
   525
    "This is a hook method generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
   526
     It will be invoked during the initialization of your app/dialog,
ab88e78f027c initial checkin
james
parents:
diff changeset
   527
     after all of the visual components have been built, 
ab88e78f027c initial checkin
james
parents:
diff changeset
   528
     but BEFORE the top window is made visible.
ab88e78f027c initial checkin
james
parents:
diff changeset
   529
     Add any app-specific actions here (reading files, setting up values etc.)
ab88e78f027c initial checkin
james
parents:
diff changeset
   530
     See also #postOpenWith:, which is invoked after opening."
ab88e78f027c initial checkin
james
parents:
diff changeset
   531
ab88e78f027c initial checkin
james
parents:
diff changeset
   532
    "/ add any code here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
   533
ab88e78f027c initial checkin
james
parents:
diff changeset
   534
    ^ super postBuildWith:aBuilder
ab88e78f027c initial checkin
james
parents:
diff changeset
   535
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   536
ab88e78f027c initial checkin
james
parents:
diff changeset
   537
postOpenWith:aBuilder
ab88e78f027c initial checkin
james
parents:
diff changeset
   538
    "This is a hook method generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
   539
     It will be invoked right after the applications window has been opened.
ab88e78f027c initial checkin
james
parents:
diff changeset
   540
     Add any app-specific actions here (starting background processes etc.).
ab88e78f027c initial checkin
james
parents:
diff changeset
   541
     See also #postBuildWith:, which is invoked before opening."
ab88e78f027c initial checkin
james
parents:
diff changeset
   542
ab88e78f027c initial checkin
james
parents:
diff changeset
   543
    "/ add any code here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
   544
ab88e78f027c initial checkin
james
parents:
diff changeset
   545
    ^ super postOpenWith:aBuilder
ab88e78f027c initial checkin
james
parents:
diff changeset
   546
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
   547
ab88e78f027c initial checkin
james
parents:
diff changeset
   548
!PackageDetails::Class methodsFor:'menu actions'!
ab88e78f027c initial checkin
james
parents:
diff changeset
   549
ab88e78f027c initial checkin
james
parents:
diff changeset
   550
menuNew
ab88e78f027c initial checkin
james
parents:
diff changeset
   551
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
   552
     It will be invoked when the menu-item 'new' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
   553
ab88e78f027c initial checkin
james
parents:
diff changeset
   554
    "/ change below and add any actions as required here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
   555
    self warn:'no action for ''new'' available.'.
ab88e78f027c initial checkin
james
parents:
diff changeset
   556
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   557
ab88e78f027c initial checkin
james
parents:
diff changeset
   558
menuOpen
ab88e78f027c initial checkin
james
parents:
diff changeset
   559
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
   560
     It will be invoked when the menu-item 'open' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
   561
ab88e78f027c initial checkin
james
parents:
diff changeset
   562
    "/ change below and add any actions as required here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
   563
    self warn:'no action for ''open'' available.'.
ab88e78f027c initial checkin
james
parents:
diff changeset
   564
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   565
ab88e78f027c initial checkin
james
parents:
diff changeset
   566
menuSave
ab88e78f027c initial checkin
james
parents:
diff changeset
   567
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
   568
     It will be invoked when the menu-item 'save' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
   569
ab88e78f027c initial checkin
james
parents:
diff changeset
   570
    "/ change below and add any actions as required here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
   571
    self warn:'no action for ''save'' available.'.
ab88e78f027c initial checkin
james
parents:
diff changeset
   572
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   573
ab88e78f027c initial checkin
james
parents:
diff changeset
   574
menuSaveAs
ab88e78f027c initial checkin
james
parents:
diff changeset
   575
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
   576
     It will be invoked when the menu-item 'saveAs' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
   577
ab88e78f027c initial checkin
james
parents:
diff changeset
   578
    "/ change below and add any actions as required here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
   579
    self warn:'no action for ''saveAs'' available.'.
ab88e78f027c initial checkin
james
parents:
diff changeset
   580
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   581
ab88e78f027c initial checkin
james
parents:
diff changeset
   582
openAboutThisApplication
ab88e78f027c initial checkin
james
parents:
diff changeset
   583
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
   584
     It will be invoked when the menu-item 'help-about' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
   585
ab88e78f027c initial checkin
james
parents:
diff changeset
   586
    "/ could open a customized aboutBox here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
   587
    super openAboutThisApplication
ab88e78f027c initial checkin
james
parents:
diff changeset
   588
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   589
ab88e78f027c initial checkin
james
parents:
diff changeset
   590
openDocumentation
ab88e78f027c initial checkin
james
parents:
diff changeset
   591
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
   592
     It will be invoked when the menu-item 'help-documentation' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
   593
ab88e78f027c initial checkin
james
parents:
diff changeset
   594
    "/ change below as required ...
ab88e78f027c initial checkin
james
parents:
diff changeset
   595
ab88e78f027c initial checkin
james
parents:
diff changeset
   596
    "/ to open an HTML viewer on some document (under 'doc/online/<language>/' ):
ab88e78f027c initial checkin
james
parents:
diff changeset
   597
    HTMLDocumentView openFullOnDocumentationFile:'TOP.html'.
ab88e78f027c initial checkin
james
parents:
diff changeset
   598
ab88e78f027c initial checkin
james
parents:
diff changeset
   599
    "/ add application-specific help files under the 'doc/online/<language>/help/appName'
ab88e78f027c initial checkin
james
parents:
diff changeset
   600
    "/ directory, and open a viewer with:
ab88e78f027c initial checkin
james
parents:
diff changeset
   601
    "/ HTMLDocumentView openFullOnDocumentationFile:'help/<MyApplication>/TOP.html'.
ab88e78f027c initial checkin
james
parents:
diff changeset
   602
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
   603
1241
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   604
!PackageDetails::Class methodsFor:'process'!
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   605
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   606
withProcessNamed:aName do:aBlock 
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   607
    "stop unconditionally the process and replace with aBlock"
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   608
    (self privateProcessesAt:aName) terminate.
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   609
    self privateProcessesAt:aName put:aBlock fork.
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   610
! !
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   611
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
   612
!PackageDetails::Class methodsFor:'queries'!
ab88e78f027c initial checkin
james
parents:
diff changeset
   613
ab88e78f027c initial checkin
james
parents:
diff changeset
   614
validateCanChange:arg 
ab88e78f027c initial checkin
james
parents:
diff changeset
   615
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
   616
1241
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   617
!PackageDetails::Class::ClassLabelAndIcon class methodsFor:'instance'!
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   618
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   619
class:aClass
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   620
    ^ (self basicNew) classModel:aClass; initialize
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   621
! !
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   622
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   623
!PackageDetails::Class::ClassLabelAndIcon methodsFor:'accessing'!
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   624
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   625
asString
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   626
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   627
    | aString |
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   628
    aString := String new.
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   629
    class isPrivate ifTrue:[
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   630
        aString := '    '.
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   631
        self privateClassDepth timesRepeat:[
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   632
            aString := aString , '  '.
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   633
        ].
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   634
        aString := aString , '::'. 
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   635
    ].
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   636
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   637
    aString := aString, class shortName asString. 
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   638
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   639
    ^ aString
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   640
!
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   641
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   642
classModel
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   643
    "return the value of the instance variable 'class' (automatically generated)"
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   644
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   645
    ^ class
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   646
!
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   647
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   648
classModel:something
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   649
    "set the value of the instance variable 'class' (automatically generated)"
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   650
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   651
    class := something.
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   652
    self string: self asString.
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   653
!
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   654
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   655
privateClassDepth
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   656
    | thisClass counter |
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   657
    thisClass := class.
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   658
    counter := 0.
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   659
    [thisClass isNameSpace] whileFalse:[
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   660
        thisClass := thisClass owningClass.
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   661
        thisClass ifNil:[thisClass := Smalltalk].
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   662
        counter := counter + 1.
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   663
    ].
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   664
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   665
    ^ counter - 1
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   666
! !
3a977bf0d483 *** empty log message ***
james
parents: 1227
diff changeset
   667
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
   668
!PackageDetails::Comment class methodsFor:'constant values'!
ab88e78f027c initial checkin
james
parents:
diff changeset
   669
ab88e78f027c initial checkin
james
parents:
diff changeset
   670
applicationName
ab88e78f027c initial checkin
james
parents:
diff changeset
   671
    ^ 'Comment' asSymbol
ab88e78f027c initial checkin
james
parents:
diff changeset
   672
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
   673
ab88e78f027c initial checkin
james
parents:
diff changeset
   674
!PackageDetails::Comment class methodsFor:'interface specs'!
ab88e78f027c initial checkin
james
parents:
diff changeset
   675
ab88e78f027c initial checkin
james
parents:
diff changeset
   676
windowSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
   677
    "This resource specification was automatically generated
ab88e78f027c initial checkin
james
parents:
diff changeset
   678
     by the UIPainter of ST/X."
ab88e78f027c initial checkin
james
parents:
diff changeset
   679
ab88e78f027c initial checkin
james
parents:
diff changeset
   680
    "Do not manually edit this!! If it is corrupted,
ab88e78f027c initial checkin
james
parents:
diff changeset
   681
     the UIPainter may not be able to read the specification."
ab88e78f027c initial checkin
james
parents:
diff changeset
   682
ab88e78f027c initial checkin
james
parents:
diff changeset
   683
    "
ab88e78f027c initial checkin
james
parents:
diff changeset
   684
     UIPainter new openOnClass:Packages::PackageDetails::Comment andSelector:#windowSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
   685
     Packages::PackageDetails::Comment new openInterface:#windowSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
   686
     Packages::PackageDetails::Comment open
ab88e78f027c initial checkin
james
parents:
diff changeset
   687
    "
ab88e78f027c initial checkin
james
parents:
diff changeset
   688
ab88e78f027c initial checkin
james
parents:
diff changeset
   689
    <resource: #canvas>
ab88e78f027c initial checkin
james
parents:
diff changeset
   690
ab88e78f027c initial checkin
james
parents:
diff changeset
   691
    ^ 
ab88e78f027c initial checkin
james
parents:
diff changeset
   692
     #(#FullSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
   693
        #name: #windowSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
   694
        #window: 
ab88e78f027c initial checkin
james
parents:
diff changeset
   695
       #(#WindowSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
   696
          #label: 'Packages::PackageDetails::Comment'
ab88e78f027c initial checkin
james
parents:
diff changeset
   697
          #name: 'Packages::PackageDetails::Comment'
ab88e78f027c initial checkin
james
parents:
diff changeset
   698
          #min: #(#Point 10 10)
ab88e78f027c initial checkin
james
parents:
diff changeset
   699
          #max: #(#Point 1024 768)
ab88e78f027c initial checkin
james
parents:
diff changeset
   700
          #bounds: #(#Rectangle 29 59 329 359)
ab88e78f027c initial checkin
james
parents:
diff changeset
   701
        )
ab88e78f027c initial checkin
james
parents:
diff changeset
   702
        #component: 
ab88e78f027c initial checkin
james
parents:
diff changeset
   703
       #(#SpecCollection
ab88e78f027c initial checkin
james
parents:
diff changeset
   704
          #collection: #(
ab88e78f027c initial checkin
james
parents:
diff changeset
   705
           #(#TextEditorSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
   706
              #name: 'TextEditor1'
ab88e78f027c initial checkin
james
parents:
diff changeset
   707
              #layout: #(#LayoutFrame 0 0 0 0 0 1 0 1)
ab88e78f027c initial checkin
james
parents:
diff changeset
   708
              #model: #commentTextHolder
ab88e78f027c initial checkin
james
parents:
diff changeset
   709
              #hasHorizontalScrollBar: true
ab88e78f027c initial checkin
james
parents:
diff changeset
   710
              #hasVerticalScrollBar: true
ab88e78f027c initial checkin
james
parents:
diff changeset
   711
              #modifiedChannel: #commentTextModifiedChannel
ab88e78f027c initial checkin
james
parents:
diff changeset
   712
              #acceptCallBack: #commentAccepted:
ab88e78f027c initial checkin
james
parents:
diff changeset
   713
              #postBuildCallback: #commentTextEditorCreated:
ab88e78f027c initial checkin
james
parents:
diff changeset
   714
            )
ab88e78f027c initial checkin
james
parents:
diff changeset
   715
           )
ab88e78f027c initial checkin
james
parents:
diff changeset
   716
         
ab88e78f027c initial checkin
james
parents:
diff changeset
   717
        )
ab88e78f027c initial checkin
james
parents:
diff changeset
   718
      )
ab88e78f027c initial checkin
james
parents:
diff changeset
   719
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
   720
ab88e78f027c initial checkin
james
parents:
diff changeset
   721
!PackageDetails::Comment methodsFor:'accessing'!
ab88e78f027c initial checkin
james
parents:
diff changeset
   722
ab88e78f027c initial checkin
james
parents:
diff changeset
   723
declareDependents
ab88e78f027c initial checkin
james
parents:
diff changeset
   724
    super declareDependents
ab88e78f027c initial checkin
james
parents:
diff changeset
   725
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
   726
ab88e78f027c initial checkin
james
parents:
diff changeset
   727
!PackageDetails::Comment methodsFor:'aspects'!
ab88e78f027c initial checkin
james
parents:
diff changeset
   728
ab88e78f027c initial checkin
james
parents:
diff changeset
   729
commentTextAcceptChannel
ab88e78f027c initial checkin
james
parents:
diff changeset
   730
    "automatically generated by UIPainter ..."
ab88e78f027c initial checkin
james
parents:
diff changeset
   731
ab88e78f027c initial checkin
james
parents:
diff changeset
   732
    "*** the code below creates a default model when invoked."
ab88e78f027c initial checkin
james
parents:
diff changeset
   733
    "*** (which may not be the one you wanted)"
ab88e78f027c initial checkin
james
parents:
diff changeset
   734
    "*** Please change as required and accept it in the browser."
ab88e78f027c initial checkin
james
parents:
diff changeset
   735
    "*** (and replace this comment by something more useful ;-)"
ab88e78f027c initial checkin
james
parents:
diff changeset
   736
ab88e78f027c initial checkin
james
parents:
diff changeset
   737
    commentTextAcceptChannel isNil ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
   738
        commentTextAcceptChannel := TriggerValue new.
ab88e78f027c initial checkin
james
parents:
diff changeset
   739
    ].
ab88e78f027c initial checkin
james
parents:
diff changeset
   740
    ^ commentTextAcceptChannel.
ab88e78f027c initial checkin
james
parents:
diff changeset
   741
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   742
ab88e78f027c initial checkin
james
parents:
diff changeset
   743
commentTextHolder
ab88e78f027c initial checkin
james
parents:
diff changeset
   744
    "automatically generated by UIPainter ..."
ab88e78f027c initial checkin
james
parents:
diff changeset
   745
ab88e78f027c initial checkin
james
parents:
diff changeset
   746
    "*** the code below creates a default model when invoked."
ab88e78f027c initial checkin
james
parents:
diff changeset
   747
    "*** (which may not be the one you wanted)"
ab88e78f027c initial checkin
james
parents:
diff changeset
   748
    "*** Please change as required and accept it in the browser."
ab88e78f027c initial checkin
james
parents:
diff changeset
   749
    "*** (and replace this comment by something more useful ;-)"
ab88e78f027c initial checkin
james
parents:
diff changeset
   750
ab88e78f027c initial checkin
james
parents:
diff changeset
   751
    commentTextHolder isNil ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
   752
        commentTextHolder := '' asValue.
ab88e78f027c initial checkin
james
parents:
diff changeset
   753
"/ if your app needs to be notified of changes, uncomment one of the lines below:
ab88e78f027c initial checkin
james
parents:
diff changeset
   754
"/       commentTextHolder addDependent:self.
ab88e78f027c initial checkin
james
parents:
diff changeset
   755
"/       commentTextHolder onChangeSend:#commentTextHolderChanged to:self.
ab88e78f027c initial checkin
james
parents:
diff changeset
   756
    ].
ab88e78f027c initial checkin
james
parents:
diff changeset
   757
    ^ commentTextHolder.
ab88e78f027c initial checkin
james
parents:
diff changeset
   758
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   759
ab88e78f027c initial checkin
james
parents:
diff changeset
   760
commentTextModifiedChannel
ab88e78f027c initial checkin
james
parents:
diff changeset
   761
    "automatically generated by UIPainter ..."
ab88e78f027c initial checkin
james
parents:
diff changeset
   762
ab88e78f027c initial checkin
james
parents:
diff changeset
   763
    "*** the code below creates a default model when invoked."
ab88e78f027c initial checkin
james
parents:
diff changeset
   764
    "*** (which may not be the one you wanted)"
ab88e78f027c initial checkin
james
parents:
diff changeset
   765
    "*** Please change as required and accept it in the browser."
ab88e78f027c initial checkin
james
parents:
diff changeset
   766
    "*** (and replace this comment by something more useful ;-)"
ab88e78f027c initial checkin
james
parents:
diff changeset
   767
ab88e78f027c initial checkin
james
parents:
diff changeset
   768
    commentTextModifiedChannel isNil ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
   769
        commentTextModifiedChannel := TriggerValue new.
ab88e78f027c initial checkin
james
parents:
diff changeset
   770
    ].
ab88e78f027c initial checkin
james
parents:
diff changeset
   771
    ^ commentTextModifiedChannel.
ab88e78f027c initial checkin
james
parents:
diff changeset
   772
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
   773
ab88e78f027c initial checkin
james
parents:
diff changeset
   774
!PackageDetails::Comment methodsFor:'callbacks'!
ab88e78f027c initial checkin
james
parents:
diff changeset
   775
ab88e78f027c initial checkin
james
parents:
diff changeset
   776
commentAccepted:aStringCollection 
ab88e78f027c initial checkin
james
parents:
diff changeset
   777
    |packagesSelected|
ab88e78f027c initial checkin
james
parents:
diff changeset
   778
    (packagesSelected := self packagesSelected) size > 1 ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
   779
        Smalltalk beep.
ab88e78f027c initial checkin
james
parents:
diff changeset
   780
        ^ self.
ab88e78f027c initial checkin
james
parents:
diff changeset
   781
    ].
ab88e78f027c initial checkin
james
parents:
diff changeset
   782
ab88e78f027c initial checkin
james
parents:
diff changeset
   783
    (self packagesNamed:self packagesSelected) first packageComment:aStringCollection asString.
ab88e78f027c initial checkin
james
parents:
diff changeset
   784
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   785
ab88e78f027c initial checkin
james
parents:
diff changeset
   786
commentTextEditorCreated:aScrolledViewWithTextEditor 
ab88e78f027c initial checkin
james
parents:
diff changeset
   787
    "do with the text editor widget as you will...."
ab88e78f027c initial checkin
james
parents:
diff changeset
   788
    editTextView := aScrolledViewWithTextEditor scrolledView.
ab88e78f027c initial checkin
james
parents:
diff changeset
   789
ab88e78f027c initial checkin
james
parents:
diff changeset
   790
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
   791
ab88e78f027c initial checkin
james
parents:
diff changeset
   792
!PackageDetails::Comment methodsFor:'change & update'!
ab88e78f027c initial checkin
james
parents:
diff changeset
   793
1268
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   794
packagesSelectedHolderChanged:selectedPackages 
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   795
    |packagesSelected selectedSinglePackage |
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   796
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   797
    packagesSelected := self packagesSelected.
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   798
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   799
    selectedPackages size == 1 ifTrue:[
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   800
        selectedSinglePackage := selectedPackages first.
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   801
        ^ commentTextHolder value: selectedSinglePackage packageComment.
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
   802
    ].
1268
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   803
    selectedPackages size == 0 ifTrue:[
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   804
        ^ commentTextHolder value:'No package selected' 
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   805
    ].   
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   806
    "selectedPackages size > 1 ifTrue:["
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   807
        ^ commentTextHolder value:'Cannot show more than one comment!!'  
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
   808
    "]."
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
   809
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   810
ab88e78f027c initial checkin
james
parents:
diff changeset
   811
validateCanChange:arg 
ab88e78f027c initial checkin
james
parents:
diff changeset
   812
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
   813
ab88e78f027c initial checkin
james
parents:
diff changeset
   814
!PackageDetails::Comment methodsFor:'defaults'!
ab88e78f027c initial checkin
james
parents:
diff changeset
   815
ab88e78f027c initial checkin
james
parents:
diff changeset
   816
commentForMultiplePackageSelect
ab88e78f027c initial checkin
james
parents:
diff changeset
   817
    ^ String new
ab88e78f027c initial checkin
james
parents:
diff changeset
   818
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
   819
ab88e78f027c initial checkin
james
parents:
diff changeset
   820
!PackageDetails::Comment methodsFor:'initialization & release'!
ab88e78f027c initial checkin
james
parents:
diff changeset
   821
ab88e78f027c initial checkin
james
parents:
diff changeset
   822
closeDownViews
ab88e78f027c initial checkin
james
parents:
diff changeset
   823
    "This is a hook method generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
   824
     It will be invoked when your app/dialog-window is really closed.
ab88e78f027c initial checkin
james
parents:
diff changeset
   825
     See also #closeDownViews, which is invoked before and may suppress the close
ab88e78f027c initial checkin
james
parents:
diff changeset
   826
     or ask the user for confirmation."
ab88e78f027c initial checkin
james
parents:
diff changeset
   827
ab88e78f027c initial checkin
james
parents:
diff changeset
   828
    "/ change the code below as required ...
ab88e78f027c initial checkin
james
parents:
diff changeset
   829
    "/ This should cleanup any leftover resources
ab88e78f027c initial checkin
james
parents:
diff changeset
   830
    "/ (for example, temporary files)
ab88e78f027c initial checkin
james
parents:
diff changeset
   831
    "/ super closeRequest will initiate the closeDown
ab88e78f027c initial checkin
james
parents:
diff changeset
   832
ab88e78f027c initial checkin
james
parents:
diff changeset
   833
    "/ add your code here
ab88e78f027c initial checkin
james
parents:
diff changeset
   834
ab88e78f027c initial checkin
james
parents:
diff changeset
   835
    "/ do not remove the one below ...
ab88e78f027c initial checkin
james
parents:
diff changeset
   836
    ^ super closeDownViews
ab88e78f027c initial checkin
james
parents:
diff changeset
   837
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   838
ab88e78f027c initial checkin
james
parents:
diff changeset
   839
closeRequest
ab88e78f027c initial checkin
james
parents:
diff changeset
   840
    "This is a hook method generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
   841
     It will be invoked when your app/dialog-window is about to be
ab88e78f027c initial checkin
james
parents:
diff changeset
   842
     closed (this method has a chance to suppress the close).
ab88e78f027c initial checkin
james
parents:
diff changeset
   843
     See also #closeDownViews, which is invoked when the close is really done."
ab88e78f027c initial checkin
james
parents:
diff changeset
   844
ab88e78f027c initial checkin
james
parents:
diff changeset
   845
    "/ change the code below as required ...
ab88e78f027c initial checkin
james
parents:
diff changeset
   846
    "/ Closing can be suppressed, by simply returning.
ab88e78f027c initial checkin
james
parents:
diff changeset
   847
    "/ The 'super closeRequest' at the end will initiate the real closeDown
ab88e78f027c initial checkin
james
parents:
diff changeset
   848
ab88e78f027c initial checkin
james
parents:
diff changeset
   849
    ("self hasUnsavedChanges" true) ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
   850
        (self confirm:(resources string:'Close without saving ?')) ifFalse:[
ab88e78f027c initial checkin
james
parents:
diff changeset
   851
            ^ self
ab88e78f027c initial checkin
james
parents:
diff changeset
   852
        ]
ab88e78f027c initial checkin
james
parents:
diff changeset
   853
    ].
ab88e78f027c initial checkin
james
parents:
diff changeset
   854
ab88e78f027c initial checkin
james
parents:
diff changeset
   855
    ^ super closeRequest
ab88e78f027c initial checkin
james
parents:
diff changeset
   856
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   857
ab88e78f027c initial checkin
james
parents:
diff changeset
   858
postBuildWith:aBuilder
ab88e78f027c initial checkin
james
parents:
diff changeset
   859
    "This is a hook method generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
   860
     It will be invoked during the initialization of your app/dialog,
ab88e78f027c initial checkin
james
parents:
diff changeset
   861
     after all of the visual components have been built, 
ab88e78f027c initial checkin
james
parents:
diff changeset
   862
     but BEFORE the top window is made visible.
ab88e78f027c initial checkin
james
parents:
diff changeset
   863
     Add any app-specific actions here (reading files, setting up values etc.)
ab88e78f027c initial checkin
james
parents:
diff changeset
   864
     See also #postOpenWith:, which is invoked after opening."
ab88e78f027c initial checkin
james
parents:
diff changeset
   865
ab88e78f027c initial checkin
james
parents:
diff changeset
   866
    "/ add any code here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
   867
ab88e78f027c initial checkin
james
parents:
diff changeset
   868
    ^ super postBuildWith:aBuilder
ab88e78f027c initial checkin
james
parents:
diff changeset
   869
!
ab88e78f027c initial checkin
james
parents:
diff changeset
   870
ab88e78f027c initial checkin
james
parents:
diff changeset
   871
postOpenWith:aBuilder
ab88e78f027c initial checkin
james
parents:
diff changeset
   872
    "This is a hook method generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
   873
     It will be invoked right after the applications window has been opened.
ab88e78f027c initial checkin
james
parents:
diff changeset
   874
     Add any app-specific actions here (starting background processes etc.).
ab88e78f027c initial checkin
james
parents:
diff changeset
   875
     See also #postBuildWith:, which is invoked before opening."
ab88e78f027c initial checkin
james
parents:
diff changeset
   876
ab88e78f027c initial checkin
james
parents:
diff changeset
   877
    "/ add any code here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
   878
ab88e78f027c initial checkin
james
parents:
diff changeset
   879
    ^ super postOpenWith:aBuilder
ab88e78f027c initial checkin
james
parents:
diff changeset
   880
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
   881
ab88e78f027c initial checkin
james
parents:
diff changeset
   882
!PackageDetails::LooseMethod class methodsFor:'constant values'!
ab88e78f027c initial checkin
james
parents:
diff changeset
   883
ab88e78f027c initial checkin
james
parents:
diff changeset
   884
applicationName
ab88e78f027c initial checkin
james
parents:
diff changeset
   885
    ^ 'Loose Method' asSymbol
ab88e78f027c initial checkin
james
parents:
diff changeset
   886
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
   887
ab88e78f027c initial checkin
james
parents:
diff changeset
   888
!PackageDetails::LooseMethod class methodsFor:'interface specs'!
ab88e78f027c initial checkin
james
parents:
diff changeset
   889
ab88e78f027c initial checkin
james
parents:
diff changeset
   890
windowSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
   891
    "This resource specification was automatically generated
ab88e78f027c initial checkin
james
parents:
diff changeset
   892
     by the UIPainter of ST/X."
ab88e78f027c initial checkin
james
parents:
diff changeset
   893
ab88e78f027c initial checkin
james
parents:
diff changeset
   894
    "Do not manually edit this!! If it is corrupted,
ab88e78f027c initial checkin
james
parents:
diff changeset
   895
     the UIPainter may not be able to read the specification."
ab88e78f027c initial checkin
james
parents:
diff changeset
   896
ab88e78f027c initial checkin
james
parents:
diff changeset
   897
    "
ab88e78f027c initial checkin
james
parents:
diff changeset
   898
     UIPainter new openOnClass:Packages::PackageDetails::LooseMethod andSelector:#windowSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
   899
     Packages::PackageDetails::LooseMethod new openInterface:#windowSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
   900
     Packages::PackageDetails::LooseMethod open
ab88e78f027c initial checkin
james
parents:
diff changeset
   901
    "
ab88e78f027c initial checkin
james
parents:
diff changeset
   902
ab88e78f027c initial checkin
james
parents:
diff changeset
   903
    <resource: #canvas>
ab88e78f027c initial checkin
james
parents:
diff changeset
   904
ab88e78f027c initial checkin
james
parents:
diff changeset
   905
    ^ 
ab88e78f027c initial checkin
james
parents:
diff changeset
   906
     #(#FullSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
   907
        #name: #windowSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
   908
        #window: 
ab88e78f027c initial checkin
james
parents:
diff changeset
   909
       #(#WindowSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
   910
          #label: 'Packages::PackageDetails::LooseMethod'
ab88e78f027c initial checkin
james
parents:
diff changeset
   911
          #name: 'Packages::PackageDetails::LooseMethod'
ab88e78f027c initial checkin
james
parents:
diff changeset
   912
          #min: #(#Point 10 10)
ab88e78f027c initial checkin
james
parents:
diff changeset
   913
          #max: #(#Point 1024 768)
ab88e78f027c initial checkin
james
parents:
diff changeset
   914
          #bounds: #(#Rectangle 29 59 329 359)
ab88e78f027c initial checkin
james
parents:
diff changeset
   915
          #menu: #mainMenu
ab88e78f027c initial checkin
james
parents:
diff changeset
   916
        )
ab88e78f027c initial checkin
james
parents:
diff changeset
   917
        #component: 
ab88e78f027c initial checkin
james
parents:
diff changeset
   918
       #(#SpecCollection
ab88e78f027c initial checkin
james
parents:
diff changeset
   919
          #collection: #(
ab88e78f027c initial checkin
james
parents:
diff changeset
   920
           #(#VariableVerticalPanelSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
   921
              #name: 'VariableVerticalPanel1'
ab88e78f027c initial checkin
james
parents:
diff changeset
   922
              #layout: #(#LayoutFrame 0 0 0 0 0 1 0 1)
ab88e78f027c initial checkin
james
parents:
diff changeset
   923
              #component: 
ab88e78f027c initial checkin
james
parents:
diff changeset
   924
             #(#SpecCollection
ab88e78f027c initial checkin
james
parents:
diff changeset
   925
                #collection: #(
ab88e78f027c initial checkin
james
parents:
diff changeset
   926
                 #(#DataSetSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
   927
                    #name: 'Table1'
ab88e78f027c initial checkin
james
parents:
diff changeset
   928
                    #model: #methodSelectedHolder
ab88e78f027c initial checkin
james
parents:
diff changeset
   929
                    #hasHorizontalScrollBar: true
ab88e78f027c initial checkin
james
parents:
diff changeset
   930
                    #hasVerticalScrollBar: true
ab88e78f027c initial checkin
james
parents:
diff changeset
   931
                    #dataList: #methodList
ab88e78f027c initial checkin
james
parents:
diff changeset
   932
                    #has3Dsepartors: false
ab88e78f027c initial checkin
james
parents:
diff changeset
   933
                    #columnHolder: #tableColumns
ab88e78f027c initial checkin
james
parents:
diff changeset
   934
                    #multipleSelectOk: true
ab88e78f027c initial checkin
james
parents:
diff changeset
   935
                    #verticalSpacing: 0
ab88e78f027c initial checkin
james
parents:
diff changeset
   936
                  )
ab88e78f027c initial checkin
james
parents:
diff changeset
   937
                 #(#TextEditorSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
   938
                    #name: 'SourceEditor'
ab88e78f027c initial checkin
james
parents:
diff changeset
   939
                    #model: #currentMethodSourceHolder
ab88e78f027c initial checkin
james
parents:
diff changeset
   940
                    #hasHorizontalScrollBar: true
ab88e78f027c initial checkin
james
parents:
diff changeset
   941
                    #hasVerticalScrollBar: true
ab88e78f027c initial checkin
james
parents:
diff changeset
   942
                  )
ab88e78f027c initial checkin
james
parents:
diff changeset
   943
                 )
ab88e78f027c initial checkin
james
parents:
diff changeset
   944
               
ab88e78f027c initial checkin
james
parents:
diff changeset
   945
              )
ab88e78f027c initial checkin
james
parents:
diff changeset
   946
              #handles: #(#Any 0.5 1.0)
ab88e78f027c initial checkin
james
parents:
diff changeset
   947
            )
ab88e78f027c initial checkin
james
parents:
diff changeset
   948
           )
ab88e78f027c initial checkin
james
parents:
diff changeset
   949
         
ab88e78f027c initial checkin
james
parents:
diff changeset
   950
        )
ab88e78f027c initial checkin
james
parents:
diff changeset
   951
      )
ab88e78f027c initial checkin
james
parents:
diff changeset
   952
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
   953
ab88e78f027c initial checkin
james
parents:
diff changeset
   954
!PackageDetails::LooseMethod class methodsFor:'menu specs'!
ab88e78f027c initial checkin
james
parents:
diff changeset
   955
ab88e78f027c initial checkin
james
parents:
diff changeset
   956
mainMenu
ab88e78f027c initial checkin
james
parents:
diff changeset
   957
    "This resource specification was automatically generated by the CodeGeneratorTool."
ab88e78f027c initial checkin
james
parents:
diff changeset
   958
ab88e78f027c initial checkin
james
parents:
diff changeset
   959
    "Do not manually edit this!! If it is corrupted,
ab88e78f027c initial checkin
james
parents:
diff changeset
   960
     the MenuEditor may not be able to read the specification."
ab88e78f027c initial checkin
james
parents:
diff changeset
   961
ab88e78f027c initial checkin
james
parents:
diff changeset
   962
    "
ab88e78f027c initial checkin
james
parents:
diff changeset
   963
     MenuEditor new openOnClass:Packages::PackageDetails::LooseMethod andSelector:#mainMenu
ab88e78f027c initial checkin
james
parents:
diff changeset
   964
    "
ab88e78f027c initial checkin
james
parents:
diff changeset
   965
ab88e78f027c initial checkin
james
parents:
diff changeset
   966
    <resource: #menu>
ab88e78f027c initial checkin
james
parents:
diff changeset
   967
ab88e78f027c initial checkin
james
parents:
diff changeset
   968
    ^ #(#Menu
ab88e78f027c initial checkin
james
parents:
diff changeset
   969
           #(
ab88e78f027c initial checkin
james
parents:
diff changeset
   970
             #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
   971
                #label: 'File'
ab88e78f027c initial checkin
james
parents:
diff changeset
   972
                #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
   973
                #submenu: 
ab88e78f027c initial checkin
james
parents:
diff changeset
   974
                 #(#Menu
ab88e78f027c initial checkin
james
parents:
diff changeset
   975
                     #(
ab88e78f027c initial checkin
james
parents:
diff changeset
   976
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
   977
                          #label: 'New'
ab88e78f027c initial checkin
james
parents:
diff changeset
   978
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
   979
                          #value: #menuNew
ab88e78f027c initial checkin
james
parents:
diff changeset
   980
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
   981
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
   982
                          #label: '-'
ab88e78f027c initial checkin
james
parents:
diff changeset
   983
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
   984
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
   985
                          #label: 'Open...'
ab88e78f027c initial checkin
james
parents:
diff changeset
   986
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
   987
                          #value: #menuOpen
ab88e78f027c initial checkin
james
parents:
diff changeset
   988
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
   989
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
   990
                          #label: '-'
ab88e78f027c initial checkin
james
parents:
diff changeset
   991
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
   992
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
   993
                          #label: 'Save'
ab88e78f027c initial checkin
james
parents:
diff changeset
   994
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
   995
                          #value: #menuSave
ab88e78f027c initial checkin
james
parents:
diff changeset
   996
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
   997
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
   998
                          #label: 'Save As...'
ab88e78f027c initial checkin
james
parents:
diff changeset
   999
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1000
                          #value: #menuSaveAs
ab88e78f027c initial checkin
james
parents:
diff changeset
  1001
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1002
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1003
                          #label: '-'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1004
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1005
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1006
                          #label: 'Exit'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1007
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1008
                          #value: #closeRequest
ab88e78f027c initial checkin
james
parents:
diff changeset
  1009
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1010
                    ) nil
ab88e78f027c initial checkin
james
parents:
diff changeset
  1011
                    nil
ab88e78f027c initial checkin
james
parents:
diff changeset
  1012
                )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1013
            )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1014
             #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1015
                #label: 'Help'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1016
                #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1017
                #startGroup: #right
ab88e78f027c initial checkin
james
parents:
diff changeset
  1018
                #submenu: 
ab88e78f027c initial checkin
james
parents:
diff changeset
  1019
                 #(#Menu
ab88e78f027c initial checkin
james
parents:
diff changeset
  1020
                     #(
ab88e78f027c initial checkin
james
parents:
diff changeset
  1021
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1022
                          #label: 'Documentation'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1023
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1024
                          #value: #openDocumentation
ab88e78f027c initial checkin
james
parents:
diff changeset
  1025
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1026
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1027
                          #label: '-'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1028
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1029
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1030
                          #label: 'About this Application'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1031
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1032
                          #value: #openAboutThisApplication
ab88e78f027c initial checkin
james
parents:
diff changeset
  1033
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1034
                    ) nil
ab88e78f027c initial checkin
james
parents:
diff changeset
  1035
                    nil
ab88e78f027c initial checkin
james
parents:
diff changeset
  1036
                )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1037
            )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1038
          ) nil
ab88e78f027c initial checkin
james
parents:
diff changeset
  1039
          nil
ab88e78f027c initial checkin
james
parents:
diff changeset
  1040
      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1041
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1042
ab88e78f027c initial checkin
james
parents:
diff changeset
  1043
!PackageDetails::LooseMethod class methodsFor:'tableColumns specs'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1044
ab88e78f027c initial checkin
james
parents:
diff changeset
  1045
tableColumns
ab88e78f027c initial checkin
james
parents:
diff changeset
  1046
    "This resource specification was automatically generated
ab88e78f027c initial checkin
james
parents:
diff changeset
  1047
     by the DataSetBuilder of ST/X."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1048
ab88e78f027c initial checkin
james
parents:
diff changeset
  1049
    "Do not manually edit this!! If it is corrupted,
ab88e78f027c initial checkin
james
parents:
diff changeset
  1050
     the DataSetBuilder may not be able to read the specification."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1051
ab88e78f027c initial checkin
james
parents:
diff changeset
  1052
    "
ab88e78f027c initial checkin
james
parents:
diff changeset
  1053
     DataSetBuilder new openOnClass:Packages::PackageDetails::LooseMethod andSelector:#tableColumns
ab88e78f027c initial checkin
james
parents:
diff changeset
  1054
    "
ab88e78f027c initial checkin
james
parents:
diff changeset
  1055
ab88e78f027c initial checkin
james
parents:
diff changeset
  1056
    <resource: #tableColumns>
ab88e78f027c initial checkin
james
parents:
diff changeset
  1057
ab88e78f027c initial checkin
james
parents:
diff changeset
  1058
    ^#(
ab88e78f027c initial checkin
james
parents:
diff changeset
  1059
      #(#DataSetColumnSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
  1060
         #label: ''
ab88e78f027c initial checkin
james
parents:
diff changeset
  1061
         #id: 'Icon'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1062
         #labelButtonType: #Button
ab88e78f027c initial checkin
james
parents:
diff changeset
  1063
         #model: #icon
ab88e78f027c initial checkin
james
parents:
diff changeset
  1064
         #canSelect: false
ab88e78f027c initial checkin
james
parents:
diff changeset
  1065
         #showRowSeparator: false
ab88e78f027c initial checkin
james
parents:
diff changeset
  1066
         #showColSeparator: false
ab88e78f027c initial checkin
james
parents:
diff changeset
  1067
       )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1068
      #(#DataSetColumnSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
  1069
         #label: 'Selector'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1070
         #id: 'Selector'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1071
         #labelAlignment: #left
ab88e78f027c initial checkin
james
parents:
diff changeset
  1072
         #labelButtonType: #Button
ab88e78f027c initial checkin
james
parents:
diff changeset
  1073
         #model: #selector
ab88e78f027c initial checkin
james
parents:
diff changeset
  1074
         #canSelect: false
ab88e78f027c initial checkin
james
parents:
diff changeset
  1075
         #showRowSeparator: false
ab88e78f027c initial checkin
james
parents:
diff changeset
  1076
         #showColSeparator: false
ab88e78f027c initial checkin
james
parents:
diff changeset
  1077
       )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1078
      #(#DataSetColumnSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
  1079
         #label: 'Class'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1080
         #id: 'Class'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1081
         #labelAlignment: #left
ab88e78f027c initial checkin
james
parents:
diff changeset
  1082
         #labelButtonType: #Button
ab88e78f027c initial checkin
james
parents:
diff changeset
  1083
         #model: #myClass
ab88e78f027c initial checkin
james
parents:
diff changeset
  1084
         #canSelect: false
ab88e78f027c initial checkin
james
parents:
diff changeset
  1085
         #showRowSeparator: false
ab88e78f027c initial checkin
james
parents:
diff changeset
  1086
         #showColSeparator: false
ab88e78f027c initial checkin
james
parents:
diff changeset
  1087
       )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1088
      #(#DataSetColumnSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
  1089
         #label: 'Package'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1090
         #id: 'Package'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1091
         #labelButtonType: #Button
ab88e78f027c initial checkin
james
parents:
diff changeset
  1092
         #model: #myPackage
ab88e78f027c initial checkin
james
parents:
diff changeset
  1093
         #canSelect: false
ab88e78f027c initial checkin
james
parents:
diff changeset
  1094
         #showRowSeparator: false
ab88e78f027c initial checkin
james
parents:
diff changeset
  1095
         #showColSeparator: false
ab88e78f027c initial checkin
james
parents:
diff changeset
  1096
       )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1097
      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1098
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1099
ab88e78f027c initial checkin
james
parents:
diff changeset
  1100
tableColumnsOld
ab88e78f027c initial checkin
james
parents:
diff changeset
  1101
    "This resource specification was automatically generated
ab88e78f027c initial checkin
james
parents:
diff changeset
  1102
     by the DataSetBuilder of ST/X."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1103
ab88e78f027c initial checkin
james
parents:
diff changeset
  1104
    "Do not manually edit this!! If it is corrupted,
ab88e78f027c initial checkin
james
parents:
diff changeset
  1105
     the DataSetBuilder may not be able to read the specification."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1106
ab88e78f027c initial checkin
james
parents:
diff changeset
  1107
    "
ab88e78f027c initial checkin
james
parents:
diff changeset
  1108
     DataSetBuilder new openOnClass:Packages::PackageDetails::LooseMethod andSelector:#tableColumns
ab88e78f027c initial checkin
james
parents:
diff changeset
  1109
    "
ab88e78f027c initial checkin
james
parents:
diff changeset
  1110
ab88e78f027c initial checkin
james
parents:
diff changeset
  1111
    <resource: #tableColumns>
ab88e78f027c initial checkin
james
parents:
diff changeset
  1112
ab88e78f027c initial checkin
james
parents:
diff changeset
  1113
    ^#(
ab88e78f027c initial checkin
james
parents:
diff changeset
  1114
      #(#DataSetColumnSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
  1115
         #label: ''
ab88e78f027c initial checkin
james
parents:
diff changeset
  1116
         #id: 'Icon'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1117
         #labelButtonType: #Button
ab88e78f027c initial checkin
james
parents:
diff changeset
  1118
         #model: #icon
ab88e78f027c initial checkin
james
parents:
diff changeset
  1119
         #canSelect: false
ab88e78f027c initial checkin
james
parents:
diff changeset
  1120
       )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1121
      #(#DataSetColumnSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
  1122
         #label: 'Selector'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1123
         #id: 'Selector'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1124
         #labelAlignment: #left
ab88e78f027c initial checkin
james
parents:
diff changeset
  1125
         #labelButtonType: #Button
ab88e78f027c initial checkin
james
parents:
diff changeset
  1126
         #model: #selector
ab88e78f027c initial checkin
james
parents:
diff changeset
  1127
         #canSelect: false
ab88e78f027c initial checkin
james
parents:
diff changeset
  1128
       )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1129
      #(#DataSetColumnSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
  1130
         #label: 'Class'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1131
         #id: 'Class'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1132
         #labelAlignment: #left
ab88e78f027c initial checkin
james
parents:
diff changeset
  1133
         #labelButtonType: #Button
ab88e78f027c initial checkin
james
parents:
diff changeset
  1134
         #model: #myClass
ab88e78f027c initial checkin
james
parents:
diff changeset
  1135
         #canSelect: false
ab88e78f027c initial checkin
james
parents:
diff changeset
  1136
       )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1137
      #(#DataSetColumnSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
  1138
         #label: 'Package'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1139
         #id: 'Package'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1140
         #labelButtonType: #Button
ab88e78f027c initial checkin
james
parents:
diff changeset
  1141
         #model: #myPackage
ab88e78f027c initial checkin
james
parents:
diff changeset
  1142
         #canSelect: false
ab88e78f027c initial checkin
james
parents:
diff changeset
  1143
       )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1144
      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1145
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1146
ab88e78f027c initial checkin
james
parents:
diff changeset
  1147
!PackageDetails::LooseMethod methodsFor:'accessing'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1148
ab88e78f027c initial checkin
james
parents:
diff changeset
  1149
currentMethodSource:aString 
ab88e78f027c initial checkin
james
parents:
diff changeset
  1150
    self currentMethodSourceHolder value:aString
ab88e78f027c initial checkin
james
parents:
diff changeset
  1151
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1152
ab88e78f027c initial checkin
james
parents:
diff changeset
  1153
declareDependents
ab88e78f027c initial checkin
james
parents:
diff changeset
  1154
    super declareDependents
ab88e78f027c initial checkin
james
parents:
diff changeset
  1155
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1156
ab88e78f027c initial checkin
james
parents:
diff changeset
  1157
!PackageDetails::LooseMethod methodsFor:'aspects'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1158
ab88e78f027c initial checkin
james
parents:
diff changeset
  1159
currentMethodSourceHolder
ab88e78f027c initial checkin
james
parents:
diff changeset
  1160
    "automatically generated by UIPainter ..."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1161
ab88e78f027c initial checkin
james
parents:
diff changeset
  1162
    "*** the code below creates a default model when invoked."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1163
    "*** (which may not be the one you wanted)"
ab88e78f027c initial checkin
james
parents:
diff changeset
  1164
    "*** Please change as required and accept it in the browser."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1165
    "*** (and replace this comment by something more useful ;-)"
ab88e78f027c initial checkin
james
parents:
diff changeset
  1166
ab88e78f027c initial checkin
james
parents:
diff changeset
  1167
    currentMethodSourceHolder isNil ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
  1168
        currentMethodSourceHolder := '' asValue.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1169
"/ if your app needs to be notified of changes, uncomment one of the lines below:
ab88e78f027c initial checkin
james
parents:
diff changeset
  1170
"/       currentMethodSourceHolder addDependent:self.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1171
"/       currentMethodSourceHolder onChangeSend:#currentMethodSourceHolderChanged to:self.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1172
    ].
ab88e78f027c initial checkin
james
parents:
diff changeset
  1173
    ^ currentMethodSourceHolder.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1174
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1175
ab88e78f027c initial checkin
james
parents:
diff changeset
  1176
methodList
ab88e78f027c initial checkin
james
parents:
diff changeset
  1177
    "automatically generated by UIPainter ..."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1178
ab88e78f027c initial checkin
james
parents:
diff changeset
  1179
    "*** the code below creates a default model when invoked."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1180
    "*** (which may not be the one you wanted)"
ab88e78f027c initial checkin
james
parents:
diff changeset
  1181
    "*** Please change as required and accept it in the browser."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1182
    "*** (and replace this comment by something more useful ;-)"
ab88e78f027c initial checkin
james
parents:
diff changeset
  1183
ab88e78f027c initial checkin
james
parents:
diff changeset
  1184
    methodList isNil ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
  1185
        methodList := List new.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1186
"/ if your app needs to be notified of changes, uncomment one of the lines below:
ab88e78f027c initial checkin
james
parents:
diff changeset
  1187
"/       methodList addDependent:self.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1188
"/       methodList onChangeSend:#methodListChanged to:self.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1189
    ].
ab88e78f027c initial checkin
james
parents:
diff changeset
  1190
    ^ methodList.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1191
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1192
ab88e78f027c initial checkin
james
parents:
diff changeset
  1193
methodSelectedHolder
ab88e78f027c initial checkin
james
parents:
diff changeset
  1194
    "automatically generated by UIPainter ..."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1195
ab88e78f027c initial checkin
james
parents:
diff changeset
  1196
    "*** the code below creates a default model when invoked."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1197
    "*** (which may not be the one you wanted)"
ab88e78f027c initial checkin
james
parents:
diff changeset
  1198
    "*** Please change as required and accept it in the browser."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1199
    "*** (and replace this comment by something more useful ;-)"
ab88e78f027c initial checkin
james
parents:
diff changeset
  1200
ab88e78f027c initial checkin
james
parents:
diff changeset
  1201
    methodSelectedHolder isNil ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
  1202
        methodSelectedHolder := ValueHolder new.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1203
        methodSelectedHolder onChangeEvaluate:[| methodSelectedHolderValue|
ab88e78f027c initial checkin
james
parents:
diff changeset
  1204
            (methodSelectedHolderValue := methodSelectedHolder value) ifNotNil:[
ab88e78f027c initial checkin
james
parents:
diff changeset
  1205
                self currentMethodSourceChangedToIndex:methodSelectedHolderValue
ab88e78f027c initial checkin
james
parents:
diff changeset
  1206
            ].
ab88e78f027c initial checkin
james
parents:
diff changeset
  1207
ab88e78f027c initial checkin
james
parents:
diff changeset
  1208
        ]
ab88e78f027c initial checkin
james
parents:
diff changeset
  1209
    ].
ab88e78f027c initial checkin
james
parents:
diff changeset
  1210
    ^ methodSelectedHolder.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1211
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1212
ab88e78f027c initial checkin
james
parents:
diff changeset
  1213
tableColumns
ab88e78f027c initial checkin
james
parents:
diff changeset
  1214
    "automatically generated by UIPainter ..."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1215
ab88e78f027c initial checkin
james
parents:
diff changeset
  1216
    "*** the code below creates a default model when invoked."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1217
    "*** (which may not be the one you wanted)"
ab88e78f027c initial checkin
james
parents:
diff changeset
  1218
    "*** Please change as required and accept it in the browser."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1219
    "*** (and replace this comment by something more useful ;-)"
ab88e78f027c initial checkin
james
parents:
diff changeset
  1220
ab88e78f027c initial checkin
james
parents:
diff changeset
  1221
    tableColumns isNil ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
  1222
        tableColumns := self class tableColumns asValue.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1223
"/ if your app needs to be notified of changes, uncomment one of the lines below:
ab88e78f027c initial checkin
james
parents:
diff changeset
  1224
"/       tableColumns addDependent:self.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1225
"/       tableColumns onChangeSend:#tableColumnsChanged to:self.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1226
    ].
ab88e78f027c initial checkin
james
parents:
diff changeset
  1227
    ^ tableColumns.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1228
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1229
ab88e78f027c initial checkin
james
parents:
diff changeset
  1230
!PackageDetails::LooseMethod methodsFor:'change & update'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1231
ab88e78f027c initial checkin
james
parents:
diff changeset
  1232
currentMethodSourceChangedToIndex:aCollection
ab88e78f027c initial checkin
james
parents:
diff changeset
  1233
    | currentPackageDetailsRow |
ab88e78f027c initial checkin
james
parents:
diff changeset
  1234
    aCollection size > 1 ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
  1235
        self currentMethodSource: self moreThanOneMethodCode.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1236
        ^ self.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1237
    ].
ab88e78f027c initial checkin
james
parents:
diff changeset
  1238
    currentPackageDetailsRow := (self methodList at:aCollection first).
ab88e78f027c initial checkin
james
parents:
diff changeset
  1239
    self currentMethodSourceHolder value:(currentPackageDetailsRow model source).
ab88e78f027c initial checkin
james
parents:
diff changeset
  1240
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1241
ab88e78f027c initial checkin
james
parents:
diff changeset
  1242
updateWithPackages:packages
ab88e78f027c initial checkin
james
parents:
diff changeset
  1243
    | methodNames |
ab88e78f027c initial checkin
james
parents:
diff changeset
  1244
    methodList removeAll.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1245
    currentMethodSourceHolder value:String new.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1246
    methodNames := OrderedCollection new.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1247
ab88e78f027c initial checkin
james
parents:
diff changeset
  1248
    packages do:[:aPackage | 
ab88e78f027c initial checkin
james
parents:
diff changeset
  1249
        methodNames addAll:(aPackage looseMethods collect:[:aMethod| self newPackageDetailsRowWithModel:aMethod]).   
ab88e78f027c initial checkin
james
parents:
diff changeset
  1250
    ].
ab88e78f027c initial checkin
james
parents:
diff changeset
  1251
ab88e78f027c initial checkin
james
parents:
diff changeset
  1252
    methodList addAll:methodNames.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1253
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1254
ab88e78f027c initial checkin
james
parents:
diff changeset
  1255
validateCanChange:arg 
ab88e78f027c initial checkin
james
parents:
diff changeset
  1256
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1257
ab88e78f027c initial checkin
james
parents:
diff changeset
  1258
!PackageDetails::LooseMethod methodsFor:'defaults'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1259
ab88e78f027c initial checkin
james
parents:
diff changeset
  1260
moreThanOneMethodCode
ab88e78f027c initial checkin
james
parents:
diff changeset
  1261
    ^ String new
ab88e78f027c initial checkin
james
parents:
diff changeset
  1262
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1263
ab88e78f027c initial checkin
james
parents:
diff changeset
  1264
!PackageDetails::LooseMethod methodsFor:'factory'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1265
ab88e78f027c initial checkin
james
parents:
diff changeset
  1266
newPackageDetailsRowWithModel:aModel 
ab88e78f027c initial checkin
james
parents:
diff changeset
  1267
    ^ PackageDetailsRow new model: aModel
ab88e78f027c initial checkin
james
parents:
diff changeset
  1268
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1269
ab88e78f027c initial checkin
james
parents:
diff changeset
  1270
!PackageDetails::LooseMethod methodsFor:'initialization & release'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1271
ab88e78f027c initial checkin
james
parents:
diff changeset
  1272
closeDownViews
ab88e78f027c initial checkin
james
parents:
diff changeset
  1273
    "This is a hook method generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1274
     It will be invoked when your app/dialog-window is really closed.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1275
     See also #closeDownViews, which is invoked before and may suppress the close
ab88e78f027c initial checkin
james
parents:
diff changeset
  1276
     or ask the user for confirmation."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1277
ab88e78f027c initial checkin
james
parents:
diff changeset
  1278
    "/ change the code below as required ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1279
    "/ This should cleanup any leftover resources
ab88e78f027c initial checkin
james
parents:
diff changeset
  1280
    "/ (for example, temporary files)
ab88e78f027c initial checkin
james
parents:
diff changeset
  1281
    "/ super closeRequest will initiate the closeDown
ab88e78f027c initial checkin
james
parents:
diff changeset
  1282
ab88e78f027c initial checkin
james
parents:
diff changeset
  1283
    "/ add your code here
ab88e78f027c initial checkin
james
parents:
diff changeset
  1284
ab88e78f027c initial checkin
james
parents:
diff changeset
  1285
    "/ do not remove the one below ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1286
    ^ super closeDownViews
ab88e78f027c initial checkin
james
parents:
diff changeset
  1287
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1288
ab88e78f027c initial checkin
james
parents:
diff changeset
  1289
closeRequest
ab88e78f027c initial checkin
james
parents:
diff changeset
  1290
    "This is a hook method generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1291
     It will be invoked when your app/dialog-window is about to be
ab88e78f027c initial checkin
james
parents:
diff changeset
  1292
     closed (this method has a chance to suppress the close).
ab88e78f027c initial checkin
james
parents:
diff changeset
  1293
     See also #closeDownViews, which is invoked when the close is really done."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1294
ab88e78f027c initial checkin
james
parents:
diff changeset
  1295
    "/ change the code below as required ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1296
    "/ Closing can be suppressed, by simply returning.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1297
    "/ The 'super closeRequest' at the end will initiate the real closeDown
ab88e78f027c initial checkin
james
parents:
diff changeset
  1298
ab88e78f027c initial checkin
james
parents:
diff changeset
  1299
    ("self hasUnsavedChanges" true) ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
  1300
        (self confirm:(resources string:'Close without saving ?')) ifFalse:[
ab88e78f027c initial checkin
james
parents:
diff changeset
  1301
            ^ self
ab88e78f027c initial checkin
james
parents:
diff changeset
  1302
        ]
ab88e78f027c initial checkin
james
parents:
diff changeset
  1303
    ].
ab88e78f027c initial checkin
james
parents:
diff changeset
  1304
ab88e78f027c initial checkin
james
parents:
diff changeset
  1305
    ^ super closeRequest
ab88e78f027c initial checkin
james
parents:
diff changeset
  1306
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1307
ab88e78f027c initial checkin
james
parents:
diff changeset
  1308
postBuildWith:aBuilder
ab88e78f027c initial checkin
james
parents:
diff changeset
  1309
    "This is a hook method generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1310
     It will be invoked during the initialization of your app/dialog,
ab88e78f027c initial checkin
james
parents:
diff changeset
  1311
     after all of the visual components have been built, 
ab88e78f027c initial checkin
james
parents:
diff changeset
  1312
     but BEFORE the top window is made visible.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1313
     Add any app-specific actions here (reading files, setting up values etc.)
ab88e78f027c initial checkin
james
parents:
diff changeset
  1314
     See also #postOpenWith:, which is invoked after opening."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1315
ab88e78f027c initial checkin
james
parents:
diff changeset
  1316
    "/ add any code here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1317
    ^ super postBuildWith:aBuilder
ab88e78f027c initial checkin
james
parents:
diff changeset
  1318
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1319
ab88e78f027c initial checkin
james
parents:
diff changeset
  1320
postOpenWith:aBuilder
ab88e78f027c initial checkin
james
parents:
diff changeset
  1321
    "This is a hook method generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1322
     It will be invoked right after the applications window has been opened.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1323
     Add any app-specific actions here (starting background processes etc.).
ab88e78f027c initial checkin
james
parents:
diff changeset
  1324
     See also #postBuildWith:, which is invoked before opening."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1325
ab88e78f027c initial checkin
james
parents:
diff changeset
  1326
    "/ add any code here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1327
ab88e78f027c initial checkin
james
parents:
diff changeset
  1328
    ^ super postOpenWith:aBuilder
ab88e78f027c initial checkin
james
parents:
diff changeset
  1329
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1330
ab88e78f027c initial checkin
james
parents:
diff changeset
  1331
!PackageDetails::LooseMethod methodsFor:'menu actions'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1332
ab88e78f027c initial checkin
james
parents:
diff changeset
  1333
menuNew
ab88e78f027c initial checkin
james
parents:
diff changeset
  1334
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1335
     It will be invoked when the menu-item 'new' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1336
ab88e78f027c initial checkin
james
parents:
diff changeset
  1337
    "/ change below and add any actions as required here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1338
    self warn:'no action for ''new'' available.'.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1339
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1340
ab88e78f027c initial checkin
james
parents:
diff changeset
  1341
menuOpen
ab88e78f027c initial checkin
james
parents:
diff changeset
  1342
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1343
     It will be invoked when the menu-item 'open' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1344
ab88e78f027c initial checkin
james
parents:
diff changeset
  1345
    "/ change below and add any actions as required here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1346
    self warn:'no action for ''open'' available.'.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1347
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1348
ab88e78f027c initial checkin
james
parents:
diff changeset
  1349
menuSave
ab88e78f027c initial checkin
james
parents:
diff changeset
  1350
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1351
     It will be invoked when the menu-item 'save' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1352
ab88e78f027c initial checkin
james
parents:
diff changeset
  1353
    "/ change below and add any actions as required here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1354
    self warn:'no action for ''save'' available.'.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1355
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1356
ab88e78f027c initial checkin
james
parents:
diff changeset
  1357
menuSaveAs
ab88e78f027c initial checkin
james
parents:
diff changeset
  1358
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1359
     It will be invoked when the menu-item 'saveAs' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1360
ab88e78f027c initial checkin
james
parents:
diff changeset
  1361
    "/ change below and add any actions as required here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1362
    self warn:'no action for ''saveAs'' available.'.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1363
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1364
ab88e78f027c initial checkin
james
parents:
diff changeset
  1365
openAboutThisApplication
ab88e78f027c initial checkin
james
parents:
diff changeset
  1366
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1367
     It will be invoked when the menu-item 'help-about' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1368
ab88e78f027c initial checkin
james
parents:
diff changeset
  1369
    "/ could open a customized aboutBox here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1370
    super openAboutThisApplication
ab88e78f027c initial checkin
james
parents:
diff changeset
  1371
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1372
ab88e78f027c initial checkin
james
parents:
diff changeset
  1373
openDocumentation
ab88e78f027c initial checkin
james
parents:
diff changeset
  1374
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1375
     It will be invoked when the menu-item 'help-documentation' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1376
ab88e78f027c initial checkin
james
parents:
diff changeset
  1377
    "/ change below as required ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1378
ab88e78f027c initial checkin
james
parents:
diff changeset
  1379
    "/ to open an HTML viewer on some document (under 'doc/online/<language>/' ):
ab88e78f027c initial checkin
james
parents:
diff changeset
  1380
    HTMLDocumentView openFullOnDocumentationFile:'TOP.html'.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1381
ab88e78f027c initial checkin
james
parents:
diff changeset
  1382
    "/ add application-specific help files under the 'doc/online/<language>/help/appName'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1383
    "/ directory, and open a viewer with:
ab88e78f027c initial checkin
james
parents:
diff changeset
  1384
    "/ HTMLDocumentView openFullOnDocumentationFile:'help/<MyApplication>/TOP.html'.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1385
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1386
ab88e78f027c initial checkin
james
parents:
diff changeset
  1387
!PackageDetails::LooseMethod::PackageDetailsRow methodsFor:'accessing'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1388
ab88e78f027c initial checkin
james
parents:
diff changeset
  1389
icon
ab88e78f027c initial checkin
james
parents:
diff changeset
  1390
    "automatically generated by DataSetBuilder ..."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1391
ab88e78f027c initial checkin
james
parents:
diff changeset
  1392
    "get value"
ab88e78f027c initial checkin
james
parents:
diff changeset
  1393
ab88e78f027c initial checkin
james
parents:
diff changeset
  1394
    ^ ''
ab88e78f027c initial checkin
james
parents:
diff changeset
  1395
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1396
ab88e78f027c initial checkin
james
parents:
diff changeset
  1397
model
ab88e78f027c initial checkin
james
parents:
diff changeset
  1398
    "return the value of the instance variable 'model' (automatically generated)"
ab88e78f027c initial checkin
james
parents:
diff changeset
  1399
ab88e78f027c initial checkin
james
parents:
diff changeset
  1400
    ^ model
ab88e78f027c initial checkin
james
parents:
diff changeset
  1401
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1402
ab88e78f027c initial checkin
james
parents:
diff changeset
  1403
model:arg 
ab88e78f027c initial checkin
james
parents:
diff changeset
  1404
    model:= arg.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1405
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1406
ab88e78f027c initial checkin
james
parents:
diff changeset
  1407
myClass
ab88e78f027c initial checkin
james
parents:
diff changeset
  1408
    "automatically generated by DataSetBuilder ..."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1409
ab88e78f027c initial checkin
james
parents:
diff changeset
  1410
    "get value"
ab88e78f027c initial checkin
james
parents:
diff changeset
  1411
ab88e78f027c initial checkin
james
parents:
diff changeset
  1412
    ^ model mclass
ab88e78f027c initial checkin
james
parents:
diff changeset
  1413
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1414
ab88e78f027c initial checkin
james
parents:
diff changeset
  1415
myPackage
ab88e78f027c initial checkin
james
parents:
diff changeset
  1416
    "automatically generated by DataSetBuilder ..."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1417
ab88e78f027c initial checkin
james
parents:
diff changeset
  1418
    "get value"
ab88e78f027c initial checkin
james
parents:
diff changeset
  1419
ab88e78f027c initial checkin
james
parents:
diff changeset
  1420
    ^ model package
ab88e78f027c initial checkin
james
parents:
diff changeset
  1421
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1422
ab88e78f027c initial checkin
james
parents:
diff changeset
  1423
selector
ab88e78f027c initial checkin
james
parents:
diff changeset
  1424
    "automatically generated by DataSetBuilder ..."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1425
ab88e78f027c initial checkin
james
parents:
diff changeset
  1426
    "get value"
ab88e78f027c initial checkin
james
parents:
diff changeset
  1427
ab88e78f027c initial checkin
james
parents:
diff changeset
  1428
    ^ model selector
ab88e78f027c initial checkin
james
parents:
diff changeset
  1429
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1430
ab88e78f027c initial checkin
james
parents:
diff changeset
  1431
!PackageDetails::Prerequisites class methodsFor:'constant values'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1432
ab88e78f027c initial checkin
james
parents:
diff changeset
  1433
applicationName
ab88e78f027c initial checkin
james
parents:
diff changeset
  1434
    ^ 'Prerequisites' asSymbol
ab88e78f027c initial checkin
james
parents:
diff changeset
  1435
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1436
ab88e78f027c initial checkin
james
parents:
diff changeset
  1437
!PackageDetails::Prerequisites class methodsFor:'interface specs'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1438
ab88e78f027c initial checkin
james
parents:
diff changeset
  1439
windowSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
  1440
    "This resource specification was automatically generated by the CodeGeneratorTool."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1441
ab88e78f027c initial checkin
james
parents:
diff changeset
  1442
    "Do not manually edit this!! If it is corrupted,
ab88e78f027c initial checkin
james
parents:
diff changeset
  1443
     the UIPainter may not be able to read the specification."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1444
ab88e78f027c initial checkin
james
parents:
diff changeset
  1445
    "
ab88e78f027c initial checkin
james
parents:
diff changeset
  1446
     UIPainter new openOnClass:Packages::PackageDetails::Prerequisites andSelector:#windowSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
  1447
    "
ab88e78f027c initial checkin
james
parents:
diff changeset
  1448
ab88e78f027c initial checkin
james
parents:
diff changeset
  1449
    <resource: #canvas>
ab88e78f027c initial checkin
james
parents:
diff changeset
  1450
ab88e78f027c initial checkin
james
parents:
diff changeset
  1451
    ^ #(#FullSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
  1452
          #window: 
ab88e78f027c initial checkin
james
parents:
diff changeset
  1453
           #(#WindowSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
  1454
              #name: 'Packages::PackageDetails::Prerequisites'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1455
              #layout: #(#LayoutFrame 204 0 162 0 503 0 461 0)
ab88e78f027c initial checkin
james
parents:
diff changeset
  1456
              #label: 'Packages::PackageDetails::Prerequisites'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1457
              #min: #(#Point 10 10)
ab88e78f027c initial checkin
james
parents:
diff changeset
  1458
              #max: #(#Point 1024 768)
ab88e78f027c initial checkin
james
parents:
diff changeset
  1459
              #bounds: #(#Rectangle 204 162 504 462)
ab88e78f027c initial checkin
james
parents:
diff changeset
  1460
              #menu: #mainMenu
ab88e78f027c initial checkin
james
parents:
diff changeset
  1461
              #usePreferredExtent: false
ab88e78f027c initial checkin
james
parents:
diff changeset
  1462
          )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1463
          #component: 
ab88e78f027c initial checkin
james
parents:
diff changeset
  1464
           #(#SpecCollection
ab88e78f027c initial checkin
james
parents:
diff changeset
  1465
              #collection: #()
ab88e78f027c initial checkin
james
parents:
diff changeset
  1466
          )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1467
      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1468
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1469
ab88e78f027c initial checkin
james
parents:
diff changeset
  1470
!PackageDetails::Prerequisites class methodsFor:'menu specs'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1471
ab88e78f027c initial checkin
james
parents:
diff changeset
  1472
mainMenu
ab88e78f027c initial checkin
james
parents:
diff changeset
  1473
    "This resource specification was automatically generated by the CodeGeneratorTool."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1474
ab88e78f027c initial checkin
james
parents:
diff changeset
  1475
    "Do not manually edit this!! If it is corrupted,
ab88e78f027c initial checkin
james
parents:
diff changeset
  1476
     the MenuEditor may not be able to read the specification."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1477
ab88e78f027c initial checkin
james
parents:
diff changeset
  1478
    "
ab88e78f027c initial checkin
james
parents:
diff changeset
  1479
     MenuEditor new openOnClass:Packages::PackageDetails::Prerequisites andSelector:#mainMenu
ab88e78f027c initial checkin
james
parents:
diff changeset
  1480
    "
ab88e78f027c initial checkin
james
parents:
diff changeset
  1481
ab88e78f027c initial checkin
james
parents:
diff changeset
  1482
    <resource: #menu>
ab88e78f027c initial checkin
james
parents:
diff changeset
  1483
ab88e78f027c initial checkin
james
parents:
diff changeset
  1484
    ^ #(#Menu
ab88e78f027c initial checkin
james
parents:
diff changeset
  1485
           #(
ab88e78f027c initial checkin
james
parents:
diff changeset
  1486
             #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1487
                #label: 'File'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1488
                #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1489
                #submenu: 
ab88e78f027c initial checkin
james
parents:
diff changeset
  1490
                 #(#Menu
ab88e78f027c initial checkin
james
parents:
diff changeset
  1491
                     #(
ab88e78f027c initial checkin
james
parents:
diff changeset
  1492
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1493
                          #label: 'New'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1494
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1495
                          #value: #menuNew
ab88e78f027c initial checkin
james
parents:
diff changeset
  1496
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1497
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1498
                          #label: '-'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1499
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1500
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1501
                          #label: 'Open...'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1502
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1503
                          #value: #menuOpen
ab88e78f027c initial checkin
james
parents:
diff changeset
  1504
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1505
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1506
                          #label: '-'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1507
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1508
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1509
                          #label: 'Save'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1510
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1511
                          #value: #menuSave
ab88e78f027c initial checkin
james
parents:
diff changeset
  1512
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1513
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1514
                          #label: 'Save As...'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1515
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1516
                          #value: #menuSaveAs
ab88e78f027c initial checkin
james
parents:
diff changeset
  1517
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1518
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1519
                          #label: '-'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1520
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1521
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1522
                          #label: 'Exit'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1523
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1524
                          #value: #closeRequest
ab88e78f027c initial checkin
james
parents:
diff changeset
  1525
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1526
                    ) nil
ab88e78f027c initial checkin
james
parents:
diff changeset
  1527
                    nil
ab88e78f027c initial checkin
james
parents:
diff changeset
  1528
                )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1529
            )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1530
             #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1531
                #label: 'Help'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1532
                #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1533
                #startGroup: #right
ab88e78f027c initial checkin
james
parents:
diff changeset
  1534
                #submenu: 
ab88e78f027c initial checkin
james
parents:
diff changeset
  1535
                 #(#Menu
ab88e78f027c initial checkin
james
parents:
diff changeset
  1536
                     #(
ab88e78f027c initial checkin
james
parents:
diff changeset
  1537
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1538
                          #label: 'Documentation'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1539
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1540
                          #value: #openDocumentation
ab88e78f027c initial checkin
james
parents:
diff changeset
  1541
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1542
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1543
                          #label: '-'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1544
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1545
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1546
                          #label: 'About this Application'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1547
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1548
                          #value: #openAboutThisApplication
ab88e78f027c initial checkin
james
parents:
diff changeset
  1549
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1550
                    ) nil
ab88e78f027c initial checkin
james
parents:
diff changeset
  1551
                    nil
ab88e78f027c initial checkin
james
parents:
diff changeset
  1552
                )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1553
            )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1554
          ) nil
ab88e78f027c initial checkin
james
parents:
diff changeset
  1555
          nil
ab88e78f027c initial checkin
james
parents:
diff changeset
  1556
      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1557
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1558
ab88e78f027c initial checkin
james
parents:
diff changeset
  1559
!PackageDetails::Prerequisites methodsFor:'accessing'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1560
ab88e78f027c initial checkin
james
parents:
diff changeset
  1561
declareDependents
ab88e78f027c initial checkin
james
parents:
diff changeset
  1562
    super declareDependents
ab88e78f027c initial checkin
james
parents:
diff changeset
  1563
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1564
ab88e78f027c initial checkin
james
parents:
diff changeset
  1565
!PackageDetails::Prerequisites methodsFor:'change & update'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1566
ab88e78f027c initial checkin
james
parents:
diff changeset
  1567
packagesSelectedHolderChanged:aCollection 
ab88e78f027c initial checkin
james
parents:
diff changeset
  1568
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1569
ab88e78f027c initial checkin
james
parents:
diff changeset
  1570
validateCanChange:arg 
ab88e78f027c initial checkin
james
parents:
diff changeset
  1571
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1572
ab88e78f027c initial checkin
james
parents:
diff changeset
  1573
!PackageDetails::Prerequisites methodsFor:'initialization & release'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1574
ab88e78f027c initial checkin
james
parents:
diff changeset
  1575
closeDownViews
ab88e78f027c initial checkin
james
parents:
diff changeset
  1576
    "This is a hook method generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1577
     It will be invoked when your app/dialog-window is really closed.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1578
     See also #closeDownViews, which is invoked before and may suppress the close
ab88e78f027c initial checkin
james
parents:
diff changeset
  1579
     or ask the user for confirmation."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1580
ab88e78f027c initial checkin
james
parents:
diff changeset
  1581
    "/ change the code below as required ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1582
    "/ This should cleanup any leftover resources
ab88e78f027c initial checkin
james
parents:
diff changeset
  1583
    "/ (for example, temporary files)
ab88e78f027c initial checkin
james
parents:
diff changeset
  1584
    "/ super closeRequest will initiate the closeDown
ab88e78f027c initial checkin
james
parents:
diff changeset
  1585
ab88e78f027c initial checkin
james
parents:
diff changeset
  1586
    "/ add your code here
ab88e78f027c initial checkin
james
parents:
diff changeset
  1587
ab88e78f027c initial checkin
james
parents:
diff changeset
  1588
    "/ do not remove the one below ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1589
    ^ super closeDownViews
ab88e78f027c initial checkin
james
parents:
diff changeset
  1590
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1591
ab88e78f027c initial checkin
james
parents:
diff changeset
  1592
closeRequest
ab88e78f027c initial checkin
james
parents:
diff changeset
  1593
    "This is a hook method generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1594
     It will be invoked when your app/dialog-window is about to be
ab88e78f027c initial checkin
james
parents:
diff changeset
  1595
     closed (this method has a chance to suppress the close).
ab88e78f027c initial checkin
james
parents:
diff changeset
  1596
     See also #closeDownViews, which is invoked when the close is really done."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1597
ab88e78f027c initial checkin
james
parents:
diff changeset
  1598
    "/ change the code below as required ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1599
    "/ Closing can be suppressed, by simply returning.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1600
    "/ The 'super closeRequest' at the end will initiate the real closeDown
ab88e78f027c initial checkin
james
parents:
diff changeset
  1601
ab88e78f027c initial checkin
james
parents:
diff changeset
  1602
    ("self hasUnsavedChanges" true) ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
  1603
        (self confirm:(resources string:'Close without saving ?')) ifFalse:[
ab88e78f027c initial checkin
james
parents:
diff changeset
  1604
            ^ self
ab88e78f027c initial checkin
james
parents:
diff changeset
  1605
        ]
ab88e78f027c initial checkin
james
parents:
diff changeset
  1606
    ].
ab88e78f027c initial checkin
james
parents:
diff changeset
  1607
ab88e78f027c initial checkin
james
parents:
diff changeset
  1608
    ^ super closeRequest
ab88e78f027c initial checkin
james
parents:
diff changeset
  1609
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1610
ab88e78f027c initial checkin
james
parents:
diff changeset
  1611
postBuildWith:aBuilder
ab88e78f027c initial checkin
james
parents:
diff changeset
  1612
    "This is a hook method generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1613
     It will be invoked during the initialization of your app/dialog,
ab88e78f027c initial checkin
james
parents:
diff changeset
  1614
     after all of the visual components have been built, 
ab88e78f027c initial checkin
james
parents:
diff changeset
  1615
     but BEFORE the top window is made visible.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1616
     Add any app-specific actions here (reading files, setting up values etc.)
ab88e78f027c initial checkin
james
parents:
diff changeset
  1617
     See also #postOpenWith:, which is invoked after opening."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1618
ab88e78f027c initial checkin
james
parents:
diff changeset
  1619
    "/ add any code here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1620
ab88e78f027c initial checkin
james
parents:
diff changeset
  1621
    ^ super postBuildWith:aBuilder
ab88e78f027c initial checkin
james
parents:
diff changeset
  1622
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1623
ab88e78f027c initial checkin
james
parents:
diff changeset
  1624
postOpenWith:aBuilder
ab88e78f027c initial checkin
james
parents:
diff changeset
  1625
    "This is a hook method generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1626
     It will be invoked right after the applications window has been opened.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1627
     Add any app-specific actions here (starting background processes etc.).
ab88e78f027c initial checkin
james
parents:
diff changeset
  1628
     See also #postBuildWith:, which is invoked before opening."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1629
ab88e78f027c initial checkin
james
parents:
diff changeset
  1630
    "/ add any code here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1631
ab88e78f027c initial checkin
james
parents:
diff changeset
  1632
    ^ super postOpenWith:aBuilder
ab88e78f027c initial checkin
james
parents:
diff changeset
  1633
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1634
ab88e78f027c initial checkin
james
parents:
diff changeset
  1635
!PackageDetails::Prerequisites methodsFor:'menu actions'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1636
ab88e78f027c initial checkin
james
parents:
diff changeset
  1637
menuNew
ab88e78f027c initial checkin
james
parents:
diff changeset
  1638
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1639
     It will be invoked when the menu-item 'new' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1640
ab88e78f027c initial checkin
james
parents:
diff changeset
  1641
    "/ change below and add any actions as required here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1642
    self warn:'no action for ''new'' available.'.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1643
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1644
ab88e78f027c initial checkin
james
parents:
diff changeset
  1645
menuOpen
ab88e78f027c initial checkin
james
parents:
diff changeset
  1646
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1647
     It will be invoked when the menu-item 'open' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1648
ab88e78f027c initial checkin
james
parents:
diff changeset
  1649
    "/ change below and add any actions as required here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1650
    self warn:'no action for ''open'' available.'.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1651
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1652
ab88e78f027c initial checkin
james
parents:
diff changeset
  1653
menuSave
ab88e78f027c initial checkin
james
parents:
diff changeset
  1654
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1655
     It will be invoked when the menu-item 'save' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1656
ab88e78f027c initial checkin
james
parents:
diff changeset
  1657
    "/ change below and add any actions as required here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1658
    self warn:'no action for ''save'' available.'.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1659
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1660
ab88e78f027c initial checkin
james
parents:
diff changeset
  1661
menuSaveAs
ab88e78f027c initial checkin
james
parents:
diff changeset
  1662
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1663
     It will be invoked when the menu-item 'saveAs' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1664
ab88e78f027c initial checkin
james
parents:
diff changeset
  1665
    "/ change below and add any actions as required here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1666
    self warn:'no action for ''saveAs'' available.'.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1667
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1668
ab88e78f027c initial checkin
james
parents:
diff changeset
  1669
openAboutThisApplication
ab88e78f027c initial checkin
james
parents:
diff changeset
  1670
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1671
     It will be invoked when the menu-item 'help-about' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1672
ab88e78f027c initial checkin
james
parents:
diff changeset
  1673
    "/ could open a customized aboutBox here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1674
    super openAboutThisApplication
ab88e78f027c initial checkin
james
parents:
diff changeset
  1675
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1676
ab88e78f027c initial checkin
james
parents:
diff changeset
  1677
openDocumentation
ab88e78f027c initial checkin
james
parents:
diff changeset
  1678
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1679
     It will be invoked when the menu-item 'help-documentation' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1680
ab88e78f027c initial checkin
james
parents:
diff changeset
  1681
    "/ change below as required ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1682
ab88e78f027c initial checkin
james
parents:
diff changeset
  1683
    "/ to open an HTML viewer on some document (under 'doc/online/<language>/' ):
ab88e78f027c initial checkin
james
parents:
diff changeset
  1684
    HTMLDocumentView openFullOnDocumentationFile:'TOP.html'.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1685
ab88e78f027c initial checkin
james
parents:
diff changeset
  1686
    "/ add application-specific help files under the 'doc/online/<language>/help/appName'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1687
    "/ directory, and open a viewer with:
ab88e78f027c initial checkin
james
parents:
diff changeset
  1688
    "/ HTMLDocumentView openFullOnDocumentationFile:'help/<MyApplication>/TOP.html'.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1689
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1690
ab88e78f027c initial checkin
james
parents:
diff changeset
  1691
!PackageDetails::Scripts class methodsFor:'constant values'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1692
ab88e78f027c initial checkin
james
parents:
diff changeset
  1693
applicationName
ab88e78f027c initial checkin
james
parents:
diff changeset
  1694
    ^ 'Scripts' asSymbol
ab88e78f027c initial checkin
james
parents:
diff changeset
  1695
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1696
ab88e78f027c initial checkin
james
parents:
diff changeset
  1697
!PackageDetails::Scripts class methodsFor:'interface specs'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1698
ab88e78f027c initial checkin
james
parents:
diff changeset
  1699
windowSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
  1700
    "This resource specification was automatically generated by the CodeGeneratorTool."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1701
ab88e78f027c initial checkin
james
parents:
diff changeset
  1702
    "Do not manually edit this!! If it is corrupted,
ab88e78f027c initial checkin
james
parents:
diff changeset
  1703
     the UIPainter may not be able to read the specification."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1704
ab88e78f027c initial checkin
james
parents:
diff changeset
  1705
    "
ab88e78f027c initial checkin
james
parents:
diff changeset
  1706
     UIPainter new openOnClass:Packages::PackageDetails::Scripts andSelector:#windowSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
  1707
    "
ab88e78f027c initial checkin
james
parents:
diff changeset
  1708
ab88e78f027c initial checkin
james
parents:
diff changeset
  1709
    <resource: #canvas>
ab88e78f027c initial checkin
james
parents:
diff changeset
  1710
ab88e78f027c initial checkin
james
parents:
diff changeset
  1711
    ^ #(#FullSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
  1712
          #window: 
ab88e78f027c initial checkin
james
parents:
diff changeset
  1713
           #(#WindowSpec
ab88e78f027c initial checkin
james
parents:
diff changeset
  1714
              #name: 'Packages::PackageDetails::Scripts'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1715
              #layout: #(#LayoutFrame 204 0 162 0 503 0 461 0)
ab88e78f027c initial checkin
james
parents:
diff changeset
  1716
              #label: 'Packages::PackageDetails::Scripts'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1717
              #min: #(#Point 10 10)
ab88e78f027c initial checkin
james
parents:
diff changeset
  1718
              #max: #(#Point 1024 768)
ab88e78f027c initial checkin
james
parents:
diff changeset
  1719
              #bounds: #(#Rectangle 204 162 504 462)
ab88e78f027c initial checkin
james
parents:
diff changeset
  1720
              #menu: #mainMenu
ab88e78f027c initial checkin
james
parents:
diff changeset
  1721
              #usePreferredExtent: false
ab88e78f027c initial checkin
james
parents:
diff changeset
  1722
          )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1723
          #component: 
ab88e78f027c initial checkin
james
parents:
diff changeset
  1724
           #(#SpecCollection
ab88e78f027c initial checkin
james
parents:
diff changeset
  1725
              #collection: #()
ab88e78f027c initial checkin
james
parents:
diff changeset
  1726
          )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1727
      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1728
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1729
ab88e78f027c initial checkin
james
parents:
diff changeset
  1730
!PackageDetails::Scripts class methodsFor:'menu specs'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1731
ab88e78f027c initial checkin
james
parents:
diff changeset
  1732
mainMenu
ab88e78f027c initial checkin
james
parents:
diff changeset
  1733
    "This resource specification was automatically generated by the CodeGeneratorTool."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1734
ab88e78f027c initial checkin
james
parents:
diff changeset
  1735
    "Do not manually edit this!! If it is corrupted,
ab88e78f027c initial checkin
james
parents:
diff changeset
  1736
     the MenuEditor may not be able to read the specification."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1737
ab88e78f027c initial checkin
james
parents:
diff changeset
  1738
    "
ab88e78f027c initial checkin
james
parents:
diff changeset
  1739
     MenuEditor new openOnClass:Packages::PackageDetails::Scripts andSelector:#mainMenu
ab88e78f027c initial checkin
james
parents:
diff changeset
  1740
    "
ab88e78f027c initial checkin
james
parents:
diff changeset
  1741
ab88e78f027c initial checkin
james
parents:
diff changeset
  1742
    <resource: #menu>
ab88e78f027c initial checkin
james
parents:
diff changeset
  1743
ab88e78f027c initial checkin
james
parents:
diff changeset
  1744
    ^ #(#Menu
ab88e78f027c initial checkin
james
parents:
diff changeset
  1745
           #(
ab88e78f027c initial checkin
james
parents:
diff changeset
  1746
             #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1747
                #label: 'File'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1748
                #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1749
                #submenu: 
ab88e78f027c initial checkin
james
parents:
diff changeset
  1750
                 #(#Menu
ab88e78f027c initial checkin
james
parents:
diff changeset
  1751
                     #(
ab88e78f027c initial checkin
james
parents:
diff changeset
  1752
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1753
                          #label: 'New'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1754
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1755
                          #value: #menuNew
ab88e78f027c initial checkin
james
parents:
diff changeset
  1756
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1757
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1758
                          #label: '-'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1759
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1760
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1761
                          #label: 'Open...'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1762
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1763
                          #value: #menuOpen
ab88e78f027c initial checkin
james
parents:
diff changeset
  1764
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1765
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1766
                          #label: '-'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1767
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1768
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1769
                          #label: 'Save'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1770
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1771
                          #value: #menuSave
ab88e78f027c initial checkin
james
parents:
diff changeset
  1772
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1773
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1774
                          #label: 'Save As...'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1775
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1776
                          #value: #menuSaveAs
ab88e78f027c initial checkin
james
parents:
diff changeset
  1777
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1778
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1779
                          #label: '-'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1780
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1781
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1782
                          #label: 'Exit'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1783
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1784
                          #value: #closeRequest
ab88e78f027c initial checkin
james
parents:
diff changeset
  1785
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1786
                    ) nil
ab88e78f027c initial checkin
james
parents:
diff changeset
  1787
                    nil
ab88e78f027c initial checkin
james
parents:
diff changeset
  1788
                )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1789
            )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1790
             #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1791
                #label: 'Help'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1792
                #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1793
                #startGroup: #right
ab88e78f027c initial checkin
james
parents:
diff changeset
  1794
                #submenu: 
ab88e78f027c initial checkin
james
parents:
diff changeset
  1795
                 #(#Menu
ab88e78f027c initial checkin
james
parents:
diff changeset
  1796
                     #(
ab88e78f027c initial checkin
james
parents:
diff changeset
  1797
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1798
                          #label: 'Documentation'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1799
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1800
                          #value: #openDocumentation
ab88e78f027c initial checkin
james
parents:
diff changeset
  1801
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1802
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1803
                          #label: '-'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1804
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1805
                       #(#MenuItem
ab88e78f027c initial checkin
james
parents:
diff changeset
  1806
                          #label: 'About this Application'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1807
                          #translateLabel: true
ab88e78f027c initial checkin
james
parents:
diff changeset
  1808
                          #value: #openAboutThisApplication
ab88e78f027c initial checkin
james
parents:
diff changeset
  1809
                      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1810
                    ) nil
ab88e78f027c initial checkin
james
parents:
diff changeset
  1811
                    nil
ab88e78f027c initial checkin
james
parents:
diff changeset
  1812
                )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1813
            )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1814
          ) nil
ab88e78f027c initial checkin
james
parents:
diff changeset
  1815
          nil
ab88e78f027c initial checkin
james
parents:
diff changeset
  1816
      )
ab88e78f027c initial checkin
james
parents:
diff changeset
  1817
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1818
ab88e78f027c initial checkin
james
parents:
diff changeset
  1819
!PackageDetails::Scripts methodsFor:'accessing'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1820
ab88e78f027c initial checkin
james
parents:
diff changeset
  1821
declareDependents
ab88e78f027c initial checkin
james
parents:
diff changeset
  1822
    super declareDependents
ab88e78f027c initial checkin
james
parents:
diff changeset
  1823
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1824
ab88e78f027c initial checkin
james
parents:
diff changeset
  1825
!PackageDetails::Scripts methodsFor:'change & update'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1826
ab88e78f027c initial checkin
james
parents:
diff changeset
  1827
packagesSelectedHolderChanged:aCollection 
1268
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
  1828
    self breakPoint:''.
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
  1829
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1830
ab88e78f027c initial checkin
james
parents:
diff changeset
  1831
validateCanChange:arg 
ab88e78f027c initial checkin
james
parents:
diff changeset
  1832
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1833
ab88e78f027c initial checkin
james
parents:
diff changeset
  1834
!PackageDetails::Scripts methodsFor:'initialization & release'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1835
ab88e78f027c initial checkin
james
parents:
diff changeset
  1836
closeDownViews
ab88e78f027c initial checkin
james
parents:
diff changeset
  1837
    "This is a hook method generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1838
     It will be invoked when your app/dialog-window is really closed.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1839
     See also #closeDownViews, which is invoked before and may suppress the close
ab88e78f027c initial checkin
james
parents:
diff changeset
  1840
     or ask the user for confirmation."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1841
ab88e78f027c initial checkin
james
parents:
diff changeset
  1842
    "/ change the code below as required ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1843
    "/ This should cleanup any leftover resources
ab88e78f027c initial checkin
james
parents:
diff changeset
  1844
    "/ (for example, temporary files)
ab88e78f027c initial checkin
james
parents:
diff changeset
  1845
    "/ super closeRequest will initiate the closeDown
ab88e78f027c initial checkin
james
parents:
diff changeset
  1846
ab88e78f027c initial checkin
james
parents:
diff changeset
  1847
    "/ add your code here
ab88e78f027c initial checkin
james
parents:
diff changeset
  1848
ab88e78f027c initial checkin
james
parents:
diff changeset
  1849
    "/ do not remove the one below ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1850
    ^ super closeDownViews
ab88e78f027c initial checkin
james
parents:
diff changeset
  1851
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1852
ab88e78f027c initial checkin
james
parents:
diff changeset
  1853
closeRequest
ab88e78f027c initial checkin
james
parents:
diff changeset
  1854
    "This is a hook method generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1855
     It will be invoked when your app/dialog-window is about to be
ab88e78f027c initial checkin
james
parents:
diff changeset
  1856
     closed (this method has a chance to suppress the close).
ab88e78f027c initial checkin
james
parents:
diff changeset
  1857
     See also #closeDownViews, which is invoked when the close is really done."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1858
ab88e78f027c initial checkin
james
parents:
diff changeset
  1859
    "/ change the code below as required ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1860
    "/ Closing can be suppressed, by simply returning.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1861
    "/ The 'super closeRequest' at the end will initiate the real closeDown
ab88e78f027c initial checkin
james
parents:
diff changeset
  1862
ab88e78f027c initial checkin
james
parents:
diff changeset
  1863
    ("self hasUnsavedChanges" true) ifTrue:[
ab88e78f027c initial checkin
james
parents:
diff changeset
  1864
        (self confirm:(resources string:'Close without saving ?')) ifFalse:[
ab88e78f027c initial checkin
james
parents:
diff changeset
  1865
            ^ self
ab88e78f027c initial checkin
james
parents:
diff changeset
  1866
        ]
ab88e78f027c initial checkin
james
parents:
diff changeset
  1867
    ].
ab88e78f027c initial checkin
james
parents:
diff changeset
  1868
ab88e78f027c initial checkin
james
parents:
diff changeset
  1869
    ^ super closeRequest
ab88e78f027c initial checkin
james
parents:
diff changeset
  1870
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1871
ab88e78f027c initial checkin
james
parents:
diff changeset
  1872
postBuildWith:aBuilder
ab88e78f027c initial checkin
james
parents:
diff changeset
  1873
    "This is a hook method generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1874
     It will be invoked during the initialization of your app/dialog,
ab88e78f027c initial checkin
james
parents:
diff changeset
  1875
     after all of the visual components have been built, 
ab88e78f027c initial checkin
james
parents:
diff changeset
  1876
     but BEFORE the top window is made visible.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1877
     Add any app-specific actions here (reading files, setting up values etc.)
ab88e78f027c initial checkin
james
parents:
diff changeset
  1878
     See also #postOpenWith:, which is invoked after opening."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1879
ab88e78f027c initial checkin
james
parents:
diff changeset
  1880
    "/ add any code here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1881
ab88e78f027c initial checkin
james
parents:
diff changeset
  1882
    ^ super postBuildWith:aBuilder
ab88e78f027c initial checkin
james
parents:
diff changeset
  1883
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1884
ab88e78f027c initial checkin
james
parents:
diff changeset
  1885
postOpenWith:aBuilder
ab88e78f027c initial checkin
james
parents:
diff changeset
  1886
    "This is a hook method generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1887
     It will be invoked right after the applications window has been opened.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1888
     Add any app-specific actions here (starting background processes etc.).
ab88e78f027c initial checkin
james
parents:
diff changeset
  1889
     See also #postBuildWith:, which is invoked before opening."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1890
ab88e78f027c initial checkin
james
parents:
diff changeset
  1891
    "/ add any code here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1892
ab88e78f027c initial checkin
james
parents:
diff changeset
  1893
    ^ super postOpenWith:aBuilder
ab88e78f027c initial checkin
james
parents:
diff changeset
  1894
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1895
ab88e78f027c initial checkin
james
parents:
diff changeset
  1896
!PackageDetails::Scripts methodsFor:'menu actions'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1897
ab88e78f027c initial checkin
james
parents:
diff changeset
  1898
menuNew
ab88e78f027c initial checkin
james
parents:
diff changeset
  1899
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1900
     It will be invoked when the menu-item 'new' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1901
ab88e78f027c initial checkin
james
parents:
diff changeset
  1902
    "/ change below and add any actions as required here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1903
    self warn:'no action for ''new'' available.'.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1904
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1905
ab88e78f027c initial checkin
james
parents:
diff changeset
  1906
menuOpen
ab88e78f027c initial checkin
james
parents:
diff changeset
  1907
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1908
     It will be invoked when the menu-item 'open' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1909
ab88e78f027c initial checkin
james
parents:
diff changeset
  1910
    "/ change below and add any actions as required here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1911
    self warn:'no action for ''open'' available.'.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1912
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1913
ab88e78f027c initial checkin
james
parents:
diff changeset
  1914
menuSave
ab88e78f027c initial checkin
james
parents:
diff changeset
  1915
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1916
     It will be invoked when the menu-item 'save' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1917
ab88e78f027c initial checkin
james
parents:
diff changeset
  1918
    "/ change below and add any actions as required here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1919
    self warn:'no action for ''save'' available.'.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1920
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1921
ab88e78f027c initial checkin
james
parents:
diff changeset
  1922
menuSaveAs
ab88e78f027c initial checkin
james
parents:
diff changeset
  1923
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1924
     It will be invoked when the menu-item 'saveAs' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1925
ab88e78f027c initial checkin
james
parents:
diff changeset
  1926
    "/ change below and add any actions as required here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1927
    self warn:'no action for ''saveAs'' available.'.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1928
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1929
ab88e78f027c initial checkin
james
parents:
diff changeset
  1930
openAboutThisApplication
ab88e78f027c initial checkin
james
parents:
diff changeset
  1931
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1932
     It will be invoked when the menu-item 'help-about' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1933
ab88e78f027c initial checkin
james
parents:
diff changeset
  1934
    "/ could open a customized aboutBox here ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1935
    super openAboutThisApplication
ab88e78f027c initial checkin
james
parents:
diff changeset
  1936
!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1937
ab88e78f027c initial checkin
james
parents:
diff changeset
  1938
openDocumentation
ab88e78f027c initial checkin
james
parents:
diff changeset
  1939
    "This method was generated by the Browser.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1940
     It will be invoked when the menu-item 'help-documentation' is selected."
ab88e78f027c initial checkin
james
parents:
diff changeset
  1941
ab88e78f027c initial checkin
james
parents:
diff changeset
  1942
    "/ change below as required ...
ab88e78f027c initial checkin
james
parents:
diff changeset
  1943
ab88e78f027c initial checkin
james
parents:
diff changeset
  1944
    "/ to open an HTML viewer on some document (under 'doc/online/<language>/' ):
ab88e78f027c initial checkin
james
parents:
diff changeset
  1945
    HTMLDocumentView openFullOnDocumentationFile:'TOP.html'.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1946
ab88e78f027c initial checkin
james
parents:
diff changeset
  1947
    "/ add application-specific help files under the 'doc/online/<language>/help/appName'
ab88e78f027c initial checkin
james
parents:
diff changeset
  1948
    "/ directory, and open a viewer with:
ab88e78f027c initial checkin
james
parents:
diff changeset
  1949
    "/ HTMLDocumentView openFullOnDocumentationFile:'help/<MyApplication>/TOP.html'.
ab88e78f027c initial checkin
james
parents:
diff changeset
  1950
! !
ab88e78f027c initial checkin
james
parents:
diff changeset
  1951
ab88e78f027c initial checkin
james
parents:
diff changeset
  1952
!PackageDetails class methodsFor:'documentation'!
ab88e78f027c initial checkin
james
parents:
diff changeset
  1953
ab88e78f027c initial checkin
james
parents:
diff changeset
  1954
version
1268
9dc8d1b8ce9b Lots and lots of changes...
james
parents: 1241
diff changeset
  1955
    ^ '$Header: /cvs/stx/stx/libbasic3/packages/PackageDetails.st,v 1.3 2003-05-09 12:22:58 james Exp $'
1227
ab88e78f027c initial checkin
james
parents:
diff changeset
  1956
! !