ResourceSelectionBrowser.st
author tz
Fri, 27 Feb 1998 17:54:29 +0100
changeset 693 bb247cc428c3
parent 689 ff099c344dd6
child 718 c2e814032029
permissions -rw-r--r--
also return resource selectors from private classes
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
425
cf47d420764a initial checkin
tz
parents:
diff changeset
     1
"
504
1ff52096d1d3 copyright changed
tz
parents: 481
diff changeset
     2
 COPYRIGHT (c) 1997 by eXept Software AG
425
cf47d420764a initial checkin
tz
parents:
diff changeset
     3
              All Rights Reserved
cf47d420764a initial checkin
tz
parents:
diff changeset
     4
cf47d420764a initial checkin
tz
parents:
diff changeset
     5
 This software is furnished under a license and may be used
cf47d420764a initial checkin
tz
parents:
diff changeset
     6
 only in accordance with the terms of that license and with the
cf47d420764a initial checkin
tz
parents:
diff changeset
     7
 inclusion of the above copyright notice. This software may not
cf47d420764a initial checkin
tz
parents:
diff changeset
     8
 be provided or otherwise made available to, or used by, any
cf47d420764a initial checkin
tz
parents:
diff changeset
     9
 other person. No title to or ownership of the software is
cf47d420764a initial checkin
tz
parents:
diff changeset
    10
 hereby transferred.
cf47d420764a initial checkin
tz
parents:
diff changeset
    11
"
cf47d420764a initial checkin
tz
parents:
diff changeset
    12
cf47d420764a initial checkin
tz
parents:
diff changeset
    13
cf47d420764a initial checkin
tz
parents:
diff changeset
    14
SelectionBrowser subclass:#ResourceSelectionBrowser
477
857d4289a2bd improved class name completion routine
tz
parents: 472
diff changeset
    15
	instanceVariableNames:'resourceMethod resourceClass resourceSuperclass resourceTypes
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
    16
		allClasses classSelectionBlock'
425
cf47d420764a initial checkin
tz
parents:
diff changeset
    17
	classVariableNames:''
cf47d420764a initial checkin
tz
parents:
diff changeset
    18
	poolDictionaries:''
619
36c9d07f7dc3 class category changed
tz
parents: 616
diff changeset
    19
	category:'Interface-Dialogs'
425
cf47d420764a initial checkin
tz
parents:
diff changeset
    20
!
cf47d420764a initial checkin
tz
parents:
diff changeset
    21
523
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
    22
Object subclass:#Row
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
    23
	instanceVariableNames:'method icon resourceType selector'
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
    24
	classVariableNames:''
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
    25
	poolDictionaries:''
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
    26
	privateIn:ResourceSelectionBrowser
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
    27
!
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
    28
425
cf47d420764a initial checkin
tz
parents:
diff changeset
    29
!ResourceSelectionBrowser class methodsFor:'documentation'!
cf47d420764a initial checkin
tz
parents:
diff changeset
    30
cf47d420764a initial checkin
tz
parents:
diff changeset
    31
copyright
cf47d420764a initial checkin
tz
parents:
diff changeset
    32
"
504
1ff52096d1d3 copyright changed
tz
parents: 481
diff changeset
    33
 COPYRIGHT (c) 1997 by eXept Software AG
425
cf47d420764a initial checkin
tz
parents:
diff changeset
    34
              All Rights Reserved
cf47d420764a initial checkin
tz
parents:
diff changeset
    35
cf47d420764a initial checkin
tz
parents:
diff changeset
    36
 This software is furnished under a license and may be used
cf47d420764a initial checkin
tz
parents:
diff changeset
    37
 only in accordance with the terms of that license and with the
cf47d420764a initial checkin
tz
parents:
diff changeset
    38
 inclusion of the above copyright notice. This software may not
cf47d420764a initial checkin
tz
parents:
diff changeset
    39
 be provided or otherwise made available to, or used by, any
cf47d420764a initial checkin
tz
parents:
diff changeset
    40
 other person. No title to or ownership of the software is
cf47d420764a initial checkin
tz
parents:
diff changeset
    41
 hereby transferred.
cf47d420764a initial checkin
tz
parents:
diff changeset
    42
"
cf47d420764a initial checkin
tz
parents:
diff changeset
    43
cf47d420764a initial checkin
tz
parents:
diff changeset
    44
!
cf47d420764a initial checkin
tz
parents:
diff changeset
    45
cf47d420764a initial checkin
tz
parents:
diff changeset
    46
documentation
cf47d420764a initial checkin
tz
parents:
diff changeset
    47
"
504
1ff52096d1d3 copyright changed
tz
parents: 481
diff changeset
    48
    [start with:]
1ff52096d1d3 copyright changed
tz
parents: 481
diff changeset
    49
        ResourceSelectionBrowser open
1ff52096d1d3 copyright changed
tz
parents: 481
diff changeset
    50
1ff52096d1d3 copyright changed
tz
parents: 481
diff changeset
    51
    [author:]
1ff52096d1d3 copyright changed
tz
parents: 481
diff changeset
    52
        Thomas Zwick
425
cf47d420764a initial checkin
tz
parents:
diff changeset
    53
"
cf47d420764a initial checkin
tz
parents:
diff changeset
    54
! !
cf47d420764a initial checkin
tz
parents:
diff changeset
    55
cf47d420764a initial checkin
tz
parents:
diff changeset
    56
!ResourceSelectionBrowser class methodsFor:'instance creation'!
cf47d420764a initial checkin
tz
parents:
diff changeset
    57
649
1896945cf5d4 some cleans
tz
parents: 648
diff changeset
    58
request: aTitle onSuperclass: aSuperclass andClass: aClass andSelector: aSelector withResourceTypes: resourceTypes
425
cf47d420764a initial checkin
tz
parents:
diff changeset
    59
649
1896945cf5d4 some cleans
tz
parents: 648
diff changeset
    60
    "
1896945cf5d4 some cleans
tz
parents: 648
diff changeset
    61
    ResourceSelectionBrowser
1896945cf5d4 some cleans
tz
parents: 648
diff changeset
    62
        request: 'Select a Resource Selector'
425
cf47d420764a initial checkin
tz
parents:
diff changeset
    63
        onSuperclass: #ApplicationModel 
cf47d420764a initial checkin
tz
parents:
diff changeset
    64
        andClass: #ToolApplicationModel 
cf47d420764a initial checkin
tz
parents:
diff changeset
    65
        andSelector: #saveIcon 
517
91ff807d8a23 set resource selection after opening
tz
parents: 504
diff changeset
    66
        withResourceTypes: #(image) 
425
cf47d420764a initial checkin
tz
parents:
diff changeset
    67
    "
cf47d420764a initial checkin
tz
parents:
diff changeset
    68
cf47d420764a initial checkin
tz
parents:
diff changeset
    69
    ^self new
cf47d420764a initial checkin
tz
parents:
diff changeset
    70
        title: aTitle;
cf47d420764a initial checkin
tz
parents:
diff changeset
    71
        openOnSuperclass: aSuperclass
cf47d420764a initial checkin
tz
parents:
diff changeset
    72
        andClass: aClass
cf47d420764a initial checkin
tz
parents:
diff changeset
    73
        andSelector: aSelector
649
1896945cf5d4 some cleans
tz
parents: 648
diff changeset
    74
        withResourceTypes: resourceTypes
425
cf47d420764a initial checkin
tz
parents:
diff changeset
    75
! !
cf47d420764a initial checkin
tz
parents:
diff changeset
    76
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
    77
!ResourceSelectionBrowser class methodsFor:'callbacks - default'!
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
    78
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
    79
treeViewChildren
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
    80
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
    81
    ^[:aTreeItem|
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
    82
        |classes|
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
    83
        classes := OrderedCollection new.    
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
    84
        classes 
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
    85
            addAll: (aTreeItem contents subclasses asSortedCollection: [:i1 :i2| i1 name < i2 name]);
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
    86
        yourself]
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
    87
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
    88
!
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
    89
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
    90
treeViewContents
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
    91
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
    92
    ^Smalltalk at: #Object
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
    93
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
    94
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
    95
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
    96
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
    97
!
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
    98
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
    99
treeViewIcon
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   100
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   101
    ^[self iconClass]
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   102
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   103
!
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   104
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   105
treeViewLabel
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   106
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   107
    ^[:aTreeItem|aTreeItem contents name]
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   108
! !
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   109
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   110
!ResourceSelectionBrowser class methodsFor:'interface specs'!
cf47d420764a initial checkin
tz
parents:
diff changeset
   111
cf47d420764a initial checkin
tz
parents:
diff changeset
   112
windowSpec
cf47d420764a initial checkin
tz
parents:
diff changeset
   113
    "this window spec was automatically generated by the ST/X UIPainter"
cf47d420764a initial checkin
tz
parents:
diff changeset
   114
cf47d420764a initial checkin
tz
parents:
diff changeset
   115
    "do not manually edit this - the painter/builder may not be able to
cf47d420764a initial checkin
tz
parents:
diff changeset
   116
     handle the specification if its corrupted."
cf47d420764a initial checkin
tz
parents:
diff changeset
   117
cf47d420764a initial checkin
tz
parents:
diff changeset
   118
    "
cf47d420764a initial checkin
tz
parents:
diff changeset
   119
     UIPainter new openOnClass:ResourceSelectionBrowser andSelector:#windowSpec
cf47d420764a initial checkin
tz
parents:
diff changeset
   120
     ResourceSelectionBrowser new openInterface:#windowSpec
cf47d420764a initial checkin
tz
parents:
diff changeset
   121
    "
cf47d420764a initial checkin
tz
parents:
diff changeset
   122
    "ResourceSelectionBrowser open"
cf47d420764a initial checkin
tz
parents:
diff changeset
   123
cf47d420764a initial checkin
tz
parents:
diff changeset
   124
    <resource: #canvas>
cf47d420764a initial checkin
tz
parents:
diff changeset
   125
cf47d420764a initial checkin
tz
parents:
diff changeset
   126
    ^
468
bb4e776b9210 levels changed
tz
parents: 467
diff changeset
   127
     
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   128
       #(#FullSpec
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   129
          #window: 
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   130
           #(#WindowSpec
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   131
              #name: 'Resource Selection Browser'
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   132
              #layout: #(#LayoutFrame 197 0 172 0 796 0 521 0)
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   133
              #label: 'Resource Selection Browser'
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   134
              #min: #(#Point 400 300)
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   135
              #max: #(#Point 1152 864)
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   136
              #bounds: #(#Rectangle 197 172 797 522)
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   137
              #usePreferredExtent: false
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   138
          )
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   139
          #component: 
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   140
           #(#SpecCollection
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   141
              #collection: 
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   142
               #(
cf47d420764a initial checkin
tz
parents:
diff changeset
   143
                 #(#VariableHorizontalPanelSpec
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   144
                    #name: 'variableHorizontalPanel'
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   145
                    #layout: #(#LayoutFrame 0 0.0 0 0.0 0 1.0 -40 1.0)
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   146
                    #component: 
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   147
                     #(#SpecCollection
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   148
                        #collection: 
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   149
                         #(
cf47d420764a initial checkin
tz
parents:
diff changeset
   150
                           #(#ViewSpec
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   151
                              #name: 'view1'
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   152
                              #component: 
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   153
                               #(#SpecCollection
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   154
                                  #collection: 
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   155
                                   #(
cf47d420764a initial checkin
tz
parents:
diff changeset
   156
                                     #(#SelectionInTreeViewSpec
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   157
                                        #name: 'listOfClassesView'
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   158
                                        #layout: #(#LayoutFrame 0 0.0 23 0.0 0 1.0 -22 1.0)
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   159
                                        #model: #selectionOfClass
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   160
                                        #hasHorizontalScrollBar: true
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   161
                                        #hasVerticalScrollBar: true
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   162
                                        #miniScrollerHorizontal: true
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   163
                                        #showDirectoryIndicatorForRoot: false
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   164
                                        #showDirectoryIndicator: true
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   165
                                        #valueChangeSelector: #classSelected:
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   166
                                        #hierarchicalList: #listOfClasses
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   167
                                        #contentsSelector: #treeViewContents
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   168
                                        #labelSelector: #treeViewLabel
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   169
                                        #childrenSelector: #treeViewChildren
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   170
                                        #iconSelector: #treeViewIcon
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   171
                                    )
467
ddb605aaf94a class retrieval support added
tz
parents: 463
diff changeset
   172
                                     #(#InputFieldSpec
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   173
                                        #name: 'classNameInputField'
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   174
                                        #layout: #(#LayoutFrame 2 0.0 -22 1 -1 1.0 0 1)
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   175
                                        #model: #valueOfClassName
467
ddb605aaf94a class retrieval support added
tz
parents: 463
diff changeset
   176
                                    )
664
6ed67e67d321 label for class tree added
tz
parents: 649
diff changeset
   177
                                     #(#LabelSpec
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   178
                                        #name: 'ClassHierarchyLabel'
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   179
                                        #layout: #(#LayoutFrame 0 0 2 0 297 0 23 0)
664
6ed67e67d321 label for class tree added
tz
parents: 649
diff changeset
   180
                                        #label: ' Class Hierarchy'
6ed67e67d321 label for class tree added
tz
parents: 649
diff changeset
   181
                                        #level: 1
6ed67e67d321 label for class tree added
tz
parents: 649
diff changeset
   182
                                        #adjust: #left
6ed67e67d321 label for class tree added
tz
parents: 649
diff changeset
   183
                                    )
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   184
                                  )
cf47d420764a initial checkin
tz
parents:
diff changeset
   185
                              )
cf47d420764a initial checkin
tz
parents:
diff changeset
   186
                          )
cf47d420764a initial checkin
tz
parents:
diff changeset
   187
                           #(#ViewSpec
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   188
                              #name: 'view2'
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   189
                              #component: 
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   190
                               #(#SpecCollection
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   191
                                  #collection: 
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   192
                                   #(
cf47d420764a initial checkin
tz
parents:
diff changeset
   193
                                     #(#DataSetSpec
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   194
                                        #name: 'resourcesDataSetView'
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   195
                                        #layout: #(#LayoutFrame 2 0.0 2 0.0 -2 1.0 -22 1.0)
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   196
                                        #model: #selectionOfResource
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   197
                                        #hasHorizontalScrollBar: true
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   198
                                        #hasVerticalScrollBar: true
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   199
                                        #miniScrollerHorizontal: true
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   200
                                        #rowClassName: 'ResourceSelectionBrowser::Row'
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   201
                                        #dataList: #listOfResources
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   202
                                        #useIndex: false
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   203
                                        #has3Dsepartors: true
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   204
                                        #doubleClickSelector: #resourceDoubleClicked
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   205
                                        #columnHolder: #columnsOfDataSetView
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   206
                                        #valueChangeSelector: #resourceSelected
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   207
                                        #verticalSpacing: 1
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   208
                                    )
cf47d420764a initial checkin
tz
parents:
diff changeset
   209
                                     #(#InputFieldSpec
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   210
                                        #name: 'selectorInputField'
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   211
                                        #layout: #(#LayoutFrame 2 0.0 -22 1 -2 1.0 0 1)
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   212
                                        #model: #valueOfSelector
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   213
                                    )
cf47d420764a initial checkin
tz
parents:
diff changeset
   214
                                  )
cf47d420764a initial checkin
tz
parents:
diff changeset
   215
                              )
cf47d420764a initial checkin
tz
parents:
diff changeset
   216
                          )
cf47d420764a initial checkin
tz
parents:
diff changeset
   217
                        )
cf47d420764a initial checkin
tz
parents:
diff changeset
   218
                    )
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   219
                    #handles: #(#Any 0.5 1.0)
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   220
                )
436
07be1c96bb58 *** empty log message ***
tz
parents: 435
diff changeset
   221
                 #(#UISubSpecification
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   222
                    #name: 'SubSpecification'
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   223
                    #layout: #(#LayoutFrame 301 0.0 -32 1 -2 1.0 -8 1.0)
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   224
                    #majorKey: #ToolApplicationModel
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   225
                    #minorKey: #windowSpecForCommitWithoutChannels
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   226
                )
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   227
                 #(#HorizontalPanelViewSpec
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   228
                    #name: 'HorizontalPanelView1'
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   229
                    #layout: #(#LayoutFrame 3 0 76 0.691429 300 0 0 0.977143)
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   230
                    #component: 
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   231
                     #(#SpecCollection
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   232
                        #collection: 
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   233
                         #(
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   234
                           #(#LabelSpec
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   235
                              #name: 'Label2'
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   236
                              #label: 'Create: '
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   237
                              #adjust: #right
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   238
                              #extent: #(#Point 67 24)
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   239
                          )
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   240
                           #(#ActionButtonSpec
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   241
                              #name: 'CreateClassButton'
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   242
                              #activeHelpKey: #dss
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   243
                              #label: 'Class'
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   244
                              #model: #createClass:
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   245
                              #actionValue: 'class'
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   246
                              #extent: #(#Point 72 24)
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   247
                          )
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   248
                           #(#ActionButtonSpec
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   249
                              #name: 'CreateSubclassButton'
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   250
                              #activeHelpKey: #dss
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   251
                              #label: 'Subclass'
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   252
                              #model: #createClass:
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   253
                              #actionValue: 'subclass'
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   254
                              #extent: #(#Point 72 24)
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   255
                          )
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   256
                           #(#ActionButtonSpec
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   257
                              #name: 'CreatePrivateClassButton'
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   258
                              #activeHelpKey: #dss
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   259
                              #label: 'Private'
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   260
                              #model: #createClass:
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   261
                              #actionValue: 'private'
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   262
                              #extent: #(#Point 72 24)
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   263
                          )
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   264
                        )
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   265
                    )
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   266
                    #horizontalLayout: #fit
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   267
                    #verticalLayout: #fit
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   268
                )
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   269
              )
cf47d420764a initial checkin
tz
parents:
diff changeset
   270
          )
cf47d420764a initial checkin
tz
parents:
diff changeset
   271
      )
cf47d420764a initial checkin
tz
parents:
diff changeset
   272
! !
cf47d420764a initial checkin
tz
parents:
diff changeset
   273
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   274
!ResourceSelectionBrowser class methodsFor:'list specs'!
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   275
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   276
columnsOfDataSetView
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   277
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   278
  ^ #(#(#DataSetColumnSpec
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   279
      #width: 20
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   280
      #height: 20
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   281
      #printSelector: #iconOn:
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   282
      #canSelect: false
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   283
  )
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   284
   #(#DataSetColumnSpec
649
1896945cf5d4 some cleans
tz
parents: 648
diff changeset
   285
      #label: ' Selector'
1896945cf5d4 some cleans
tz
parents: 648
diff changeset
   286
      #'labelAlignment:' #left
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   287
      #model: #selector
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   288
      #canSelect: false
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   289
  )
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   290
   (#DataSetColumnSpec
649
1896945cf5d4 some cleans
tz
parents: 648
diff changeset
   291
      #label: ' Resource Type'
1896945cf5d4 some cleans
tz
parents: 648
diff changeset
   292
      #'labelAlignment:' #left
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   293
      #model: #resourceType
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   294
      #canSelect: false
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   295
  ))
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   296
! !
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   297
632
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   298
!ResourceSelectionBrowser class methodsFor:'resources'!
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   299
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   300
iconClass
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   301
    "Generated by the Image Editor"
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   302
    "
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   303
    ImageEditor openOnClass:self andSelector:#iconClass
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   304
    "
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   305
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   306
    <resource: #image>
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   307
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   308
    ^Icon
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   309
        constantNamed:#'ResourceSelectionBrowser iconClass'
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   310
        ifAbsentPut:[(Depth2Image new) width: 18; height: 16; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@UUUUUAQ****(@F**** @Z****@A****(@F**** @Z****@A****(LF**** TZ****@A****(@F**** @Z****@@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 255 255 170 170 170 255 0 0]; mask:((Depth1Image new) width: 18; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'_?>@???@???@???@???@???@???@???@???@???@???@???@???@???@???@_?>@') ; yourself); yourself]
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   311
!
632
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   312
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   313
iconPrivateClass
632
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   314
    "Generated by the Image Editor"
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   315
    "
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   316
    ImageEditor openOnClass:self andSelector:#iconPrivateClass
632
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   317
    "
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   318
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   319
    <resource: #image>
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   320
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   321
    ^Icon
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   322
        constantNamed:#'ResourceSelectionBrowser iconPrivateClass'
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   323
        ifAbsentPut:[(Depth2Image new) width: 18; height: 16; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@PUUUUU@A****(@F*??* @Z/??*@A+???(MF/??> @Z5UU:@A+UUW(DF/??> @Z???:@A*??>(@F*??* @Z****C@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 255 255 170 170 170 127 0 0]; mask:((Depth1Image new) width: 18; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'_?>@???@???@???@???@???@???@???@???@???@???@???@???@???@???@_?>@') ; yourself); yourself]
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   324
!
632
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   325
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   326
iconRealPrivateClass
632
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   327
    "Generated by the Image Editor"
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   328
    "
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   329
    ImageEditor openOnClass:self andSelector:#iconRealPrivateClass
632
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   330
    "
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   331
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   332
    <resource: #image>
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   333
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   334
    ^Icon
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   335
        constantNamed:#'ResourceSelectionBrowser iconRealPrivateClass'
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   336
        ifAbsentPut:[(Depth2Image new) width: 18; height: 16; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@PUUUUU@A****(@F*??* @Z/??*@A+???(OF/??> @Z5UU:@A+UUW(DF/??> @Z???:@A*??>(@F*??* @Z****C0@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 255 255 170 170 170 255 0 0]; mask:((Depth1Image new) width: 18; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'_?>@???@???@???@???@???@???@???@???@???@???@???@???@???@???@_?>@') ; yourself); yourself]
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   337
! !
632
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   338
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   339
!ResourceSelectionBrowser methodsFor:'accessing - views'!
cf47d420764a initial checkin
tz
parents:
diff changeset
   340
467
ddb605aaf94a class retrieval support added
tz
parents: 463
diff changeset
   341
classNameInputField
ddb605aaf94a class retrieval support added
tz
parents: 463
diff changeset
   342
ddb605aaf94a class retrieval support added
tz
parents: 463
diff changeset
   343
    ^builder componentAt: #classNameInputField
ddb605aaf94a class retrieval support added
tz
parents: 463
diff changeset
   344
!
ddb605aaf94a class retrieval support added
tz
parents: 463
diff changeset
   345
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   346
listOfClassesView
cf47d420764a initial checkin
tz
parents:
diff changeset
   347
cf47d420764a initial checkin
tz
parents:
diff changeset
   348
    ^builder componentAt: #listOfClassesView
cf47d420764a initial checkin
tz
parents:
diff changeset
   349
! !
cf47d420764a initial checkin
tz
parents:
diff changeset
   350
cf47d420764a initial checkin
tz
parents:
diff changeset
   351
!ResourceSelectionBrowser methodsFor:'aspects'!
cf47d420764a initial checkin
tz
parents:
diff changeset
   352
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   353
columnsOfDataSetView
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   354
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   355
    |holder|
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   356
    (holder := builder bindingAt:#columnsOfDataSetView) isNil ifTrue:[
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   357
        builder aspectAt:#columnsOfDataSetView put:(holder := List new).
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   358
        holder addAll: (self class columnsOfDataSetView collect: [:i| i decodeAsLiteralArray]).
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   359
    ].
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   360
    ^ holder
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   361
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   362
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   363
!
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   364
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   365
listOfClasses
cf47d420764a initial checkin
tz
parents:
diff changeset
   366
cf47d420764a initial checkin
tz
parents:
diff changeset
   367
    |holder|
cf47d420764a initial checkin
tz
parents:
diff changeset
   368
    (holder := builder bindingAt:#listOfClasses) isNil ifTrue:[
632
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   369
        builder aspectAt:#listOfClasses put: (holder := TreeItem new)
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   370
    ].
cf47d420764a initial checkin
tz
parents:
diff changeset
   371
    ^ holder
cf47d420764a initial checkin
tz
parents:
diff changeset
   372
cf47d420764a initial checkin
tz
parents:
diff changeset
   373
cf47d420764a initial checkin
tz
parents:
diff changeset
   374
!
cf47d420764a initial checkin
tz
parents:
diff changeset
   375
cf47d420764a initial checkin
tz
parents:
diff changeset
   376
listOfResources
cf47d420764a initial checkin
tz
parents:
diff changeset
   377
cf47d420764a initial checkin
tz
parents:
diff changeset
   378
    |holder|
cf47d420764a initial checkin
tz
parents:
diff changeset
   379
    (holder := builder bindingAt:#listOfResources) isNil ifTrue:[
cf47d420764a initial checkin
tz
parents:
diff changeset
   380
        builder aspectAt:#listOfResources put:(holder :=  List new).
cf47d420764a initial checkin
tz
parents:
diff changeset
   381
    ].
cf47d420764a initial checkin
tz
parents:
diff changeset
   382
    ^ holder
cf47d420764a initial checkin
tz
parents:
diff changeset
   383
!
cf47d420764a initial checkin
tz
parents:
diff changeset
   384
cf47d420764a initial checkin
tz
parents:
diff changeset
   385
selectionOfClass
cf47d420764a initial checkin
tz
parents:
diff changeset
   386
cf47d420764a initial checkin
tz
parents:
diff changeset
   387
    |holder|
cf47d420764a initial checkin
tz
parents:
diff changeset
   388
    (holder := builder bindingAt:#selectionOfClass) isNil ifTrue:[
cf47d420764a initial checkin
tz
parents:
diff changeset
   389
        builder aspectAt:#selectionOfClass put:(holder :=  ValueHolder new).
cf47d420764a initial checkin
tz
parents:
diff changeset
   390
    ].
cf47d420764a initial checkin
tz
parents:
diff changeset
   391
    ^ holder
cf47d420764a initial checkin
tz
parents:
diff changeset
   392
!
cf47d420764a initial checkin
tz
parents:
diff changeset
   393
cf47d420764a initial checkin
tz
parents:
diff changeset
   394
selectionOfResource
cf47d420764a initial checkin
tz
parents:
diff changeset
   395
cf47d420764a initial checkin
tz
parents:
diff changeset
   396
    |holder|
cf47d420764a initial checkin
tz
parents:
diff changeset
   397
    (holder := builder bindingAt:#selectionOfResource) isNil ifTrue:[
cf47d420764a initial checkin
tz
parents:
diff changeset
   398
        builder aspectAt:#selectionOfResource put:(holder :=  '' asValue).
cf47d420764a initial checkin
tz
parents:
diff changeset
   399
    ].
cf47d420764a initial checkin
tz
parents:
diff changeset
   400
    ^ holder
cf47d420764a initial checkin
tz
parents:
diff changeset
   401
!
cf47d420764a initial checkin
tz
parents:
diff changeset
   402
467
ddb605aaf94a class retrieval support added
tz
parents: 463
diff changeset
   403
valueOfClassName
ddb605aaf94a class retrieval support added
tz
parents: 463
diff changeset
   404
ddb605aaf94a class retrieval support added
tz
parents: 463
diff changeset
   405
    |holder|
ddb605aaf94a class retrieval support added
tz
parents: 463
diff changeset
   406
    (holder := builder bindingAt:#valueOfClassName) isNil ifTrue:[
ddb605aaf94a class retrieval support added
tz
parents: 463
diff changeset
   407
        builder aspectAt:#valueOfClassName put:(holder :=  '' asValue).
ddb605aaf94a class retrieval support added
tz
parents: 463
diff changeset
   408
    ].
ddb605aaf94a class retrieval support added
tz
parents: 463
diff changeset
   409
    ^ holder
ddb605aaf94a class retrieval support added
tz
parents: 463
diff changeset
   410
!
ddb605aaf94a class retrieval support added
tz
parents: 463
diff changeset
   411
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   412
valueOfSelector
cf47d420764a initial checkin
tz
parents:
diff changeset
   413
cf47d420764a initial checkin
tz
parents:
diff changeset
   414
    |holder|
cf47d420764a initial checkin
tz
parents:
diff changeset
   415
    (holder := builder bindingAt:#valueOfSelector) isNil ifTrue:[
cf47d420764a initial checkin
tz
parents:
diff changeset
   416
        builder aspectAt:#valueOfSelector put:(holder :=  '' asValue).
cf47d420764a initial checkin
tz
parents:
diff changeset
   417
    ].
cf47d420764a initial checkin
tz
parents:
diff changeset
   418
    ^ holder
cf47d420764a initial checkin
tz
parents:
diff changeset
   419
! !
cf47d420764a initial checkin
tz
parents:
diff changeset
   420
632
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   421
!ResourceSelectionBrowser methodsFor:'callbacks - tree view'!
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   422
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   423
treeViewChildren
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   424
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   425
    ^[:aTreeItem|
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   426
        |classes|
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   427
        classes := self class treeViewChildren value: aTreeItem.
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   428
        classes addAll: (aTreeItem contents privateClasses asSortedCollection: [:i1 :i2| i1 name < i2 name]);
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   429
        yourself]
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   430
!
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   431
632
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   432
treeViewContents
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   433
648
d0724edba450 some changes for the lib builder and for its new subclass
tz
parents: 641
diff changeset
   434
    ^(Smalltalk at: resourceSuperclass) ? self class treeViewContents
632
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   435
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   436
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   437
!
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   438
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   439
treeViewIcon
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   440
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   441
    ^[:aTreeItem|
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   442
        |icon|
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   443
        icon := self class treeViewIcon value.
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   444
        aTreeItem contents isPrivate 
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   445
        ifTrue:
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   446
        [
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   447
            aTreeItem parent contents ~~ aTreeItem contents superclass
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   448
                ifTrue: [icon := self class iconRealPrivateClass]
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   449
                ifFalse: [icon := self class iconPrivateClass]
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   450
        ].
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   451
        icon]
632
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   452
!
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   453
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   454
treeViewLabel
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   455
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   456
    ^[:aTreeItem|
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   457
        |label superCls|
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   458
        label := self class treeViewLabel value: aTreeItem.
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   459
        (aTreeItem contents isPrivate and: [aTreeItem parent contents ~~ (superCls := aTreeItem contents superclass)])
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   460
            ifTrue: [label := label, ' (', superCls name, ')'].
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   461
        label]
632
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   462
! !
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   463
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   464
!ResourceSelectionBrowser methodsFor:'callbacks - user'!
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   465
cf47d420764a initial checkin
tz
parents:
diff changeset
   466
classSelected: anIndex
cf47d420764a initial checkin
tz
parents:
diff changeset
   467
    
cf47d420764a initial checkin
tz
parents:
diff changeset
   468
    self selectionOfClass value isNil ifTrue: [^nil].
cf47d420764a initial checkin
tz
parents:
diff changeset
   469
    self withWaitCursorDo:
cf47d420764a initial checkin
tz
parents:
diff changeset
   470
    [
cf47d420764a initial checkin
tz
parents:
diff changeset
   471
        |clsName|
517
91ff807d8a23 set resource selection after opening
tz
parents: 504
diff changeset
   472
        resourceTypes isNil ifTrue: [resourceTypes := Method resourceTypes].
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   473
        clsName := ((self listOfClassesView list at: anIndex) upTo: $ ) asSymbol.
477
857d4289a2bd improved class name completion routine
tz
parents: 472
diff changeset
   474
        self valueOfClassName value: clsName.
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   475
        self class lastSelection: clsName.
cf47d420764a initial checkin
tz
parents:
diff changeset
   476
        self listOfResources contents:
523
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   477
            ((((Smalltalk at: clsName) 
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   478
                class methodDictionary
cf47d420764a initial checkin
tz
parents:
diff changeset
   479
                asOrderedCollection select: 
523
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   480
                    [:m| m resources notNil and: [resourceTypes includes: m resourceType]]))
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   481
             collect: [:m| Row new method: m]).
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   482
    ]
cf47d420764a initial checkin
tz
parents:
diff changeset
   483
!
cf47d420764a initial checkin
tz
parents:
diff changeset
   484
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   485
createClass: what
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   486
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   487
    |clsCandidat cls|
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   488
    clsCandidat := self valueOfClassName value asSymbol.
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   489
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   490
    (Smalltalk at: clsCandidat) notNil 
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   491
        ifTrue: [^self warn: 'Cannot create class ', clsCandidat asBoldText,
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   492
                '!!\Key with that name in dictionary ' withCRs, 'Smalltalk' asBoldText, ' detected.'].
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   493
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   494
    cls := self selectionOfClass value contents.
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   495
    what = 'class' ifTrue: [cls := cls superclass].
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   496
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   497
    cls isNil ifTrue: [^self warn: 'May not create class with superclass ', 'nil' asBoldText, '!!'].
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   498
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   499
    what = 'private' 
693
bb247cc428c3 also return resource selectors from private classes
tz
parents: 689
diff changeset
   500
    ifFalse: 
bb247cc428c3 also return resource selectors from private classes
tz
parents: 689
diff changeset
   501
    [
bb247cc428c3 also return resource selectors from private classes
tz
parents: 689
diff changeset
   502
        cls subclass: clsCandidat
bb247cc428c3 also return resource selectors from private classes
tz
parents: 689
diff changeset
   503
            instanceVariableNames:''
bb247cc428c3 also return resource selectors from private classes
tz
parents: 689
diff changeset
   504
            classVariableNames:''
bb247cc428c3 also return resource selectors from private classes
tz
parents: 689
diff changeset
   505
            poolDictionaries:''
bb247cc428c3 also return resource selectors from private classes
tz
parents: 689
diff changeset
   506
            category: cls category
bb247cc428c3 also return resource selectors from private classes
tz
parents: 689
diff changeset
   507
    ]
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   508
    ifTrue:
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   509
    [
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   510
        |superClsCandidate|
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   511
        superClsCandidate := (Dialog 
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   512
                request: 'Enter name of superclass of private class.'
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   513
                initialAnswer: 'Object') asSymbol.
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   514
        (superClsCandidate := Smalltalk at: superClsCandidate) isNil ifTrue: [^nil].
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   515
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   516
        (superClsCandidate isClass and: [superClsCandidate isPrivate not])
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   517
            ifFalse: [^self warn: 'May not create private class with superclass ', superClsCandidate asBoldText, '!!'].
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   518
        superClsCandidate subclass: clsCandidat
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   519
            instanceVariableNames:''
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   520
            classVariableNames:''
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   521
            poolDictionaries:''
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   522
            privateIn: cls
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   523
    ].
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   524
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   525
    allClasses := Object withAllSubclasses.
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   526
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   527
    what = 'class' 
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   528
        ifTrue:  [self selectionOfClass value parent changed: #children]
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   529
        ifFalse: [self selectionOfClass value changed: #children].
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   530
693
bb247cc428c3 also return resource selectors from private classes
tz
parents: 689
diff changeset
   531
    classSelectionBlock value: self valueOfClassName value 
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   532
!
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   533
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   534
resourceDoubleClicked
cf47d420764a initial checkin
tz
parents:
diff changeset
   535
cf47d420764a initial checkin
tz
parents:
diff changeset
   536
    resourceMethod := self selectionOfResource value.
cf47d420764a initial checkin
tz
parents:
diff changeset
   537
    accept value: true.
cf47d420764a initial checkin
tz
parents:
diff changeset
   538
    self close
cf47d420764a initial checkin
tz
parents:
diff changeset
   539
!
cf47d420764a initial checkin
tz
parents:
diff changeset
   540
cf47d420764a initial checkin
tz
parents:
diff changeset
   541
resourceSelected
cf47d420764a initial checkin
tz
parents:
diff changeset
   542
cf47d420764a initial checkin
tz
parents:
diff changeset
   543
    resourceMethod := self selectionOfResource value.
649
1896945cf5d4 some cleans
tz
parents: 648
diff changeset
   544
    self selectionOfResource value notNil
1896945cf5d4 some cleans
tz
parents: 648
diff changeset
   545
        ifTrue: [self valueOfSelector value: self selectionOfResource value selector]
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   546
! !
cf47d420764a initial checkin
tz
parents:
diff changeset
   547
cf47d420764a initial checkin
tz
parents:
diff changeset
   548
!ResourceSelectionBrowser methodsFor:'instance creation'!
cf47d420764a initial checkin
tz
parents:
diff changeset
   549
cf47d420764a initial checkin
tz
parents:
diff changeset
   550
openOnSuperclass: aSuperclassOrSymbol andClass: aClassOrSymbol andSelector: aSelector withResourceTypes: aResourceTypes
cf47d420764a initial checkin
tz
parents:
diff changeset
   551
693
bb247cc428c3 also return resource selectors from private classes
tz
parents: 689
diff changeset
   552
    |cls clsName|
517
91ff807d8a23 set resource selection after opening
tz
parents: 504
diff changeset
   553
    resourceMethod := aSelector.
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   554
    resourceTypes := aResourceTypes.
cf47d420764a initial checkin
tz
parents:
diff changeset
   555
    resourceSuperclass := aSuperclassOrSymbol isClass ifTrue: [aSuperclassOrSymbol name] ifFalse: [aSuperclassOrSymbol].
689
ff099c344dd6 try to find out convenient class selection
tz
parents: 680
diff changeset
   556
    resourceClass := aClassOrSymbol isClass 
ff099c344dd6 try to find out convenient class selection
tz
parents: 680
diff changeset
   557
        ifTrue: [aClassOrSymbol name] 
ff099c344dd6 try to find out convenient class selection
tz
parents: 680
diff changeset
   558
        ifFalse: [(Smalltalk at: aClassOrSymbol)
ff099c344dd6 try to find out convenient class selection
tz
parents: 680
diff changeset
   559
            ifTrue:  [aClassOrSymbol]
ff099c344dd6 try to find out convenient class selection
tz
parents: 680
diff changeset
   560
            ifFalse: [nil]].      
481
e2e1ea013229 Take care of nil selectors in #openOnSuperClass:andClass:andSelector:
Stefan Vogel <sv@exept.de>
parents: 477
diff changeset
   561
    self valueOfSelector value:(aSelector ? '').
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   562
463
947f89198464 return complete message even if not implemented
tz
parents: 436
diff changeset
   563
    self open.
947f89198464 return complete message even if not implemented
tz
parents: 436
diff changeset
   564
693
bb247cc428c3 also return resource selectors from private classes
tz
parents: 689
diff changeset
   565
    clsName := (self selectionOfClass value name upTo: $ ) asSymbol.
bb247cc428c3 also return resource selectors from private classes
tz
parents: 689
diff changeset
   566
632
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   567
    (self selectionOfClass value notNil and:
693
bb247cc428c3 also return resource selectors from private classes
tz
parents: 689
diff changeset
   568
    [(cls := Smalltalk at: clsName) isClass and:
641
06bf664cab3c the same mistake once again
tz
parents: 636
diff changeset
   569
    [accept value]]) 
632
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   570
    ifTrue:
693
bb247cc428c3 also return resource selectors from private classes
tz
parents: 689
diff changeset
   571
    [            
bb247cc428c3 also return resource selectors from private classes
tz
parents: 689
diff changeset
   572
        ^clsName, ' ', self valueOfSelector value
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   573
    ].
cf47d420764a initial checkin
tz
parents:
diff changeset
   574
    ^nil
cf47d420764a initial checkin
tz
parents:
diff changeset
   575
! !
cf47d420764a initial checkin
tz
parents:
diff changeset
   576
cf47d420764a initial checkin
tz
parents:
diff changeset
   577
!ResourceSelectionBrowser methodsFor:'startup / release'!
cf47d420764a initial checkin
tz
parents:
diff changeset
   578
cf47d420764a initial checkin
tz
parents:
diff changeset
   579
closeCancel
cf47d420764a initial checkin
tz
parents:
diff changeset
   580
cf47d420764a initial checkin
tz
parents:
diff changeset
   581
    resourceMethod := nil.
cf47d420764a initial checkin
tz
parents:
diff changeset
   582
    super closeCancel
cf47d420764a initial checkin
tz
parents:
diff changeset
   583
cf47d420764a initial checkin
tz
parents:
diff changeset
   584
cf47d420764a initial checkin
tz
parents:
diff changeset
   585
623
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   586
!
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   587
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   588
postBuildWith:aBuilder
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   589
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   590
    |classSelection|
623
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   591
    allClasses := Object withAllSubclasses.
689
ff099c344dd6 try to find out convenient class selection
tz
parents: 680
diff changeset
   592
    classSelection :=  resourceClass. 
ff099c344dd6 try to find out convenient class selection
tz
parents: 680
diff changeset
   593
    (Smalltalk at: classSelection) isNil 
ff099c344dd6 try to find out convenient class selection
tz
parents: 680
diff changeset
   594
        ifTrue: [classSelection :=  self class lastSelection].
ff099c344dd6 try to find out convenient class selection
tz
parents: 680
diff changeset
   595
    (Smalltalk at: classSelection) isNil 
ff099c344dd6 try to find out convenient class selection
tz
parents: 680
diff changeset
   596
        ifTrue: [classSelection :=  #Object].
623
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   597
    classSelectionBlock := 
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   598
    [:clsPattern|                                  
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   599
        |foundClass classes|         
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   600
        ((foundClass := Smalltalk at: clsPattern printString asSymbol) isClass not or:
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   601
        [foundClass name ~= clsPattern])
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   602
        ifTrue:
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   603
        [
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   604
            classes := allClasses select: [:cls| cls name size >= clsPattern size].
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   605
            1 to: clsPattern size do: 
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   606
            [:i|    
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   607
                 classes := classes select: [:cls| (cls name at: i) == (clsPattern at: i)].
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   608
            ].    
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   609
            foundClass := classes at: 1 ifAbsent: [nil] 
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   610
        ].
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   611
        foundClass notNil
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   612
        ifTrue:
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   613
        [
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   614
            self listOfClassesView 
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   615
                selectFromListOfNames: (foundClass 
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   616
                    withAllSuperclasses reverse collect: [:cls| cls name asString]);
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   617
                selectedNodeExpand: true
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   618
        ].
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   619
        self valueOfClassName value: clsPattern
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   620
    ].
635
47ffd4e4f387 do select method row after opening
tz
parents: 632
diff changeset
   621
    self valueOfClassName value: classSelection.  
623
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   622
    self classNameInputField entryCompletionBlock:
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   623
    [:value|
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   624
        |what|
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   625
        what := Smalltalk classnameCompletion: value withoutSpaces.
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   626
        self classNameInputField contents:what first.
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   627
        (what at:2) size ~~ 1 ifTrue:[Display beep].
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   628
        classSelectionBlock value: self classNameInputField contents
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   629
    ].
632
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   630
    self listOfClassesView validateDoubleClickBlock: [:aTreeItem | aTreeItem contents ~~ self treeViewContents].
930b778d5e28 uses now dynamic tree items
tz
parents: 623
diff changeset
   631
    self listOfClassesView selectedNodeExpand: true.
623
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   632
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   633
    [
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   634
        [classSelectionBlock value: classSelection] value.
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   635
        self selectionOfResource value: (self listOfResources detect: [:m| m selector == resourceMethod] ifNone: nil)
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   636
    ]
635
47ffd4e4f387 do select method row after opening
tz
parents: 632
diff changeset
   637
    forkAt: 4.
623
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   638
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   639
    ^super postBuildWith:aBuilder
c8a99cea56f7 expand selected class node after opening
tz
parents: 619
diff changeset
   640
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   641
! !
cf47d420764a initial checkin
tz
parents:
diff changeset
   642
523
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   643
!ResourceSelectionBrowser::Row methodsFor:'accessing'!
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   644
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   645
iconOn:aGC
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   646
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   647
    icon isNil ifTrue: [icon := method iconOn: aGC].
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   648
    ^icon
680
49c81e9cc6f7 create class support added
tz
parents: 664
diff changeset
   649
523
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   650
!
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   651
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   652
method: aMethod
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   653
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   654
    method := aMethod
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   655
!
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   656
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   657
resourceType
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   658
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   659
    resourceType isNil ifTrue: [resourceType := method resourceType].
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   660
    ^resourceType
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   661
!
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   662
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   663
selector
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   664
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   665
    selector isNil ifTrue: [selector := method who methodSelector].
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   666
    ^selector
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   667
! !
eec155f1b037 resource methods are now put own rows
tz
parents: 517
diff changeset
   668
425
cf47d420764a initial checkin
tz
parents:
diff changeset
   669
!ResourceSelectionBrowser class methodsFor:'documentation'!
cf47d420764a initial checkin
tz
parents:
diff changeset
   670
cf47d420764a initial checkin
tz
parents:
diff changeset
   671
version
cf47d420764a initial checkin
tz
parents:
diff changeset
   672
    ^ '$Header$'
cf47d420764a initial checkin
tz
parents:
diff changeset
   673
! !