ChangesBrowser.st
author Claus Gittinger <cg@exept.de>
Fri, 12 Oct 2001 08:57:44 +0200
changeset 3297 12b826adb7aa
parent 3292 7eca3bb7b8cb
child 3304 cf0831ca5783
permissions -rw-r--r--
*** empty log message ***
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
     1
"
4
77d8e96499b2 *** empty log message ***
claus
parents: 1
diff changeset
     2
 COPYRIGHT (c) 1990 by Claus Gittinger
45
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
     3
	      All Rights Reserved
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
     4
571fd5eee315 Initial revision
claus
parents:
diff changeset
     5
 This software is furnished under a license and may be used
571fd5eee315 Initial revision
claus
parents:
diff changeset
     6
 only in accordance with the terms of that license and with the
571fd5eee315 Initial revision
claus
parents:
diff changeset
     7
 inclusion of the above copyright notice.   This software may not
571fd5eee315 Initial revision
claus
parents:
diff changeset
     8
 be provided or otherwise made available to, or used by, any
571fd5eee315 Initial revision
claus
parents:
diff changeset
     9
 other person.  No title to or ownership of the software is
571fd5eee315 Initial revision
claus
parents:
diff changeset
    10
 hereby transferred.
571fd5eee315 Initial revision
claus
parents:
diff changeset
    11
"
571fd5eee315 Initial revision
claus
parents:
diff changeset
    12
2664
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
    13
"{ Package: 'stx:libtool' }"
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
    14
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
    15
StandardSystemView subclass:#ChangesBrowser
275
604a906c0eb7 better handling of changes for autoloaded classes
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    16
	instanceVariableNames:'changeListView codeView changeFileName changeChunks
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
    17
		changePositions changeClassNames changeSelectors
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
    18
		changeHeaderLines changeIsFollowupMethodChange anyChanges
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
    19
		changeNrShown changeNrProcessed skipSignal autoCompare
703
1b3b008d9f19 fixed to allow class-source files to be handled
Claus Gittinger <cg@exept.de>
parents: 627
diff changeset
    20
		changeFileSize changeFileTimestamp checkBlock changeTimeStamps
2301
d557a9dec28c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2295
diff changeset
    21
		tabSpec autoUpdate editingClassSource lastSearchType
3224
b2f3a2a0bc80 readOnly flag added (for method-versions browsing)
Claus Gittinger <cg@exept.de>
parents: 3211
diff changeset
    22
		lastSearchString applyInOriginalNameSpace lastSaveFileName
3227
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
    23
		readOnly enforcedPackage'
2637
2df524da9f63 use my owen cached defaultIcon
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    24
	classVariableNames:'CompressSnapshotInfo NoColoring ShowWarningDialogs DefaultIcon'
275
604a906c0eb7 better handling of changes for autoloaded classes
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    25
	poolDictionaries:''
604a906c0eb7 better handling of changes for autoloaded classes
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    26
	category:'Interface-Browsers'
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
    27
!
571fd5eee315 Initial revision
claus
parents:
diff changeset
    28
761
5c2b46a38efa checkin from browser
Claus Gittinger <cg@exept.de>
parents: 744
diff changeset
    29
!ChangesBrowser class methodsFor:'documentation'!
29
8a72e10043f6 *** empty log message ***
claus
parents: 28
diff changeset
    30
8a72e10043f6 *** empty log message ***
claus
parents: 28
diff changeset
    31
copyright
8a72e10043f6 *** empty log message ***
claus
parents: 28
diff changeset
    32
"
8a72e10043f6 *** empty log message ***
claus
parents: 28
diff changeset
    33
 COPYRIGHT (c) 1990 by Claus Gittinger
45
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
    34
	      All Rights Reserved
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
    35
29
8a72e10043f6 *** empty log message ***
claus
parents: 28
diff changeset
    36
 This software is furnished under a license and may be used
8a72e10043f6 *** empty log message ***
claus
parents: 28
diff changeset
    37
 only in accordance with the terms of that license and with the
8a72e10043f6 *** empty log message ***
claus
parents: 28
diff changeset
    38
 inclusion of the above copyright notice.   This software may not
8a72e10043f6 *** empty log message ***
claus
parents: 28
diff changeset
    39
 be provided or otherwise made available to, or used by, any
8a72e10043f6 *** empty log message ***
claus
parents: 28
diff changeset
    40
 other person.  No title to or ownership of the software is
8a72e10043f6 *** empty log message ***
claus
parents: 28
diff changeset
    41
 hereby transferred.
8a72e10043f6 *** empty log message ***
claus
parents: 28
diff changeset
    42
"
8a72e10043f6 *** empty log message ***
claus
parents: 28
diff changeset
    43
!
8a72e10043f6 *** empty log message ***
claus
parents: 28
diff changeset
    44
8a72e10043f6 *** empty log message ***
claus
parents: 28
diff changeset
    45
documentation
8a72e10043f6 *** empty log message ***
claus
parents: 28
diff changeset
    46
"
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
    47
    this implements a browser for the changes-file (actually, it can display
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
    48
    any sourceFiles contents).
29
8a72e10043f6 *** empty log message ***
claus
parents: 28
diff changeset
    49
    See the extra document 'doc/misc/cbrowser.doc' for how to use this browser.
8a72e10043f6 *** empty log message ***
claus
parents: 28
diff changeset
    50
8a72e10043f6 *** empty log message ***
claus
parents: 28
diff changeset
    51
    written jan 90 by claus
51
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
    52
508
8d2ab732fca5 documentation
Claus Gittinger <cg@exept.de>
parents: 502
diff changeset
    53
    [Class variables:]
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
    54
        CompressSnapshotInfo            if true (the default), snapshot entries
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
    55
                                        are also compressed in the compress function.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
    56
                                        Some users prefer them to be not compressed.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
    57
                                        Set it to false for this.
58
43b7d463a7e5 *** empty log message ***
claus
parents: 57
diff changeset
    58
51
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
    59
    Notice:
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
    60
        this needs a total rewrite, to build up a changeSet from the file
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
    61
        (which did not exist when the ChangesBrowser was originally written) 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
    62
        and manipulate that changeSet.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
    63
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
    64
        This way, we get a browser for any upcoming incore changeSets for
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
    65
        free. Also, this will put the chunk analyzation code into Change and
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
    66
        subclasses (where it belongs) and give a better encapsulation and
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
    67
        overall structure. Do not take this as an example for good style ;-)
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
    68
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
    69
        The Change hierarchy is currently been completed, and the changes browser
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
    70
        will be adapted soon.
508
8d2ab732fca5 documentation
Claus Gittinger <cg@exept.de>
parents: 502
diff changeset
    71
8d2ab732fca5 documentation
Claus Gittinger <cg@exept.de>
parents: 502
diff changeset
    72
    [author:]
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
    73
        Claus Gittinger
508
8d2ab732fca5 documentation
Claus Gittinger <cg@exept.de>
parents: 502
diff changeset
    74
8d2ab732fca5 documentation
Claus Gittinger <cg@exept.de>
parents: 502
diff changeset
    75
    [start with:]
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
    76
        ChangesBrowser open
1359
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
    77
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
    78
    [see also:]
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
    79
        ( Using the ChangesBrowser :html: tools/cbrowser/TOP.html )
1359
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
    80
        
29
8a72e10043f6 *** empty log message ***
claus
parents: 28
diff changeset
    81
"
8a72e10043f6 *** empty log message ***
claus
parents: 28
diff changeset
    82
! !
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
    83
761
5c2b46a38efa checkin from browser
Claus Gittinger <cg@exept.de>
parents: 744
diff changeset
    84
!ChangesBrowser class methodsFor:'instance creation'!
45
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
    85
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
    86
new
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
    87
    "create a new changes browser"
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
    88
1470
6c0fc11207fe checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1431
diff changeset
    89
    ^ super 
6c0fc11207fe checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1431
diff changeset
    90
        label:(self defaultLabel)
6c0fc11207fe checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1431
diff changeset
    91
        icon:(self defaultIcon)
6c0fc11207fe checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1431
diff changeset
    92
6c0fc11207fe checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1431
diff changeset
    93
    "Modified: / 6.2.1998 / 13:25:18 / cg"
45
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
    94
!
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
    95
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
    96
openOn:aFileName
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
    97
    "create c changes browser on a change file"
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
    98
1470
6c0fc11207fe checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1431
diff changeset
    99
    ^ ((self new label:(self defaultLabel , ': ', aFileName)) 
6c0fc11207fe checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1431
diff changeset
   100
        changeFileName:aFileName) open
6c0fc11207fe checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1431
diff changeset
   101
6c0fc11207fe checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1431
diff changeset
   102
    "Modified: / 6.2.1998 / 13:27:19 / cg"
45
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
   103
! !
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
   104
761
5c2b46a38efa checkin from browser
Claus Gittinger <cg@exept.de>
parents: 744
diff changeset
   105
!ChangesBrowser class methodsFor:'behavior'!
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
   106
571fd5eee315 Initial revision
claus
parents:
diff changeset
   107
autoSelectNext
571fd5eee315 Initial revision
claus
parents:
diff changeset
   108
    "returning true here, makes a Delete operation automatically
571fd5eee315 Initial revision
claus
parents:
diff changeset
   109
     select the next change"
571fd5eee315 Initial revision
claus
parents:
diff changeset
   110
571fd5eee315 Initial revision
claus
parents:
diff changeset
   111
    ^ true
571fd5eee315 Initial revision
claus
parents:
diff changeset
   112
! !
571fd5eee315 Initial revision
claus
parents:
diff changeset
   113
761
5c2b46a38efa checkin from browser
Claus Gittinger <cg@exept.de>
parents: 744
diff changeset
   114
!ChangesBrowser class methodsFor:'defaults'!
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
   115
489
89cbd82e4541 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 419
diff changeset
   116
defaultIcon
1153
9e57c1d4339a better default icon
Claus Gittinger <cg@exept.de>
parents: 1150
diff changeset
   117
    "return the browsers default window icon"
9e57c1d4339a better default icon
Claus Gittinger <cg@exept.de>
parents: 1150
diff changeset
   118
9e57c1d4339a better default icon
Claus Gittinger <cg@exept.de>
parents: 1150
diff changeset
   119
    <resource: #style (#ICON #ICON_FILE)>
9e57c1d4339a better default icon
Claus Gittinger <cg@exept.de>
parents: 1150
diff changeset
   120
9e57c1d4339a better default icon
Claus Gittinger <cg@exept.de>
parents: 1150
diff changeset
   121
    |nm i|
9e57c1d4339a better default icon
Claus Gittinger <cg@exept.de>
parents: 1150
diff changeset
   122
9e57c1d4339a better default icon
Claus Gittinger <cg@exept.de>
parents: 1150
diff changeset
   123
    (i := DefaultIcon) isNil ifTrue:[
2341
a342f41922c9 #on: -> #onDevice:
Claus Gittinger <cg@exept.de>
parents: 2329
diff changeset
   124
        i := self classResources at:'ICON' default:nil.
a342f41922c9 #on: -> #onDevice:
Claus Gittinger <cg@exept.de>
parents: 2329
diff changeset
   125
        i isNil ifTrue:[
a342f41922c9 #on: -> #onDevice:
Claus Gittinger <cg@exept.de>
parents: 2329
diff changeset
   126
            nm := ClassResources at:'ICON_FILE' default:'CBrowser.xbm'.
2477
cfb8a4d7b557 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2474
diff changeset
   127
            i := Smalltalk imageFromFileNamed:nm inPackage:#'stx:libtool'.
2341
a342f41922c9 #on: -> #onDevice:
Claus Gittinger <cg@exept.de>
parents: 2329
diff changeset
   128
            i isNil ifTrue:[
2451
2a01088e75d3 try bitmaps in package directory
Claus Gittinger <cg@exept.de>
parents: 2450
diff changeset
   129
                i := StandardSystemView defaultIcon
2341
a342f41922c9 #on: -> #onDevice:
Claus Gittinger <cg@exept.de>
parents: 2329
diff changeset
   130
            ]
a342f41922c9 #on: -> #onDevice:
Claus Gittinger <cg@exept.de>
parents: 2329
diff changeset
   131
        ].
a342f41922c9 #on: -> #onDevice:
Claus Gittinger <cg@exept.de>
parents: 2329
diff changeset
   132
        i notNil ifTrue:[
a342f41922c9 #on: -> #onDevice:
Claus Gittinger <cg@exept.de>
parents: 2329
diff changeset
   133
            DefaultIcon := i := i onDevice:Display
a342f41922c9 #on: -> #onDevice:
Claus Gittinger <cg@exept.de>
parents: 2329
diff changeset
   134
        ]
1084
bf64c6b08604 icon from resources
Claus Gittinger <cg@exept.de>
parents: 1070
diff changeset
   135
    ].
bf64c6b08604 icon from resources
Claus Gittinger <cg@exept.de>
parents: 1070
diff changeset
   136
    ^ i
bf64c6b08604 icon from resources
Claus Gittinger <cg@exept.de>
parents: 1070
diff changeset
   137
1153
9e57c1d4339a better default icon
Claus Gittinger <cg@exept.de>
parents: 1150
diff changeset
   138
    "Modified: 19.3.1997 / 20:48:34 / ca"
9e57c1d4339a better default icon
Claus Gittinger <cg@exept.de>
parents: 1150
diff changeset
   139
    "Modified: 18.4.1997 / 15:16:24 / cg"
489
89cbd82e4541 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 419
diff changeset
   140
!
89cbd82e4541 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 419
diff changeset
   141
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
   142
defaultLabel
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
   143
    ^ 'Changes Browser'
2417
2330ef87fa59 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2396
diff changeset
   144
!
2330ef87fa59 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2396
diff changeset
   145
2330ef87fa59 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2396
diff changeset
   146
isVisualStartable
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   147
    "return true, if this application can be started via #open.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   148
     (to allow start of a change browser via double-click in the browser)"
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   149
2417
2330ef87fa59 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2396
diff changeset
   150
    ^ true
2330ef87fa59 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2396
diff changeset
   151
2330ef87fa59 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2396
diff changeset
   152
    "Created: / 27.9.1999 / 12:28:27 / cg"
28
eea5a71a1e23 *** empty log message ***
claus
parents: 27
diff changeset
   153
! !
eea5a71a1e23 *** empty log message ***
claus
parents: 27
diff changeset
   154
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   155
!ChangesBrowser class methodsFor:'menu specs'!
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   156
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   157
menuSpec
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   158
    "This resource specification was automatically generated
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   159
     by the MenuEditor of ST/X."
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   160
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   161
    "Do not manually edit this!! If it is corrupted,
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   162
     the MenuEditor may not be able to read the specification."
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   163
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   164
    "
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   165
     MenuEditor new openOnClass:ChangesBrowser andSelector:#menuSpec
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   166
     (Menu new fromLiteralArrayEncoding:(ChangesBrowser menuSpec)) startUp
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   167
    "
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   168
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   169
    <resource: #menu>
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   170
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   171
    ^ 
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   172
     #(#Menu
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   173
        #(
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   174
         #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   175
            #label: 'File'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   176
            #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   177
            #submenu: 
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   178
           #(#Menu
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   179
              #(
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   180
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   181
                  #label: 'Compress'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   182
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   183
                  #isVisible: #notEditingClassSource
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   184
                  #value: #doCompress
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   185
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   186
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   187
                  #label: 'Compress for Class'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   188
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   189
                  #isVisible: #notEditingClassSource
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   190
                  #value: #doCompressClass
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   191
                  #enabled: #hasSingleSelection
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   192
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   193
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   194
                  #label: 'Compare and Compress'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   195
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   196
                  #isVisible: #notEditingClassSource
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   197
                  #value: #doCompareAndCompress
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   198
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   199
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   200
                  #label: '-'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   201
                  #isVisible: #notEditingClassSource
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   202
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   203
               #(#MenuItem
3234
1cb3bf47d498 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 3229
diff changeset
   204
                  #label: 'Fileout && Delete All Changes for Class'
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   205
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   206
                  #isVisible: #notEditingClassSource
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   207
                  #value: #doFileoutAndDeleteClassAll
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   208
                  #enabled: #hasSingleSelection
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   209
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   210
               #(#MenuItem
3234
1cb3bf47d498 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 3229
diff changeset
   211
                  #label: 'CheckIn && Delete All Changes for Class'
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   212
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   213
                  #isVisible: #notEditingClassSource
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   214
                  #value: #doCheckinAndDeleteClassAll
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   215
                  #enabled: #hasSingleSelection
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   216
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   217
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   218
                  #label: '-'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   219
                  #isVisible: #notEditingClassSource
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   220
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   221
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   222
                  #label: 'Save in...'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   223
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   224
                  #value: #doSave
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   225
                  #enabled: #hasSelection
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   226
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   227
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   228
                  #label: 'Save to End in...'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   229
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   230
                  #value: #doSaveRest
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   231
                  #enabled: #hasSingleSelection
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   232
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   233
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   234
                  #label: 'Save for Class to End in...'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   235
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   236
                  #value: #doSaveClassRest
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   237
                  #enabled: #hasSingleSelection
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   238
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   239
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   240
                  #label: 'Save All for Class in...'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   241
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   242
                  #value: #doSaveClassAll
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   243
                  #enabled: #hasSingleSelection
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   244
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   245
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   246
                  #label: '-'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   247
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   248
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   249
                  #label: 'Writeback ClassFile'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   250
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   251
                  #isVisible: #editingClassSource
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   252
                  #value: #doWriteBack
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   253
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   254
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   255
                  #label: 'Writeback ChangeFile'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   256
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   257
                  #isVisible: #notEditingClassSource
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   258
                  #value: #doWriteBack
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   259
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   260
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   261
                  #label: '-'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   262
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   263
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   264
                  #label: 'Update'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   265
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   266
                  #value: #doUpdate
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   267
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   268
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   269
                  #label: '-'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   270
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   271
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   272
                  #label: 'Exit'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   273
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   274
                  #value: #menuExit
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   275
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   276
               )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   277
              nil
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   278
              nil
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   279
            )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   280
          )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   281
         #(#MenuItem
3275
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   282
            #label: 'Change'
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   283
            #translateLabel: true
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   284
            #submenu: 
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   285
           #(#Menu
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   286
              #(
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   287
               #(#MenuItem
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   288
                  #label: 'Apply'
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   289
                  #translateLabel: true
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   290
                  #value: #doApply
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   291
                  #enabled: #hasSelection
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   292
                )
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   293
               #(#MenuItem
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   294
                  #label: 'Apply to End'
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   295
                  #translateLabel: true
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   296
                  #value: #doApplyRest
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   297
                  #enabled: #hasSingleSelection
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   298
                )
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   299
               #(#MenuItem
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   300
                  #label: 'Apply for Class to End'
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   301
                  #translateLabel: true
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   302
                  #value: #doApplyClassRest
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   303
                  #enabled: #hasSingleSelection
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   304
                )
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   305
               #(#MenuItem
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   306
                  #label: 'Apply All'
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   307
                  #translateLabel: true
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   308
                  #value: #doApplyAll
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   309
                  #enabled: #hasNoSelection
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   310
                )
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   311
               #(#MenuItem
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   312
                  #label: '-'
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   313
                )
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   314
               #(#MenuItem
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   315
                  #label: 'Delete'
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   316
                  #translateLabel: true
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   317
                  #value: #doDelete
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   318
                  #enabled: #hasSelection
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   319
                )
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   320
               #(#MenuItem
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   321
                  #label: 'Delete to End'
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   322
                  #translateLabel: true
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   323
                  #value: #doDeleteRest
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   324
                  #enabled: #hasSingleSelection
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   325
                )
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   326
               #(#MenuItem
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   327
                  #label: 'Delete for Class to End'
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   328
                  #translateLabel: true
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   329
                  #value: #doDeleteClassRest
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   330
                  #enabled: #hasSingleSelection
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   331
                )
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   332
               #(#MenuItem
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   333
                  #label: 'Delete for Class from Begin'
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   334
                  #translateLabel: true
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   335
                  #value: #doDeleteClassFromBeginning
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   336
                  #enabled: #hasSingleSelection
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   337
                )
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   338
               #(#MenuItem
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   339
                  #label: 'Delete All for Class'
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   340
                  #translateLabel: true
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   341
                  #isVisible: #hasNoMultiSelection
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   342
                  #value: #doDeleteClassAll
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   343
                  #enabled: #hasSelection
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   344
                )
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   345
               #(#MenuItem
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   346
                  #label: 'Delete All for Class && its private Classes'
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   347
                  #translateLabel: true
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   348
                  #isVisible: #hasNoMultiSelection
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   349
                  #value: #doDeleteClassAndPrivateClassesAll
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   350
                  #enabled: #hasSelection
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   351
                )
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   352
               #(#MenuItem
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   353
                  #label: 'Delete All for Classes'
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   354
                  #translateLabel: true
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   355
                  #isVisible: #hasMultiSelection
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   356
                  #value: #doDeleteClassAll
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   357
                  #enabled: #hasSelection
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   358
                )
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   359
               #(#MenuItem
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   360
                  #label: 'Delete All for Classes && their private Classes'
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   361
                  #translateLabel: true
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   362
                  #isVisible: #hasMultiSelection
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   363
                  #value: #doDeleteClassAndPrivateClassesAll
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   364
                  #enabled: #hasSelection
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   365
                )
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   366
               #(#MenuItem
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   367
                  #label: '-'
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   368
                )
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   369
               #(#MenuItem
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   370
                  #label: 'Compare with Current'
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   371
                  #translateLabel: true
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   372
                  #value: #doCompare
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   373
                  #enabled: #hasSingleSelection
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   374
                )
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   375
               #(#MenuItem
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   376
                  #label: '-'
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   377
                )
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   378
               #(#MenuItem
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   379
                  #label: 'Make Change a Patch'
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   380
                  #translateLabel: true
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   381
                  #value: #doMakePatch
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   382
                  #enabled: #hasSelection
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   383
                )
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   384
               )
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   385
              nil
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   386
              nil
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   387
            )
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   388
          )
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   389
         #(#MenuItem
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   390
            #label: 'Search'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   391
            #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   392
            #submenu: 
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   393
           #(#Menu
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   394
              #(
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   395
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   396
                  #label: 'Class...'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   397
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   398
                  #value: #findClass
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   399
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   400
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   401
                  #label: 'Previous for Class'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   402
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   403
                  #value: #findPreviousForClass
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   404
                  #enabled: #hasSelection
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   405
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   406
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   407
                  #label: 'Next for Class'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   408
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   409
                  #value: #findNextForClass
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   410
                  #enabled: #hasSelection
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   411
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   412
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   413
                  #label: '-'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   414
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   415
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   416
                  #label: 'Selector...'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   417
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   418
                  #value: #findSelector
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   419
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   420
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   421
                  #label: 'Previous for Selector'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   422
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   423
                  #value: #findPreviousForSelector
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   424
                  #enabled: #hasSelection
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   425
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   426
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   427
                  #label: 'Next for Selector'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   428
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   429
                  #value: #findNextForSelector
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   430
                  #enabled: #hasSelection
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   431
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   432
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   433
                  #label: '-'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   434
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   435
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   436
                  #label: 'String...'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   437
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   438
                  #value: #findString
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   439
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   440
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   441
                  #label: 'Previous with String'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   442
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   443
                  #value: #findPreviousForString
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   444
                  #enabled: #hasSelection
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   445
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   446
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   447
                  #label: 'Next with String'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   448
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   449
                  #value: #findNextForString
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   450
                  #enabled: #hasSelection
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   451
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   452
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   453
                  #label: '-'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   454
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   455
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   456
                  #label: 'Previous Snapshot'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   457
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   458
                  #value: #findPreviousSnapshot
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   459
                  #enabled: #hasSelection
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   460
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   461
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   462
                  #label: 'Next Snapshot'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   463
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   464
                  #value: #findNextSnapshot
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   465
                  #enabled: #hasSelection
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   466
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   467
               )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   468
              nil
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   469
              nil
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   470
            )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   471
          )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   472
         #(#MenuItem
3275
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   473
            #label: 'Browse'
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   474
            #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   475
            #submenu: 
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   476
           #(#Menu
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   477
              #(
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   478
               #(#MenuItem
3275
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   479
                  #label: 'Class'
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   480
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   481
                  #value: #doBrowse
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   482
                  #enabled: #hasSingleSelection
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   483
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   484
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   485
                  #label: '-'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   486
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   487
               #(#MenuItem
3275
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   488
                  #label: 'Senders...'
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   489
                  #translateLabel: true
3275
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   490
                  #value: #doBrowseSenders
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   491
                )
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   492
               #(#MenuItem
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   493
                  #label: 'Implementors...'
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   494
                  #translateLabel: true
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
   495
                  #value: #doBrowseImplementors
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   496
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   497
               )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   498
              nil
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   499
              nil
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   500
            )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   501
          )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   502
         #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   503
            #label: 'Settings'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   504
            #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   505
            #submenu: 
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   506
           #(#Menu
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   507
              #(
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   508
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   509
                  #label: 'Auto Compare'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   510
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   511
                  #indication: #autoCompare
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   512
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   513
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   514
                  #label: 'Auto Update'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   515
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   516
                  #indication: #autoUpdate
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   517
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   518
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   519
                  #label: '-'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   520
                )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   521
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   522
                  #label: 'Apply in Original NameSpace'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   523
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   524
                  #indication: #applyInOriginalNameSpace
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   525
                )
3227
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   526
               #(#MenuItem
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   527
                  #label: '-'
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   528
                )
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   529
               #(#MenuItem
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   530
                  #label: 'Apply into Package...'
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   531
                  #translateLabel: true
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   532
                  #value: #setEnforcedPackage
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   533
                )
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   534
               )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   535
              nil
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   536
              nil
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   537
            )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   538
          )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   539
         #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   540
            #label: 'Help'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   541
            #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   542
            #startGroup: #right
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   543
            #submenu: 
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   544
           #(#Menu
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   545
              #(
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   546
               #(#MenuItem
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   547
                  #label: 'ChangesBrowser Documentation'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   548
                  #translateLabel: true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   549
                  #value: #openHTMLDocument:
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   550
                  #argument: 'tools/cbrowser/TOP.html'
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   551
                )
3205
83631369b396 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 3204
diff changeset
   552
               #(#MenuItem
83631369b396 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 3204
diff changeset
   553
                  #label: '-'
83631369b396 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 3204
diff changeset
   554
                )
83631369b396 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 3204
diff changeset
   555
               #(#MenuItem
83631369b396 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 3204
diff changeset
   556
                  #label: 'About ChangesBrowser...'
83631369b396 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 3204
diff changeset
   557
                  #translateLabel: true
83631369b396 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 3204
diff changeset
   558
                  #value: #openAboutThisApplication
83631369b396 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 3204
diff changeset
   559
                )
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   560
               )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   561
              nil
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   562
              nil
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   563
            )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   564
          )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   565
         )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   566
        nil
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   567
        nil
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   568
      )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   569
! !
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   570
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   571
!ChangesBrowser methodsFor:'aspects'!
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   572
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   573
applyInOriginalNameSpace
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   574
    ^ applyInOriginalNameSpace
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   575
!
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   576
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   577
autoCompare
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   578
    ^ autoCompare
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   579
!
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   580
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   581
autoUpdate
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   582
    "enabled/disable automatic update from the change-file (for monitoring)"
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   583
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   584
    ^ autoUpdate
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   585
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   586
    "Created: 3.12.1995 / 14:14:24 / cg"
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   587
    "Modified: 3.12.1995 / 14:20:45 / cg"
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   588
!
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   589
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   590
editingClassSource
3203
44ac975f0993 pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3202
diff changeset
   591
    ^ editingClassSource ? false
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   592
!
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   593
3227
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   594
hasMultiSelection
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   595
    ^ self hasSelection and:[self hasSingleSelection not]
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   596
!
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   597
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   598
hasNoMultiSelection
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   599
    ^ self hasMultiSelection not
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   600
!
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   601
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   602
hasNoSelection
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   603
    ^ self hasSelection not
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   604
!
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   605
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   606
hasSelection
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   607
    ^ changeListView hasSelection 
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   608
!
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   609
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   610
hasSingleSelection
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   611
    changeListView multipleSelectOk ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   612
        ^ changeListView selection size == 1
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   613
    ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   614
    ^ changeListView hasSelection
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   615
!
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   616
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   617
notEditingClassSource
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   618
    ^ self editingClassSource not
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   619
!
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   620
3224
b2f3a2a0bc80 readOnly flag added (for method-versions browsing)
Claus Gittinger <cg@exept.de>
parents: 3211
diff changeset
   621
notEditingClassSourceAndNotReadOnly
b2f3a2a0bc80 readOnly flag added (for method-versions browsing)
Claus Gittinger <cg@exept.de>
parents: 3211
diff changeset
   622
    ^ (self editingClassSource or:[readOnly == true]) not
b2f3a2a0bc80 readOnly flag added (for method-versions browsing)
Claus Gittinger <cg@exept.de>
parents: 3211
diff changeset
   623
!
b2f3a2a0bc80 readOnly flag added (for method-versions browsing)
Claus Gittinger <cg@exept.de>
parents: 3211
diff changeset
   624
b2f3a2a0bc80 readOnly flag added (for method-versions browsing)
Claus Gittinger <cg@exept.de>
parents: 3211
diff changeset
   625
notReadOnly
b2f3a2a0bc80 readOnly flag added (for method-versions browsing)
Claus Gittinger <cg@exept.de>
parents: 3211
diff changeset
   626
    ^ (readOnly ~~ true)
b2f3a2a0bc80 readOnly flag added (for method-versions browsing)
Claus Gittinger <cg@exept.de>
parents: 3211
diff changeset
   627
!
b2f3a2a0bc80 readOnly flag added (for method-versions browsing)
Claus Gittinger <cg@exept.de>
parents: 3211
diff changeset
   628
b2f3a2a0bc80 readOnly flag added (for method-versions browsing)
Claus Gittinger <cg@exept.de>
parents: 3211
diff changeset
   629
readOnly:aBoolean
b2f3a2a0bc80 readOnly flag added (for method-versions browsing)
Claus Gittinger <cg@exept.de>
parents: 3211
diff changeset
   630
    readOnly := aBoolean
b2f3a2a0bc80 readOnly flag added (for method-versions browsing)
Claus Gittinger <cg@exept.de>
parents: 3211
diff changeset
   631
!
b2f3a2a0bc80 readOnly flag added (for method-versions browsing)
Claus Gittinger <cg@exept.de>
parents: 3211
diff changeset
   632
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   633
theSingleSelection
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   634
    |sel|
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   635
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   636
    sel := changeListView selection.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   637
    changeListView multipleSelectOk ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   638
        sel size == 1 ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   639
            ^ sel first
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   640
        ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   641
        ^ nil
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   642
    ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   643
    ^ sel.
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   644
! !
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   645
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   646
!ChangesBrowser methodsFor:'compiler interface'!
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   647
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   648
wantChangeLog
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   649
    "sent by the compiler to ask if a changeLog entry should
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
   650
     be written when compiling. Return false here."
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   651
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   652
    ^ false
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   653
! !
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   654
2604
d09c51169bc8 category rename
Claus Gittinger <cg@exept.de>
parents: 2576
diff changeset
   655
!ChangesBrowser methodsFor:'compiler interface - error handling'!
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   656
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   657
correctableError:aString position:relPos to:relEndPos from:aCompiler
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   658
    "compiler notifys us of an error - this should really not happen since
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   659
     changes ought to be correct (did someone edit the changes file ??).
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   660
     Show the bad change in the codeView and let codeView hilight the error;
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   661
     no corrections allowed here therefore return false"
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   662
2293
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   663
    ShowWarningDialogs == true ifTrue:[
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   664
        self error:aString position:relPos to:relEndPos from:aCompiler.
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   665
    ] ifFalse:[
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   666
        Transcript showCR:aString.
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   667
    ].
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   668
    ^ false
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   669
!
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   670
2555
d92a6526ec47 correctable selectors.
Claus Gittinger <cg@exept.de>
parents: 2541
diff changeset
   671
correctableSelectorWarning:aString position:relPos to:relEndPos from:aCompiler
d92a6526ec47 correctable selectors.
Claus Gittinger <cg@exept.de>
parents: 2541
diff changeset
   672
    "compiler notifys us of a warning"
d92a6526ec47 correctable selectors.
Claus Gittinger <cg@exept.de>
parents: 2541
diff changeset
   673
d92a6526ec47 correctable selectors.
Claus Gittinger <cg@exept.de>
parents: 2541
diff changeset
   674
    ^ false
d92a6526ec47 correctable selectors.
Claus Gittinger <cg@exept.de>
parents: 2541
diff changeset
   675
d92a6526ec47 correctable selectors.
Claus Gittinger <cg@exept.de>
parents: 2541
diff changeset
   676
    "Modified: / 19.1.2000 / 16:25:31 / cg"
d92a6526ec47 correctable selectors.
Claus Gittinger <cg@exept.de>
parents: 2541
diff changeset
   677
    "Created: / 19.1.2000 / 16:27:23 / cg"
d92a6526ec47 correctable selectors.
Claus Gittinger <cg@exept.de>
parents: 2541
diff changeset
   678
!
d92a6526ec47 correctable selectors.
Claus Gittinger <cg@exept.de>
parents: 2541
diff changeset
   679
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   680
error:aString position:relPos to:relEndPos from:aCompiler
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   681
    "compiler notifys us of an error - this should really not happen since
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   682
     changes ought to be correct (did someone edit the changes file ??).
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   683
     Show the bad change in the codeView and let codeView hilight the error"
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   684
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   685
    |action|
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   686
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   687
    (changeNrProcessed ~~ changeNrShown) ifTrue:[
2293
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   688
        self changeSelection:changeNrProcessed
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   689
    ].
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   690
    (skipSignal notNil) ifTrue:[
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   691
2293
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   692
        codeView highlightingErrorPosition:relPos to:relEndPos do:[
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   693
            |box|
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   694
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   695
            "
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   696
             start dialog - make certain cleanup is done
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   697
            "
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   698
            action := OptionBox 
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   699
                          request:aString
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   700
                          label:'Error'
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   701
                          form:(WarningBox iconBitmap)
2420
6de430648cfe checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2417
diff changeset
   702
                          buttonLabels:#('cancel' 'skip' " 'shut up' " 'continue')
6de430648cfe checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2417
diff changeset
   703
                          values:#(#abort #skip " #shutUp " #continue)
3071
652c6b4f6981 optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents: 3069
diff changeset
   704
                          default:#continue
652c6b4f6981 optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents: 3069
diff changeset
   705
                          onCancel:#abort.
2293
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   706
        ].
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   707
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   708
"/        action == #shutUp ifTrue:[
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   709
"/            aCompiler ignoreWarnings.
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   710
"/            ^  false 
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   711
"/        ].
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   712
3071
652c6b4f6981 optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents: 3069
diff changeset
   713
        (action == #abort) ifTrue:[
2293
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   714
            Object abortSignal raise.
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   715
            ^ false
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   716
        ].
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   717
        action == #skip ifTrue:[
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   718
            skipSignal raise.
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   719
            ^ false
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   720
        ].
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
   721
        ^  false 
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   722
    ].
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   723
    ^ codeView error:aString position:relPos to:relEndPos from:aCompiler
373
292071301f91 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 358
diff changeset
   724
292071301f91 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 358
diff changeset
   725
    "Modified: 20.2.1996 / 20:47:59 / cg"
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   726
!
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   727
3064
20d22fe3d13b unusedVariableWarning
Claus Gittinger <cg@exept.de>
parents: 2965
diff changeset
   728
unusedVariableWarning:aString position:relPos to:relEndPos from:aCompiler
20d22fe3d13b unusedVariableWarning
Claus Gittinger <cg@exept.de>
parents: 2965
diff changeset
   729
    "compiler notifies us of a (or some) unused variables;
20d22fe3d13b unusedVariableWarning
Claus Gittinger <cg@exept.de>
parents: 2965
diff changeset
   730
     hilight the error (relPos to relEndPos) and show a Box asking for continue/correct/abort;
20d22fe3d13b unusedVariableWarning
Claus Gittinger <cg@exept.de>
parents: 2965
diff changeset
   731
     this method should return true to the compiler if user wants the error
20d22fe3d13b unusedVariableWarning
Claus Gittinger <cg@exept.de>
parents: 2965
diff changeset
   732
     to be corrected; false otherwise"
20d22fe3d13b unusedVariableWarning
Claus Gittinger <cg@exept.de>
parents: 2965
diff changeset
   733
20d22fe3d13b unusedVariableWarning
Claus Gittinger <cg@exept.de>
parents: 2965
diff changeset
   734
    ^ false
20d22fe3d13b unusedVariableWarning
Claus Gittinger <cg@exept.de>
parents: 2965
diff changeset
   735
!
20d22fe3d13b unusedVariableWarning
Claus Gittinger <cg@exept.de>
parents: 2965
diff changeset
   736
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   737
warning:aString position:relPos to:relEndPos from:aCompiler
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   738
    "compiler notifys us of a warning - ignore it"
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   739
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   740
    ^ self
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   741
! !
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   742
2604
d09c51169bc8 category rename
Claus Gittinger <cg@exept.de>
parents: 2576
diff changeset
   743
!ChangesBrowser methodsFor:'event handling'!
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   744
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   745
handlesKeyPress:key inView:view
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   746
    "this method is reached via delegation: are we prepared to handle
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   747
     a keyPress in some other view ?"
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   748
1127
32383ecaebe4 added alt-S for search
Claus Gittinger <cg@exept.de>
parents: 1109
diff changeset
   749
    <resource: #keyboard (#Delete #BackSpace #Accept #Find #FindPrev #FindNext)>
417
c80a8acf429c show shortkeys in changeList view
Claus Gittinger <cg@exept.de>
parents: 394
diff changeset
   750
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   751
    view == changeListView ifTrue:[
1378
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
   752
	(key == #Delete 
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
   753
	or:[key == #BackSpace
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
   754
	or:[key == #Accept
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
   755
	or:[key == #Find
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
   756
	or:[key == #FindPrev
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
   757
	or:[key == #FindNext]]]]]) ifTrue:[^ true].
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   758
    ].
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   759
    ^ false
417
c80a8acf429c show shortkeys in changeList view
Claus Gittinger <cg@exept.de>
parents: 394
diff changeset
   760
1127
32383ecaebe4 added alt-S for search
Claus Gittinger <cg@exept.de>
parents: 1109
diff changeset
   761
    "Modified: 8.4.1997 / 11:01:42 / cg"
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
   762
!
571fd5eee315 Initial revision
claus
parents:
diff changeset
   763
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   764
keyPress:key x:x y:y view:view
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   765
    "this method is reached via delegation from the changeListView"
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   766
1127
32383ecaebe4 added alt-S for search
Claus Gittinger <cg@exept.de>
parents: 1109
diff changeset
   767
    <resource: #keyboard (#Delete #BackSpace #Accept #Find #FindPrev #FindNext)>
417
c80a8acf429c show shortkeys in changeList view
Claus Gittinger <cg@exept.de>
parents: 394
diff changeset
   768
3249
b6509548b414 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3242
diff changeset
   769
    (key == #Delete) ifTrue:[
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
   770
        self doDelete.
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
   771
        ^ self
417
c80a8acf429c show shortkeys in changeList view
Claus Gittinger <cg@exept.de>
parents: 394
diff changeset
   772
    ].
3249
b6509548b414 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3242
diff changeset
   773
    (key == #BackSpace) ifTrue:[
b6509548b414 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3242
diff changeset
   774
        self doDeleteAndSelectPrevious.
b6509548b414 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3242
diff changeset
   775
        ^ self
b6509548b414 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3242
diff changeset
   776
    ].
417
c80a8acf429c show shortkeys in changeList view
Claus Gittinger <cg@exept.de>
parents: 394
diff changeset
   777
    (key == #Accept) ifTrue:[
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
   778
        self doApply.
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
   779
        ^ self
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   780
    ].
1127
32383ecaebe4 added alt-S for search
Claus Gittinger <cg@exept.de>
parents: 1109
diff changeset
   781
    (key == #Find) ifTrue:[
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
   782
        self findClass.
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
   783
        ^ self
1127
32383ecaebe4 added alt-S for search
Claus Gittinger <cg@exept.de>
parents: 1109
diff changeset
   784
    ].
975
41a41f54874d added findPrev (Alt-B) and findNext (Alt-F)
Claus Gittinger <cg@exept.de>
parents: 958
diff changeset
   785
    (key == #FindPrev) ifTrue:[
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
   786
        self findPrevious.
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
   787
        ^ self
975
41a41f54874d added findPrev (Alt-B) and findNext (Alt-F)
Claus Gittinger <cg@exept.de>
parents: 958
diff changeset
   788
    ].
41a41f54874d added findPrev (Alt-B) and findNext (Alt-F)
Claus Gittinger <cg@exept.de>
parents: 958
diff changeset
   789
    (key == #FindNext) ifTrue:[
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
   790
        self findNext.
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
   791
        ^ self
975
41a41f54874d added findPrev (Alt-B) and findNext (Alt-F)
Claus Gittinger <cg@exept.de>
parents: 958
diff changeset
   792
    ].
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   793
    changeListView keyPress:key x:x y:y
417
c80a8acf429c show shortkeys in changeList view
Claus Gittinger <cg@exept.de>
parents: 394
diff changeset
   794
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
   795
    "Modified: / 18.6.1998 / 22:15:36 / cg"
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   796
! !
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   797
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   798
!ChangesBrowser methodsFor:'help '!
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   799
394
1d19a14fc96e show activity notifiactions
Claus Gittinger <cg@exept.de>
parents: 392
diff changeset
   800
showActivity:someMessage
502
e8d7b3f08e03 commentary
Claus Gittinger <cg@exept.de>
parents: 489
diff changeset
   801
    "some activityNotification to be forwarded to the user;
e8d7b3f08e03 commentary
Claus Gittinger <cg@exept.de>
parents: 489
diff changeset
   802
     show it in the windows title area here."
e8d7b3f08e03 commentary
Claus Gittinger <cg@exept.de>
parents: 489
diff changeset
   803
394
1d19a14fc96e show activity notifiactions
Claus Gittinger <cg@exept.de>
parents: 392
diff changeset
   804
    self label:someMessage
1d19a14fc96e show activity notifiactions
Claus Gittinger <cg@exept.de>
parents: 392
diff changeset
   805
1d19a14fc96e show activity notifiactions
Claus Gittinger <cg@exept.de>
parents: 392
diff changeset
   806
    "Created: 24.2.1996 / 19:35:42 / cg"
502
e8d7b3f08e03 commentary
Claus Gittinger <cg@exept.de>
parents: 489
diff changeset
   807
    "Modified: 23.4.1996 / 21:39:36 / cg"
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   808
! !
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   809
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   810
!ChangesBrowser methodsFor:'initialize / release'!
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   811
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   812
autoCompareChanged
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   813
    "sent from the compare-toggle"
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   814
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   815
    autoCompare value ifTrue:[
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   816
        tabSpec positions:#(0  0.15  5   8.5 ).
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   817
        self doUpdate
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   818
    ] ifFalse:[
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   819
        "/
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   820
        "/ set tabs to hide compare-column
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   821
        "/
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   822
        tabSpec positions:#(-1  0    5   8.5 ).
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   823
        changeListView invalidate. "/ clear; redraw.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   824
    ]
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   825
!
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   826
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   827
changeListMenu
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   828
    "return the menu for the change (upper) list"
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   829
586
1acb0c4f0ecd added resource info
Claus Gittinger <cg@exept.de>
parents: 584
diff changeset
   830
    <resource: #keyboard ( #Accept #Delete ) >
1359
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
   831
    <resource: #programMenu >
586
1acb0c4f0ecd added resource info
Claus Gittinger <cg@exept.de>
parents: 584
diff changeset
   832
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   833
    |items m replNext replPrev sel|
1670
c3915af3f7f6 use new menu creation message
Claus Gittinger <cg@exept.de>
parents: 1649
diff changeset
   834
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
   835
    self sensor ctrlDown ifTrue:[
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   836
        "/ notice - findNext/prev shortKeys will search for the same thing again.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   837
        items := #(
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   838
                          ('Search Class...'              findClass               #Find       )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   839
                          ('Previous for this Class'      findPreviousForClass    #FindPrevClass      )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   840
                          ('Next for this Class'          findNextForClass        #FindNextClass      )
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   841
                          ('-'                                                                )
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   842
                          ('Search Selector...'           findSelector                        )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   843
                          ('Previous with this Selector'  findPreviousForSelector #FindPrevSelector   )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   844
                          ('Next with this Selector'      findNextForSelector     #FindNextSelector   )
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   845
                          ('-'                                                                )
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   846
                          ('Search String...'             findString                        )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   847
                          ('Previous with this String'    findPreviousForString   #FindPrevString   )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   848
                          ('Next with this String'        findNextForString       #FindNextString   )
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   849
                          ('-'                                                                )
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   850
                          ('Previous Snapshot'            findPreviousSnapshot    #FindPrevSnapshot   )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   851
                          ('Next Snapshot'                findNextSnapshot        #FindNextSnapshot   )
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   852
                 ).
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   853
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
   854
        lastSearchType == #selector ifTrue:[
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   855
            replNext := #FindNextSelector.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   856
            replPrev := #FindPrevSelector.
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
   857
        ] ifFalse:[
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   858
            lastSearchType == #snapshot ifTrue:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   859
                replNext := #FindNextSnapshot.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   860
                replPrev := #FindPrevSnapshot.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   861
            ] ifFalse:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   862
                lastSearchType == #string ifTrue:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   863
                    replNext := #FindNextString.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   864
                    replPrev := #FindPrevString.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   865
                ] ifFalse:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   866
                    replNext := #FindNextClass.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   867
                    replPrev := #FindPrevClass.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   868
                ]
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   869
            ]
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
   870
        ].
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   871
        items := items deepCopy.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   872
        items do:[:each | 
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   873
                        each replaceAll:replNext with:#FindNext.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   874
                        each replaceAll:replPrev with:#FindPrev.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   875
                        each replaceAny:#(FindNextClass FindPrevClass 
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   876
                                          FindNextSelector FindPrevSelector
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   877
                                          FindNextSnapshot FindPrevSnapshot
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   878
                                          FindNextString FindPrevString)
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   879
                             with:nil.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   880
                 ].
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
   881
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
   882
        ^ PopUpMenu itemList:items resources:resources.
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
   883
    ].
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
   884
1670
c3915af3f7f6 use new menu creation message
Claus Gittinger <cg@exept.de>
parents: 1649
diff changeset
   885
    items := #(
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   886
                      ('Apply'                        doApply                    Accept)
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   887
                      ('Apply to End'                 doApplyRest                      )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   888
                      ('Apply for Class to End'       doApplyClassRest                 )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   889
                      ('Apply All'                    doApplyAll                       )
1670
c3915af3f7f6 use new menu creation message
Claus Gittinger <cg@exept.de>
parents: 1649
diff changeset
   890
                      ('-'                                                             )
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   891
                      ('Delete'                       doDelete                   Delete)
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   892
                      ('Delete to End'                doDeleteRest                     )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   893
                      ('Delete for Class to End'      doDeleteClassRest                )
3234
1cb3bf47d498 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 3229
diff changeset
   894
                      ('Delete for Class from Begin'  doDeleteClassFromBeginning       )
3227
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   895
             ).
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   896
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   897
    (self hasSelection and:[self hasSingleSelection not]) ifTrue:[
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   898
        items := items ,
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   899
                 #(
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   900
                          ('Delete All for Classes'         doDeleteClassAll                 )
3234
1cb3bf47d498 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 3229
diff changeset
   901
                          ('Delete All for Classes & their private Classes' doDeleteClassAndPrivateClassesAll )
3227
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   902
                 ).
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   903
    ] ifFalse:[
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   904
        items := items ,
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   905
                 #(
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   906
                          ('Delete All for Class'         doDeleteClassAll                 )
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   907
                          ('Delete All for Class & its private Classes' doDeleteClassAndPrivateClassesAll )
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   908
                 ).
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   909
    ].
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   910
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   911
    items := items ,
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   912
             #(
1670
c3915af3f7f6 use new menu creation message
Claus Gittinger <cg@exept.de>
parents: 1649
diff changeset
   913
                      ('-'                                                             )
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   914
                      ('Compress'                     doCompress                       )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   915
                      ('Compress for Class'           doCompressClass                  )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   916
                      ('Compare and Compress'         doCompareAndCompress             )
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
   917
                      ('-'                                                             )
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   918
                      ('Compare with current Version' doCompare                        )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   919
                      ('Browse Class'                 doBrowse                         )
1670
c3915af3f7f6 use new menu creation message
Claus Gittinger <cg@exept.de>
parents: 1649
diff changeset
   920
                      ('-'                                                             )
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   921
                      ('Make Change a Patch'          doMakePatch                      )
1670
c3915af3f7f6 use new menu creation message
Claus Gittinger <cg@exept.de>
parents: 1649
diff changeset
   922
             ).
703
1b3b008d9f19 fixed to allow class-source files to be handled
Claus Gittinger <cg@exept.de>
parents: 627
diff changeset
   923
1b3b008d9f19 fixed to allow class-source files to be handled
Claus Gittinger <cg@exept.de>
parents: 627
diff changeset
   924
    editingClassSource ifFalse:[
1670
c3915af3f7f6 use new menu creation message
Claus Gittinger <cg@exept.de>
parents: 1649
diff changeset
   925
        items := items , #(
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   926
                      ('Fileout & Delete All for Class' doFileoutAndDeleteClassAll     )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   927
                      ('CheckIn & Delete All for Class' doCheckinAndDeleteClassAll     )
1670
c3915af3f7f6 use new menu creation message
Claus Gittinger <cg@exept.de>
parents: 1649
diff changeset
   928
                          )
703
1b3b008d9f19 fixed to allow class-source files to be handled
Claus Gittinger <cg@exept.de>
parents: 627
diff changeset
   929
    ].
1b3b008d9f19 fixed to allow class-source files to be handled
Claus Gittinger <cg@exept.de>
parents: 627
diff changeset
   930
1670
c3915af3f7f6 use new menu creation message
Claus Gittinger <cg@exept.de>
parents: 1649
diff changeset
   931
    items := items , #(
2474
6767e6c2f04c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2466
diff changeset
   932
                      ('-'                                            )
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   933
                      ('Save in...'                  doSave           )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   934
                      ('Save to End in...'           doSaveRest       )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   935
                      ('Save for Class to End in...' doSaveClassRest  )
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   936
                      ('Save All for Class in...'    doSaveClassAll   )
2474
6767e6c2f04c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2466
diff changeset
   937
                      ('-'                                            )
1670
c3915af3f7f6 use new menu creation message
Claus Gittinger <cg@exept.de>
parents: 1649
diff changeset
   938
                     ).
703
1b3b008d9f19 fixed to allow class-source files to be handled
Claus Gittinger <cg@exept.de>
parents: 627
diff changeset
   939
1b3b008d9f19 fixed to allow class-source files to be handled
Claus Gittinger <cg@exept.de>
parents: 627
diff changeset
   940
    editingClassSource ifTrue:[
1670
c3915af3f7f6 use new menu creation message
Claus Gittinger <cg@exept.de>
parents: 1649
diff changeset
   941
        items := items , #(
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   942
                      ('Writeback ClassFile'  doWriteBack )
1670
c3915af3f7f6 use new menu creation message
Claus Gittinger <cg@exept.de>
parents: 1649
diff changeset
   943
                     )
703
1b3b008d9f19 fixed to allow class-source files to be handled
Claus Gittinger <cg@exept.de>
parents: 627
diff changeset
   944
    ] ifFalse:[
1670
c3915af3f7f6 use new menu creation message
Claus Gittinger <cg@exept.de>
parents: 1649
diff changeset
   945
        items := items , #(
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   946
                      ('Writeback ChangeFile' doWriteBack )
1670
c3915af3f7f6 use new menu creation message
Claus Gittinger <cg@exept.de>
parents: 1649
diff changeset
   947
                     )
703
1b3b008d9f19 fixed to allow class-source files to be handled
Claus Gittinger <cg@exept.de>
parents: 627
diff changeset
   948
    ].
1b3b008d9f19 fixed to allow class-source files to be handled
Claus Gittinger <cg@exept.de>
parents: 627
diff changeset
   949
1833
c9b1a30b326d moved update item to the end
Claus Gittinger <cg@exept.de>
parents: 1788
diff changeset
   950
    items := items , #(
c9b1a30b326d moved update item to the end
Claus Gittinger <cg@exept.de>
parents: 1788
diff changeset
   951
                  ('-'                                                             )
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   952
                  ('Update'                       doUpdate                         )
1833
c9b1a30b326d moved update item to the end
Claus Gittinger <cg@exept.de>
parents: 1788
diff changeset
   953
                 ).
1670
c3915af3f7f6 use new menu creation message
Claus Gittinger <cg@exept.de>
parents: 1649
diff changeset
   954
c3915af3f7f6 use new menu creation message
Claus Gittinger <cg@exept.de>
parents: 1649
diff changeset
   955
    m := PopUpMenu itemList:items resources:resources.
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   956
255
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
   957
    "/
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
   958
    "/ disable those that require a selected entry
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
   959
    "/
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   960
    self hasSelection ifFalse:[
1670
c3915af3f7f6 use new menu creation message
Claus Gittinger <cg@exept.de>
parents: 1649
diff changeset
   961
        m disableAll:#(doApply doApplyClassRest doApplyRest doDelete doDeleteRest doDeleteClassRest
2511
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
   962
                       doDeleteClassFromBeginning doDeleteClassAll doDeleteClassAndPrivateClassesAll 
1670
c3915af3f7f6 use new menu creation message
Claus Gittinger <cg@exept.de>
parents: 1649
diff changeset
   963
                       doCompare doCompressClass doMakePatch doSaveChangeInFile doMakePermanent
2541
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
   964
                       doSave doSaveRest doSaveClassAll doSaveClassRest doBrowse 
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
   965
                       doFileoutAndDeleteClassAll doCheckinAndDeleteClassAll) 
1368
a27fc06ba9ea checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1359
diff changeset
   966
    ] ifTrue:[
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   967
        sel := self theSingleSelection.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   968
        sel isNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   969
            "/ multiple selections
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   970
            m disableAll:#(doApplyClassRest doApplyRest doDeleteClassRest doDeleteRest
3227
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   971
                           doDeleteClassFromBeginning 
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   972
                           doCompressClass doCompare
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   973
                           doSaveClassAll doSaveClassRest doSaveRest doBrowse 
2541
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
   974
                           doFileoutAndDeleteClassAll doCheckinAndDeleteClassAll) 
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   975
        ] ifFalse:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   976
            (self classNameOfChange:sel) isNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   977
                m disableAll:#(doApplyClassRest doDeleteClassRest
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   978
                               doDeleteClassFromBeginning doDeleteClassAll doDeleteClassAndPrivateClassesAll
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   979
                               doCompressClass doCompare doMakePatch
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   980
                               doSaveClassAll doSaveClassRest doBrowse 
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   981
                               doFileoutAndDeleteClassAll doCheckinAndDeleteClassAll) 
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
   982
            ]
1670
c3915af3f7f6 use new menu creation message
Claus Gittinger <cg@exept.de>
parents: 1649
diff changeset
   983
        ]
255
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
   984
    ].
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
   985
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
   986
    "/
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
   987
    "/ disable those that do not make sense with autoUpdate
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
   988
    "/ ('cause this would be overwritten by next update operation)
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
   989
    "/
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
   990
    autoUpdate value ifTrue:[
2511
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
   991
        m disableAll:#(doDelete doDeleteRest doDeleteClassRest doDeleteClassAll 
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
   992
                       doDeleteClassAndPrivateClassesAll doCompress 
2541
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
   993
                       doFileoutAndDeleteClassAll doCheckinAndDeleteClassAll
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
   994
                       doWriteBack)
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
   995
    ].
3227
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   996
    readOnly == true ifTrue:[
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   997
        m disableAll:#(doDelete doDeleteRest doDeleteClassRest doDeleteClassAll 
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   998
                       doDeleteClassAndPrivateClassesAll doCompress 
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
   999
                       doFileoutAndDeleteClassAll doCheckinAndDeleteClassAll
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  1000
                       doWriteBack doSaveBack doUpdate
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  1001
                       doApplyAll doApplyRest)
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  1002
    ].
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  1003
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  1004
    self hasSelection ifTrue:[
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  1005
        m disable:#doApplyAll
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  1006
    ].
3224
b2f3a2a0bc80 readOnly flag added (for method-versions browsing)
Claus Gittinger <cg@exept.de>
parents: 3211
diff changeset
  1007
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1008
    ^ m
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1009
1359
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  1010
    "Modified: / 6.9.1995 / 17:14:22 / claus"
1848
61054ff3d470 added find prev/next snapshot to search menu
Claus Gittinger <cg@exept.de>
parents: 1833
diff changeset
  1011
    "Modified: / 22.8.1998 / 15:50:17 / cg"
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1012
!
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1013
2114
720edbe757f5 category change
Claus Gittinger <cg@exept.de>
parents: 2093
diff changeset
  1014
destroy
720edbe757f5 category change
Claus Gittinger <cg@exept.de>
parents: 2093
diff changeset
  1015
    "destroy the receiver; make certain, that boxes are destroyed too"
720edbe757f5 category change
Claus Gittinger <cg@exept.de>
parents: 2093
diff changeset
  1016
720edbe757f5 category change
Claus Gittinger <cg@exept.de>
parents: 2093
diff changeset
  1017
    Processor removeTimedBlock:checkBlock.
720edbe757f5 category change
Claus Gittinger <cg@exept.de>
parents: 2093
diff changeset
  1018
    ObjectMemory removeDependent:self.
720edbe757f5 category change
Claus Gittinger <cg@exept.de>
parents: 2093
diff changeset
  1019
    super destroy
720edbe757f5 category change
Claus Gittinger <cg@exept.de>
parents: 2093
diff changeset
  1020
!
720edbe757f5 category change
Claus Gittinger <cg@exept.de>
parents: 2093
diff changeset
  1021
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1022
focusSequence
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1023
    ^ Array with:changeListView with:codeView
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1024
!
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1025
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1026
initialize
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1027
    |panel v upperFrame buttonPanel menuPanel mH
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1028
     checkBox protectExistingMethods oldStyle|
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1029
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1030
    "/ oldStyle := true.
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1031
    oldStyle := false.
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1032
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1033
    super initialize.
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1034
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1035
    changeFileName := ObjectMemory nameForChanges. "/ 'changes'.
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1036
    autoCompare := false asValue.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1037
    autoCompare onChangeSend:#autoCompareChanged to:self.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1038
    autoUpdate := false asValue.
2343
20af8b9e9d8d checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2341
diff changeset
  1039
    applyInOriginalNameSpace := true asValue.
221
6c278b8ec6ca added autoUpdate
Claus Gittinger <cg@exept.de>
parents: 209
diff changeset
  1040
1099
b0a4e8ccc5cc Use #pushEvent: for timer handling.
Stefan Vogel <sv@exept.de>
parents: 1090
diff changeset
  1041
    "
b0a4e8ccc5cc Use #pushEvent: for timer handling.
Stefan Vogel <sv@exept.de>
parents: 1090
diff changeset
  1042
      checkBlock is executed by the Processor.
b0a4e8ccc5cc Use #pushEvent: for timer handling.
Stefan Vogel <sv@exept.de>
parents: 1090
diff changeset
  1043
      We use #pushEvent: to perform the update
b0a4e8ccc5cc Use #pushEvent: for timer handling.
Stefan Vogel <sv@exept.de>
parents: 1090
diff changeset
  1044
      in our windowgroups process.
b0a4e8ccc5cc Use #pushEvent: for timer handling.
Stefan Vogel <sv@exept.de>
parents: 1090
diff changeset
  1045
    "
b0a4e8ccc5cc Use #pushEvent: for timer handling.
Stefan Vogel <sv@exept.de>
parents: 1090
diff changeset
  1046
    checkBlock := [self pushEvent:#checkIfFileHasChanged].
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1047
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1048
    oldStyle ifFalse:[
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1049
        menuPanel := MenuPanel in:self.
3242
0fc239690314 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3234
diff changeset
  1050
        "/ menuPanel level:1.
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1051
        menuPanel verticalLayout:false.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1052
        menuPanel receiver:self.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1053
        menuPanel menu:(self pullDownMenu).
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1054
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1055
        mH := menuPanel preferredExtent y.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1056
        menuPanel origin:(0.0 @ 0.0) corner:(1.0 @ (mH)).
3297
12b826adb7aa *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 3292
diff changeset
  1057
        mH := mH + 1.
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1058
    ] ifTrue:[
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1059
        mH := 0.0
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1060
    ].
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1061
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1062
    panel := VariableVerticalPanel origin:(0.0 @ mH)
1471
f73ed23816d4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1470
diff changeset
  1063
                                   corner:(1.0 @ 1.0)
f73ed23816d4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1470
diff changeset
  1064
                              borderWidth:0
f73ed23816d4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1470
diff changeset
  1065
                                       in:self.
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1066
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1067
    upperFrame := panel.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1068
    oldStyle ifTrue:[
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1069
        upperFrame := VariableHorizontalPanel origin:(0.0 @ 0.0) corner:(1.0 @ 0.3) in:panel.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1070
    ].
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1071
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1072
    v := HVScrollableView for:SelectionInListView miniScrollerH:true in:upperFrame.
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1073
    oldStyle ifTrue:[
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1074
        v origin:(0.0 @ 0.0) corner:(0.75 @ 1.0).
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1075
    ] ifFalse:[
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1076
        v origin:(0.0 @ 0.0) corner:(1.0 @ 0.3).
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1077
    ].
3090
2306c68dfee1 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3071
diff changeset
  1078
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1079
    changeListView := v scrolledView.
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1080
    changeListView delegate:self.
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1081
    changeListView menuHolder:self; menuPerformer:self; menuMessage:#changeListMenu.
1471
f73ed23816d4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1470
diff changeset
  1082
    changeListView doubleClickAction:[:line | self doubleClickOnChange:line].
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1083
    oldStyle ifFalse:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1084
        changeListView multipleSelectOk:true.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1085
    ].
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1086
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1087
    oldStyle ifTrue:[
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1088
        buttonPanel := VerticalPanelView in:upperFrame.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1089
        buttonPanel origin:(0.75 @ 0.0) corner:(1.0 @ 1.0).
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1090
        buttonPanel verticalLayout:#topSpace; horizontalLayout:#leftSpace.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1091
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1092
        checkBox := CheckBox new model:autoCompare.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1093
        checkBox label:(resources string:'Auto Compare').
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1094
        checkBox action:[:val | autoCompare value:val].
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1095
        buttonPanel addSubView:checkBox.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1096
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1097
        checkBox := CheckBox new model:autoUpdate.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1098
        checkBox label:(resources string:'Auto Update').
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1099
        checkBox action:[:val | autoUpdate value:val].
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1100
        buttonPanel addSubView:checkBox.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1101
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1102
        checkBox := CheckBox new.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1103
        checkBox label:(resources string:'Apply in original NameSpace' withCRs).
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1104
        checkBox model:applyInOriginalNameSpace.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1105
        buttonPanel addSubView:checkBox.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1106
    ].
2301
d557a9dec28c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2295
diff changeset
  1107
3090
2306c68dfee1 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3071
diff changeset
  1108
"/    protectExistingMethods := CheckBox new.
2306c68dfee1 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3071
diff changeset
  1109
"/    protectExistingMethods label:(resources string:'Protect existing code' withCRs).
2306c68dfee1 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3071
diff changeset
  1110
"/    protectExistingMethods model:protectExistingMethods.
2306c68dfee1 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3071
diff changeset
  1111
"/    buttonPanel addSubView:protectExistingMethods.
2306c68dfee1 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3071
diff changeset
  1112
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1113
    v := HVScrollableView for:CodeView miniScrollerH:true miniScrollerV:false in:panel.
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1114
    v origin:(0.0 @ 0.3) corner:(1.0 @ 1.0).
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1115
    codeView := v scrolledView.
1996
e229ecc9f839 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1848
diff changeset
  1116
    codeView readOnly:true.
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1117
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1118
    anyChanges := false.
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1119
    ObjectMemory addDependent:self.   "to get shutdown-update"
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1120
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1121
    tabSpec := TabulatorSpecification new.
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1122
    tabSpec unit:#inch.
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1123
    tabSpec positions:#(-1      0        5      8.5 ).
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1124
    "                   +/-    cls>>sel  type   info"
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1125
    tabSpec align:    #(#left  #left     #left  #left).
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1126
1471
f73ed23816d4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1470
diff changeset
  1127
    "Modified: / 27.3.1997 / 11:07:07 / stefan"
3297
12b826adb7aa *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 3292
diff changeset
  1128
    "Modified: / 11.10.2001 / 21:20:48 / cg"
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1129
!
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1130
1246
9ed3722bd2f2 setup in #postRealize instead of #realize
Claus Gittinger <cg@exept.de>
parents: 1200
diff changeset
  1131
postRealize
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1132
    self readChangesFileInBackground:true.
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1133
    self setChangeList.
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1134
    changeListView action:[:lineNr | self changeSelection:lineNr].
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1135
    Processor addTimedBlock:checkBlock afterSeconds:5.
1246
9ed3722bd2f2 setup in #postRealize instead of #realize
Claus Gittinger <cg@exept.de>
parents: 1200
diff changeset
  1136
9ed3722bd2f2 setup in #postRealize instead of #realize
Claus Gittinger <cg@exept.de>
parents: 1200
diff changeset
  1137
    "Created: 24.7.1997 / 18:06:12 / cg"
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1138
!
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1139
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1140
pullDownMenu
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1141
    "return the top (pullDown) menu"
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1142
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1143
    <resource: #programMenu>
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1144
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1145
    |m|
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1146
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1147
    m := self class menuSpec.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1148
    m := m decodeAsLiteralArray.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1149
    m receiver:self.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1150
    m findGuiResourcesIn:self.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1151
    ^ m.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1152
!
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1153
627
60c38701d4a2 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 586
diff changeset
  1154
update:what with:aParameter from:changedObject
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1155
    |box|
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1156
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1157
    (what == #aboutToExit) ifTrue:[
2353
707dd9391c02 Consistent use of 'update' and 'write' in the user interface
Stefan Vogel <sv@exept.de>
parents: 2343
diff changeset
  1158
        "
707dd9391c02 Consistent use of 'update' and 'write' in the user interface
Stefan Vogel <sv@exept.de>
parents: 2343
diff changeset
  1159
         smalltalk is about to shut down -
707dd9391c02 Consistent use of 'update' and 'write' in the user interface
Stefan Vogel <sv@exept.de>
parents: 2343
diff changeset
  1160
         - if change list was modified, ask user and save if requested.
707dd9391c02 Consistent use of 'update' and 'write' in the user interface
Stefan Vogel <sv@exept.de>
parents: 2343
diff changeset
  1161
        "
707dd9391c02 Consistent use of 'update' and 'write' in the user interface
Stefan Vogel <sv@exept.de>
parents: 2343
diff changeset
  1162
        anyChanges ifTrue:[
707dd9391c02 Consistent use of 'update' and 'write' in the user interface
Stefan Vogel <sv@exept.de>
parents: 2343
diff changeset
  1163
            self raiseDeiconified.
707dd9391c02 Consistent use of 'update' and 'write' in the user interface
Stefan Vogel <sv@exept.de>
parents: 2343
diff changeset
  1164
707dd9391c02 Consistent use of 'update' and 'write' in the user interface
Stefan Vogel <sv@exept.de>
parents: 2343
diff changeset
  1165
            box := YesNoBox new.
2888
a8f77fb777ee better warn text
Claus Gittinger <cg@exept.de>
parents: 2867
diff changeset
  1166
            box title:('The modified changelist has not been written back to the change file.\\Write change file before exiting ?') withCRs.
2353
707dd9391c02 Consistent use of 'update' and 'write' in the user interface
Stefan Vogel <sv@exept.de>
parents: 2343
diff changeset
  1167
            box okText:(resources at:'write') noText:(resources at:'don''t write').
707dd9391c02 Consistent use of 'update' and 'write' in the user interface
Stefan Vogel <sv@exept.de>
parents: 2343
diff changeset
  1168
            box yesAction:[self writeBackChanges] 
707dd9391c02 Consistent use of 'update' and 'write' in the user interface
Stefan Vogel <sv@exept.de>
parents: 2343
diff changeset
  1169
                 noAction:[].
707dd9391c02 Consistent use of 'update' and 'write' in the user interface
Stefan Vogel <sv@exept.de>
parents: 2343
diff changeset
  1170
            box showAtPointer.
707dd9391c02 Consistent use of 'update' and 'write' in the user interface
Stefan Vogel <sv@exept.de>
parents: 2343
diff changeset
  1171
            box destroy
707dd9391c02 Consistent use of 'update' and 'write' in the user interface
Stefan Vogel <sv@exept.de>
parents: 2343
diff changeset
  1172
        ].
707dd9391c02 Consistent use of 'update' and 'write' in the user interface
Stefan Vogel <sv@exept.de>
parents: 2343
diff changeset
  1173
        ^ self
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1174
    ].
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1175
    super update:what
627
60c38701d4a2 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 586
diff changeset
  1176
2353
707dd9391c02 Consistent use of 'update' and 'write' in the user interface
Stefan Vogel <sv@exept.de>
parents: 2343
diff changeset
  1177
    "Created: / 15.6.1996 / 15:26:30 / cg"
707dd9391c02 Consistent use of 'update' and 'write' in the user interface
Stefan Vogel <sv@exept.de>
parents: 2343
diff changeset
  1178
    "Modified: / 7.1.1997 / 23:03:47 / cg"
707dd9391c02 Consistent use of 'update' and 'write' in the user interface
Stefan Vogel <sv@exept.de>
parents: 2343
diff changeset
  1179
    "Modified: / 24.8.1999 / 09:45:06 / stefan"
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1180
! !
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1181
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1182
!ChangesBrowser methodsFor:'menu actions'!
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1183
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1184
menuExit
3204
f3efd0865b8c *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 3203
diff changeset
  1185
    self closeRequest
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1186
!
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1187
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1188
openAboutThisApplication
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1189
    "opens an about box for this application."
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1190
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1191
    |rev box myClass clsRev image msg|
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1192
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1193
    rev := ''.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1194
    myClass := self class.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1195
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1196
    (clsRev := myClass revision) notNil ifTrue: [rev := '  (rev: ', clsRev printString, ')'].
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1197
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1198
    msg := '\' withCRs , myClass name asBoldText, rev.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1199
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1200
    AboutBox isNil ifTrue:[
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1201
        "/ this handles bad installations of ST/X,
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1202
        "/ where the AboutBox is missing.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1203
        "/ (May vanish in the future)
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1204
        ^ self information:msg
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1205
    ].
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1206
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1207
    box := AboutBox title:msg.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1208
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1209
    image := self class defaultIcon.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1210
    image notNil ifTrue:[
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1211
        box image:image
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1212
    ].
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1213
    box   label:'About This Application'.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1214
    box   autoHideAfter:10 with:[].
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1215
    box   showAtPointer.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1216
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1217
    "Modified: / 14.8.1998 / 13:20:24 / cg"
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1218
!
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1219
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1220
openHTMLDocument:relativeDocPath
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1221
    HTMLDocumentView openFullOnDocumentationFile:relativeDocPath
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1222
!
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1223
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1224
showAboutSTX
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1225
    ToolApplicationModel openAboutSTX
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1226
! !
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1227
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1228
!ChangesBrowser methodsFor:'private'!
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  1229
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1230
autoSelect:changeNr
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1231
    "select a change"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1232
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1233
    self class autoSelectNext ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1234
        (changeNr <= self numberOfChanges) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1235
            changeListView setSelection:changeNr.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1236
            self changeSelection:changeNr.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1237
            ^ self
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1238
        ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1239
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1240
    self clearCodeView.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1241
    changeListView setSelection:nil.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1242
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1243
    "Modified: / 18.5.1998 / 14:26:43 / cg"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1244
!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1245
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1246
autoSelectLast
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1247
    "select the last change"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1248
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1249
    self autoSelect:(self numberOfChanges)
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1250
!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1251
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1252
autoSelectOrEnd:changeNr
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1253
    "select the next change or the last"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1254
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1255
    |last|
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1256
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1257
    last := self numberOfChanges.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1258
    changeNr < last ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1259
	self autoSelect:changeNr
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1260
    ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1261
	changeListView setSelection:last .
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1262
	self changeSelection:last.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1263
    ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1264
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1265
    "Modified: 25.5.1996 / 12:26:17 / cg"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1266
!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1267
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1268
checkClassIsLoaded:aClass
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1269
    "check for and warn if a class is unloaded (helper for compare-change)"
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1270
2474
6767e6c2f04c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2466
diff changeset
  1271
    |cls answer|
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1272
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1273
    aClass isMeta ifTrue:[
2474
6767e6c2f04c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2466
diff changeset
  1274
        cls := aClass soleInstance
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1275
    ] ifFalse:[
2474
6767e6c2f04c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2466
diff changeset
  1276
        cls := aClass
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1277
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1278
    cls isLoaded ifFalse:[
2474
6767e6c2f04c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2466
diff changeset
  1279
        (self confirm:(resources 
6767e6c2f04c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2466
diff changeset
  1280
                        string:'%1 is an autoloaded class.\I can only compare the methods source if its loaded first.\\Shall the class be loaded now ?'
2867
0ce30d3c763f asText allBold -> allBold
Claus Gittinger <cg@exept.de>
parents: 2863
diff changeset
  1281
                        with:cls name allBold) withCRs)
2474
6767e6c2f04c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2466
diff changeset
  1282
        ifFalse:[
6767e6c2f04c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2466
diff changeset
  1283
            AbortSignal raise
6767e6c2f04c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2466
diff changeset
  1284
        ].
6767e6c2f04c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2466
diff changeset
  1285
        cls autoload
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1286
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1287
    ^ cls isLoaded
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1288
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1289
    "Created: 12.12.1995 / 14:04:39 / cg"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1290
    "Modified: 12.12.1995 / 14:11:05 / cg"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1291
!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1292
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1293
clearCodeView
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1294
    "clear the (lower) code view."
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1295
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1296
    self unselect "changeListView deselect".
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1297
    codeView contents:nil.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1298
    changeNrShown := nil
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1299
!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1300
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1301
contractClass:className selector:selector to:maxLen
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1302
    "contract a class>>selector string (for display in the changeList)."
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1303
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1304
    |s l|
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1305
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1306
    s := className , ' ', selector.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1307
    s size > maxLen ifTrue:[
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1308
        l := maxLen - 1 - selector size max:20.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1309
        s := (className contractTo:l) , ' ' , selector.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1310
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1311
        s size > maxLen ifTrue:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1312
            l := maxLen - 1 - className size max:20.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1313
            s := className , ' ', (selector contractTo:l).
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1314
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1315
            s size > maxLen ifTrue:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1316
                s := (className contractTo:(maxLen // 2 - 1)) , ' ' , (selector contractTo:maxLen // 2)
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1317
            ]
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1318
        ]
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1319
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1320
    ^ s
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1321
!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1322
3203
44ac975f0993 pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3202
diff changeset
  1323
isChangeSetBrowser
44ac975f0993 pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3202
diff changeset
  1324
    ^ false
44ac975f0993 pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3202
diff changeset
  1325
!
44ac975f0993 pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3202
diff changeset
  1326
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1327
newLabel:how
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1328
    |l|
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1329
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1330
    (changeFileName ~= 'changes') ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1331
        l := self class defaultLabel , ': ', changeFileName
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1332
    ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1333
        l := self class defaultLabel
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1334
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1335
    l := l , ' ' , how.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1336
    self label:l
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1337
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1338
    "Created: / 8.9.1995 / 19:32:04 / claus"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1339
    "Modified: / 8.9.1995 / 19:39:29 / claus"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1340
    "Modified: / 6.2.1998 / 13:27:01 / cg"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1341
!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1342
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1343
queryCloseText
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1344
    "made this a method for easy redefinition in subclasses"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1345
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1346
    ^ 'Quit without updating changeFile ?'
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1347
!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1348
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1349
setChangeList
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1350
    "extract type-information from changes and stuff into top selection
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1351
     view"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1352
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1353
    changeListView setList:changeHeaderLines expandTabs:false redraw:false.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1354
    changeListView invalidate.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1355
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1356
    "/ changeListView deselect.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1357
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1358
    "Modified: / 18.5.1998 / 14:29:10 / cg"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1359
!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1360
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1361
setSingleSelection:changeNr
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1362
    changeListView multipleSelectOk ifFalse:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1363
        changeListView setSelection:changeNr.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1364
    ] ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1365
        changeListView setSelection:(Array with:changeNr).
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1366
    ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1367
!
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1368
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1369
showNotFound
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1370
    |savedCursor|
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1371
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1372
    savedCursor := cursor.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1373
    [
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1374
        self cursor:(Cursor cross).
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1375
        self beep.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1376
        Delay waitForMilliseconds:300.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1377
    ] valueNowOrOnUnwindDo:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1378
        self cursor:savedCursor
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1379
    ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1380
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1381
    "Modified: / 29.4.1999 / 22:36:54 / cg"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1382
!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1383
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1384
unselect
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1385
    "common unselect"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1386
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1387
    changeListView setSelection:nil.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1388
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1389
    "Modified: 25.5.1996 / 13:02:49 / cg"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1390
!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1391
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1392
withSelectedChangesDo:aBlock
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1393
    "just a helper, check for a selected change and evaluate aBlock
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1394
     with busy cursor"
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1395
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1396
    self withSelectedChangesInOrder:nil do:aBlock
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1397
!
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1398
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1399
withSelectedChangesInOrder:order do:aBlock
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1400
    "just a helper, check for a selected change and evaluate aBlock
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1401
     with busy cursor"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1402
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1403
    |changeNrSelection|
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1404
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1405
    changeNrSelection := changeListView selection.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1406
    changeListView multipleSelectOk ifFalse:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1407
        changeNrSelection notNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1408
            self withExecuteCursorDo:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1409
                aBlock value:changeNrSelection
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1410
            ]
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1411
        ]
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1412
    ] ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1413
        changeNrSelection size > 0 ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1414
            self withExecuteCursorDo:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1415
                |changeNumbers|
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1416
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1417
                changeNumbers := changeNrSelection copy sort.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1418
                order == #reverse ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1419
                    changeNumbers reverse
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1420
                ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1421
                changeNumbers do:aBlock
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1422
            ]
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1423
        ]
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1424
    ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1425
!
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1426
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1427
withSelectedChangesReverseDo:aBlock
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1428
    "just a helper, check for a selected change and evaluate aBlock
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1429
     with busy cursor"
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1430
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  1431
    self withSelectedChangesInOrder:#reverse do:aBlock
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1432
! !
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1433
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1434
!ChangesBrowser methodsFor:'private-change access'!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1435
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1436
changeIsFollowupMethodChange:changeNr
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1437
    "return true, if a change is a followup change (i.e. a followup change
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1438
     in a bunch of methodsFor-changes)"
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1439
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1440
    ^ changeIsFollowupMethodChange at:changeNr
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1441
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1442
    "Created: / 6.2.1998 / 13:03:39 / cg"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1443
!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1444
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1445
changeIsSnapShotInfo:changeNr
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1446
    "return true, if a change is a snapShot info chunk"
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1447
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1448
    |words chunk|
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1449
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1450
    (self classNameOfChange:changeNr) isNil ifTrue:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1451
        "
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1452
         get the chunk
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1453
        "
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1454
        chunk := changeChunks at:changeNr.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1455
        "mhmh - empty ??"
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1456
        chunk notNil ifTrue:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1457
            (chunk startsWith:'''---') ifTrue:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1458
                words := chunk asCollectionOfWords.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1459
                words size > 2 ifTrue:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1460
                    (words at:2) = 'snapshot' ifTrue:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1461
                        ^ true
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1462
                    ].
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1463
                ].
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1464
            ].
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1465
        ].
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1466
    ].
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1467
    ^ false
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1468
!
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1469
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1470
classNameOfChange:changeNr
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1471
    "return the classname of a change 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1472
     (for classChanges (i.e. xxx class), the non-metaClassName (i.e. xxx) is returned)"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1473
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1474
    |name|
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1475
2686
e814876e7d61 class name cache
Claus Gittinger <cg@exept.de>
parents: 2683
diff changeset
  1476
    name := changeClassNames at:changeNr.
e814876e7d61 class name cache
Claus Gittinger <cg@exept.de>
parents: 2683
diff changeset
  1477
    name isNil ifTrue:[
e814876e7d61 class name cache
Claus Gittinger <cg@exept.de>
parents: 2683
diff changeset
  1478
        name := self fullClassNameOfChange:changeNr.
e814876e7d61 class name cache
Claus Gittinger <cg@exept.de>
parents: 2683
diff changeset
  1479
    ].
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1480
    name isNil ifTrue:[^ nil].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1481
    (name endsWith:' class') ifTrue:[
2686
e814876e7d61 class name cache
Claus Gittinger <cg@exept.de>
parents: 2683
diff changeset
  1482
        ^ name copyWithoutLast:6
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1483
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1484
    ^ name
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1485
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1486
    "Modified: 6.12.1995 / 17:06:31 / cg"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1487
!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1488
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1489
extractSelectorOfMethodChange:changeNr
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1490
    "return a method-changes selector, or nil if its not a methodChange"
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1491
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1492
    |source parser sel chunk aParseTree |
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1493
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1494
    source := self sourceOfMethodChange:changeNr.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1495
    source isNil ifTrue:[
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1496
        (self classNameOfChange:changeNr) notNil ifTrue:[
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1497
            chunk := changeChunks at:changeNr.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1498
            chunk isNil ifTrue:[^ nil].       "mhmh - empty"
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1499
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1500
            aParseTree := Parser parseExpression:chunk.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1501
            (aParseTree isNil 
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1502
            or:[aParseTree == #Error
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1503
            or:[aParseTree isMessage not]]) ifTrue:[
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1504
                ^ nil        "seems strange ... (could be a comment)"
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1505
            ].
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1506
            sel := aParseTree selector.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1507
            (#(
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1508
                #'removeSelector:' 
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1509
            ) includes:sel) ifTrue:[
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1510
                sel := aParseTree arguments at:1.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1511
                sel isConstant ifTrue:[
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1512
                    sel := sel evaluate.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1513
                    sel isSymbol ifTrue:[
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1514
                        ^ sel
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1515
                    ]
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1516
                ]
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1517
            ]
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1518
        ].
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1519
        ^ nil
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1520
    ].
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1521
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1522
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1523
    parser := Parser 
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1524
                parseMethodArgAndVarSpecification:source
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1525
                in:nil 
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1526
                ignoreErrors:true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1527
                ignoreWarnings:true
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1528
                parseBody:false.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1529
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1530
    (parser notNil and:[parser ~~ #Error]) ifTrue:[
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1531
        sel := parser selector.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1532
    ].
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1533
    ^ sel
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1534
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1535
    "Created: 24.11.1995 / 14:30:46 / cg"
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1536
    "Modified: 5.9.1996 / 17:12:50 / cg"
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1537
!
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1538
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1539
fullClassNameOfChange:changeNr
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1540
    "return the full classname of a change 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1541
     (for classChanges (i.e. xxx class), a string ending in ' class' is returned.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1542
     - since parsing ascii methods is slow, keep result cached in 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1543
       changeClassNames for the next query"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1544
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1545
    |chunk aParseTree recTree sel name arg1Tree isMeta prevMethodDefNr
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1546
     words changeStream fullParseTree ownerTree ownerName oldDollarSetting|
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1547
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1548
    changeNr isNil ifTrue:[^ nil].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1549
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1550
    "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1551
     first look, if not already known
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1552
    "
2683
e76575e4346f private className extraction
tm
parents: 2682
diff changeset
  1553
"/    name := changeClassNames at:changeNr.
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1554
    name notNil ifTrue:[^ name].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1555
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1556
    prevMethodDefNr := changeNr.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1557
    [changeIsFollowupMethodChange at:prevMethodDefNr] whileTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1558
        prevMethodDefNr := prevMethodDefNr - 1.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1559
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1560
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1561
    "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1562
     get the chunk
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1563
    "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1564
    chunk := changeChunks at:prevMethodDefNr.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1565
    chunk isNil ifTrue:[^ nil].       "mhmh - empty"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1566
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1567
    (chunk startsWith:'''---') ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1568
        words := chunk asCollectionOfWords.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1569
        words size > 2 ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1570
            (words at:2) = 'checkin' ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1571
                name := words at:3.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1572
                changeClassNames at:changeNr put:name.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1573
                ^ name
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1574
            ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1575
        ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1576
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1577
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1578
    "/ fix it - otherwise, it cannot be parsed
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1579
    (chunk endsWith:'primitiveDefinitions:') ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1580
        chunk := chunk , ''''''
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1581
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1582
    (chunk endsWith:'primitiveFunctions:') ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1583
        chunk := chunk , ''''''
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1584
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1585
    (chunk endsWith:'primitiveVariables:') ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1586
        chunk := chunk , ''''''
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1587
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1588
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1589
    "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1590
     use parser to construct a parseTree
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1591
    "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1592
    oldDollarSetting := Parser allowDollarInIdentifier.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1593
    [
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1594
        Parser allowDollarInIdentifier:true.
2286
6da16a42e507 care for defaultNameSpace being set to something
Claus Gittinger <cg@exept.de>
parents: 2267
diff changeset
  1595
        Class nameSpaceQuerySignal answer:Smalltalk
6da16a42e507 care for defaultNameSpace being set to something
Claus Gittinger <cg@exept.de>
parents: 2267
diff changeset
  1596
        do:[
6da16a42e507 care for defaultNameSpace being set to something
Claus Gittinger <cg@exept.de>
parents: 2267
diff changeset
  1597
            aParseTree := Parser parseExpression:chunk.
6da16a42e507 care for defaultNameSpace being set to something
Claus Gittinger <cg@exept.de>
parents: 2267
diff changeset
  1598
        ].
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1599
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1600
        aParseTree == #Error ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1601
            (chunk includesString:'comment') ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1602
                "/ could be a comment ...
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1603
                aParseTree := Parser parseExpression:chunk , ''''.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1604
            ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1605
        ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1606
    ] valueNowOrOnUnwindDo:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1607
        Parser allowDollarInIdentifier:oldDollarSetting
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1608
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1609
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1610
    (aParseTree isNil or:[aParseTree == #Error]) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1611
        ^ nil        "seems strange ... (could be a comment)"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1612
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1613
    aParseTree isMessage ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1614
        ^ nil        "very strange ... (whats that ?)"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1615
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1616
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1617
    "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1618
     ask parser for selector
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1619
    "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1620
    sel := aParseTree selector.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1621
    recTree := aParseTree receiver.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1622
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1623
    "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1624
     is it a method-change, methodRemove or comment-change ?
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1625
    "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1626
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1627
    (#(#'methodsFor:' 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1628
       #'privateMethodsFor:' 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1629
       #'protectedMethodsFor:' 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1630
       #'ignoredMethodsFor:' 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1631
       #'publicMethodsFor:' 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1632
       #'removeSelector:' 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1633
       #'comment:'
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1634
       #'primitiveDefinitions:'
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1635
       #'primitiveFunctions:'
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1636
       #'primitiveVariables:'
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1637
       #'renameCategory:to:'
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1638
       #'instanceVariableNames:'
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1639
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1640
       #'methodsFor:stamp:'          "/ Squeak support
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1641
       #'commentStamp:prior:'        "/ Squeak support
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1642
       #'addClassVarName:'           "/ Squeak support
2527
afa639104477 some support for dolphin source files
Claus Gittinger <cg@exept.de>
parents: 2511
diff changeset
  1643
       #methodsFor                   "/ Dolphin support
2606
61cc86fff103 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2604
diff changeset
  1644
       #methods                      "/ STV support
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1645
    ) includes:sel) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1646
        "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1647
         yes, the className is the receiver
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1648
        "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1649
        (recTree notNil and:[recTree ~~ #Error]) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1650
            isMeta := false.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1651
            recTree isUnaryMessage ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1652
                (recTree selector ~~ #class) ifTrue:[^ nil].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1653
                "id class methodsFor:..."
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1654
                recTree := recTree receiver.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1655
                isMeta := true.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1656
            ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1657
            recTree isPrimary ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1658
                name := recTree name.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1659
                isMeta ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1660
                    name := name , ' class'.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1661
                ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1662
                changeClassNames at:changeNr put:name.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1663
                ^ name
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1664
            ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1665
        ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1666
        "more strange things"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1667
        ^ nil
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1668
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1669
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1670
    "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1671
     is it a change in a class-description ?
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1672
    "
2322
f97b8cd42889 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2319
diff changeset
  1673
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1674
    (('subclass:*' match:sel) 
2322
f97b8cd42889 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2319
diff changeset
  1675
    or:[('variable*ubclass:*' match:sel)]) ifTrue:[
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1676
        "/ must parse the full changes text, to get
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1677
        "/ privacy information.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1678
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1679
        changeStream := self streamForChange:changeNr.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1680
        changeStream notNil ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1681
            chunk := changeStream nextChunk.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1682
            changeStream close.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1683
            fullParseTree := Parser parseExpression:chunk.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1684
            (fullParseTree isNil or:[fullParseTree == #Error]) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1685
                fullParseTree := nil
2396
26d6b768e3d2 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2394
diff changeset
  1686
            ] ifFalse:[
26d6b768e3d2 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2394
diff changeset
  1687
                fullParseTree isMessage ifFalse:[
26d6b768e3d2 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2394
diff changeset
  1688
                    fullParseTree := nil
26d6b768e3d2 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2394
diff changeset
  1689
                ]
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1690
            ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1691
            "/ actually, the nil case cannot happen
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1692
            fullParseTree notNil ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1693
                aParseTree := fullParseTree.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1694
                sel := aParseTree selector.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1695
            ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1696
        ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1697
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1698
        arg1Tree := aParseTree arg1.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1699
        (arg1Tree notNil and:[arg1Tree isConstant]) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1700
            name := arg1Tree value asString.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1701
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1702
            "/ is it a private-class ?
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1703
            ('*privateIn:' match:sel) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1704
                ownerTree := aParseTree args last.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1705
                ownerName := ownerTree name asString.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1706
                name := ownerName , '::' , name
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1707
            ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1708
            changeClassNames at:changeNr put:name.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1709
            ^ name
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1710
        ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1711
        "very strange"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1712
        ^ nil
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1713
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1714
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1715
    "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1716
     is it a class remove ?
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1717
    "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1718
    (sel == #removeClass:) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1719
        (recTree notNil 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1720
        and:[recTree ~~ #Error
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1721
        and:[recTree isPrimary
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1722
        and:[recTree name = 'Smalltalk']]]) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1723
            arg1Tree := aParseTree arg1.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1724
            (arg1Tree notNil and:[arg1Tree isPrimary]) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1725
                name := arg1Tree name.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1726
                changeClassNames at:changeNr put:name.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1727
                ^ name
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1728
            ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1729
        ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1730
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1731
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1732
    "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1733
     is it a method category change ?
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1734
    "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1735
    ((sel == #category:)
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1736
    or:[sel == #privacy:]) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1737
        (recTree notNil 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1738
        and:[recTree ~~ #Error
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1739
        and:[recTree isMessage
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1740
        and:[recTree selector == #compiledMethodAt:]]]) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1741
            isMeta := false.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1742
            recTree := recTree receiver.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1743
            recTree isUnaryMessage ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1744
                (recTree selector ~~ #class) ifTrue:[^ nil].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1745
                "id class "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1746
                recTree := recTree receiver
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1747
            ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1748
            recTree isPrimary ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1749
                isMeta ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1750
                    name := name , ' class'.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1751
                ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1752
                name := recTree name.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1753
                changeClassNames at:changeNr put:name.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1754
                ^ name
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1755
            ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1756
        ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1757
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1758
    ^ nil
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1759
2606
61cc86fff103 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2604
diff changeset
  1760
    "Modified: / 13.2.2000 / 15:05:28 / cg"
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1761
!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1762
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1763
numberOfChanges
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1764
    ^ changePositions size
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1765
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1766
    "Created: 3.12.1995 / 18:15:39 / cg"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1767
!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1768
2511
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1769
ownerClassNameOfChange:changeNr
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1770
    "return the owner classname of a change 
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1771
     For a normal class, this is the className;
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1772
     for a private class, this is the name of the owning class"
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1773
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1774
    |name ns idx cls|
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1775
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1776
    name := self classNameOfChange:changeNr.
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1777
    name isNil ifTrue:[^ nil].
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1778
    cls := Smalltalk at:name asSymbol.
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1779
    (cls notNil and:[cls isBehavior]) ifTrue:[
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1780
        cls owningClass notNil ifTrue:[
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1781
            ^ cls owningClass name
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1782
        ].
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1783
        ^ cls name
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1784
    ].
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1785
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1786
"/    (name includes:$:) ifTrue:[
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1787
"/        idx := name indexOf:$:.
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1788
"/        ns := name copyTo:idx-1.
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1789
"/        ns := Smalltalk at:ns asSymbol.
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1790
"/        ns notNil ifTrue:[
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1791
"/        
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1792
"/        ].
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1793
"/
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1794
"/        name := name copyFrom:idx+2.
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1795
"/        (Smalltalk at:ns asSymbol) notNil ifTrue:[
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1796
"/            cls
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1797
"/        ].
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1798
"/        ^ name copyWithoutLast:6
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1799
"/    ].
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1800
    ^ name
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1801
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1802
    "Modified: 6.12.1995 / 17:06:31 / cg"
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1803
!
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  1804
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1805
selectorOfMethodChange:changeNr
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1806
    "return a method-changes selector, or nil if its not a methodChange"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1807
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1808
    |sel |
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1809
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1810
    changeSelectors size >= changeNr ifTrue:[
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1811
        sel := changeSelectors at:changeNr.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1812
        sel notNil ifTrue:[ ^ sel ].
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1813
    ].
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1814
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1815
    sel := self extractSelectorOfMethodChange:changeNr.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1816
    sel notNil ifTrue:[
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1817
        changeSelectors isNil ifTrue:[
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1818
            changeSelectors := OrderedCollection new
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1819
        ].
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1820
        changeSelectors grow:changeNr.
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1821
        changeSelectors at:changeNr put:sel.
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1822
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1823
    ^ sel
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1824
!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1825
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1826
sourceOfMethodChange:changeNr
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1827
    "return a method-changes source code, or nil if its not a methodChange."
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1828
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1829
    |aStream chunk sawExcla parseTree sourceChunk sel|
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1830
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1831
    aStream := self streamForChange:changeNr.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1832
    aStream isNil ifTrue:[^ nil].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1833
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1834
    (self changeIsFollowupMethodChange:changeNr) ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1835
        sawExcla := aStream peekFor:(aStream class chunkSeparator).
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1836
        chunk := aStream nextChunk.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1837
    ] ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1838
        chunk := (changeChunks at:changeNr).
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1839
        sawExcla := true.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1840
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1841
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1842
    sawExcla ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1843
        parseTree := Parser parseExpression:chunk.
2797
97dea7bc3db3 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2746
diff changeset
  1844
        (parseTree notNil 
97dea7bc3db3 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2746
diff changeset
  1845
        and:[parseTree ~~ #Error
97dea7bc3db3 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2746
diff changeset
  1846
        and:[parseTree isMessage]]) ifTrue:[
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1847
            sel := parseTree selector.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1848
            (#(
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1849
               #methodsFor: 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1850
               #privateMethodsFor:
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1851
               #publicMethodsFor:
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1852
               #ignoredMethodsFor:
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1853
               #protectedMethodsFor:
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1854
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1855
               #methodsFor:stamp:             "/ Squeak support
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1856
               #commentStamp:prior:           "/ Squeak support
2527
afa639104477 some support for dolphin source files
Claus Gittinger <cg@exept.de>
parents: 2511
diff changeset
  1857
               #methodsFor                    "/ Dolphin support
2606
61cc86fff103 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2604
diff changeset
  1858
               #methods                       "/ STV support
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1859
              ) 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1860
            includes:sel) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1861
                sourceChunk := aStream nextChunk.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1862
            ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1863
        ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1864
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1865
    aStream close.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1866
    ^ sourceChunk
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1867
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1868
    "Created: / 5.9.1996 / 17:11:32 / cg"
2606
61cc86fff103 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2604
diff changeset
  1869
    "Modified: / 13.2.2000 / 15:05:45 / cg"
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1870
!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1871
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1872
streamForChange:changeNr
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1873
    "answer a stream for change"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1874
 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1875
    |aStream|
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1876
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1877
    (changeNr between:1 and:changePositions size) ifFalse:[^ nil].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1878
    aStream := FileStream readonlyFileNamed:changeFileName.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1879
    aStream isNil ifTrue:[^ nil].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1880
    aStream position:(changePositions at:changeNr).
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1881
    ^ aStream
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1882
! !
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1883
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1884
!ChangesBrowser methodsFor:'private-changeFile access'!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1885
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1886
changeFileName:aFileName
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1887
    "set the name of the changeFile"
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1888
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1889
    changeFileName := aFileName
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1890
!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1891
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1892
checkIfFileHasChanged
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1893
    "check if the changeFile has been modified since the last check;
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1894
     install a timeout for rechecking after some time."
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1895
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1896
    |f info |
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1897
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1898
    Processor removeTimedBlock:checkBlock.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1899
    f := changeFileName asFilename.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1900
    (info := f info) isNil ifTrue:[
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1901
        self newLabel:'(unaccessable)'
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1902
    ] ifFalse:[
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1903
        (info modified) > changeFileTimestamp ifTrue:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1904
            self newLabel:'(outdated)'.
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  1905
            autoUpdate value ifTrue:[
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1906
                self doUpdate
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1907
            ]
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1908
        ] ifFalse:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1909
            self newLabel:''
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  1910
        ]
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1911
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1912
    Processor addTimedBlock:checkBlock afterSeconds:5.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1913
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1914
    "Created: 8.9.1995 / 19:30:19 / claus"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1915
    "Modified: 8.9.1995 / 19:38:18 / claus"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1916
    "Modified: 1.11.1996 / 20:22:56 / cg"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1917
!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1918
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1919
readChangesFile
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1920
    "read the changes file, create a list of header-lines (changeChunks)
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1921
     and a list of chunk-positions (changePositions)"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1922
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1923
    ^ self readChangesFileInBackground:false
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1924
!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1925
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1926
readChangesFileInBackground:inBackground
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1927
    "read the changes file, create a list of header-lines (changeChunks)
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1928
     and a list of chunk-positions (changePositions).
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1929
     Starting with 2.10.3, the entries are multi-col entries;
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1930
     the cols are:
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1931
        1   delta (only if comparing)
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1932
                '+' -> new method (w.r.t. current state)
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1933
                '-' -> removed method (w.r.t. current state)
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1934
                '?' -> class does not exist currently
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1935
                '=' -> change is same as current methods source
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1936
        2   class/selector
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1937
        3   type of change
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1938
                doit
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1939
                method
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1940
                category change
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1941
        4   timestamp
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1942
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1943
     since comparing slows down startup time, it is now disabled by
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1944
     default and can be enabled via a toggle."
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1945
2641
cfd94f3cc611 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2637
diff changeset
  1946
    |aStream maxLen i f chunkText fullChunkText askedForEditingClassSource
2683
e76575e4346f private className extraction
tm
parents: 2682
diff changeset
  1947
     excla timeStampInfo entry changeDelta changeString changeType 
3067
96387c6aa216 allItalic now understood by CharacterArray
Claus Gittinger <cg@exept.de>
parents: 3065
diff changeset
  1948
     s changeClass sawExcla category 
96387c6aa216 allItalic now understood by CharacterArray
Claus Gittinger <cg@exept.de>
parents: 3065
diff changeset
  1949
     chunkPos sel headerLine cls p rec clsName
2683
e76575e4346f private className extraction
tm
parents: 2682
diff changeset
  1950
     myProcess myPriority myPrioRange
e76575e4346f private className extraction
tm
parents: 2682
diff changeset
  1951
     done first className  text methodPos 
e76575e4346f private className extraction
tm
parents: 2682
diff changeset
  1952
     singleJunkOnly methodChunks singleInfo
e76575e4346f private className extraction
tm
parents: 2682
diff changeset
  1953
     ownerTree ownerName
e76575e4346f private className extraction
tm
parents: 2682
diff changeset
  1954
     m currentText t1 t2|
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1955
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1956
    editingClassSource := false.
2641
cfd94f3cc611 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2637
diff changeset
  1957
    askedForEditingClassSource := false.
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1958
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1959
    maxLen := 60.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1960
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1961
    f := changeFileName asFilename.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1962
    aStream :=  f readStream.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1963
    aStream isNil ifTrue:[^ nil].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1964
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1965
    self newLabel:'updating ...'.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1966
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1967
    i := f info.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1968
    changeFileSize := i size.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1969
    changeFileTimestamp := i modified.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1970
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1971
    self withReadCursorDo:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1972
        "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1973
         this is a time consuming operation (especially, if reading an
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1974
         NFS-mounted directory; therefore lower my priority ...
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1975
        "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1976
        inBackground ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1977
            myProcess := Processor activeProcess.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1978
            myPriority := myProcess priority.
2295
4e05198e7dd8 execute BG tasks at a prio range, to ensure progress.
Claus Gittinger <cg@exept.de>
parents: 2293
diff changeset
  1979
            myPrioRange := myProcess priorityRange.
4e05198e7dd8 execute BG tasks at a prio range, to ensure progress.
Claus Gittinger <cg@exept.de>
parents: 2293
diff changeset
  1980
            myProcess priorityRange:(Processor userBackgroundPriority to:Processor activePriority).
4e05198e7dd8 execute BG tasks at a prio range, to ensure progress.
Claus Gittinger <cg@exept.de>
parents: 2293
diff changeset
  1981
"/            myProcess priority:(Processor userBackgroundPriority).
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1982
        ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1983
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1984
        [
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1985
            changeChunks := OrderedCollection new.
2664
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  1986
            changeClassNames := OrderedCollection new.
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1987
            changeHeaderLines := OrderedCollection new.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1988
            changePositions := OrderedCollection new.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1989
            changeTimeStamps := OrderedCollection new.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1990
            changeIsFollowupMethodChange := OrderedCollection new.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1991
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1992
            excla := aStream class chunkSeparator.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1993
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1994
            [aStream atEnd] whileFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1995
                "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1996
                 get a chunk (separated by excla)
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1997
                "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1998
                aStream skipSeparators.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  1999
                chunkPos := aStream position.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2000
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2001
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2002
                sawExcla := aStream peekFor:excla.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2003
                chunkText := fullChunkText := aStream nextChunk.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2004
                chunkText notNil ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2005
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2006
                    (chunkText startsWith:'''---- timestamp ') ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2007
                        timeStampInfo := (chunkText copyFrom:16 to:(chunkText size - 6)) withoutSpaces.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2008
                    ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2009
                        "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2010
                         only first line is saved in changeChunks ...
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2011
                        "
2664
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2012
"/                        index := chunkText indexOf:(Character cr).
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2013
"/                        (index ~~ 0) ifTrue:[
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2014
"/                            chunkText := chunkText copyTo:(index - 1).
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2015
"/
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2016
"/                            "take care for comment changes - must still be a
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2017
"/                             valid expression for classNameOfChange: to work"
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2018
"/
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2019
"/                            (chunkText endsWith:'comment:''') ifTrue:[
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2020
"/                                chunkText := chunkText , '...'''
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2021
"/                            ].
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2022
"/                            (chunkText endsWith:'primitiveDefinitions:''') ifTrue:[
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2023
"/                                sel := 'primitiveDefinitions:'.
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2024
"/                                chunkText := chunkText copyWithoutLast:1
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2025
"/                            ].
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2026
"/                            (chunkText endsWith:'primitiveVariables:''') ifTrue:[
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2027
"/                                sel := 'primitiveVariables:'.
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2028
"/                                chunkText := chunkText copyWithoutLast:1
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2029
"/                            ].
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2030
"/                            (chunkText endsWith:'primitiveFunctions:''') ifTrue:[
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2031
"/                                sel := 'primitiveFunctions:'.
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2032
"/                                chunkText := chunkText copyWithoutLast:1
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2033
"/                            ].
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2034
"/                        ].
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2035
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2036
                        changeChunks add:chunkText.
2664
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2037
                        changeClassNames add:nil.
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2038
                        changePositions add:chunkPos.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2039
                        changeTimeStamps add:timeStampInfo.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2040
                        changeIsFollowupMethodChange add:false.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2041
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2042
                        headerLine := nil.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2043
                        changeDelta := ' '.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2044
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2045
                        sawExcla ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2046
                            (chunkText startsWith:'''---- snap') ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2047
                                changeType := ''.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2048
                                headerLine := chunkText.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2049
                                changeString := (chunkText contractTo:maxLen).
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2050
                                timeStampInfo := nil.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2051
                            ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2052
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2053
                                headerLine := chunkText , ' (doIt)'.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2054
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2055
                                "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2056
                                 first, assume doIt - then lets have a more detailed look ...
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2057
                                "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2058
                                ((chunkText startsWith:'''---- file')
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2059
                                or:[(chunkText startsWith:'''---- check')]) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2060
                                    changeType := ''.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2061
                                    timeStampInfo := nil.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2062
                                ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2063
                                    changeType := '(doIt)'.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2064
                                ].    
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2065
                                changeString := (chunkText contractTo:maxLen).
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2066
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2067
                                p := Parser parseExpression:fullChunkText inNameSpace:Smalltalk.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2068
                                (p notNil and:[p ~~ #Error]) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2069
                                    p isMessage ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2070
                                        sel := p selector.
2292
321bca750f46 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2291
diff changeset
  2071
                                        rec := p receiver.
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2072
                                    ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2073
                                ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2074
                                    sel := nil.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2075
                                    (Scanner new scanTokens:fullChunkText) size == 0 ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2076
                                        "/ a comment only
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2077
                                        changeType := '(comment)'.
2292
321bca750f46 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2291
diff changeset
  2078
                                        NoColoring ~~ true ifTrue:[
3067
96387c6aa216 allItalic now understood by CharacterArray
Claus Gittinger <cg@exept.de>
parents: 3065
diff changeset
  2079
                                            changeType := changeType allItalic.
96387c6aa216 allItalic now understood by CharacterArray
Claus Gittinger <cg@exept.de>
parents: 3065
diff changeset
  2080
                                            "/ changeString := changeString allItalic.
2292
321bca750f46 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2291
diff changeset
  2081
                                            changeType emphasisAllAdd:(#color -> UserPreferences current commentColor).
321bca750f46 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2291
diff changeset
  2082
                                        ]
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2083
                                    ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2084
                                        changeType := '(???)'.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2085
                                    ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2086
                                ].
2291
6f517d3e1d83 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2290
diff changeset
  2087
                                (sel == #comment:) ifTrue:[
6f517d3e1d83 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2290
diff changeset
  2088
                                    changeType := '(comment)'.
2292
321bca750f46 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2291
diff changeset
  2089
                                    clsName := rec name.
2570
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2090
                                    changeClass := (Smalltalk classNamed:clsName).
2664
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2091
                                    changeClassNames at:changeClassNames size put:clsName.
2292
321bca750f46 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2291
diff changeset
  2092
                                    NoColoring ~~ true ifTrue:[
3067
96387c6aa216 allItalic now understood by CharacterArray
Claus Gittinger <cg@exept.de>
parents: 3065
diff changeset
  2093
                                        changeType := changeType allItalic.
2292
321bca750f46 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2291
diff changeset
  2094
                                        changeType emphasisAllAdd:(#color -> UserPreferences current commentColor).
3067
96387c6aa216 allItalic now understood by CharacterArray
Claus Gittinger <cg@exept.de>
parents: 3065
diff changeset
  2095
                                        "/ changeString := clsName allItalic.
2570
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2096
                                    ].
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  2097
                                    autoCompare value ifTrue:[
2570
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2098
                                        (changeClass isNil or:[changeClass isLoaded not]) ifTrue:[
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2099
                                            changeDelta := '?'
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2100
                                        ] ifFalse:[
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2101
                                            (changeClass comment = (p args at:1) evaluate) ifTrue:[
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2102
                                                changeDelta := '='.
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2103
                                            ]
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2104
                                        ]
2573
5a0d8ad2c073 more compares.
Claus Gittinger <cg@exept.de>
parents: 2571
diff changeset
  2105
                                    ].
5a0d8ad2c073 more compares.
Claus Gittinger <cg@exept.de>
parents: 2571
diff changeset
  2106
                                    sel := nil.
2291
6f517d3e1d83 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2290
diff changeset
  2107
                                ].
6f517d3e1d83 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2290
diff changeset
  2108
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2109
                                (sel == #removeSelector:) ifTrue:[
2292
321bca750f46 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2291
diff changeset
  2110
                                    rec isUnaryMessage ifTrue:[
321bca750f46 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2291
diff changeset
  2111
                                        cls := rec receiver name.
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2112
                                        changeClass := (Smalltalk classNamed:cls) class.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2113
                                        cls := cls , ' class'.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2114
                                    ] ifFalse:[
2292
321bca750f46 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2291
diff changeset
  2115
                                        cls := rec name.
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2116
                                        changeClass := (Smalltalk classNamed:cls)
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2117
                                    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2118
                                    sel := (p args at:1) evaluate.
2664
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2119
                                    changeClassNames at:changeClassNames size put:cls.
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2120
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  2121
                                    autoCompare value ifTrue:[
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2122
                                        (changeClass isNil or:[changeClass isLoaded not]) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2123
                                            changeDelta := '?'
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2124
                                        ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2125
                                            (changeClass implements:sel asSymbol) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2126
                                                changeDelta := '-'.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2127
                                            ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2128
                                                changeDelta := '='.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2129
                                            ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2130
                                        ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2131
                                    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2132
                                    changeType := '(remove)'.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2133
                                    changeString := self contractClass:cls selector:sel to:maxLen.
2573
5a0d8ad2c073 more compares.
Claus Gittinger <cg@exept.de>
parents: 2571
diff changeset
  2134
                                    sel := nil.
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2135
                                ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2136
                                (p ~~ #Error
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2137
                                and:[p isMessage 
2292
321bca750f46 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2291
diff changeset
  2138
                                and:[rec isMessage
321bca750f46 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2291
diff changeset
  2139
                                and:[rec selector == #compiledMethodAt:]]]) ifTrue:[
321bca750f46 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2291
diff changeset
  2140
                                    rec receiver isUnaryMessage ifTrue:[
321bca750f46 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2291
diff changeset
  2141
                                        cls := rec receiver receiver name.
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2142
                                        changeClass := (Smalltalk classNamed:cls) class.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2143
                                        cls := cls , ' class'.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2144
                                    ] ifFalse:[
2292
321bca750f46 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2291
diff changeset
  2145
                                        cls := rec receiver name.
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2146
                                        changeClass := (Smalltalk classNamed:cls)
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2147
                                    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2148
                                    (sel == #category:) ifTrue:[
2292
321bca750f46 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2291
diff changeset
  2149
                                        sel := (rec args at:1) evaluate.
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2150
                                        changeType := '(category change)'.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2151
                                        changeString := self contractClass:cls selector:sel to:maxLen.
2664
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2152
                                        changeClassNames at:changeClassNames size put:cls.
3069
4bc1b0f7b848 Fix for non-existant classes (cg)
Stefan Vogel <sv@exept.de>
parents: 3067
diff changeset
  2153
                                        changeClass notNil ifTrue:[
4bc1b0f7b848 Fix for non-existant classes (cg)
Stefan Vogel <sv@exept.de>
parents: 3067
diff changeset
  2154
                                            m := changeClass compiledMethodAt:sel asSymbol.
4bc1b0f7b848 Fix for non-existant classes (cg)
Stefan Vogel <sv@exept.de>
parents: 3067
diff changeset
  2155
                                            m notNil ifTrue:[
4bc1b0f7b848 Fix for non-existant classes (cg)
Stefan Vogel <sv@exept.de>
parents: 3067
diff changeset
  2156
                                                m category = (p args at:1) evaluate ifTrue:[
4bc1b0f7b848 Fix for non-existant classes (cg)
Stefan Vogel <sv@exept.de>
parents: 3067
diff changeset
  2157
                                                    changeDelta := '='.
4bc1b0f7b848 Fix for non-existant classes (cg)
Stefan Vogel <sv@exept.de>
parents: 3067
diff changeset
  2158
                                                ]
3065
3de1f9ddd72a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 3064
diff changeset
  2159
                                            ]
3de1f9ddd72a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 3064
diff changeset
  2160
                                        ].
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2161
                                    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2162
                                    (sel == #privacy:) ifTrue:[
2292
321bca750f46 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2291
diff changeset
  2163
                                        sel := (rec args at:1) evaluate.
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2164
                                        changeType := '(privacy change)'.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2165
                                        changeString := self contractClass:cls selector:sel to:maxLen.
2664
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2166
                                        changeClassNames at:changeClassNames size put:cls.
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2167
                                    ].
2573
5a0d8ad2c073 more compares.
Claus Gittinger <cg@exept.de>
parents: 2571
diff changeset
  2168
                                    sel := nil.
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2169
                                ].
2290
59207b94df0c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2286
diff changeset
  2170
                                (Class definitionSelectors includes:sel) ifTrue:[
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2171
                                    changeType := '(class definition)'.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2172
                                    clsName := (p args at:1) evaluate.
2664
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2173
                                    changeClassNames at:changeClassNames size put:clsName.
2683
e76575e4346f private className extraction
tm
parents: 2682
diff changeset
  2174
e76575e4346f private className extraction
tm
parents: 2682
diff changeset
  2175
                                    "/ is it a private-class ?
e76575e4346f private className extraction
tm
parents: 2682
diff changeset
  2176
                                    ('*privateIn:' match:sel) ifTrue:[
e76575e4346f private className extraction
tm
parents: 2682
diff changeset
  2177
                                        ownerTree := p args last.
e76575e4346f private className extraction
tm
parents: 2682
diff changeset
  2178
                                        ownerName := ownerTree name asString.
e76575e4346f private className extraction
tm
parents: 2682
diff changeset
  2179
                                        clsName := ownerName , '::' , clsName
e76575e4346f private className extraction
tm
parents: 2682
diff changeset
  2180
                                    ].
e76575e4346f private className extraction
tm
parents: 2682
diff changeset
  2181
                                
2290
59207b94df0c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2286
diff changeset
  2182
                                    changeString := clsName.
2292
321bca750f46 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2291
diff changeset
  2183
                                    NoColoring ~~ true ifTrue:[
2867
0ce30d3c763f asText allBold -> allBold
Claus Gittinger <cg@exept.de>
parents: 2863
diff changeset
  2184
                                        changeType := changeType allBold.
0ce30d3c763f asText allBold -> allBold
Claus Gittinger <cg@exept.de>
parents: 2863
diff changeset
  2185
                                        changeString := changeString allBold.
2573
5a0d8ad2c073 more compares.
Claus Gittinger <cg@exept.de>
parents: 2571
diff changeset
  2186
                                    ].
5a0d8ad2c073 more compares.
Claus Gittinger <cg@exept.de>
parents: 2571
diff changeset
  2187
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  2188
                                    autoCompare value ifTrue:[
2573
5a0d8ad2c073 more compares.
Claus Gittinger <cg@exept.de>
parents: 2571
diff changeset
  2189
                                        cls := Smalltalk at:clsName ifAbsent:nil.
5a0d8ad2c073 more compares.
Claus Gittinger <cg@exept.de>
parents: 2571
diff changeset
  2190
                                        cls isNil ifTrue:[
5a0d8ad2c073 more compares.
Claus Gittinger <cg@exept.de>
parents: 2571
diff changeset
  2191
                                            changeDelta := '+'.
5a0d8ad2c073 more compares.
Claus Gittinger <cg@exept.de>
parents: 2571
diff changeset
  2192
                                        ] ifFalse:[
2816
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2193
                                            cls definitionSelector = sel ifTrue:[
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2194
                                                ((cls superclass isNil 
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2195
                                                    and:[p receiver isConstant 
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2196
                                                    and:[p receiver evaluate isNil]])
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2197
                                                or:[
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2198
                                                    cls superclass notNil 
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2199
                                                    and:[p receiver isConstant not
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2200
                                                    and:[cls superclass name = p receiver name]]
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2201
                                                ]) ifTrue:[
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2202
                                                    cls instanceVariableString asCollectionOfWords = (p args at:2) evaluate asCollectionOfWords ifTrue:[
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2203
                                                        cls classVariableString asCollectionOfWords = (p args at:3) evaluate asCollectionOfWords ifTrue:[
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2204
                                                            (p args at:4) evaluate isEmpty ifTrue:[
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2205
                                                                cls category = (p args at:5) evaluate ifTrue:[
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2206
                                                                    changeDelta := '='.
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2207
                                                                ] ifFalse:[
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2208
                                                                   changeType := '(class category change)'.
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2209
                                                                ]
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2210
                                                            ]
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2211
                                                        ]
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2212
                                                    ]
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2213
                                                ]
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2214
                                            ].
2573
5a0d8ad2c073 more compares.
Claus Gittinger <cg@exept.de>
parents: 2571
diff changeset
  2215
                                        ]
5a0d8ad2c073 more compares.
Claus Gittinger <cg@exept.de>
parents: 2571
diff changeset
  2216
                                    ].
5a0d8ad2c073 more compares.
Claus Gittinger <cg@exept.de>
parents: 2571
diff changeset
  2217
                                    sel := nil.
2265
693dad31ead8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2263
diff changeset
  2218
                                ] ifFalse:[
693dad31ead8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2263
diff changeset
  2219
                                    (#(
693dad31ead8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2263
diff changeset
  2220
                                      #'primitiveDefinitions:'
693dad31ead8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2263
diff changeset
  2221
                                      #'primitiveFunctions:'
693dad31ead8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2263
diff changeset
  2222
                                      #'primitiveVariables:'
693dad31ead8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2263
diff changeset
  2223
                                     ) includes:sel) ifTrue:[
693dad31ead8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2263
diff changeset
  2224
                                        changeType := '(class definition)'.
2292
321bca750f46 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2291
diff changeset
  2225
                                        clsName := rec evaluate.
2816
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2226
                                    ] ifFalse:[
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2227
                                        ((sel == #instanceVariableNames:) 
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2228
                                        and:[rec isMessage
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2229
                                        and:[rec selector == #class]]) ifTrue:[
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2230
                                            clsName := rec receiver name.
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2231
                                            changeClass := (Smalltalk classNamed:clsName).
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2232
                                            changeType := '(class definition)'.
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2233
                                            changeClassNames at:changeClassNames size put:clsName.
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2234
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  2235
                                            autoCompare value ifTrue:[
2816
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2236
                                                changeClass isNil ifTrue:[
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2237
                                                    changeDelta := '?'.
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2238
                                                ] ifFalse:[
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2239
                                                    s := (p args at:1) evaluate.
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2240
                                                    s = changeClass class instanceVariableString ifTrue:[
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2241
                                                        changeDelta := '='.
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2242
                                                    ]
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2243
                                                ]
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2244
                                            ].
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2245
                                        ]
2265
693dad31ead8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2263
diff changeset
  2246
                                    ]
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2247
                                ].
2265
693dad31ead8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2263
diff changeset
  2248
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2249
                            ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2250
                        ] ifTrue:[ "sawExcla"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2251
                            singleJunkOnly := false.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2252
                            methodChunks := false.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2253
                            singleInfo := false.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2254
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2255
                            "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2256
                             method definitions actually consist of
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2257
                             two (or more) chunks; skip next chunk(s)
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2258
                             up to an empty one.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2259
                             The system only writes one chunk,
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2260
                             and we cannot handle more in this ChangesBrowser ....
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2261
                            "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2262
                            className := nil.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2263
                            p := Parser parseExpression:chunkText inNameSpace:Smalltalk.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2264
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2265
                            (p notNil and:[p ~~ #Error]) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2266
                                sel := p selector.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2267
                                (#(
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2268
                                   #methodsFor: 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2269
                                   #privateMethodsFor:
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2270
                                   #publicMethodsFor:
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2271
                                   #ignoredMethodsFor:
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2272
                                   #protectedMethodsFor:
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2273
                                   #methodsFor:stamp:             "/ Squeak support
2527
afa639104477 some support for dolphin source files
Claus Gittinger <cg@exept.de>
parents: 2511
diff changeset
  2274
                                   #'commentStamp:prior:'         "/ Squeak support
afa639104477 some support for dolphin source files
Claus Gittinger <cg@exept.de>
parents: 2511
diff changeset
  2275
                                   #methodsFor                    "/ Dolphin support
2606
61cc86fff103 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2604
diff changeset
  2276
                                   #methods                       "/ STV support
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2277
                                  ) 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2278
                                includes:sel) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2279
                                    methodChunks := true.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2280
                                    p receiver isUnaryMessage ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2281
                                        className := p receiver receiver name.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2282
                                        changeClass := (Smalltalk classNamed:className) class.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2283
                                        className := className , ' class'.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2284
                                    ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2285
                                        className := p receiver name.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2286
                                        changeClass := Smalltalk classNamed:className
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2287
                                    ].
2606
61cc86fff103 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2604
diff changeset
  2288
                                    (sel == #'methodsFor') ifTrue:[
2527
afa639104477 some support for dolphin source files
Claus Gittinger <cg@exept.de>
parents: 2511
diff changeset
  2289
                                        category := 'Dolphin methods'.
afa639104477 some support for dolphin source files
Claus Gittinger <cg@exept.de>
parents: 2511
diff changeset
  2290
                                    ] ifFalse:[
2606
61cc86fff103 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2604
diff changeset
  2291
                                        (sel == #methods) ifTrue:[
61cc86fff103 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2604
diff changeset
  2292
                                            category := 'STV methods'.
61cc86fff103 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2604
diff changeset
  2293
                                        ] ifFalse:[
61cc86fff103 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2604
diff changeset
  2294
                                            category := (p args at:1) evaluate.
61cc86fff103 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2604
diff changeset
  2295
                                        ]
2527
afa639104477 some support for dolphin source files
Claus Gittinger <cg@exept.de>
parents: 2511
diff changeset
  2296
                                    ].
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2297
                                    sel == #'methodsFor:stamp:' ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2298
                                        "/ Squeak timeStamp
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2299
                                        timeStampInfo := (p args at:2) evaluate.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2300
                                        singleInfo := true
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2301
                                    ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2302
                                        sel == #'commentStamp:prior:' ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2303
                                            singleJunkOnly := true.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2304
                                            methodChunks := false.
2301
d557a9dec28c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2295
diff changeset
  2305
                                        ]
d557a9dec28c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2295
diff changeset
  2306
                                    ]
d557a9dec28c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2295
diff changeset
  2307
                                ] ifFalse:[
d557a9dec28c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2295
diff changeset
  2308
                                    sel == #reorganize ifTrue:[
d557a9dec28c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2295
diff changeset
  2309
                                        singleJunkOnly := true.
d557a9dec28c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2295
diff changeset
  2310
                                        methodChunks := false.
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2311
                                    ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2312
                                ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2313
                            ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2314
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2315
                            done := false.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2316
                            first := true.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2317
                            [done] whileFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2318
                                changeDelta := ' '.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2319
                                methodPos := aStream position.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2320
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2321
                                text := aStream nextChunk.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2322
                                text isNil ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2323
                                    done := true
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2324
                                ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2325
                                    done := text isEmpty
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2326
                                ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2327
                                done ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2328
                                    first ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2329
                                        changeChunks add:chunkText.
2664
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2330
                                        changeClassNames add:className.
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2331
                                        changePositions add:methodPos.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2332
                                        changeTimeStamps add:timeStampInfo.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2333
                                        changeIsFollowupMethodChange add:true.
2641
cfd94f3cc611 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2637
diff changeset
  2334
                                        askedForEditingClassSource ifFalse:[
2863
c9cea7dfa990 suffix check fixed
Claus Gittinger <cg@exept.de>
parents: 2843
diff changeset
  2335
                                            (changeFileName asFilename hasSuffix:'st') ifFalse:[
2641
cfd94f3cc611 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2637
diff changeset
  2336
                                                editingClassSource :=  (self confirm:'Multiple method chunks without individual ''methodsFor:'' encountered.
2635
4ac62d4f2346 care for malformed changes file and ask
Claus Gittinger <cg@exept.de>
parents: 2606
diff changeset
  2337
Is this a class-file being browsed ?')
2641
cfd94f3cc611 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2637
diff changeset
  2338
                                            ] ifTrue:[
cfd94f3cc611 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2637
diff changeset
  2339
                                                editingClassSource := true.
cfd94f3cc611 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2637
diff changeset
  2340
                                            ].
cfd94f3cc611 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2637
diff changeset
  2341
                                            askedForEditingClassSource := true.
2635
4ac62d4f2346 care for malformed changes file and ask
Claus Gittinger <cg@exept.de>
parents: 2606
diff changeset
  2342
                                        ]
2664
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2343
                                    ] ifTrue:[
541f43019451 fixed class-chunk remembering (remember the full chunk,
Claus Gittinger <cg@exept.de>
parents: 2641
diff changeset
  2344
                                        changeClassNames at:changeClassNames size put:className.
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2345
                                    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2346
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2347
                                    first := false.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2348
                                    "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2349
                                     try to find the selector
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2350
                                    "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2351
                                    sel := nil.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2352
                                    className notNil ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2353
                                        methodChunks ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2354
                                            p := Parser 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2355
                                                     parseMethodSpecification:text
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2356
                                                     in:nil
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2357
                                                     ignoreErrors:true
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2358
                                                     ignoreWarnings:true.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2359
                                            (p notNil and:[p ~~ #Error]) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2360
                                                sel := p selector.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2361
                                            ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2362
                                        ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2363
                                    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2364
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2365
                                    sel isNil ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2366
                                        changeString := (chunkText contractTo:maxLen).
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2367
                                        changeType := '(change)'.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2368
                                        headerLine := chunkText , ' (change)'.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2369
                                    ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2370
                                        changeString :=  self contractClass:className selector:sel to:maxLen.
2319
fd83f279ef24 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2301
diff changeset
  2371
                                        changeType := '{ ' , category , ' }'.
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2372
                                        headerLine := className , ' ' , sel , ' ' , '(change category: ''' , category , ''')'.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2373
                                    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2374
3202
9f6e0824af37 added a pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3140
diff changeset
  2375
                                    autoCompare value ifTrue:[ 
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2376
                                        changeClass isNil ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2377
                                            changeClass isMeta ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2378
                                                cls := changeClass soleInstance
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2379
                                            ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2380
                                                cls := changeClass
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2381
                                            ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2382
                                        ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2383
2286
6da16a42e507 care for defaultNameSpace being set to something
Claus Gittinger <cg@exept.de>
parents: 2267
diff changeset
  2384
                                        (changeClass isNil or:[sel isNil or:[cls isLoaded not]]) ifTrue:[
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2385
                                            changeDelta := '?'
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2386
                                        ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2387
                                            (changeClass implements:sel asSymbol) ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2388
                                                changeDelta := '+'.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2389
                                            ] ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2390
                                                m := changeClass compiledMethodAt:sel asSymbol.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2391
                                                currentText := m source.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2392
                                                currentText notNil ifTrue:[
2836
3b19c368a67e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2835
diff changeset
  2393
                                                    text asString string withoutTrailingSeparators = currentText asString string withoutTrailingSeparators ifTrue:[
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2394
                                                        changeDelta := '='
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2395
                                                    ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2396
                                                        t1 := currentText asCollectionOfLines collect:[:s | s withTabsExpanded].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2397
                                                        t2 := text asCollectionOfLines collect:[:s | s withTabsExpanded].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2398
                                                        t1 = t2 ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2399
                                                            changeDelta := '='
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2400
                                                        ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2401
                                                    ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2402
                                                ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2403
                                            ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2404
                                        ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2405
                                    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2406
                                    entry := MultiColListEntry new.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2407
                                    entry tabulatorSpecification:tabSpec.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2408
                                    entry colAt:1 put:changeDelta.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2409
                                    entry colAt:2 put:changeString.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2410
                                    entry colAt:3 put:changeType.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2411
                                    timeStampInfo notNil ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2412
                                        entry colAt:4 put:timeStampInfo.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2413
                                    ].    
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2414
                                    changeHeaderLines add:entry
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2415
                                ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2416
                                changeString := nil.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2417
                                headerLine := nil.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2418
                                singleJunkOnly ifTrue:[done := true]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2419
                            ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2420
                            singleInfo ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2421
                                timeStampInfo := nil
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2422
                            ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2423
                        ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2424
                        changeString notNil ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2425
                            entry := MultiColListEntry new.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2426
                            entry tabulatorSpecification:tabSpec.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2427
                            entry colAt:1 put:changeDelta.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2428
                            entry colAt:2 put:changeString.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2429
                            entry colAt:3 put:changeType.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2430
                            timeStampInfo notNil ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2431
                                entry colAt:4 put:timeStampInfo.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2432
                            ].    
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2433
                            changeHeaderLines add:entry
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2434
                        ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2435
                            headerLine notNil ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2436
                                changeHeaderLines add:headerLine
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2437
                            ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2438
                        ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2439
                    ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2440
                ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2441
            ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2442
            anyChanges := false
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2443
        ] valueNowOrOnUnwindDo:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2444
            aStream close.
2295
4e05198e7dd8 execute BG tasks at a prio range, to ensure progress.
Claus Gittinger <cg@exept.de>
parents: 2293
diff changeset
  2445
            inBackground ifTrue:[
4e05198e7dd8 execute BG tasks at a prio range, to ensure progress.
Claus Gittinger <cg@exept.de>
parents: 2293
diff changeset
  2446
                myProcess priority:myPriority.
4e05198e7dd8 execute BG tasks at a prio range, to ensure progress.
Claus Gittinger <cg@exept.de>
parents: 2293
diff changeset
  2447
                myProcess priorityRange:myPrioRange.
4e05198e7dd8 execute BG tasks at a prio range, to ensure progress.
Claus Gittinger <cg@exept.de>
parents: 2293
diff changeset
  2448
            ].
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2449
        ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2450
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2451
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2452
    self checkIfFileHasChanged
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2453
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2454
    "Modified: / 27.8.1995 / 23:06:55 / claus"
2606
61cc86fff103 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2604
diff changeset
  2455
    "Modified: / 13.2.2000 / 15:02:11 / cg"
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2456
!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2457
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2458
writeBackChanges
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2459
    "write back the changes file. To avoid problems when the disk is full
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2460
     or a crash occurs while writing (well, or someone kills us), 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2461
     first write the stuff to a new temporary file. If this works ok,
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2462
     rename the old change-file to a .bak file and finally rename the
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2463
     tempfile back to the change-file. 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2464
     That way, if anything happens, either the original file is left unchanged,
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2465
     or we have at least a backup of the previous change file."
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2466
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2467
    |inStream outStream tempfile stamp f|
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2468
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2469
    editingClassSource ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2470
        (self confirm:'You are editing a classes sourceFile (not a changeFile) !!\\Are you certain, you want to overwrite it ?' withCRs)
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2471
        ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2472
            ^ false
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2473
        ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2474
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2475
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2476
    tempfile := Filename newTemporaryIn:nil.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2477
    tempfile exists ifTrue:[tempfile remove].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2478
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2479
    outStream := tempfile writeStream.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2480
    outStream isNil ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2481
        self warn:'cannot create temporary file in current directory.'.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2482
        ^ false
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2483
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2484
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2485
    inStream := FileStream readonlyFileNamed:changeFileName.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2486
    inStream isNil ifTrue:[^ false].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2487
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2488
    self withCursor:(Cursor write) do:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2489
        |excla sawExcla done first chunk
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2490
         nChanges "{Class:SmallInteger}" |
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2491
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2492
        Stream writeErrorSignal handle:[:ex |
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2493
            self warn:('could not update the changes file.\\' , ex description) withCRs.
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2494
            tempfile exists ifTrue:[tempfile remove].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2495
            ^ false
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2496
        ] do:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2497
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2498
            excla := inStream class chunkSeparator.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2499
            nChanges := self numberOfChanges.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2500
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2501
            1 to:nChanges do:[:index |
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2502
                inStream position:(changePositions at:index).
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2503
                sawExcla := inStream peekFor:excla.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2504
                chunk := inStream nextChunk.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2505
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2506
                (chunk notNil
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2507
                and:[(chunk startsWith:'''---- snap') not]) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2508
                    (stamp := changeTimeStamps at:index) notNil ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2509
                        outStream nextPutAll:'''---- timestamp ' , stamp , ' ----'''.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2510
                        outStream nextPut:excla; cr.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2511
                    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2512
                ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2513
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2514
                sawExcla ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2515
                    outStream nextPut:excla.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2516
                    outStream nextChunkPut:chunk.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2517
                    outStream cr; cr.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2518
                    "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2519
                     a method-definition chunk - output followups
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2520
                    "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2521
                    done := false.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2522
                    first := true.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2523
                    [done] whileFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2524
                        chunk := inStream nextChunk.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2525
                        chunk isNil ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2526
                            outStream cr; cr.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2527
                            done := true
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2528
                        ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2529
                            chunk isEmpty ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2530
                                outStream space; nextChunkPut:chunk; cr; cr.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2531
                                done := true.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2532
                            ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2533
                                first ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2534
                                    outStream cr; cr.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2535
                                ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2536
                                outStream nextChunkPut:chunk.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2537
                            ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2538
                        ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2539
                        first := false.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2540
                    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2541
                ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2542
                    outStream nextChunkPut:chunk.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2543
                    outStream cr
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2544
                ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2545
            ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2546
            outStream close.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2547
            inStream close.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2548
        ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2549
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2550
        f := changeFileName asFilename.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2551
        f renameTo:(f withSuffix:'bak').
2466
66842be773bd care for cross-device rename
Claus Gittinger <cg@exept.de>
parents: 2451
diff changeset
  2552
        tempfile renameOrCopyTo:changeFileName.
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2553
        anyChanges := false
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2554
    ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2555
    ^ true
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2556
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2557
    "Modified: / 2.12.1996 / 22:29:15 / stefan"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2558
    "Modified: / 21.4.1998 / 17:50:11 / cg"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2559
! !
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2560
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2561
!ChangesBrowser methodsFor:'private-user interaction ops'!
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2562
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  2563
appendChange:changeNr toFile:fileName
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  2564
    "append change to a file. return true if ok."
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  2565
2394
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2566
    |aStream outStream chunk chunk2 sawExcla separator|
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2567
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2568
    aStream := self streamForChange:changeNr.
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2569
    aStream isNil ifTrue:[
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2570
        self warn:'oops - cannot read change'.
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2571
        ^ false
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2572
    ].
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2573
    aStream skipSeparators.
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2574
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2575
    separator := aStream class chunkSeparator.
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2576
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2577
    (self changeIsFollowupMethodChange:changeNr) ifTrue:[
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2578
        sawExcla := true.
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2579
        chunk := changeChunks at:changeNr.
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2580
        chunk withoutSeparators isEmpty ifTrue:[
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2581
            self halt:'oops - should not happen'.
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2582
        ]
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2583
    ] ifFalse:[
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2584
        sawExcla := aStream peekFor:separator.
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2585
        chunk := aStream nextChunk.
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2586
        chunk withoutSeparators isEmpty ifTrue:[
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2587
            self halt:'oops - should not happen'.
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2588
        ]
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2589
    ].
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  2590
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  2591
    outStream := FileStream oldFileNamed:fileName.
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  2592
    outStream isNil ifTrue:[
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2593
        outStream isNil ifTrue:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2594
            outStream := FileStream newFileNamed:fileName.
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2595
            outStream isNil ifTrue:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2596
                self warn:'cannot update file ''%1''' with:fileName.
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2597
                ^ false
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2598
            ]
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2599
        ]
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  2600
    ].
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  2601
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  2602
    outStream setToEnd.
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  2603
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  2604
    sawExcla ifTrue:[
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2605
        outStream nextPut:separator
703
1b3b008d9f19 fixed to allow class-source files to be handled
Claus Gittinger <cg@exept.de>
parents: 627
diff changeset
  2606
    ].
1b3b008d9f19 fixed to allow class-source files to be handled
Claus Gittinger <cg@exept.de>
parents: 627
diff changeset
  2607
    outStream nextChunkPut:chunk; cr.
1b3b008d9f19 fixed to allow class-source files to be handled
Claus Gittinger <cg@exept.de>
parents: 627
diff changeset
  2608
    sawExcla ifTrue:[
2394
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2609
        chunk2 := aStream nextChunk.
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2610
        chunk2 withoutSeparators isEmpty ifTrue:[
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2611
            self halt:'oops - should not happen'.
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2612
        ].
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  2613
        outStream nextChunkPut:chunk2; space
703
1b3b008d9f19 fixed to allow class-source files to be handled
Claus Gittinger <cg@exept.de>
parents: 627
diff changeset
  2614
    ].
1b3b008d9f19 fixed to allow class-source files to be handled
Claus Gittinger <cg@exept.de>
parents: 627
diff changeset
  2615
    sawExcla ifTrue:[
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2616
        outStream nextPut:separator
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  2617
    ].
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  2618
    outStream cr.
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  2619
    aStream close.
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  2620
    outStream close.
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  2621
    ^ true
703
1b3b008d9f19 fixed to allow class-source files to be handled
Claus Gittinger <cg@exept.de>
parents: 627
diff changeset
  2622
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2623
    "Modified: / 6.2.1998 / 13:03:54 / cg"
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  2624
!
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  2625
51
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  2626
applyChange:changeNr
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  2627
    "fileIn a change"
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  2628
3091
12dd79e44cea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 3090
diff changeset
  2629
    |aStream applyAction nameSpace className changeClass ownerName ownerClass
3227
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2630
     sig reader doItChunk methodsForChunk pkg|
45
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  2631
51
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  2632
    aStream := self streamForChange:changeNr.
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  2633
    aStream isNil ifTrue:[^ self].
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  2634
2965
4ca3db1708a1 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2888
diff changeset
  2635
    className := self classNameOfChange:changeNr.
4ca3db1708a1 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2888
diff changeset
  2636
    className notNil ifTrue:[
4ca3db1708a1 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2888
diff changeset
  2637
        changeClass := Smalltalk at:(className asSymbol) ifAbsent:[].
4ca3db1708a1 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2888
diff changeset
  2638
        changeClass notNil ifTrue:[
4ca3db1708a1 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2888
diff changeset
  2639
            changeClass isLoaded ifFalse:[
4ca3db1708a1 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2888
diff changeset
  2640
                changeClass autoload
1427
0b2794583306 care for methodRedefinitionSignal when accepting
Claus Gittinger <cg@exept.de>
parents: 1425
diff changeset
  2641
            ]
0b2794583306 care for methodRedefinitionSignal when accepting
Claus Gittinger <cg@exept.de>
parents: 1425
diff changeset
  2642
        ]
51
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  2643
    ].
45
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  2644
51
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  2645
    changeNrProcessed := changeNr.
45
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  2646
358
a7546792f073 update changeFile if applying changes from another changeFile
Claus Gittinger <cg@exept.de>
parents: 326
diff changeset
  2647
    applyAction := [
1427
0b2794583306 care for methodRedefinitionSignal when accepting
Claus Gittinger <cg@exept.de>
parents: 1425
diff changeset
  2648
        (skipSignal notNil) ifTrue:[
0b2794583306 care for methodRedefinitionSignal when accepting
Claus Gittinger <cg@exept.de>
parents: 1425
diff changeset
  2649
            sig := skipSignal
0b2794583306 care for methodRedefinitionSignal when accepting
Claus Gittinger <cg@exept.de>
parents: 1425
diff changeset
  2650
        ] ifFalse:[
0b2794583306 care for methodRedefinitionSignal when accepting
Claus Gittinger <cg@exept.de>
parents: 1425
diff changeset
  2651
            sig := Object abortSignal
0b2794583306 care for methodRedefinitionSignal when accepting
Claus Gittinger <cg@exept.de>
parents: 1425
diff changeset
  2652
        ].
0b2794583306 care for methodRedefinitionSignal when accepting
Claus Gittinger <cg@exept.de>
parents: 1425
diff changeset
  2653
        sig catch:[
2343
20af8b9e9d8d checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2341
diff changeset
  2654
            applyInOriginalNameSpace value ifFalse:[
2301
d557a9dec28c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2295
diff changeset
  2655
                nameSpace := Class nameSpaceQuerySignal query.    
2343
20af8b9e9d8d checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2341
diff changeset
  2656
            ] ifTrue:[
20af8b9e9d8d checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2341
diff changeset
  2657
                nameSpace := Smalltalk.
2301
d557a9dec28c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2295
diff changeset
  2658
            ].
3227
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2659
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2660
            pkg := enforcedPackage ? Class packageQuerySignal query.             
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2661
            Class packageQuerySignal answer:pkg
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2662
            do:[    
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2663
                Class nameSpaceQuerySignal answer:nameSpace
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2664
                do:[
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2665
                    "/ a followup methodsFor: chunk ...
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2666
                    (self changeIsFollowupMethodChange:changeNr) ifTrue:[
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2667
                        methodsForChunk := (changeChunks at:changeNr).
2286
6da16a42e507 care for defaultNameSpace being set to something
Claus Gittinger <cg@exept.de>
parents: 2267
diff changeset
  2668
                    ] ifFalse:[
3227
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2669
                        doItChunk := aStream nextChunk.   "/ an empty chunk sometimes ...
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2670
                        doItChunk notEmpty ifTrue:[
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2671
                            Compiler evaluate:doItChunk notifying:self.
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2672
                        ] ifFalse:[
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2673
                            methodsForChunk := aStream nextChunk.   "/ the real one
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2674
                        ]
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2675
                    ].
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2676
                    methodsForChunk notNil ifTrue:[
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2677
                        changeClass isNil ifTrue:[
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2678
                            (className includes:$:) ifTrue:[
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2679
                                ownerName := className copyTo:(className lastIndexOf:$:) - 1.
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2680
                                (ownerName endsWith:$:) ifTrue:[
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2681
                                    ownerName := ownerName copyWithoutLast:1.
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2682
                                ].
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2683
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2684
                                ownerClass := Smalltalk at:(ownerName asSymbol) ifAbsent:[].
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2685
                                ownerClass notNil ifTrue:[
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2686
                                    ownerClass isLoaded ifFalse:[
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2687
                                        ownerClass autoload
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2688
                                    ]
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2689
                                ].
2965
4ca3db1708a1 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2888
diff changeset
  2690
                            ].
3227
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2691
                            (nameSpace notNil and:[nameSpace ~~ Smalltalk]) ifTrue:[
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2692
                                changeClass := nameSpace at:(className asSymbol) ifAbsent:[].
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2693
                            ].
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2694
                            changeClass isNil ifTrue:[
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2695
                                changeClass := Smalltalk at:(className asSymbol) ifAbsent:[].
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2696
                            ].
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2697
                            changeClass isNil ifTrue:[
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2698
                                self warn:'no class ''' , className , ''' for change'.
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2699
                                ^ self    
2965
4ca3db1708a1 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2888
diff changeset
  2700
                            ].
4ca3db1708a1 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2888
diff changeset
  2701
                        ].
3227
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2702
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2703
                        reader := Compiler evaluate:methodsForChunk notifying:self.
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2704
                        reader fileInFrom:aStream notifying:self passChunk:false single:true.
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  2705
                    ]
1427
0b2794583306 care for methodRedefinitionSignal when accepting
Claus Gittinger <cg@exept.de>
parents: 1425
diff changeset
  2706
                ]
0b2794583306 care for methodRedefinitionSignal when accepting
Claus Gittinger <cg@exept.de>
parents: 1425
diff changeset
  2707
            ]
0b2794583306 care for methodRedefinitionSignal when accepting
Claus Gittinger <cg@exept.de>
parents: 1425
diff changeset
  2708
        ].
0b2794583306 care for methodRedefinitionSignal when accepting
Claus Gittinger <cg@exept.de>
parents: 1425
diff changeset
  2709
        changeNrProcessed := nil.
358
a7546792f073 update changeFile if applying changes from another changeFile
Claus Gittinger <cg@exept.de>
parents: 326
diff changeset
  2710
    ].
a7546792f073 update changeFile if applying changes from another changeFile
Claus Gittinger <cg@exept.de>
parents: 326
diff changeset
  2711
a7546792f073 update changeFile if applying changes from another changeFile
Claus Gittinger <cg@exept.de>
parents: 326
diff changeset
  2712
    "/
a7546792f073 update changeFile if applying changes from another changeFile
Claus Gittinger <cg@exept.de>
parents: 326
diff changeset
  2713
    "/ if I am showing the changes file, dont update it
a7546792f073 update changeFile if applying changes from another changeFile
Claus Gittinger <cg@exept.de>
parents: 326
diff changeset
  2714
    "/
a7546792f073 update changeFile if applying changes from another changeFile
Claus Gittinger <cg@exept.de>
parents: 326
diff changeset
  2715
    changeFileName = ObjectMemory nameForChanges ifTrue:[
1427
0b2794583306 care for methodRedefinitionSignal when accepting
Claus Gittinger <cg@exept.de>
parents: 1425
diff changeset
  2716
        Class withoutUpdatingChangesDo:applyAction
358
a7546792f073 update changeFile if applying changes from another changeFile
Claus Gittinger <cg@exept.de>
parents: 326
diff changeset
  2717
    ] ifFalse:[
1427
0b2794583306 care for methodRedefinitionSignal when accepting
Claus Gittinger <cg@exept.de>
parents: 1425
diff changeset
  2718
        applyAction value
45
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  2719
    ].
132
claus
parents: 126
diff changeset
  2720
    aStream close
358
a7546792f073 update changeFile if applying changes from another changeFile
Claus Gittinger <cg@exept.de>
parents: 326
diff changeset
  2721
1473
160652b05e38 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1472
diff changeset
  2722
    "Modified: / 7.2.1998 / 19:56:34 / cg"
45
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  2723
!
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  2724
255
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  2725
compareChange:changeNr
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2726
    "compare a change with the current (in-image) version; show the result of the compare (as dialog)"
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2727
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2728
    ^ self compareChange:changeNr showResult:true
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2729
!
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2730
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2731
compareChange:changeNr showResult:doShowResult
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2732
    "compare a change with current version.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2733
     Return the result of the compare (same -> true, different -> false, uncomparable -> nil).
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2734
     If doShowResult is true, the outcome is shown in a dialog/diffViewer."
255
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  2735
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  2736
    |aStream chunk sawExcla parseTree thisClass cat oldSource newSource
742
2ef5e22d8983 code cleanup (unused vars eliminated)
Claus Gittinger <cg@exept.de>
parents: 724
diff changeset
  2737
     parser sel oldMethod outcome showDiff d t1 t2 selector isLoaded
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2738
     method beep superClass thisClassSym varsHere varsInChange addedVars removedVars
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2739
     isSame|
255
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  2740
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  2741
    aStream := self streamForChange:changeNr.
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2742
    aStream isNil ifTrue:[^ nil].
255
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  2743
275
604a906c0eb7 better handling of changes for autoloaded classes
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
  2744
    showDiff := false.
604a906c0eb7 better handling of changes for autoloaded classes
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
  2745
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2746
    (self changeIsFollowupMethodChange:changeNr) ifFalse:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2747
        sawExcla := aStream peekFor:(aStream class chunkSeparator).
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2748
        chunk := aStream nextChunk.
703
1b3b008d9f19 fixed to allow class-source files to be handled
Claus Gittinger <cg@exept.de>
parents: 627
diff changeset
  2749
    ] ifTrue:[
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2750
        chunk := (changeChunks at:changeNr).
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2751
        sawExcla := true.
703
1b3b008d9f19 fixed to allow class-source files to be handled
Claus Gittinger <cg@exept.de>
parents: 627
diff changeset
  2752
    ].
1b3b008d9f19 fixed to allow class-source files to be handled
Claus Gittinger <cg@exept.de>
parents: 627
diff changeset
  2753
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2754
    isSame := nil.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2755
761
5c2b46a38efa checkin from browser
Claus Gittinger <cg@exept.de>
parents: 744
diff changeset
  2756
    beep := false.
255
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  2757
    sawExcla ifFalse:[
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2758
        outcome := 'cannot compare this change\\(i.e. this is not a method change).'.
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2759
2286
6da16a42e507 care for defaultNameSpace being set to something
Claus Gittinger <cg@exept.de>
parents: 2267
diff changeset
  2760
        Class nameSpaceQuerySignal answer:Smalltalk
6da16a42e507 care for defaultNameSpace being set to something
Claus Gittinger <cg@exept.de>
parents: 2267
diff changeset
  2761
        do:[
6da16a42e507 care for defaultNameSpace being set to something
Claus Gittinger <cg@exept.de>
parents: 2267
diff changeset
  2762
            parseTree := Parser parseExpression:chunk.
6da16a42e507 care for defaultNameSpace being set to something
Claus Gittinger <cg@exept.de>
parents: 2267
diff changeset
  2763
        ].
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2764
        (parseTree notNil and:[parseTree ~~ #Error and:[ parseTree isMessage ]]) ifTrue:[
2571
9812249daf39 more compare changes stuff
Claus Gittinger <cg@exept.de>
parents: 2570
diff changeset
  2765
            selector := parseTree selector.
9812249daf39 more compare changes stuff
Claus Gittinger <cg@exept.de>
parents: 2570
diff changeset
  2766
9812249daf39 more compare changes stuff
Claus Gittinger <cg@exept.de>
parents: 2570
diff changeset
  2767
            selector == #'removeSelector:' ifTrue:[
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2768
                thisClass := (parseTree receiver evaluate).
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2769
                thisClass isBehavior ifTrue:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2770
                    (self checkClassIsLoaded:thisClass) ifTrue:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2771
                        selector := (parseTree arg1 evaluate).
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2772
                        (thisClass includesSelector:selector) ifTrue:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2773
                            outcome := 'change removes the #' , selector , ' method from ' , thisClass name.
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2774
                            isSame := false.
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2775
                        ] ifFalse:[
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2776
                            outcome := 'change has no effect\\(there is no method for #' , selector , ' in ' , thisClass name , ')'.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2777
                            isSame := true.
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2778
                        ]
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2779
                    ] ifFalse:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2780
                        beep := true.
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2781
                        outcome := 'cannot compare this change (compare requires class to be loaded).'.
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2782
                        isSame := nil.
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2783
                    ]
2286
6da16a42e507 care for defaultNameSpace being set to something
Claus Gittinger <cg@exept.de>
parents: 2267
diff changeset
  2784
                ] ifFalse:[
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2785
                    outcome := 'cannot compare this change (class not present)'.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2786
                    isSame := nil.
2286
6da16a42e507 care for defaultNameSpace being set to something
Claus Gittinger <cg@exept.de>
parents: 2267
diff changeset
  2787
                ].
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2788
            ].
2571
9812249daf39 more compare changes stuff
Claus Gittinger <cg@exept.de>
parents: 2570
diff changeset
  2789
            selector == #'category:' ifTrue:[
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2790
                parseTree receiver isMessage ifTrue:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2791
                    parseTree receiver selector == #compiledMethodAt: ifTrue:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2792
                        (method := parseTree receiver evaluate) isMethod ifTrue:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2793
                            method category = parseTree arg1 evaluate ifTrue:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2794
                                outcome := 'change has no effect\\(same category)'.
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2795
                                isSame := true.
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2796
                            ] ifFalse:[
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2797
                                outcome := 'category is different (''' , method category , ''' vs. ''' , parseTree arg1 evaluate , ''')'.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2798
                                isSame := false.
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2799
                            ]
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2800
                        ] ifFalse:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2801
                            beep := true.
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2802
                            outcome := 'there is no such method'.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2803
                            isSame := nil.
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2804
                        ]
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2805
                    ]
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2806
                ]
1713
f6a93c02e953 also show '=' for method-removes (if non-existing in image);
Claus Gittinger <cg@exept.de>
parents: 1706
diff changeset
  2807
            ].
2571
9812249daf39 more compare changes stuff
Claus Gittinger <cg@exept.de>
parents: 2570
diff changeset
  2808
            selector == #'comment:' ifTrue:[
2570
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2809
                thisClass := (parseTree receiver evaluate).
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2810
                thisClass isBehavior ifTrue:[
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2811
                    (self checkClassIsLoaded:thisClass) ifTrue:[
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2812
                        (thisClass comment = parseTree arg1 evaluate) ifTrue:[
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2813
                            outcome := 'change has no effect\\(same comment)'.
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2814
                            isSame := true.
2570
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2815
                        ] ifFalse:[
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2816
                            outcome := 'comment is different'.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2817
                            isSame := false.
2570
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2818
                        ]
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2819
                    ] ifFalse:[
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2820
                        beep := true.
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2821
                        outcome := 'cannot compare this change (compare requires class to be loaded).'.
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2822
                        isSame := nil.
2570
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2823
                    ]
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2824
                ] ifFalse:[
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2825
                    outcome := 'cannot compare this change (class not present)'.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2826
                    isSame := nil.
2570
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2827
                ].
2f15ecfd80de compare comments
Claus Gittinger <cg@exept.de>
parents: 2555
diff changeset
  2828
            ].
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2829
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2830
            selector == #'instanceVariableNames:' ifTrue:[
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2831
                parseTree receiver isMessage ifTrue:[
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2832
                    parseTree receiver selector == #class ifTrue:[
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2833
                        thisClass := (parseTree receiver evaluate).
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2834
                        varsHere := thisClass instanceVariableString asCollectionOfWords.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2835
                        varsInChange := (parseTree arguments at:1) evaluate asCollectionOfWords.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2836
                        varsHere = varsInChange ifTrue:[
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2837
                            outcome := 'change has no effect\\(same definition)'.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2838
                            isSame := true.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2839
                        ] ifFalse:[
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2840
                            outcome := 'class-instanceVariable definition is different'.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2841
                            isSame := false.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2842
                        ].
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2843
                    ].
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2844
                ]
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2845
            ].
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2846
2571
9812249daf39 more compare changes stuff
Claus Gittinger <cg@exept.de>
parents: 2570
diff changeset
  2847
            selector == #'subclass:instanceVariableNames:classVariableNames:poolDictionaries:category:' ifTrue:[
9812249daf39 more compare changes stuff
Claus Gittinger <cg@exept.de>
parents: 2570
diff changeset
  2848
                superClass := (parseTree receiver evaluate).
9812249daf39 more compare changes stuff
Claus Gittinger <cg@exept.de>
parents: 2570
diff changeset
  2849
                superClass isBehavior ifTrue:[
9812249daf39 more compare changes stuff
Claus Gittinger <cg@exept.de>
parents: 2570
diff changeset
  2850
                    (self checkClassIsLoaded:superClass) ifTrue:[
1713
f6a93c02e953 also show '=' for method-removes (if non-existing in image);
Claus Gittinger <cg@exept.de>
parents: 1706
diff changeset
  2851
                        thisClassSym := (parseTree arguments at:1) evaluate.
f6a93c02e953 also show '=' for method-removes (if non-existing in image);
Claus Gittinger <cg@exept.de>
parents: 1706
diff changeset
  2852
                        thisClass := Smalltalk at:thisClassSym ifAbsent:nil.
f6a93c02e953 also show '=' for method-removes (if non-existing in image);
Claus Gittinger <cg@exept.de>
parents: 1706
diff changeset
  2853
                        thisClass notNil ifTrue:[
2816
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2854
                            (isLoaded := self checkClassIsLoaded:thisClass) ifFalse:[
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2855
                                outcome := 'cannot compare this change\\(compare requires class to be loaded).'.
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2856
                                isSame := nil.
2816
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2857
                            ] ifTrue:[
2834
0fd76c32e250 better class def compare
Claus Gittinger <cg@exept.de>
parents: 2816
diff changeset
  2858
                                varsHere := thisClass instanceVariableString asCollectionOfWords.
0fd76c32e250 better class def compare
Claus Gittinger <cg@exept.de>
parents: 2816
diff changeset
  2859
                                varsInChange := (parseTree arguments at:2) evaluate asCollectionOfWords.
0fd76c32e250 better class def compare
Claus Gittinger <cg@exept.de>
parents: 2816
diff changeset
  2860
                                varsHere = varsInChange ifTrue:[
2816
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2861
                                    thisClass classVariableString asCollectionOfWords = (parseTree arguments at:3) evaluate asCollectionOfWords ifTrue:[
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2862
                                        ((thisClass sharedPools size == 0) and:[(parseTree arguments at:4) evaluate = '']) ifTrue:[
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2863
                                            thisClass category = (parseTree arguments at:5) evaluate ifTrue:[
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2864
                                                outcome := 'change has no effect\\(same definition)'.
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2865
                                                isSame := true.
2816
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2866
                                            ] ifFalse:[
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2867
                                                outcome := 'category is different'.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2868
                                                isSame := false.
2816
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2869
                                            ]
2571
9812249daf39 more compare changes stuff
Claus Gittinger <cg@exept.de>
parents: 2570
diff changeset
  2870
                                        ] ifFalse:[
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2871
                                            outcome := 'sharedPool definition is different'.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2872
                                            isSame := false.
2816
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2873
                                        ].
2571
9812249daf39 more compare changes stuff
Claus Gittinger <cg@exept.de>
parents: 2570
diff changeset
  2874
                                    ] ifFalse:[
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2875
                                        outcome := 'classVariable definition is different'.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2876
                                        isSame := false.
2816
04c3e709fbd2 better compare functions
Claus Gittinger <cg@exept.de>
parents: 2797
diff changeset
  2877
                                    ]
2571
9812249daf39 more compare changes stuff
Claus Gittinger <cg@exept.de>
parents: 2570
diff changeset
  2878
                                ] ifFalse:[
2834
0fd76c32e250 better class def compare
Claus Gittinger <cg@exept.de>
parents: 2816
diff changeset
  2879
                                    outcome := 'instanceVariable definition is different'.
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2880
                                    isSame := false.
2834
0fd76c32e250 better class def compare
Claus Gittinger <cg@exept.de>
parents: 2816
diff changeset
  2881
                                    addedVars := varsInChange select:[:eachVar | (varsHere includes:eachVar) not].
0fd76c32e250 better class def compare
Claus Gittinger <cg@exept.de>
parents: 2816
diff changeset
  2882
                                    removedVars := varsHere select:[:eachVar | (varsInChange includes:eachVar) not].
0fd76c32e250 better class def compare
Claus Gittinger <cg@exept.de>
parents: 2816
diff changeset
  2883
                                    addedVars isEmpty ifTrue:[
0fd76c32e250 better class def compare
Claus Gittinger <cg@exept.de>
parents: 2816
diff changeset
  2884
                                        removedVars := removedVars collect:[:eachVar | '''' , eachVar , ''''].
0fd76c32e250 better class def compare
Claus Gittinger <cg@exept.de>
parents: 2816
diff changeset
  2885
                                        outcome := 'change removes instanceVariable(s): ' , (removedVars asStringWith:Character space).
0fd76c32e250 better class def compare
Claus Gittinger <cg@exept.de>
parents: 2816
diff changeset
  2886
                                    ] ifFalse:[
0fd76c32e250 better class def compare
Claus Gittinger <cg@exept.de>
parents: 2816
diff changeset
  2887
                                        removedVars isEmpty ifTrue:[
0fd76c32e250 better class def compare
Claus Gittinger <cg@exept.de>
parents: 2816
diff changeset
  2888
                                            addedVars := addedVars collect:[:eachVar | '''' , eachVar , ''''].
0fd76c32e250 better class def compare
Claus Gittinger <cg@exept.de>
parents: 2816
diff changeset
  2889
                                            outcome := 'change adds instanceVariable(s): ' , (addedVars asStringWith:Character space).
0fd76c32e250 better class def compare
Claus Gittinger <cg@exept.de>
parents: 2816
diff changeset
  2890
                                        ].
0fd76c32e250 better class def compare
Claus Gittinger <cg@exept.de>
parents: 2816
diff changeset
  2891
                                    ].
1713
f6a93c02e953 also show '=' for method-removes (if non-existing in image);
Claus Gittinger <cg@exept.de>
parents: 1706
diff changeset
  2892
                                ]
f6a93c02e953 also show '=' for method-removes (if non-existing in image);
Claus Gittinger <cg@exept.de>
parents: 1706
diff changeset
  2893
                            ]
f6a93c02e953 also show '=' for method-removes (if non-existing in image);
Claus Gittinger <cg@exept.de>
parents: 1706
diff changeset
  2894
                        ]
f6a93c02e953 also show '=' for method-removes (if non-existing in image);
Claus Gittinger <cg@exept.de>
parents: 1706
diff changeset
  2895
                    ]
f6a93c02e953 also show '=' for method-removes (if non-existing in image);
Claus Gittinger <cg@exept.de>
parents: 1706
diff changeset
  2896
                ]
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2897
            ]
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2898
        ]
255
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  2899
    ] ifTrue:[
2286
6da16a42e507 care for defaultNameSpace being set to something
Claus Gittinger <cg@exept.de>
parents: 2267
diff changeset
  2900
        Class nameSpaceQuerySignal answer:Smalltalk
6da16a42e507 care for defaultNameSpace being set to something
Claus Gittinger <cg@exept.de>
parents: 2267
diff changeset
  2901
        do:[
6da16a42e507 care for defaultNameSpace being set to something
Claus Gittinger <cg@exept.de>
parents: 2267
diff changeset
  2902
            parseTree := Parser parseExpression:chunk.
6da16a42e507 care for defaultNameSpace being set to something
Claus Gittinger <cg@exept.de>
parents: 2267
diff changeset
  2903
        ].
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2904
        (parseTree notNil 
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2905
         and:[parseTree ~~ #Error
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2906
         and:[parseTree isMessage]]) ifTrue:[
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2907
            "/ Squeak support (#methodsFor:***)
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2908
            (#(
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2909
               #methodsFor: 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2910
               #privateMethodsFor:
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2911
               #publicMethodsFor:
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2912
               #ignoredMethodsFor:
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2913
               #protectedMethodsFor:
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2914
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2915
               #methodsFor:stamp:             "/ Squeak support
2527
afa639104477 some support for dolphin source files
Claus Gittinger <cg@exept.de>
parents: 2511
diff changeset
  2916
               #methodsFor                    "/ Dolphin support
2606
61cc86fff103 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2604
diff changeset
  2917
               #methods                       "/ STV support
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2918
              ) 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  2919
            includes:parseTree selector) ifTrue:[
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2920
                thisClass := (parseTree receiver evaluate).
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2921
                thisClass isBehavior ifTrue:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2922
                    (isLoaded := self checkClassIsLoaded:thisClass) ifFalse:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2923
                        outcome := 'cannot compare this change\\(compare requires class to be loaded).'.
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2924
                        isSame := nil.
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2925
                    ].
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2926
2527
afa639104477 some support for dolphin source files
Claus Gittinger <cg@exept.de>
parents: 2511
diff changeset
  2927
                    parseTree selector == #methodsFor ifTrue:[
afa639104477 some support for dolphin source files
Claus Gittinger <cg@exept.de>
parents: 2511
diff changeset
  2928
                        cat := 'Dolphin methods'.
afa639104477 some support for dolphin source files
Claus Gittinger <cg@exept.de>
parents: 2511
diff changeset
  2929
                    ] ifFalse:[
2606
61cc86fff103 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2604
diff changeset
  2930
                        parseTree selector == #methods ifTrue:[
61cc86fff103 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2604
diff changeset
  2931
                            cat := 'STV methods'.
61cc86fff103 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2604
diff changeset
  2932
                        ] ifFalse:[
61cc86fff103 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2604
diff changeset
  2933
                            cat := parseTree arg1 evaluate.
61cc86fff103 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2604
diff changeset
  2934
                        ].
2527
afa639104477 some support for dolphin source files
Claus Gittinger <cg@exept.de>
parents: 2511
diff changeset
  2935
                    ].
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2936
                    newSource := aStream nextChunk.
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2937
2286
6da16a42e507 care for defaultNameSpace being set to something
Claus Gittinger <cg@exept.de>
parents: 2267
diff changeset
  2938
                    Class nameSpaceQuerySignal answer:Smalltalk
6da16a42e507 care for defaultNameSpace being set to something
Claus Gittinger <cg@exept.de>
parents: 2267
diff changeset
  2939
                    do:[
6da16a42e507 care for defaultNameSpace being set to something
Claus Gittinger <cg@exept.de>
parents: 2267
diff changeset
  2940
                        parser := Parser parseMethod:newSource in:thisClass.
6da16a42e507 care for defaultNameSpace being set to something
Claus Gittinger <cg@exept.de>
parents: 2267
diff changeset
  2941
                    ].
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2942
                    (parser notNil and:[parser ~~ #Error]) ifTrue:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2943
                        sel := parser selector.
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2944
                        oldMethod := thisClass compiledMethodAt:sel.
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2945
                        oldMethod notNil ifTrue:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2946
                            (oldMethod category = cat) ifFalse:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2947
                                Transcript showCR:'category changed.'.
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2948
                            ].
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2949
                            oldSource := oldMethod source.
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2950
                            (oldSource = newSource) ifTrue:[
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2951
                                outcome := 'same source'.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2952
                                isSame := true.
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2953
                            ] ifFalse:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2954
                                oldSource isNil ifTrue:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2955
                                    beep := true.
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2956
                                    outcome := 'no source for compare.'.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2957
                                    isSame := true.
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2958
                                ] ifFalse:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2959
                                    "/
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2960
                                    "/ compare for tabulator <-> space changes
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2961
                                    "/ before showing diff ...
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2962
                                    "/
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2963
                                    t1 := oldSource asCollectionOfLines collect:[:s | s withTabsExpanded].
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2964
                                    t2 := newSource asCollectionOfLines collect:[:s | s withTabsExpanded].
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2965
                                    t1 = t2 ifTrue:[
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2966
                                        outcome := 'same source'.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2967
                                        isSame := true.
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2968
                                    ] ifFalse:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2969
                                        outcome := 'source changed.'.
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2970
                                        showDiff := true.
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2971
                                        isSame := false.
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2972
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2973
                                        "/
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2974
                                        "/ check if only historyLine diffs
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2975
                                        "/
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2976
                                        (HistoryManager notNil 
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2977
                                        and:[HistoryManager isActive]) ifTrue:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2978
                                            (HistoryManager withoutHistoryLines:newSource)
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2979
                                            =
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2980
                                            (HistoryManager withoutHistoryLines:oldSource)
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2981
                                            ifTrue:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2982
                                                outcome := 'same source (history only)'.
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2983
                                                isSame := true.
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2984
                                                showDiff := false.
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2985
                                            ]
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2986
                                        ].
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2987
                                    ]
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2988
                                ]
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2989
                            ]
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2990
                        ] ifFalse:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2991
                            isLoaded ifTrue:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2992
                                beep := true.
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2993
                                outcome := 'method does not exist.'.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2994
                                isSame := nil.
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2995
                            ]
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2996
                        ]
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  2997
                    ] ifFalse:[
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2998
                        outcome := 'change unparsable (parse error).'.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  2999
                        isSame := nil.
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  3000
                    ].
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3001
                    doShowResult ifTrue:[
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3002
                        (showDiff and:[oldSource notNil and:[newSource notNil]]) ifTrue:[
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3003
                            d := DiffTextView 
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3004
                                    openOn:oldSource label:(resources string:'current version (in image)')
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3005
                                    and:newSource label:(resources string:'change version').
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3006
                            d label:'method differences'.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3007
                        ]
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  3008
                    ]
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  3009
                ] ifFalse:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  3010
                    beep := true.
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3011
                    outcome := 'class does not exist.'.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3012
                    isSame := nil.
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  3013
                ]
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  3014
            ] ifFalse:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  3015
                beep := true.
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3016
                outcome := 'not comparable.'.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3017
                isSame := nil.
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  3018
            ]
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  3019
        ] ifFalse:[
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  3020
            beep := true.
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3021
            outcome := 'not comparable.'.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3022
            isSame := nil.
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  3023
        ]
255
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  3024
    ].
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  3025
    aStream close.
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3026
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3027
    doShowResult ifTrue:[
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3028
        showDiff ifFalse:[
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3029
            outcome := (resources string:outcome) withCRs.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3030
            beep ifTrue:[
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3031
                self warn:outcome.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3032
            ] ifFalse:[
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3033
                self information:outcome.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3034
            ]
553
b67caadfe334 showCr: -> showCR:
Claus Gittinger <cg@exept.de>
parents: 548
diff changeset
  3035
"/        Transcript showCR:outcome.
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3036
        ].
255
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  3037
    ].
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3038
    ^ isSame.
255
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  3039
1472
6620dc742f2a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1471
diff changeset
  3040
    "Created: / 24.11.1995 / 14:30:46 / cg"
2606
61cc86fff103 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2604
diff changeset
  3041
    "Modified: / 13.2.2000 / 15:04:39 / cg"
255
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  3042
!
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  3043
1359
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3044
compressForClass:aClassNameOrNil
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3045
    "compress the change-set; 
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3046
     this replaces multiple method-changes by the last (i.e. the most recent) change.
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3047
     If the class argument is nil, compress for all classes.
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3048
     otherwise, only changes for that class are compressed."
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3049
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3050
    |aStream searchIndex anyMore deleteSet index  
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3051
     str snapshotProto snapshotPrefix snapshotNameIndex fileName|
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3052
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3053
    aStream := FileStream readonlyFileNamed:changeFileName.
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3054
    aStream isNil ifTrue:[^ self].
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3055
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3056
    aClassNameOrNil isNil ifTrue:[
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3057
        self newLabel:'compressing ...'.
1359
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3058
    ] ifFalse:[
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3059
        self newLabel:'compressing for ' , aClassNameOrNil.
1359
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3060
    ].
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3061
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3062
    CompressSnapshotInfo == true ifTrue:[
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3063
        "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3064
         get a prototype snapshot record (to be independent of
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3065
         the actual format ..
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3066
        "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3067
        str := WriteStream on:String new.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3068
        Class addChangeRecordForSnapshot:'foo' to:str.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3069
        snapshotProto := str contents.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3070
        snapshotPrefix := snapshotProto copyTo:10.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3071
        snapshotNameIndex := snapshotProto findString:'foo'.
1359
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3072
    ].
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3073
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3074
    self withExecuteCursorDo:[
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3075
        |numChanges classes selectors types excla sawExcla
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3076
         changeNr chunk aParseTree parseTreeChunk
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3077
         thisClass thisSelector codeChunk codeParser
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3078
         compressThis|
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3079
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3080
        numChanges := self numberOfChanges.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3081
        classes := Array new:numChanges.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3082
        selectors := Array new:numChanges.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3083
        types := Array new:numChanges.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3084
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3085
        "starting at the end, get the change class and change selector;
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3086
         collect all in classes / selectors"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3087
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3088
        changeNr := numChanges.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3089
        excla := aStream class chunkSeparator.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3090
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3091
        [changeNr >= 1] whileTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3092
            aStream position:(changePositions at:changeNr).
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3093
            sawExcla := aStream peekFor:excla.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3094
            chunk := aStream nextChunk.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3095
            sawExcla ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3096
                "optimize a bit if multiple methods for same category arrive"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3097
                (chunk = parseTreeChunk) ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3098
                    aParseTree := Parser parseExpression:chunk.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3099
                    parseTreeChunk := chunk
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3100
                ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3101
                (aParseTree notNil 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3102
                and:[(aParseTree ~~ #Error) 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3103
                and:[aParseTree isMessage]]) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3104
                    (#(
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3105
                       #methodsFor: 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3106
                       #privateMethodsFor:
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3107
                       #publicMethodsFor:
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3108
                       #ignoredMethodsFor:
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3109
                       #protectedMethodsFor:
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3110
                       #methodsFor:stamp:             "/ Squeak support
2527
afa639104477 some support for dolphin source files
Claus Gittinger <cg@exept.de>
parents: 2511
diff changeset
  3111
                       #methodsFor                    "/ Dolphin support
2606
61cc86fff103 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2604
diff changeset
  3112
                       #methods                       "/ STV support
2263
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3113
                      ) 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3114
                    includes:aParseTree selector) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3115
                        thisClass := (aParseTree receiver evaluate).
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3116
                        codeChunk := aStream nextChunk.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3117
                        codeParser := Parser 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3118
                                          parseMethodSpecification:codeChunk
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3119
                                          in:thisClass
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3120
                                          ignoreErrors:true
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3121
                                          ignoreWarnings:true.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3122
                        (codeParser notNil and:[codeParser ~~ #Error]) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3123
                            selectors at:changeNr put:(codeParser selector).
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3124
                            classes at:changeNr put:thisClass.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3125
                            types at:changeNr put:#methodsFor
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3126
                        ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3127
                    ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3128
                ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3129
            ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3130
                aParseTree := Parser parseExpression:chunk.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3131
                parseTreeChunk := chunk.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3132
                (aParseTree notNil 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3133
                and:[(aParseTree ~~ #Error) 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3134
                and:[aParseTree isMessage]]) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3135
                    (aParseTree selector == #removeSelector:) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3136
                        selectors at:changeNr put:(aParseTree arg1 value ).
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3137
                        classes at:changeNr put:(aParseTree receiver evaluate).
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3138
                        types at:changeNr put:#removeSelector
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3139
                    ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3140
                ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3141
                    CompressSnapshotInfo == true ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3142
                        (chunk startsWith:snapshotPrefix) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3143
                            str := chunk readStream position:snapshotNameIndex.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3144
                            fileName := str upTo:(Character space).
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3145
                            "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3146
                             kludge to allow use of match-check below
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3147
                            "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3148
                            selectors at:changeNr put:snapshotPrefix.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3149
                            classes at:changeNr put:fileName.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3150
                        ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3151
                    ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3152
                ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3153
            ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3154
            changeNr := changeNr - 1
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3155
        ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3156
        aStream close.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3157
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3158
        "for all changes, look for another class/selector occurence later
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3159
         in the list and, if there is one, add change number to the delete set"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3160
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3161
        deleteSet := OrderedCollection new.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3162
        changeNr := 1.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3163
        [changeNr < self numberOfChanges] whileTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3164
            thisClass := classes at:changeNr.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3165
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3166
            compressThis := false.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3167
            aClassNameOrNil isNil ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3168
                compressThis := true
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3169
            ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3170
                "/ skipping unloaded/unknown classes
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3171
                thisClass isBehavior ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3172
                    thisClass isMeta ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3173
                        compressThis := aClassNameOrNil = thisClass soleInstance name. 
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3174
                    ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3175
                        compressThis := aClassNameOrNil = thisClass name
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3176
                    ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3177
                ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3178
            ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3179
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3180
            compressThis ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3181
                thisSelector := selectors at:changeNr.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3182
                searchIndex := changeNr.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3183
                anyMore := true.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3184
                [anyMore] whileTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3185
                    searchIndex := classes indexOf:thisClass
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3186
                                        startingAt:(searchIndex + 1).
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3187
                    (searchIndex ~~ 0) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3188
                        ((selectors at:searchIndex) == thisSelector) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3189
                            thisClass notNil ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3190
                                deleteSet add:changeNr.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3191
                                anyMore := false
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3192
                            ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3193
                        ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3194
                    ] ifFalse:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3195
                        anyMore := false      
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3196
                    ]
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3197
                ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3198
            ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3199
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3200
            changeNr := changeNr + 1
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3201
        ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3202
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3203
        "finally delete what has been found"
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3204
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3205
        (deleteSet size > 0) ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3206
            changeListView setSelection:nil.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3207
            index := deleteSet size.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3208
            [index > 0] whileTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3209
                self silentDeleteChange:(deleteSet at:index).
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3210
                index := index - 1
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3211
            ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3212
            self setChangeList.
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3213
            "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3214
             scroll back a bit, if we are left way behind the list
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3215
            "
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3216
            changeListView firstLineShown > self numberOfChanges ifTrue:[
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3217
                changeListView makeLineVisible:self numberOfChanges
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3218
            ].
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3219
            self clearCodeView
46fc2bb1b9c1 changes to allow browsing Sqeak fileOut format.
Claus Gittinger <cg@exept.de>
parents: 2214
diff changeset
  3220
        ]
1359
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3221
    ].
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3222
    self newLabel:''.
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3223
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3224
    "Created: / 29.10.1997 / 01:02:44 / cg"
2606
61cc86fff103 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2604
diff changeset
  3225
    "Modified: / 13.2.2000 / 15:05:07 / cg"
1359
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3226
!
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3227
255
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  3228
deleteChange:changeNr
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  3229
    "delete a change"
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  3230
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  3231
    self deleteChangesFrom:changeNr to:changeNr
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  3232
!
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  3233
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  3234
deleteChangesFrom:start to:stop
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  3235
    "delete a range of changes"
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  3236
562
8f772068fd1a #selection: now does a notification / #setSelection: does not
Claus Gittinger <cg@exept.de>
parents: 553
diff changeset
  3237
    changeListView setSelection:nil.
255
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  3238
    stop to:start by:-1 do:[:changeNr |
1648
db1ca601ad8c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1625
diff changeset
  3239
        self silentDeleteInternalChange:changeNr.
db1ca601ad8c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1625
diff changeset
  3240
        changeListView removeIndex:changeNr.
255
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  3241
    ].
744
cb962cb21e8c faster drawing when deleting items
Claus Gittinger <cg@exept.de>
parents: 742
diff changeset
  3242
1070
cdf5cf202f3b faster redraw, when deleting items.
Claus Gittinger <cg@exept.de>
parents: 1027
diff changeset
  3243
"/    changeListView contentsChanged.
cdf5cf202f3b faster redraw, when deleting items.
Claus Gittinger <cg@exept.de>
parents: 1027
diff changeset
  3244
"/    changeListView redrawFromLine:start.
255
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  3245
744
cb962cb21e8c faster drawing when deleting items
Claus Gittinger <cg@exept.de>
parents: 742
diff changeset
  3246
"/    self setChangeList
cb962cb21e8c faster drawing when deleting items
Claus Gittinger <cg@exept.de>
parents: 742
diff changeset
  3247
1648
db1ca601ad8c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1625
diff changeset
  3248
    "Modified: / 18.5.1998 / 14:22:27 / cg"
255
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  3249
!
08ec5e9cdbd2 disable entries
Claus Gittinger <cg@exept.de>
parents: 241
diff changeset
  3250
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3251
makeChangeAPatch:changeNr
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3252
    "append change to patchfile"
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3253
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3254
    self appendChange:changeNr toFile:'patches'
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3255
!
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3256
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3257
makeChangePermanent:changeNr
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3258
    "rewrite the source file where change changeNr lies"
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3259
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3260
    self notify:'this is not yet implemented'
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3261
!
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3262
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3263
silentDeleteChange:changeNr
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3264
    "delete a change do not update changeListView"
57
36e13831b62d *** empty log message ***
claus
parents: 56
diff changeset
  3265
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3266
    anyChanges := true.
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3267
    changeChunks removeIndex:changeNr.
3203
44ac975f0993 pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3202
diff changeset
  3268
    changePositions size >= changeNr ifTrue:[ changePositions removeIndex:changeNr ].
44ac975f0993 pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3202
diff changeset
  3269
    changeClassNames size >= changeNr ifTrue:[ changeClassNames removeIndex:changeNr ].
44ac975f0993 pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3202
diff changeset
  3270
    changeSelectors size >= changeNr ifTrue:[ changeSelectors removeIndex:changeNr ].
44ac975f0993 pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3202
diff changeset
  3271
    changeHeaderLines size >= changeNr ifTrue:[ changeHeaderLines removeIndex:changeNr ].
44ac975f0993 pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3202
diff changeset
  3272
    changeTimeStamps size >= changeNr ifTrue:[ changeTimeStamps removeIndex:changeNr ].
44ac975f0993 pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3202
diff changeset
  3273
    changeIsFollowupMethodChange size >= changeNr ifTrue:[ changeIsFollowupMethodChange removeIndex:changeNr ].
182
0c2f9214d531 handle & display timestamp records
Claus Gittinger <cg@exept.de>
parents: 176
diff changeset
  3274
0c2f9214d531 handle & display timestamp records
Claus Gittinger <cg@exept.de>
parents: 176
diff changeset
  3275
    "Modified: 18.11.1995 / 17:08:44 / cg"
45
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  3276
!
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  3277
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3278
silentDeleteChangesFor:aClassName from:start to:stop
1428
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3279
    "delete changes for a given class in a range.
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3280
     Return the number of deleted changes."
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3281
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3282
    |thisClassName index numDeleted|
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3283
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3284
    numDeleted := 0.
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3285
    index := stop.
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3286
    [index >= start] whileTrue:[
1428
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3287
        thisClassName := self classNameOfChange:index.
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3288
        thisClassName = aClassName ifTrue:[
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3289
            self silentDeleteChange:index.
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3290
            numDeleted := numDeleted + 1.
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3291
        ].
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3292
        index := index - 1
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3293
    ].
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3294
    ^ numDeleted
51
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  3295
45
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  3296
!
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  3297
2511
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3298
silentDeleteChangesForClassAndPrivateClasses:aClassName from:start to:stop
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3299
    "delete changes for a given class and its private classes in a range.
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3300
     Return the number of deleted changes."
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3301
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3302
    |thisClassName index numDeleted|
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3303
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3304
    numDeleted := 0.
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3305
    index := stop.
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3306
    [index >= start] whileTrue:[
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3307
        thisClassName := self ownerClassNameOfChange:index.
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3308
        thisClassName = aClassName ifTrue:[
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3309
            self silentDeleteChange:index.
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3310
            numDeleted := numDeleted + 1.
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3311
        ].
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3312
        index := index - 1
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3313
    ].
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3314
    ^ numDeleted
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3315
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3316
!
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3317
1070
cdf5cf202f3b faster redraw, when deleting items.
Claus Gittinger <cg@exept.de>
parents: 1027
diff changeset
  3318
silentDeleteInternalChange:changeNr
cdf5cf202f3b faster redraw, when deleting items.
Claus Gittinger <cg@exept.de>
parents: 1027
diff changeset
  3319
    "delete a change do not update changeListView"
cdf5cf202f3b faster redraw, when deleting items.
Claus Gittinger <cg@exept.de>
parents: 1027
diff changeset
  3320
cdf5cf202f3b faster redraw, when deleting items.
Claus Gittinger <cg@exept.de>
parents: 1027
diff changeset
  3321
    anyChanges := true.
cdf5cf202f3b faster redraw, when deleting items.
Claus Gittinger <cg@exept.de>
parents: 1027
diff changeset
  3322
    changeChunks removeIndex:changeNr.
1473
160652b05e38 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1472
diff changeset
  3323
    changePositions size >= changeNr ifTrue:[changePositions removeIndex:changeNr].
160652b05e38 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1472
diff changeset
  3324
    changeClassNames size >= changeNr ifTrue:[changeClassNames removeIndex:changeNr].
3203
44ac975f0993 pullDownMenu
Claus Gittinger <cg@exept.de>
parents: 3202
diff changeset
  3325
    changeSelectors size >= changeNr ifTrue:[ changeSelectors removeIndex:changeNr ].
2394
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  3326
    changeTimeStamps size >= changeNr ifTrue:[changeTimeStamps removeIndex:changeNr].
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  3327
    changeIsFollowupMethodChange size >= changeNr ifTrue:[changeIsFollowupMethodChange removeIndex:changeNr].
1473
160652b05e38 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1472
diff changeset
  3328
160652b05e38 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1472
diff changeset
  3329
    "Created: / 7.3.1997 / 16:28:32 / cg"
160652b05e38 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1472
diff changeset
  3330
    "Modified: / 7.2.1998 / 19:59:11 / cg"
1496
978b3c3565c9 #silentDeleteInternalChange: copy-paste error
Stefan Vogel <sv@exept.de>
parents: 1473
diff changeset
  3331
    "Modified: / 26.2.1998 / 18:20:48 / stefan"
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3332
! !
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
  3333
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3334
!ChangesBrowser methodsFor:'termination'!
51
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  3335
1787
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3336
closeRequest
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3337
    "window manager wants us to go away"
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3338
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3339
    |action again|
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3340
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3341
    anyChanges ifTrue:[
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3342
        again := true.
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3343
        [again] whileTrue:[
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3344
            action := OptionBox 
2888
a8f77fb777ee better warn text
Claus Gittinger <cg@exept.de>
parents: 2867
diff changeset
  3345
                              request:(resources at:'The modified changelist has not been written back to the change file.\\Write change file before closing ?') withCRs
1787
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3346
                              label:'ChangesBrowser'
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3347
                              form:(WarningBox iconBitmap)
3229
ddcfc1680304 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 3227
diff changeset
  3348
                              buttonLabels:(resources array:#('Cancel' 'Don''t write' 'Write'))
1787
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3349
                              values:#(#abort #ignore #save)
3071
652c6b4f6981 optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents: 3069
diff changeset
  3350
                              default:#save
652c6b4f6981 optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents: 3069
diff changeset
  3351
                              onCancel:#abort.
1787
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3352
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3353
            again := false.
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3354
            action == #abort ifTrue:[^ self].
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3355
            action  == #save ifTrue:[
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3356
                again := self writeBackChanges not
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3357
            ].
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3358
        ]
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3359
    ].
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3360
    super closeRequest
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3361
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3362
    "Modified: / 31.7.1997 / 18:29:06 / cg"
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3363
    "Created: / 3.8.1998 / 19:54:13 / cg"
2353
707dd9391c02 Consistent use of 'update' and 'write' in the user interface
Stefan Vogel <sv@exept.de>
parents: 2343
diff changeset
  3364
    "Modified: / 24.8.1999 / 09:45:04 / stefan"
1787
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3365
!
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3366
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3367
saveAndTerminate
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3368
    "update the changes file and quit.
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3369
     Dont depend on this being sent, not all window managers
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3370
     send it; instead, they simply destroy the view."
28
eea5a71a1e23 *** empty log message ***
claus
parents: 27
diff changeset
  3371
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3372
    anyChanges ifTrue:[
1787
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3373
        self writeBackChanges.
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
  3374
    ].
1787
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3375
    super saveAndTerminate
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3376
d3d0266b35ec #terminate -> #closeRequest
Claus Gittinger <cg@exept.de>
parents: 1781
diff changeset
  3377
    "Modified: / 3.8.1998 / 19:54:00 / cg"
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
  3378
! !
571fd5eee315 Initial revision
claus
parents:
diff changeset
  3379
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3380
!ChangesBrowser methodsFor:'user interaction'!
51
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  3381
3292
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3382
askForSearch:msg initialAnswer:initial thenSearchUsing:searchBlock2 onCancel:cancelBlock
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3383
    |searchString directionHolder searchBlock|
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3384
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3385
    searchString := self 
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3386
        askForSearchString:msg
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3387
        initialAnswer:initial
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3388
        directionInto:(directionHolder := ValueHolder new).
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3389
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3390
    searchString isNil ifTrue:[
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3391
        ^ cancelBlock value
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3392
    ].
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3393
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3394
    searchBlock := [:changeNr | searchBlock2 value:searchString value:changeNr].
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3395
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3396
    directionHolder value == #backward ifTrue:[
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3397
        changeNrShown isNil ifTrue:[
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3398
            changeNrShown := self numberOfChanges.
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3399
        ].
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3400
        self findPreviousForWhich:searchBlock
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3401
    ] ifFalse:[
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3402
        changeNrShown isNil ifTrue:[
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3403
            changeNrShown := 0.
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3404
        ].
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3405
        self findNextForWhich:searchBlock
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3406
    ].
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3407
!
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3408
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3409
askForSearchString:msg initialAnswer:initial directionInto:aValueHolder
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3410
    "common code to open a search box"
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3411
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3412
    |searchString direction|
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3413
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3414
    direction := #forward.
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3415
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3416
    Dialog aboutToOpenBoxNotificationSignal handle:[:ex |
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3417
        |box nextButton prevButton| 
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3418
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3419
        box := ex parameter.
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3420
        nextButton := box okButton.
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3421
        prevButton := Button label:(resources string:'Previous').
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3422
        prevButton action:[direction := #backward. box okPressed.].
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3423
        box addButton:prevButton after:nextButton.
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3424
        nextButton label:(resources string:'Next').
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3425
        ex proceed.
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3426
    ] do:[
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3427
        searchString := Dialog 
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3428
                request:msg 
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3429
                initialAnswer:initial
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3430
                onCancel:nil.
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3431
    ].
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3432
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3433
    searchString isNil ifTrue:[
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3434
        ^ nil
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3435
    ].
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3436
    aValueHolder value:direction.
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3437
    ^ searchString
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3438
!
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  3439
221
6c278b8ec6ca added autoUpdate
Claus Gittinger <cg@exept.de>
parents: 209
diff changeset
  3440
autoUpdate:aBoolean
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  3441
    "enabled/disable automatic update from the change-file (for monitoring)"
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  3442
221
6c278b8ec6ca added autoUpdate
Claus Gittinger <cg@exept.de>
parents: 209
diff changeset
  3443
    autoUpdate := aBoolean
6c278b8ec6ca added autoUpdate
Claus Gittinger <cg@exept.de>
parents: 209
diff changeset
  3444
6c278b8ec6ca added autoUpdate
Claus Gittinger <cg@exept.de>
parents: 209
diff changeset
  3445
    "Created: 3.12.1995 / 14:14:24 / cg"
6c278b8ec6ca added autoUpdate
Claus Gittinger <cg@exept.de>
parents: 209
diff changeset
  3446
    "Modified: 3.12.1995 / 14:20:45 / cg"
6c278b8ec6ca added autoUpdate
Claus Gittinger <cg@exept.de>
parents: 209
diff changeset
  3447
!
6c278b8ec6ca added autoUpdate
Claus Gittinger <cg@exept.de>
parents: 209
diff changeset
  3448
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3449
changeSelection:lineNrCollection
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
  3450
    "show a change in the codeView"
571fd5eee315 Initial revision
claus
parents:
diff changeset
  3451
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3452
    |aStream sawExcla chunk lineNr|
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3453
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3454
    lineNrCollection isInteger ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3455
        lineNr := lineNrCollection
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3456
    ] ifFalse:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3457
        changeListView multipleSelectOk ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3458
            lineNrCollection size == 1 ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3459
                lineNr := lineNrCollection first.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3460
            ]
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3461
        ] ifFalse:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3462
            lineNr := lineNrCollection
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3463
        ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3464
    ].
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
  3465
2293
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
  3466
    lineNr isNil ifTrue:[
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
  3467
        codeView contents:nil.
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
  3468
        codeView initializeDoITAction.
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3469
        changeNrShown := nil.
2293
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
  3470
        ^ self
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
  3471
    ].
6ba9a8ce2780 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2292
diff changeset
  3472
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3473
    "/ display the changes code
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
  3474
    aStream := self streamForChange:lineNr.
2044
34e663fcfe53 default doItAction
Claus Gittinger <cg@exept.de>
parents: 2043
diff changeset
  3475
    aStream isNil ifTrue:[
2093
Claus Gittinger <cg@exept.de>
parents: 2078
diff changeset
  3476
        codeView initializeDoITAction.
2044
34e663fcfe53 default doItAction
Claus Gittinger <cg@exept.de>
parents: 2043
diff changeset
  3477
        ^ self
34e663fcfe53 default doItAction
Claus Gittinger <cg@exept.de>
parents: 2043
diff changeset
  3478
    ].
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
  3479
    sawExcla := aStream peekFor:(aStream class chunkSeparator).
571fd5eee315 Initial revision
claus
parents:
diff changeset
  3480
    chunk := aStream nextChunk.
571fd5eee315 Initial revision
claus
parents:
diff changeset
  3481
    sawExcla ifTrue:[
2043
66b5276b2760 set self in changesBrowsers doIt.
Claus Gittinger <cg@exept.de>
parents: 1996
diff changeset
  3482
        chunk := aStream nextChunk
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
  3483
    ].
571fd5eee315 Initial revision
claus
parents:
diff changeset
  3484
    aStream close.
571fd5eee315 Initial revision
claus
parents:
diff changeset
  3485
    codeView contents:chunk.
13
145a9461122e *** empty log message ***
claus
parents: 6
diff changeset
  3486
    codeView acceptAction:[:theCode | self doApply "noChangesAllowed"].
2043
66b5276b2760 set self in changesBrowsers doIt.
Claus Gittinger <cg@exept.de>
parents: 1996
diff changeset
  3487
    codeView doItAction:[:theCode |
66b5276b2760 set self in changesBrowsers doIt.
Claus Gittinger <cg@exept.de>
parents: 1996
diff changeset
  3488
        |clsName cls|
66b5276b2760 set self in changesBrowsers doIt.
Claus Gittinger <cg@exept.de>
parents: 1996
diff changeset
  3489
66b5276b2760 set self in changesBrowsers doIt.
Claus Gittinger <cg@exept.de>
parents: 1996
diff changeset
  3490
        clsName := self classNameOfChange:lineNr.
3275
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3491
        clsName := clsName asSymbolIfInterned.
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3492
        clsName notNil ifTrue:[
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3493
            cls := Smalltalk at:clsName ifAbsent:nil.
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3494
        ].
2043
66b5276b2760 set self in changesBrowsers doIt.
Claus Gittinger <cg@exept.de>
parents: 1996
diff changeset
  3495
        Compiler 
66b5276b2760 set self in changesBrowsers doIt.
Claus Gittinger <cg@exept.de>
parents: 1996
diff changeset
  3496
            evaluate:theCode 
66b5276b2760 set self in changesBrowsers doIt.
Claus Gittinger <cg@exept.de>
parents: 1996
diff changeset
  3497
            in:nil 
66b5276b2760 set self in changesBrowsers doIt.
Claus Gittinger <cg@exept.de>
parents: 1996
diff changeset
  3498
            receiver:cls 
66b5276b2760 set self in changesBrowsers doIt.
Claus Gittinger <cg@exept.de>
parents: 1996
diff changeset
  3499
            notifying:self 
66b5276b2760 set self in changesBrowsers doIt.
Claus Gittinger <cg@exept.de>
parents: 1996
diff changeset
  3500
            logged:true 
66b5276b2760 set self in changesBrowsers doIt.
Claus Gittinger <cg@exept.de>
parents: 1996
diff changeset
  3501
            ifFail:nil 
66b5276b2760 set self in changesBrowsers doIt.
Claus Gittinger <cg@exept.de>
parents: 1996
diff changeset
  3502
    ].
15
7fc8fcef7bc6 *** empty log message ***
claus
parents: 13
diff changeset
  3503
    changeNrShown := lineNr.
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
  3504
2044
34e663fcfe53 default doItAction
Claus Gittinger <cg@exept.de>
parents: 2043
diff changeset
  3505
    "Modified: / 28.2.1999 / 15:26:46 / cg"
51
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  3506
!
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  3507
3275
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3508
classOfChange:changeNr
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3509
    |className cls isMeta|
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3510
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3511
    className := self fullClassNameOfChange:changeNr.
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3512
    className isNil ifTrue:[
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3513
        self warn:'Could not extract classname from change'.
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3514
        ^ nil
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3515
    ].
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3516
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3517
    isMeta := false.
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3518
    (className endsWith:' class') ifTrue:[
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3519
        className := className copyWithoutLast:6.
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3520
        isMeta := true.
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3521
    ].
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3522
    (cls := Smalltalk classNamed:className) isNil ifTrue:[
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3523
        self warn:('Class not found: ''' , className , '''').
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3524
        ^ nil
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3525
    ].
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3526
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3527
    isMeta ifTrue:[
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3528
        cls := cls class
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3529
    ].
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3530
    ^ cls
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3531
!
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3532
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3533
doApply
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3534
    "user wants a change to be applied"
45
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  3535
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3536
    self withSelectedChangesDo:[:changeNr |
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3537
        skipSignal := nil.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3538
        self applyChange:changeNr.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3539
        self autoSelect:(changeNr + 1)
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3540
    ]
45
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  3541
!
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  3542
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3543
doApplyAll
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3544
    "user wants all changes to be applied"
37
50f59bad66b1 *** empty log message ***
claus
parents: 33
diff changeset
  3545
294
a693bd6d7ae6 read cursor while reading
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
  3546
    self withExecuteCursorDo:[
1378
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
  3547
	|lastNr "{ Class: SmallInteger }" |
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
  3548
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
  3549
	self clearCodeView.
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
  3550
	skipSignal isNil ifTrue:[skipSignal := Signal new].
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
  3551
	lastNr := self numberOfChanges.
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
  3552
	1 to:lastNr do:[:changeNr |
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
  3553
	    changeListView setSelection:changeNr.
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
  3554
	    self applyChange:changeNr
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
  3555
	].
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
  3556
	self autoSelectLast
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3557
    ]
294
a693bd6d7ae6 read cursor while reading
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
  3558
975
41a41f54874d added findPrev (Alt-B) and findNext (Alt-F)
Claus Gittinger <cg@exept.de>
parents: 958
diff changeset
  3559
    "Modified: 21.1.1997 / 22:26:30 / cg"
37
50f59bad66b1 *** empty log message ***
claus
parents: 33
diff changeset
  3560
!
50f59bad66b1 *** empty log message ***
claus
parents: 33
diff changeset
  3561
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3562
doApplyClassRest
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3563
    "user wants all changes for this class from changeNr to be applied"
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3564
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3565
    self theSingleSelection isNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3566
        ^ self information:'Only possible if a single change is selected.'.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3567
    ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3568
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3569
    self withSelectedChangesDo:[:changeNr |
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3570
        |thisClassName classNameToApply lastChange
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3571
         lastNr "{ Class: SmallInteger }" |
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3572
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3573
        classNameToApply := self classNameOfChange:changeNr.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3574
        classNameToApply notNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3575
            self clearCodeView.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3576
            skipSignal isNil ifTrue:[skipSignal := Signal new].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3577
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3578
            lastNr := self numberOfChanges.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3579
            changeNr to:lastNr do:[:changeNr |
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3580
                thisClassName := self classNameOfChange:changeNr.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3581
                thisClassName = classNameToApply ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3582
                    changeListView setSelection:changeNr.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3583
                    self applyChange:changeNr.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3584
                    lastChange := changeNr
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3585
                ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3586
            ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3587
            self autoSelect:lastChange.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3588
        ]
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3589
    ]
562
8f772068fd1a #selection: now does a notification / #setSelection: does not
Claus Gittinger <cg@exept.de>
parents: 553
diff changeset
  3590
975
41a41f54874d added findPrev (Alt-B) and findNext (Alt-F)
Claus Gittinger <cg@exept.de>
parents: 958
diff changeset
  3591
    "Modified: 21.1.1997 / 22:26:04 / cg"
37
50f59bad66b1 *** empty log message ***
claus
parents: 33
diff changeset
  3592
!
50f59bad66b1 *** empty log message ***
claus
parents: 33
diff changeset
  3593
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3594
doApplyRest
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3595
    "user wants all changes from changeNr to be applied"
28
eea5a71a1e23 *** empty log message ***
claus
parents: 27
diff changeset
  3596
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3597
    self theSingleSelection isNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3598
        ^ self information:'Only possible if a single change is selected.'.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3599
    ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3600
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3601
    self withSelectedChangesDo:[:changeNr |
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3602
        |lastNr "{ Class: SmallInteger }" |
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3603
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3604
        self clearCodeView.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3605
        skipSignal isNil ifTrue:[skipSignal := Signal new].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3606
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3607
        lastNr := self numberOfChanges.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3608
        changeNr to:lastNr do:[:changeNr |
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3609
            changeListView setSelection:changeNr.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3610
            self applyChange:changeNr
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3611
        ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3612
        self autoSelect:self numberOfChanges.
37
50f59bad66b1 *** empty log message ***
claus
parents: 33
diff changeset
  3613
    ]
562
8f772068fd1a #selection: now does a notification / #setSelection: does not
Claus Gittinger <cg@exept.de>
parents: 553
diff changeset
  3614
975
41a41f54874d added findPrev (Alt-B) and findNext (Alt-F)
Claus Gittinger <cg@exept.de>
parents: 958
diff changeset
  3615
    "Modified: 21.1.1997 / 22:25:29 / cg"
37
50f59bad66b1 *** empty log message ***
claus
parents: 33
diff changeset
  3616
!
50f59bad66b1 *** empty log message ***
claus
parents: 33
diff changeset
  3617
45
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  3618
doBrowse
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  3619
    "user wants a browser on the class of a change"
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  3620
3275
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3621
    |changeNr cls|
45
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  3622
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3623
    (changeNr := self theSingleSelection) isNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3624
        ^ self information:'Only possible if a single change is selected.'.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3625
    ].
3275
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3626
    cls := self classOfChange:changeNr.
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3627
    cls notNil ifTrue:[
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3628
        UserPreferences systemBrowserClass 
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3629
            openInClass:cls 
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3630
            selector:(self selectorOfMethodChange:changeNr)
37
50f59bad66b1 *** empty log message ***
claus
parents: 33
diff changeset
  3631
    ]
3275
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3632
!
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3633
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3634
doBrowseImplementors
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3635
    "open an implementors-browser"
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3636
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3637
    |changeNr initial selector|
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3638
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3639
    (changeNr := self theSingleSelection) notNil ifTrue:[
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3640
        initial := self selectorOfMethodChange:changeNr.
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3641
    ].
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3642
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3643
    selector := Dialog 
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3644
                    request:'Selector to browse implementors of:'
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3645
                    initialAnswer:(initial ? '').
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3646
    selector size ~~ 0 ifTrue:[
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3647
        UserPreferences systemBrowserClass
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3648
            browseImplementorsOf:selector asSymbol.
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3649
    ]
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3650
!
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3651
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3652
doBrowseSenders
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3653
    "user wants a browser on the class of a change"
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3654
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3655
    |changeNr initial selector|
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3656
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3657
    (changeNr := self theSingleSelection) notNil ifTrue:[
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3658
        initial := self selectorOfMethodChange:changeNr.
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3659
    ].
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3660
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3661
    selector := Dialog 
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3662
                    request:'Selector to browse senders of:'
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3663
                    initialAnswer:(initial ? '').
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3664
    selector size ~~ 0 ifTrue:[
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3665
        UserPreferences systemBrowserClass
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3666
            browseAllCallsOn:selector asSymbol.
88c43d1cfc99 added browse-senders & browse implementors
Claus Gittinger <cg@exept.de>
parents: 3249
diff changeset
  3667
    ]
37
50f59bad66b1 *** empty log message ***
claus
parents: 33
diff changeset
  3668
!
50f59bad66b1 *** empty log message ***
claus
parents: 33
diff changeset
  3669
2541
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
  3670
doCheckinAndDeleteClassAll
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
  3671
    "first checkin the selected changes class then delete all changes
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
  3672
     for it."
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
  3673
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3674
    self theSingleSelection isNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3675
        ^ self information:'Only possible if a single change is selected.'.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3676
    ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3677
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3678
    self withSelectedChangesDo:[:changeNr |
2541
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
  3679
        | className class |
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
  3680
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
  3681
        className := self classNameOfChange:changeNr.
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
  3682
        className notNil ifTrue:[
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
  3683
            class := Smalltalk classNamed:className.
2683
e76575e4346f private className extraction
tm
parents: 2682
diff changeset
  3684
            class isNil ifTrue:[
2746
9e7fbd54013c *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2697
diff changeset
  3685
                self halt:'oops - no such class'.
2683
e76575e4346f private className extraction
tm
parents: 2682
diff changeset
  3686
            ].
2541
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
  3687
            class notNil ifTrue:[
2682
3f35115e39f1 care for private-class-checkin
tm
parents: 2664
diff changeset
  3688
                class isPrivate ifTrue:[
2867
0ce30d3c763f asText allBold -> allBold
Claus Gittinger <cg@exept.de>
parents: 2863
diff changeset
  3689
                    (self confirm:('This is a private class.\\CheckIn the owner ''%1'' and all of its private classes ?' bindWith:class owningClass name allBold) withCRs)
2682
3f35115e39f1 care for private-class-checkin
tm
parents: 2664
diff changeset
  3690
                    ifFalse:[^ self].
3f35115e39f1 care for private-class-checkin
tm
parents: 2664
diff changeset
  3691
                    (SourceCodeManagerUtilities checkinClass:class owningClass withLog:nil)
3f35115e39f1 care for private-class-checkin
tm
parents: 2664
diff changeset
  3692
                    ifTrue:[
3f35115e39f1 care for private-class-checkin
tm
parents: 2664
diff changeset
  3693
                        self doDeleteClassAndPrivateClassesAll
3f35115e39f1 care for private-class-checkin
tm
parents: 2664
diff changeset
  3694
                    ]
3f35115e39f1 care for private-class-checkin
tm
parents: 2664
diff changeset
  3695
                ] ifFalse:[
3f35115e39f1 care for private-class-checkin
tm
parents: 2664
diff changeset
  3696
                    (SourceCodeManagerUtilities checkinClass:class withLog:nil)
3f35115e39f1 care for private-class-checkin
tm
parents: 2664
diff changeset
  3697
                    ifTrue:[
3f35115e39f1 care for private-class-checkin
tm
parents: 2664
diff changeset
  3698
                        self doDeleteClassAll
3f35115e39f1 care for private-class-checkin
tm
parents: 2664
diff changeset
  3699
                    ]
2541
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
  3700
                ]
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
  3701
            ].
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
  3702
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
  3703
        ].
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
  3704
    ]
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
  3705
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
  3706
    "Modified: 6.9.1995 / 17:11:16 / claus"
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
  3707
!
f8b6ae881564 experimental: checkIn & deleteForClass added.
Claus Gittinger <cg@exept.de>
parents: 2527
diff changeset
  3708
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3709
doCompare
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3710
    "compare change with current system version
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3711
     - give a note in transcript"
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3712
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3713
    |changeNr|
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3714
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3715
    (changeNr := self theSingleSelection) isNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3716
        ^ self information:'Only possible if a single change is selected.'.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3717
    ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3718
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3719
    self withExecuteCursorDo:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3720
        self compareChange:changeNr
394
1d19a14fc96e show activity notifiactions
Claus Gittinger <cg@exept.de>
parents: 392
diff changeset
  3721
    ].
1d19a14fc96e show activity notifiactions
Claus Gittinger <cg@exept.de>
parents: 392
diff changeset
  3722
    self newLabel:''
294
a693bd6d7ae6 read cursor while reading
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
  3723
394
1d19a14fc96e show activity notifiactions
Claus Gittinger <cg@exept.de>
parents: 392
diff changeset
  3724
    "Modified: 24.2.1996 / 19:37:19 / cg"
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3725
!
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3726
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3727
doCompareAndCompress
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3728
    "remove all changes, which are equivalent to the current image version"
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3729
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3730
    |toDelete|
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3731
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3732
    toDelete := OrderedCollection new.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3733
    self withExecuteCursorDo:[
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3734
        1 to:self numberOfChanges do:[:changeNr |
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3735
            (self compareChange:changeNr showResult:false) == true ifTrue:[
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3736
                toDelete add:changeNr
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3737
            ]
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3738
        ].
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3739
    ].
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3740
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3741
    toDelete reverseDo:[:changeNr |
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3742
        self silentDeleteChange:changeNr.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3743
    ].
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3744
    self setChangeList.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3745
    "
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3746
     scroll back a bit, if we are left way behind the list
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3747
    "
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3748
    changeListView firstLineShown > self numberOfChanges ifTrue:[
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3749
        changeListView makeLineVisible:self numberOfChanges
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3750
    ].
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3751
    self clearCodeView.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3752
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3753
    self newLabel:''
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3754
!
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3755
45
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  3756
doCompress
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  3757
    "compress the change-set; this replaces multiple method-changes by the last 
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  3758
     (i.e. the most recent) change"
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  3759
1359
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3760
    self compressForClass:nil
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3761
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3762
    "Modified: / 29.10.1997 / 01:03:26 / cg"
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3763
!
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3764
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3765
doCompressClass
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3766
    "compress changes for the selected class.
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3767
     this replaces multiple method-changes by the last (i.e. the most recent) change."
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3768
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3769
    self theSingleSelection isNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3770
        ^ self information:'Only possible if a single change is selected.'.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3771
    ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3772
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3773
    self withSelectedChangesDo:[:changeNr |
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3774
        | classNameToCompress |
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3775
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3776
        classNameToCompress := self classNameOfChange:changeNr.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3777
        classNameToCompress notNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3778
            self compressForClass:classNameToCompress.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3779
        ]
1359
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3780
    ]
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3781
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3782
    "Created: / 29.10.1997 / 01:05:16 / cg"
17bc3051f5d7 added #compressForClass
Claus Gittinger <cg@exept.de>
parents: 1321
diff changeset
  3783
    "Modified: / 29.10.1997 / 01:06:22 / cg"
45
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  3784
!
950b84ba89e6 *** empty log message ***
claus
parents: 37
diff changeset
  3785
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3786
doDelete
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3787
    "delete currently selected change(s)"
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3788
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3789
    self withSelectedChangesReverseDo:[:changeNr |
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3790
        self deleteChange:changeNr.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3791
        self autoSelectOrEnd:changeNr
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3792
    ]
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3793
!
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3794
3249
b6509548b414 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3242
diff changeset
  3795
doDeleteAndSelectPrevious
b6509548b414 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3242
diff changeset
  3796
    "delete currently selected change(s)"
b6509548b414 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3242
diff changeset
  3797
b6509548b414 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3242
diff changeset
  3798
    self withSelectedChangesReverseDo:[:changeNr |
b6509548b414 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3242
diff changeset
  3799
        self deleteChange:changeNr.
b6509548b414 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3242
diff changeset
  3800
        self autoSelectOrEnd:changeNr-1
b6509548b414 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3242
diff changeset
  3801
    ]
b6509548b414 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3242
diff changeset
  3802
!
b6509548b414 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3242
diff changeset
  3803
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3804
doDeleteClassAll
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3805
    "delete all changes with same class as currently selected change"
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3806
3227
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3807
    |classNamesToDelete lastChangeNr overAllNumDeletedBefore|
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3808
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3809
    lastChangeNr := -1.
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3810
    classNamesToDelete := Set new.
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3811
    self withSelectedChangesDo:[:changeNr |
3227
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3812
        |classNameToDelete|
1428
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3813
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3814
        classNameToDelete := self classNameOfChange:changeNr.
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3815
        classNameToDelete notNil ifTrue:[
3227
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3816
            classNamesToDelete add:classNameToDelete.
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3817
        ].
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3818
        lastChangeNr := lastChangeNr max:changeNr.
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3819
    ].
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3820
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3821
    overAllNumDeletedBefore := 0.
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3822
    changeListView setSelection:nil.
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3823
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3824
    self withExecuteCursorDo:[
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3825
        classNamesToDelete do:[:classNameToDelete |
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3826
            |numDeletedBefore|
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3827
1428
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3828
            self silentDeleteChangesFor:classNameToDelete
3227
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3829
                                   from:lastChangeNr
1428
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3830
                                     to:(self numberOfChanges).
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3831
            numDeletedBefore := self 
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3832
                                   silentDeleteChangesFor:classNameToDelete
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3833
                                   from:1
3227
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3834
                                   to:(lastChangeNr-1).
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3835
            lastChangeNr := lastChangeNr - numDeletedBefore.
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3836
            overAllNumDeletedBefore := overAllNumDeletedBefore + numDeletedBefore.    
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3837
        ].
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3838
    ].
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3839
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3840
    self setChangeList. 
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  3841
    self autoSelectOrEnd:lastChangeNr
286
96d31200b0c1 added delete-for-class-from-beginning; ignore timestamps for fileOut/checkin/snapshot entries
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
  3842
1431
f4900d4f0c06 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1428
diff changeset
  3843
    "Created: / 13.12.1995 / 16:07:14 / cg"
f4900d4f0c06 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1428
diff changeset
  3844
    "Modified: / 28.1.1998 / 20:42:14 / cg"
286
96d31200b0c1 added delete-for-class-from-beginning; ignore timestamps for fileOut/checkin/snapshot entries
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
  3845
!
96d31200b0c1 added delete-for-class-from-beginning; ignore timestamps for fileOut/checkin/snapshot entries
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
  3846
2511
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3847
doDeleteClassAndPrivateClassesAll
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3848
    "delete all changes with same class and private classes
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3849
     as currently selected change"
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3850
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3851
    self theSingleSelection isNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3852
        ^ self information:'Only possible if a single change is selected.'.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3853
    ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3854
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3855
    self withSelectedChangesDo:[:changeNr |
2511
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3856
        |classNameToDelete numDeletedBefore|
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3857
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3858
        classNameToDelete := self ownerClassNameOfChange:changeNr.
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3859
        classNameToDelete notNil ifTrue:[
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3860
            changeListView setSelection:nil.
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3861
            self silentDeleteChangesForClassAndPrivateClasses:classNameToDelete
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3862
                                   from:changeNr
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3863
                                     to:(self numberOfChanges).
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3864
            numDeletedBefore := self 
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3865
                                   silentDeleteChangesForClassAndPrivateClasses:classNameToDelete
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3866
                                   from:1
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3867
                                   to:(changeNr-1).
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3868
            self setChangeList. 
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3869
            self autoSelectOrEnd:(changeNr - numDeletedBefore)
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3870
        ]
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3871
    ]
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3872
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3873
    "Created: / 13.12.1995 / 16:07:14 / cg"
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3874
    "Modified: / 28.1.1998 / 20:42:14 / cg"
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3875
!
57e9fd0ec5c5 added new menu action:
Claus Gittinger <cg@exept.de>
parents: 2477
diff changeset
  3876
286
96d31200b0c1 added delete-for-class-from-beginning; ignore timestamps for fileOut/checkin/snapshot entries
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
  3877
doDeleteClassFromBeginning
96d31200b0c1 added delete-for-class-from-beginning; ignore timestamps for fileOut/checkin/snapshot entries
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
  3878
    "delete changes with same class as currently selected change from the beginning
96d31200b0c1 added delete-for-class-from-beginning; ignore timestamps for fileOut/checkin/snapshot entries
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
  3879
     up to the selected change.
96d31200b0c1 added delete-for-class-from-beginning; ignore timestamps for fileOut/checkin/snapshot entries
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
  3880
     Useful to get rid of obsolete changes before a fileout or checkin entry."
96d31200b0c1 added delete-for-class-from-beginning; ignore timestamps for fileOut/checkin/snapshot entries
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
  3881
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3882
    self theSingleSelection isNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3883
        ^ self information:'Only possible if a single change is selected.'.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3884
    ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3885
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3886
    self withSelectedChangesDo:[:changeNr |
1428
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3887
        |classNameToDelete prevSelection numDeleted|
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3888
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3889
        classNameToDelete := self classNameOfChange:changeNr.
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3890
        classNameToDelete notNil ifTrue:[
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3891
            prevSelection := changeNr.
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3892
            changeListView setSelection:nil.
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3893
            numDeleted := self 
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3894
                                silentDeleteChangesFor:classNameToDelete 
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3895
                                from:1 
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3896
                                to:changeNr.
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3897
            self setChangeList.
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3898
            self autoSelectOrEnd:(changeNr + 1 - numDeleted)
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3899
        ]
180d03d00db4 fixed selection after deleting a bunch of changes
Claus Gittinger <cg@exept.de>
parents: 1427
diff changeset
  3900
    ].
286
96d31200b0c1 added delete-for-class-from-beginning; ignore timestamps for fileOut/checkin/snapshot entries
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
  3901
96d31200b0c1 added delete-for-class-from-beginning; ignore timestamps for fileOut/checkin/snapshot entries
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
  3902
    "Created: 13.12.1995 / 15:41:58 / cg"
562
8f772068fd1a #selection: now does a notification / #setSelection: does not
Claus Gittinger <cg@exept.de>
parents: 553
diff changeset
  3903
    "Modified: 25.5.1996 / 12:26:34 / cg"
51
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  3904
!
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  3905
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3906
doDeleteClassRest
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3907
    "delete rest of changes with same class as currently selected change"
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3908
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3909
    self theSingleSelection isNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3910
        ^ self information:'Only possible if a single change is selected.'.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3911
    ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3912
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3913
    self withSelectedChangesDo:[:changeNr |
1648
db1ca601ad8c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1625
diff changeset
  3914
        | classNameToDelete |
db1ca601ad8c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1625
diff changeset
  3915
db1ca601ad8c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1625
diff changeset
  3916
        classNameToDelete := self classNameOfChange:changeNr.
db1ca601ad8c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1625
diff changeset
  3917
        classNameToDelete notNil ifTrue:[
db1ca601ad8c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1625
diff changeset
  3918
            changeListView setSelection:nil.
db1ca601ad8c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1625
diff changeset
  3919
            self silentDeleteChangesFor:classNameToDelete 
db1ca601ad8c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1625
diff changeset
  3920
                                   from:changeNr
db1ca601ad8c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1625
diff changeset
  3921
                                     to:(self numberOfChanges).
db1ca601ad8c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1625
diff changeset
  3922
            self setChangeList.
db1ca601ad8c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1625
diff changeset
  3923
            self autoSelectOrEnd:changeNr
db1ca601ad8c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1625
diff changeset
  3924
        ]
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3925
    ]
562
8f772068fd1a #selection: now does a notification / #setSelection: does not
Claus Gittinger <cg@exept.de>
parents: 553
diff changeset
  3926
1648
db1ca601ad8c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1625
diff changeset
  3927
    "Modified: / 18.5.1998 / 14:25:07 / cg"
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3928
!
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3929
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3930
doDeleteRest
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3931
    "delete all changes from current to the end"
51
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  3932
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3933
    |changeNr|
51
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  3934
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3935
    (changeNr := self theSingleSelection) isNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3936
        ^ self information:'Only possible if a single change is selected.'.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3937
    ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3938
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3939
    self deleteChangesFrom:changeNr to:(self numberOfChanges).
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3940
    self clearCodeView.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3941
    self autoSelectOrEnd:changeNr-1
132
claus
parents: 126
diff changeset
  3942
!
claus
parents: 126
diff changeset
  3943
claus
parents: 126
diff changeset
  3944
doFileoutAndDeleteClassAll
claus
parents: 126
diff changeset
  3945
    "first fileOut the selected changes class then delete all changes
claus
parents: 126
diff changeset
  3946
     for it."
claus
parents: 126
diff changeset
  3947
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3948
    self theSingleSelection isNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3949
        ^ self information:'Only possible if a single change is selected.'.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3950
    ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3951
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3952
    self withSelectedChangesDo:[:changeNr |
2835
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3953
        | className class |
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3954
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3955
        className := self classNameOfChange:changeNr.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3956
        className notNil ifTrue:[
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3957
            class := Smalltalk classNamed:className.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3958
            class notNil ifTrue:[
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3959
                Class fileOutErrorSignal handle:[:ex |
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3960
                    self warn:('fileout failed: ' , ex description).
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3961
                ] do:[
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3962
                    class fileOut.
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3963
                    self doDeleteClassAll
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3964
                ].
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3965
            ].
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3966
e78ff6b04c84 added compare&compress
Claus Gittinger <cg@exept.de>
parents: 2834
diff changeset
  3967
        ].
132
claus
parents: 126
diff changeset
  3968
    ]
claus
parents: 126
diff changeset
  3969
claus
parents: 126
diff changeset
  3970
    "Modified: 6.9.1995 / 17:11:16 / claus"
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3971
!
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3972
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3973
doMakePatch
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3974
    "user wants a change to be made a patch
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3975
     - copy it over to the patches file"
89
43ca5e534f5e *** empty log message ***
claus
parents: 81
diff changeset
  3976
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3977
    self withSelectedChangesDo:[:changeNr |
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3978
        self makeChangeAPatch:changeNr.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3979
        self autoSelect:(changeNr + 1)
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3980
    ]
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3981
!
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3982
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3983
doMakePermanent
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3984
    "user wants a change to be made permanent
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3985
     - rewrite the source file where this change has to go"
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3986
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3987
    |yesNoBox|
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  3988
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3989
    (self theSingleSelection) isNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3990
        ^ self information:'Only possible if a single change is selected.'.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3991
    ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3992
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3993
    yesNoBox := YesNoBox new.
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3994
    yesNoBox title:(resources at:'Warning: this operation cannot be undone').
1378
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
  3995
    yesNoBox okText:(resources at:'continue') noText:(resources at:'abort').
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3996
    yesNoBox okAction:[   |changeNr|
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  3997
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3998
                          changeNr := self theSingleSelection.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  3999
                          changeNr notNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4000
                              self makeChangePermanent:changeNr.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4001
                              self autoSelect:(changeNr + 1)
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4002
                          ]
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4003
                      ].
917
72349fe1f8ee destroy box after use
Claus Gittinger <cg@exept.de>
parents: 911
diff changeset
  4004
    yesNoBox showAtPointer.
72349fe1f8ee destroy box after use
Claus Gittinger <cg@exept.de>
parents: 911
diff changeset
  4005
    yesNoBox destroy
72349fe1f8ee destroy box after use
Claus Gittinger <cg@exept.de>
parents: 911
diff changeset
  4006
72349fe1f8ee destroy box after use
Claus Gittinger <cg@exept.de>
parents: 911
diff changeset
  4007
    "Modified: 7.1.1997 / 23:03:33 / cg"
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  4008
!
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  4009
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4010
doSave
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4011
    "user wants a change to be appended to a file"
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  4012
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4013
    |fileName|
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4014
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4015
    self withSelectedChangesDo:[:changeNr |
1473
160652b05e38 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1472
diff changeset
  4016
        fileName := Dialog
160652b05e38 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1472
diff changeset
  4017
                        requestFileName:'append change to:'
2394
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4018
                        default:(lastSaveFileName ? '')
1473
160652b05e38 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1472
diff changeset
  4019
                        ok:'append'
160652b05e38 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1472
diff changeset
  4020
                        abort:'abort'
160652b05e38 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1472
diff changeset
  4021
                        pattern:'*.chg'.
160652b05e38 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1472
diff changeset
  4022
160652b05e38 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1472
diff changeset
  4023
        fileName notNil ifTrue:[
2394
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4024
            lastSaveFileName := fileName.
1473
160652b05e38 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1472
diff changeset
  4025
            self withCursor:(Cursor write) do:[
160652b05e38 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1472
diff changeset
  4026
                self appendChange:changeNr toFile:fileName.
160652b05e38 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1472
diff changeset
  4027
            ].
160652b05e38 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1472
diff changeset
  4028
            self autoSelect:(changeNr + 1)
160652b05e38 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1472
diff changeset
  4029
        ].
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4030
    ]
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  4031
!
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  4032
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4033
doSaveClass
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4034
    "user wants changes for some class from current to end to be appended to a file"
89
43ca5e534f5e *** empty log message ***
claus
parents: 81
diff changeset
  4035
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4036
    (self theSingleSelection) isNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4037
        ^ self information:'Only possible if a single change is selected.'.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4038
    ].
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4039
    self doSaveClassFrom:1
89
43ca5e534f5e *** empty log message ***
claus
parents: 81
diff changeset
  4040
!
43ca5e534f5e *** empty log message ***
claus
parents: 81
diff changeset
  4041
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4042
doSaveClassAll
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4043
    "user wants changes for some class from current to end to be appended to a file"
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  4044
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4045
    (self theSingleSelection) isNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4046
        ^ self information:'Only possible if a single change is selected.'.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4047
    ].
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4048
    self doSaveClassFrom:1
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4049
!
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4050
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4051
doSaveClassFrom:startNr
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4052
    "user wants changes from current to end to be appended to a file"
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4053
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4054
    |changeNr classNameToSave|
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  4055
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4056
    (changeNr := self theSingleSelection) isNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4057
        ^ self information:'Only possible if a single change is selected.'.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4058
    ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4059
    classNameToSave := self classNameOfChange:changeNr.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4060
    classNameToSave notNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4061
        self saveClass:classNameToSave from:startNr
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4062
    ]
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4063
!
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  4064
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4065
doSaveClassRest
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4066
    "user wants changes for some class from current to end to be appended to a file"
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  4067
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4068
    |changeNr|
132
claus
parents: 126
diff changeset
  4069
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4070
    (changeNr := self theSingleSelection) isNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4071
        ^ self information:'Only possible if a single change is selected.'.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4072
    ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4073
    self doSaveClassFrom:changeNr
81
b3b4d34c5ada *** empty log message ***
claus
parents: 77
diff changeset
  4074
!
b3b4d34c5ada *** empty log message ***
claus
parents: 77
diff changeset
  4075
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4076
doSaveRest
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4077
    "user wants changes from current to end to be appended to a file"
73
e332d9c71624 *** empty log message ***
claus
parents: 68
diff changeset
  4078
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4079
    |changeNr fileName|
51
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  4080
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4081
    (changeNr := self theSingleSelection) isNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4082
        ^ self information:'Only possible if a single change is selected.'.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4083
    ].
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4084
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4085
    fileName := Dialog
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4086
                    requestFileName:'append changes to:'
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4087
                    default:(lastSaveFileName ? '')
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4088
                    ok:'append'
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4089
                    abort:'abort'
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4090
                    pattern:'*.chg'.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4091
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4092
    fileName notNil ifTrue:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4093
        lastSaveFileName := fileName.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4094
        self withCursor:(Cursor write) do:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4095
            changeNr to:(self numberOfChanges) do:[:changeNr |
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4096
                changeListView setSelection:changeNr.
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4097
                (self appendChange:changeNr toFile:fileName) ifFalse:[
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4098
                    ^ self
2394
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4099
                ]
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4100
            ]
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4101
        ]
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4102
    ]
562
8f772068fd1a #selection: now does a notification / #setSelection: does not
Claus Gittinger <cg@exept.de>
parents: 553
diff changeset
  4103
8f772068fd1a #selection: now does a notification / #setSelection: does not
Claus Gittinger <cg@exept.de>
parents: 553
diff changeset
  4104
    "Modified: 25.5.1996 / 12:26:41 / cg"
51
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  4105
!
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  4106
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4107
doUpdate
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4108
    "reread the changes-file"
51
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  4109
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4110
    self readChangesFileInBackground:true.
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4111
    realized ifTrue:[
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4112
	self setChangeList.
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4113
    ]
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4114
51
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  4115
!
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  4116
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4117
doWriteBack
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4118
    "write back the list onto the changes file"
51
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  4119
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  4120
    anyChanges ifTrue:[
1378
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
  4121
	(self writeBackChanges) ifTrue:[
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
  4122
	    realized ifTrue:[
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
  4123
		self readChangesFileInBackground:false.
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
  4124
		realized ifTrue:[
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
  4125
		    self setChangeList
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
  4126
		]
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
  4127
	    ]
f7cf4cf1baf2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1368
diff changeset
  4128
	]
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4129
    ]
703
1b3b008d9f19 fixed to allow class-source files to be handled
Claus Gittinger <cg@exept.de>
parents: 627
diff changeset
  4130
1b3b008d9f19 fixed to allow class-source files to be handled
Claus Gittinger <cg@exept.de>
parents: 627
diff changeset
  4131
    "Modified: 5.9.1996 / 17:19:46 / cg"
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4132
!
126
claus
parents: 123
diff changeset
  4133
1471
f73ed23816d4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1470
diff changeset
  4134
doubleClickOnChange:lineNr
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4135
    "action performed when a change-list entry is doubleClicked"
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4136
1471
f73ed23816d4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1470
diff changeset
  4137
    self doBrowse
f73ed23816d4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1470
diff changeset
  4138
f73ed23816d4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1470
diff changeset
  4139
    "Created: / 6.2.1998 / 13:08:49 / cg"
f73ed23816d4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1470
diff changeset
  4140
!
f73ed23816d4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1470
diff changeset
  4141
1127
32383ecaebe4 added alt-S for search
Claus Gittinger <cg@exept.de>
parents: 1109
diff changeset
  4142
findClass
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4143
    "findClass menu action: let user enter a classes name, and select the next change for that class"
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4144
3292
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4145
    |current|
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4146
1127
32383ecaebe4 added alt-S for search
Claus Gittinger <cg@exept.de>
parents: 1109
diff changeset
  4147
    changeNrShown notNil ifTrue:[
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4148
        current := self classNameOfChange:changeNrShown.
1127
32383ecaebe4 added alt-S for search
Claus Gittinger <cg@exept.de>
parents: 1109
diff changeset
  4149
    ].
3292
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4150
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4151
    self 
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4152
        askForSearch:'Class to search for:'
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4153
        initialAnswer:current
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4154
        thenSearchUsing:[:searchString :changeNr |
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4155
                            |thisClass|
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4156
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4157
                            thisClass := self classNameOfChange:changeNr.
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4158
                            (thisClass = searchString 
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4159
                            or:[searchString includesMatchCharacters and:[searchString match:thisClass]]) 
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4160
                        ]
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4161
        onCancel:[^ self].
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4162
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4163
    lastSearchType := #class.
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4164
    changeNrShown == 0 ifTrue:[changeNrShown := nil].
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4165
!
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4166
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4167
findNext
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4168
    "findNext menu action: select the next change. 
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4169
     Searches for what the last search was for; i.e. either same class or same selector"
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4170
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4171
    lastSearchType == #selector ifTrue:[
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4172
        ^ self findNextForSelector
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4173
    ].
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4174
    lastSearchType == #snapshot ifTrue:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4175
        ^ self findNextSnapshot
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4176
    ].
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4177
    lastSearchType == #string ifTrue:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4178
        ^ self findNextForString
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4179
    ].
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4180
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4181
    ^ self findNextForClass
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4182
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4183
    "Created: / 18.6.1998 / 22:15:00 / cg"
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4184
    "Modified: / 18.6.1998 / 22:15:25 / cg"
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4185
!
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4186
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4187
findNextForClass
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4188
    "findNextForClass menu action: select the next change for the selected changes class"
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4189
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4190
    |cls|
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4191
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4192
    lastSearchType := #class.
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4193
    changeNrShown isNil ifTrue:[^ self].
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4194
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4195
    cls := self classNameOfChange:changeNrShown.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4196
    cls isNil ifTrue:[^ self].
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4197
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4198
    self findNextForWhich:
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4199
        [:changeNr | |thisClass|
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4200
                thisClass := self classNameOfChange:changeNr.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4201
                (thisClass = cls or:[cls includesMatchCharacters and:[cls match:thisClass]]) 
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4202
        ]
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4203
!
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4204
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4205
findNextForSelector
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4206
    "findNextForSelector menu action: select the next change for the selected changes selector"
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4207
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4208
    |sel|
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4209
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4210
    lastSearchType := #selector.
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4211
    changeNrShown isNil ifTrue:[^ self].
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4212
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4213
    sel := self selectorOfMethodChange:changeNrShown.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4214
    sel isNil ifTrue:[^ self].
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4215
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4216
    self findNextForWhich:
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4217
        [:changeNr | |thisSelector|
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4218
                thisSelector := self selectorOfMethodChange:changeNr.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4219
                (thisSelector = sel or:[sel includesMatchCharacters and:[sel match:thisSelector]]) 
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4220
        ]
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4221
!
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4222
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4223
findNextForString
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4224
    self findNextWithString:lastSearchString
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4225
!
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4226
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4227
findNextForWhich:aBlock
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4228
    "helper: select the next change for which aBlock evaluates to true"
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4229
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4230
    self withCursor:Cursor questionMark do:[
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4231
        Object userInterruptSignal handle:[:ex |
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4232
            self beep.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4233
            ^ 0
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4234
        ] do:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4235
            |lastNr nr|
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4236
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4237
            lastNr := self numberOfChanges.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4238
            nr := changeNrShown + 1.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4239
            [nr <= lastNr] whileTrue:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4240
                (aBlock value:nr) ifTrue:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4241
                    changeListView setSelection:nr .
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4242
                    self changeSelection:nr.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4243
                    ^ nr
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4244
                ].
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4245
                nr := nr + 1.
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4246
            ].
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4247
        ].
1127
32383ecaebe4 added alt-S for search
Claus Gittinger <cg@exept.de>
parents: 1109
diff changeset
  4248
    ].
2132
4b6c57b84a10 common code cleanup
Claus Gittinger <cg@exept.de>
parents: 2114
diff changeset
  4249
    self showNotFound.
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4250
    self windowGroup sensor flushKeyboard. "/ avoid multiple beeps, in case of type ahead
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4251
    ^ 0
1127
32383ecaebe4 added alt-S for search
Claus Gittinger <cg@exept.de>
parents: 1109
diff changeset
  4252
!
32383ecaebe4 added alt-S for search
Claus Gittinger <cg@exept.de>
parents: 1109
diff changeset
  4253
1848
61054ff3d470 added find prev/next snapshot to search menu
Claus Gittinger <cg@exept.de>
parents: 1833
diff changeset
  4254
findNextSnapshot
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4255
    "findNextSnapshot menu action: select the next change which is for a snapShot-image save action"
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4256
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4257
    lastSearchType := #snapshot.
1848
61054ff3d470 added find prev/next snapshot to search menu
Claus Gittinger <cg@exept.de>
parents: 1833
diff changeset
  4258
    changeNrShown isNil ifTrue:[^ self].
61054ff3d470 added find prev/next snapshot to search menu
Claus Gittinger <cg@exept.de>
parents: 1833
diff changeset
  4259
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4260
    self findNextForWhich: [:changeNr | self changeIsSnapShotInfo:changeNr ]
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4261
!
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4262
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4263
findNextWithString:searchString
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4264
    lastSearchType := #string.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4265
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4266
    lastSearchString := searchString.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4267
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4268
    changeNrShown isNil ifTrue:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4269
        changeNrShown := 0.
1848
61054ff3d470 added find prev/next snapshot to search menu
Claus Gittinger <cg@exept.de>
parents: 1833
diff changeset
  4270
    ].
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4271
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4272
    self findNextForWhich:
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4273
        [:changeNr |
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4274
            |s|
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4275
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4276
            s := self sourceOfMethodChange:changeNr.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4277
            s notNil and:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4278
                (searchString includesMatchCharacters not
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4279
                            and:[(s findString:searchString) ~~ 0])
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4280
                or:[ searchString includesMatchCharacters
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4281
                            and:[s match:('*' , searchString , '*')]]]
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4282
        ].
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4283
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4284
    changeNrShown == 0 ifTrue:[changeNrShown := nil].
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4285
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4286
    codeView setSearchPattern:searchString.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4287
    codeView 
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4288
        searchFwd:searchString
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4289
        ignoreCase:false 
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4290
        startingAtLine:1 col:0 
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4291
        ifAbsent:nil.
1848
61054ff3d470 added find prev/next snapshot to search menu
Claus Gittinger <cg@exept.de>
parents: 1833
diff changeset
  4292
!
61054ff3d470 added find prev/next snapshot to search menu
Claus Gittinger <cg@exept.de>
parents: 1833
diff changeset
  4293
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4294
findPrevious
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4295
    "findPrevious menu action: select the previous change. 
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4296
     Searches for what the last search was for; i.e. either same class or same selector"
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4297
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4298
    lastSearchType == #selector ifTrue:[
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4299
        ^ self findPreviousForSelector
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4300
    ].
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4301
    lastSearchType == #snapshot ifTrue:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4302
        ^ self findPreviousSnapshot
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4303
    ].
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4304
    lastSearchType == #string ifTrue:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4305
        ^ self findPreviousForString
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4306
    ].
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4307
    ^ self findPreviousForClass
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4308
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4309
    "Created: / 18.6.1998 / 22:15:15 / cg"
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4310
!
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4311
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4312
findPreviousForClass
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4313
    "findPreviousForClass menu action: select the previous change for the selected changes class"
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4314
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4315
    |cls|
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4316
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4317
    lastSearchType := #class.
975
41a41f54874d added findPrev (Alt-B) and findNext (Alt-F)
Claus Gittinger <cg@exept.de>
parents: 958
diff changeset
  4318
    changeNrShown isNil ifTrue:[^ self].
41a41f54874d added findPrev (Alt-B) and findNext (Alt-F)
Claus Gittinger <cg@exept.de>
parents: 958
diff changeset
  4319
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4320
    cls := self classNameOfChange:changeNrShown.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4321
    cls isNil ifTrue:[^ self].
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4322
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4323
    self findPreviousForWhich:
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4324
        [:changeNr | |thisClass|
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4325
                thisClass := self classNameOfChange:changeNr.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4326
                (thisClass = cls or:[cls includesMatchCharacters and:[cls match:thisClass]])
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4327
        ]
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4328
!
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4329
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4330
findPreviousForSelector
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4331
    "findPreviousForSelector menu action: select the previous change for the selected changes selector"
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4332
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4333
    |sel|
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4334
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4335
    lastSearchType := #selector.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4336
    changeNrShown isNil ifTrue:[^ self].
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4337
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4338
    sel := self selectorOfMethodChange:changeNrShown.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4339
    sel isNil ifTrue:[^ self].
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4340
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4341
    self findPreviousForWhich:
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4342
        [:changeNr | |thisSelector|
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4343
                thisSelector := self selectorOfMethodChange:changeNr.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4344
                (thisSelector = sel or:[sel includesMatchCharacters and:[sel match:thisSelector]]) 
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4345
        ]
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4346
!
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4347
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4348
findPreviousForString
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4349
    self findPreviousWithString:lastSearchString
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4350
!
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4351
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4352
findPreviousForWhich:aBlock
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4353
    "helper: select the previous change for which aBlock evaluates to true"
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4354
975
41a41f54874d added findPrev (Alt-B) and findNext (Alt-F)
Claus Gittinger <cg@exept.de>
parents: 958
diff changeset
  4355
    self withCursor:Cursor questionMark do:[
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4356
        Object userInterruptSignal handle:[:ex |
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4357
            self beep.
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4358
            ^ 0
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4359
        ] do:[
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4360
            |nr|
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4361
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4362
            nr := changeNrShown - 1.
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4363
            [nr >= 1] whileTrue:[
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4364
                (aBlock value:nr) ifTrue:[
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4365
                    changeListView setSelection:nr .
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4366
                    self changeSelection:nr.
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4367
                    ^ nr
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4368
                ].
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4369
                nr := nr - 1.
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4370
            ].
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4371
        ]
975
41a41f54874d added findPrev (Alt-B) and findNext (Alt-F)
Claus Gittinger <cg@exept.de>
parents: 958
diff changeset
  4372
    ].
2132
4b6c57b84a10 common code cleanup
Claus Gittinger <cg@exept.de>
parents: 2114
diff changeset
  4373
    self showNotFound.
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4374
    self windowGroup sensor flushKeyboard. "/ avoid multiple beeps, in case of type ahead
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4375
    ^ 0
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4376
!
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4377
1848
61054ff3d470 added find prev/next snapshot to search menu
Claus Gittinger <cg@exept.de>
parents: 1833
diff changeset
  4378
findPreviousSnapshot
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4379
    "findPreviousSnapshot menu action: select the previous change which is for a snapShot-image save action"
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4380
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4381
    lastSearchType := #snapshot.
1848
61054ff3d470 added find prev/next snapshot to search menu
Claus Gittinger <cg@exept.de>
parents: 1833
diff changeset
  4382
    changeNrShown isNil ifTrue:[^ self].
61054ff3d470 added find prev/next snapshot to search menu
Claus Gittinger <cg@exept.de>
parents: 1833
diff changeset
  4383
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4384
    self findPreviousForWhich: [:changeNr | self changeIsSnapShotInfo:changeNr ]
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4385
!
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4386
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4387
findPreviousWithString:searchString
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4388
    lastSearchType := #string.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4389
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4390
    lastSearchString := searchString.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4391
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4392
    changeNrShown isNil ifTrue:[
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4393
        changeNrShown := 0.
1848
61054ff3d470 added find prev/next snapshot to search menu
Claus Gittinger <cg@exept.de>
parents: 1833
diff changeset
  4394
    ].
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4395
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4396
    self findPreviousForWhich:
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4397
        [:changeNr |
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4398
            |s includesMatchCharacters|
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4399
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4400
            includesMatchCharacters := searchString includesMatchCharacters.
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4401
            s := self sourceOfMethodChange:changeNr.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4402
            s notNil and:[
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4403
                (includesMatchCharacters not and:[(s findString:searchString) ~~ 0])
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4404
                or:[includesMatchCharacters and:[s match:('*' , searchString , '*')]]]
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4405
        ].
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4406
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4407
    changeNrShown == 0 ifTrue:[changeNrShown := nil].
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4408
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4409
    codeView setSearchPattern:searchString.
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4410
    codeView 
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4411
        searchFwd:searchString
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4412
        ignoreCase:false 
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4413
        startingAtLine:1 col:0 
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4414
        ifAbsent:nil.
1848
61054ff3d470 added find prev/next snapshot to search menu
Claus Gittinger <cg@exept.de>
parents: 1833
diff changeset
  4415
!
61054ff3d470 added find prev/next snapshot to search menu
Claus Gittinger <cg@exept.de>
parents: 1833
diff changeset
  4416
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4417
findSelector
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4418
    "findSelector menu action: let user enter a selector, and select the next change for that selector"
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4419
3292
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4420
    |current|
1706
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4421
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4422
    changeNrShown notNil ifTrue:[
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4423
        current := self selectorOfMethodChange:changeNrShown.
dd888c645873 added more search functions and a control-menu.
Claus Gittinger <cg@exept.de>
parents: 1670
diff changeset
  4424
    ].
3292
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4425
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4426
    self 
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4427
        askForSearch:'Selector to search for:'
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4428
        initialAnswer:current
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4429
        thenSearchUsing:[:searchString :changeNr |
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4430
                            |thisSelector|
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4431
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4432
                            thisSelector := self selectorOfMethodChange:changeNr.
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4433
                            (thisSelector = searchString 
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4434
                            or:[searchString includesMatchCharacters and:[searchString match:thisSelector]]) 
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4435
                        ]
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4436
        onCancel:[^ self].
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4437
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4438
    lastSearchType := #selector.
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4439
    changeNrShown == 0 ifTrue:[changeNrShown := nil].
975
41a41f54874d added findPrev (Alt-B) and findNext (Alt-F)
Claus Gittinger <cg@exept.de>
parents: 958
diff changeset
  4440
!
41a41f54874d added findPrev (Alt-B) and findNext (Alt-F)
Claus Gittinger <cg@exept.de>
parents: 958
diff changeset
  4441
2576
b5f0d32b09d3 added string search (in methods code)
Claus Gittinger <cg@exept.de>
parents: 2573
diff changeset
  4442
findString
3292
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4443
    |searchString directionHolder|
2576
b5f0d32b09d3 added string search (in methods code)
Claus Gittinger <cg@exept.de>
parents: 2573
diff changeset
  4444
b5f0d32b09d3 added string search (in methods code)
Claus Gittinger <cg@exept.de>
parents: 2573
diff changeset
  4445
    lastSearchType := #string.
b5f0d32b09d3 added string search (in methods code)
Claus Gittinger <cg@exept.de>
parents: 2573
diff changeset
  4446
b5f0d32b09d3 added string search (in methods code)
Claus Gittinger <cg@exept.de>
parents: 2573
diff changeset
  4447
    searchString := codeView selection.
2843
6e3fc30cd41f commented; much better functionality
Claus Gittinger <cg@exept.de>
parents: 2838
diff changeset
  4448
    searchString size == 0 ifTrue:[searchString := lastSearchString].
3292
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4449
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4450
    searchString := self 
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4451
        askForSearchString:'String to search for:'
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4452
        initialAnswer:searchString
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4453
        directionInto:(directionHolder := ValueHolder new).
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4454
2576
b5f0d32b09d3 added string search (in methods code)
Claus Gittinger <cg@exept.de>
parents: 2573
diff changeset
  4455
    searchString isNil ifTrue:[
b5f0d32b09d3 added string search (in methods code)
Claus Gittinger <cg@exept.de>
parents: 2573
diff changeset
  4456
        ^ self
b5f0d32b09d3 added string search (in methods code)
Claus Gittinger <cg@exept.de>
parents: 2573
diff changeset
  4457
    ].
b5f0d32b09d3 added string search (in methods code)
Claus Gittinger <cg@exept.de>
parents: 2573
diff changeset
  4458
3292
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4459
    directionHolder value == #backward ifTrue:[
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4460
        self findPreviousWithString:searchString.
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4461
    ] ifFalse:[
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4462
        self findNextWithString:searchString.
7eca3bb7b8cb added previous buttons to searches
Claus Gittinger <cg@exept.de>
parents: 3275
diff changeset
  4463
    ]
2576
b5f0d32b09d3 added string search (in methods code)
Claus Gittinger <cg@exept.de>
parents: 2573
diff changeset
  4464
!
b5f0d32b09d3 added string search (in methods code)
Claus Gittinger <cg@exept.de>
parents: 2573
diff changeset
  4465
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4466
noChangesAllowed
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4467
    "show a warning that changes cannot be changed"
93
claus
parents: 92
diff changeset
  4468
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4469
    self warn:'Changes are not allowed to be changed.'
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
  4470
!
571fd5eee315 Initial revision
claus
parents:
diff changeset
  4471
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4472
saveClass:aClassName from:startNr
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4473
    "user wants changes from current to end to be appended to a file"
51
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  4474
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4475
    |changeNr fileName|
51
57c1ccc3d7e0 *** empty log message ***
claus
parents: 50
diff changeset
  4476
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4477
    changeNr := changeListView selection.
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4478
    changeNr notNil ifTrue:[
2394
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4479
        fileName := Dialog
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4480
                        requestFileName:'append changes for class to:'
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4481
                        default:(lastSaveFileName ? '')
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4482
                        ok:'append'
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4483
                        abort:'abort'
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4484
                        pattern:'*.chg'.
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4485
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4486
        fileName notNil ifTrue:[
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4487
            lastSaveFileName := fileName.
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4488
            self withCursor:(Cursor write) do:[
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4489
                startNr to:(self numberOfChanges) do:[:changeNr |
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4490
                    |thisClassName|
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4491
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4492
                    thisClassName := self classNameOfChange:changeNr.
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4493
                    thisClassName = aClassName ifTrue:[
3211
f603f235e5c4 multiple select
Claus Gittinger <cg@exept.de>
parents: 3205
diff changeset
  4494
                        self setSingleSelection:changeNr.
2394
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4495
                        (self appendChange:changeNr toFile:fileName) ifFalse:[
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4496
                            ^ self
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4497
                        ]
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4498
                    ]
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4499
                ]
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4500
            ]
0841cfed6ec5 fixed delete followed by save-change
Claus Gittinger <cg@exept.de>
parents: 2353
diff changeset
  4501
        ].
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4502
    ]
562
8f772068fd1a #selection: now does a notification / #setSelection: does not
Claus Gittinger <cg@exept.de>
parents: 553
diff changeset
  4503
8f772068fd1a #selection: now does a notification / #setSelection: does not
Claus Gittinger <cg@exept.de>
parents: 553
diff changeset
  4504
    "Modified: 25.5.1996 / 12:26:44 / cg"
3227
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4505
!
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4506
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4507
setEnforcedPackage
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4508
    |pkg listOfKnownPackages|
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4509
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4510
    listOfKnownPackages := Set new.
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4511
    Smalltalk allClassesDo:[:eachClass | 
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4512
                                |package|
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4513
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4514
                                package := eachClass package.
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4515
                                package size > 0 ifTrue:[
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4516
                                    listOfKnownPackages add:package
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4517
                                ]
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4518
                           ].
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4519
    listOfKnownPackages := listOfKnownPackages asOrderedCollection sort.
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4520
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4521
    pkg := Dialog 
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4522
                request:'When Applying, changes go into package:'
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4523
                initialAnswer:(enforcedPackage ? Class packageQuerySignal query)
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4524
                list:listOfKnownPackages.
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4525
    pkg size ~~ 0 ifTrue:[
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4526
        enforcedPackage := pkg
442696985817 deleteAllForClass - support multiple selection
Claus Gittinger <cg@exept.de>
parents: 3224
diff changeset
  4527
    ]
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4528
! !
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
  4529
761
5c2b46a38efa checkin from browser
Claus Gittinger <cg@exept.de>
parents: 744
diff changeset
  4530
!ChangesBrowser class methodsFor:'documentation'!
202
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4531
468378999911 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 183
diff changeset
  4532
version
3297
12b826adb7aa *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 3292
diff changeset
  4533
    ^ '$Header: /cvs/stx/stx/libtool/ChangesBrowser.st,v 1.233 2001-10-12 06:57:25 cg Exp $'
276
017219e571e4 more stuff for autoloaded classes
Claus Gittinger <cg@exept.de>
parents: 275
diff changeset
  4534
! !