NewChangesBrowser.st
author tz
Tue, 12 May 1998 17:59:35 +0200
changeset 1636 14e3ccc3e7c6
parent 1569 96d29b2efc76
child 1641 4c430e7eb617
permissions -rw-r--r--
use Workspace
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
     1
ToolApplicationModel subclass:#NewChangesBrowser
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
     2
	instanceVariableNames:'changes changeFileName skipSignal changeFileTimestamp
ffea21e237ed revised
tz
parents: 1545
diff changeset
     3
		autoUpdateBlock filterCompletionBlock editingClassSource modified'
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
     4
	classVariableNames:'AutoUpdate CompressSnapshotInfo CategoryColumn DeltaInfoColumn
1568
b37202441764 revised
tz
parents: 1556
diff changeset
     5
		TypeColumn TimeStampColumn PositionsColumn PrivateAsSeparate'
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
     6
	poolDictionaries:''
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
     7
	category:'Interface-Browsers'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
     8
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
     9
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    10
Object subclass:#Change
1568
b37202441764 revised
tz
parents: 1556
diff changeset
    11
	instanceVariableNames:'delta string type timeStamp category chunk lastPosition position
b37202441764 revised
tz
parents: 1556
diff changeset
    12
		className followUp'
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    13
	classVariableNames:''
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    14
	poolDictionaries:''
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    15
	privateIn:NewChangesBrowser
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    16
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    17
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    18
!NewChangesBrowser class methodsFor:'documentation'!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    19
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    20
documentation
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    21
"
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    22
    The future Changes Browser.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    23
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    24
    [start with:]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    25
        NewChangesBrowser open
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    26
        NewChangesBrowser openOnFile:aFileName
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    27
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    28
    [author:]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    29
        Thomas Zwick, eXept Software AG
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    30
"
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    31
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    32
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    33
! !
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    34
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    35
!NewChangesBrowser class methodsFor:'instance creation'!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    36
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    37
openOnFile:aFileName
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
    38
    "opens a Changes Browser with the changes of the aFileName"
ffea21e237ed revised
tz
parents: 1545
diff changeset
    39
ffea21e237ed revised
tz
parents: 1545
diff changeset
    40
    ^self new 
ffea21e237ed revised
tz
parents: 1545
diff changeset
    41
        changeFileName:aFileName;
ffea21e237ed revised
tz
parents: 1545
diff changeset
    42
        open
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    43
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    44
! !
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    45
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    46
!NewChangesBrowser class methodsFor:'accessing'!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    47
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    48
autoSelectNext
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
    49
    "returns true here, makes a Delete operation automatically
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    50
     select the next change"
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    51
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    52
    ^ true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    53
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    54
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    55
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    56
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    57
label
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
    58
    "returns my label"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    59
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    60
    ^'Changes Browser'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    61
! !
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    62
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    63
!NewChangesBrowser class methodsFor:'help specs'!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    64
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    65
helpSpec
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    66
    "This resource specification was automatically generated
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    67
     by the UIHelpTool of ST/X."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    68
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    69
    "Do not manually edit this!! If it is corrupted,
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    70
     the UIHelpTool may not be able to read the specification."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    71
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    72
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    73
     UIHelpTool openOnClass:NewChangesBrowser    
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    74
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    75
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    76
    <resource: #help>
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    77
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    78
    ^super helpSpec addPairsFrom:#(
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    79
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    80
#applyAll
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    81
'Apply all changes from the first one to the last made change.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    82
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    83
#applyForClassToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    84
'Apply all changes from the selected one up to the last made change affecting on the same class as the class of the selected change.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    85
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    86
#applyFromLastSnapshot
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    87
'Apply all changes from the last snapshot up to the last made change.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    88
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    89
#applyLine
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    90
'Apply the selected change.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    91
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    92
#applyToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    93
'Apply all changes from the selected one up to the last made change.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    94
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
    95
#deleteAll
ffea21e237ed revised
tz
parents: 1545
diff changeset
    96
'Deletes all changes from the first one to the last made change.'
ffea21e237ed revised
tz
parents: 1545
diff changeset
    97
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    98
#deleteCompress
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
    99
'Deletes all multiple changes but leaving the last one.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   100
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   101
#deleteCompressForClass
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   102
'Deletes all multiple changes affecting on the same class as the class of the selected change but leaving the last one.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   103
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   104
#deleteForClassToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   105
'Deletes all changes from the selected one up to the last made change affecting on the same class as the class of the selected change.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   106
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   107
#deleteLine
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   108
'Deletes the selected change from the list of changes.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   109
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   110
#deleteToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   111
'Deletes all changes from the selected one up to the last made change.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   112
1556
tz
parents: 1554
diff changeset
   113
#fileLoad
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   114
'Opens a dialog for selecting and loading another changes files.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   115
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   116
#fileReload
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   117
'Reloads the changes file (undo your modifications).'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   118
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   119
#fileSave
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   120
'Saves the list of changes into current changes file name.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   121
1556
tz
parents: 1554
diff changeset
   122
#filterField
tz
parents: 1554
diff changeset
   123
'Matching patterns filtering the changes (separate several patterns by spaces).'
tz
parents: 1554
diff changeset
   124
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   125
#settingsAutoUpdate
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   126
'Turns on/off whether the Changes Browser makes automatically an update after a change done while running.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   127
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   128
#settingsColumns
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   129
'Turns on/off whether columns  are shown by the table.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   130
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   131
#settingsColumnsCategory
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   132
'Turns on/off whether a column for the category of the change is shown by the table.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   133
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   134
#settingsColumnsDeltaInfo
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   135
'Turns on/off whether a column for the delta info of the change is shown by the table.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   136
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   137
#settingsColumnsPosition
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   138
'Turns on/off whether a column for the positions of the change in the change file is shown by the table.'
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   139
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   140
#settingsColumnsTimeStamp
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   141
'Turns on/off whether a column for the time stamp of the change is shown by the table.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   142
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   143
#settingsColumnsType
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   144
'Turns on/off whether a column for the type of the change is shown by the table.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   145
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
   146
#settingsPrivateAsSeparate
ffea21e237ed revised
tz
parents: 1545
diff changeset
   147
'Turns on/off that private classes are separately handled when applying, deleting, or compressing for a certain class.'
ffea21e237ed revised
tz
parents: 1545
diff changeset
   148
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   149
#testCompareWithCurrentVersion
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   150
'Opens a info dialog showing the compare results between the method code of the selected change with the current code.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   151
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   152
#testFindLastSnapshot
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   153
'Moves upwards the list of changes in order to find to the last made snapshot.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   154
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   155
#testFindNextSnapshot
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   156
'Moves downwards the list of changes in order to find to the next made snapshot.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   157
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   158
)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   159
! !
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   160
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   161
!NewChangesBrowser class methodsFor:'image specs'!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   162
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   163
applyFromLastSnapshotIcon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   164
    "This resource specification was automatically generated
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   165
     by the ImageEditor of ST/X."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   166
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   167
    "Do not manually edit this!! If it is corrupted,
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   168
     the ImageEditor may not be able to read the specification."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   169
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   170
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   171
     ImageEditor openOnClass:self andSelector:#applyFromLastSnapshotIcon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   172
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   173
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   174
    <resource: #image>
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   175
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   176
    ^Icon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   177
        constantNamed:#'NewChangesBrowser applyFromLastSnapshotIcon'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   178
        ifAbsentPut:[(Depth4Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@QDQ<@@@@@@@@@@AH"H@@@@@@@@@@@D"H @@@@@@@@@@@RH"@@@@@@@@@@@AH"H@@@@@@@@@@@@@@@@@@@@@@@@@<@@@@@@@@@@@@@@@@@@@@@@@;.;.; @@@@@@@@C.;.;.@@@@@@@@@@@@@@8@@N@@@@C?????C @@@N@@@O????<@@@8@@@@@@@@@C0@@@@8@@O????<O@@C @@@@?????0@@@@C @@@@@@@O@@@N@@@@DQDQDP<@C @@@@@_??DQ@@@@@@@@@A????D@@@@@@@@@DQDQDP@@@@C @@@@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 255 255 255 0 0 0 255 0 0 0 255 0 255 255 255 255 0 255 0 255 127 0 0 0 127 0 0 0 127 0 127 127 127 127 0 127 0 127 127 127 127 170 170 170]; mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@C<@@C<@@C<@@C<@@C<@@A<@@D@@?<@@?<@@?<LC?<\C?<\C?<8O?08O?10O?10??C ??[@??_@?<^@?<_@?<_@') ; yourself); yourself]!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   179
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   180
applyIcon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   181
    "This resource specification was automatically generated
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   182
     by the ImageEditor of ST/X."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   183
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   184
    "Do not manually edit this!! If it is corrupted,
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   185
     the ImageEditor may not be able to read the specification."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   186
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   187
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   188
     ImageEditor openOnClass:self andSelector:#applyIcon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   189
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   190
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   191
    <resource: #image>
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   192
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   193
    ^Icon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   194
        constantNamed:#'NewChangesBrowser applyIcon'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   195
        ifAbsentPut:[(Depth2Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'UUUUUUUPUUUUUUUPUUUUUUU[UUUUUUUPP@@@@@@QQUUUUUTPQUUUUUTVQ**UUUTPQUUUUUTPQUUUUUTXQ***UUTPQ**UUUTPQ*****TPQ***%UTPQ****)TPQUUUUUTPQUUUUUTUP@@@@@@PUUUUUUUPUUUUUUUPUUUUUUUPUUUUUUUP') ; colorMapFromArray:#[0 0 0 255 255 255 170 170 170 255 0 0]; mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@a') ; yourself); yourself]!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   196
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   197
applyToEndIcon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   198
    "This resource specification was automatically generated
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   199
     by the ImageEditor of ST/X."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   200
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   201
    "Do not manually edit this!! If it is corrupted,
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   202
     the ImageEditor may not be able to read the specification."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   203
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   204
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   205
     ImageEditor openOnClass:self andSelector:#applyToEndIcon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   206
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   207
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   208
    <resource: #image>
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   209
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   210
    ^Icon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   211
        constantNamed:#'NewChangesBrowser applyToEndIcon'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   212
        ifAbsentPut:[(Depth2Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@B** H@@@B** H@@@@@@ @@@@**( @@@@**(@J@@@@@H@@@@O??H@@@@O??@@@@@@@C@H@@C??3@@ @C??0@ @@@@@0@B@@UUT0B@K@UUT@@H@@@@D@H@CEUUDB@@JG?U@@@@MG?=@@@@@EUU@@B@@@@@@@@@H') ; colorMapFromArray:#[0 0 0 255 255 255 127 127 127 170 170 170]; mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@C?0@C?0@C?0@O?0@O?0@O?0@??@@??@@??LC?<\C?<\C?<8O?08O?10O?10??C ??[@??_@?<^@?<_@?<_@') ; yourself); yourself]!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   213
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   214
compressIcon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   215
    "This resource specification was automatically generated
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   216
     by the ImageEditor of ST/X."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   217
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   218
    "Do not manually edit this!! If it is corrupted,
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   219
     the ImageEditor may not be able to read the specification."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   220
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   221
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   222
     ImageEditor openOnClass:self andSelector:#compressIcon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   223
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   224
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   225
    <resource: #image>
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   226
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   227
    ^Icon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   228
        constantNamed:#'NewChangesBrowser compressIcon'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   229
        ifAbsentPut:[(Depth2Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@????<@@@:***(@@@8@@@8@@@8@@@8@@@@@@@8@@@@@@@8A@@@@@@8@@:**0@8HC**+@@8@@@@@@@8H@@@@@@8@@@@@@@8@@@@@@@8@@@@@@@8@@C????8@@C****(@@@@@@@@H@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@') ; colorMapFromArray:#[0 0 0 124 124 124 170 170 170 255 255 255]; mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@??0A??8A??8A??8A8A8G>A8@@A8G?98O?18_?!!8??A8@@A8G>A8@0A8C??8C??8C??8C??0@0@@D2@@G>@@D2@@') ; yourself); yourself]!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   230
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   231
deleteIcon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   232
    "This resource specification was automatically generated
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   233
     by the ImageEditor of ST/X."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   234
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   235
    "Do not manually edit this!! If it is corrupted,
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   236
     the ImageEditor may not be able to read the specification."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   237
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   238
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   239
     ImageEditor openOnClass:self andSelector:#deleteIcon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   240
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   241
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   242
    <resource: #image>
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   243
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   244
    ^Icon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   245
        constantNamed:#'NewChangesBrowser deleteIcon'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   246
        ifAbsentPut:[(Depth2Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@AUUUU@@OA??UU@@@AUUUU@@@AUUUU@B@A???U@H@A??5U@@@A???0@@@AUUUB@B@@@@@@@@@@@@@A@BK@@@@A_:@@@@@AO2G@@@@AL2@@@@@AL2C@@@@AL2@@@@@AL2@@@@@AL2H@@@@AL2@@@@@A\:@@@@@H_8 @@@@@@@H') ; colorMapFromArray:#[0 0 0 255 255 255 127 127 127 170 170 170]; mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'_?<@_?<@_?<P_?<P_?<X_?<X_?<H_? H_?O<_?XL@@_<@@_<@@_<@@_<@@_<@@_<@@_<@@_<@@_<@@_<@@_<@@G0') ; yourself); yourself]!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   247
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   248
deleteToEndIcon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   249
    "This resource specification was automatically generated
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   250
     by the ImageEditor of ST/X."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   251
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   252
    "Do not manually edit this!! If it is corrupted,
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   253
     the ImageEditor may not be able to read the specification."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   254
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   255
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   256
     ImageEditor openOnClass:self andSelector:#deleteToEndIcon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   257
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   258
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   259
    <resource: #image>
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   260
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   261
    ^Icon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   262
        constantNamed:#'NewChangesBrowser deleteToEndIcon'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   263
        ifAbsentPut:[(Depth2Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@B** @@O@B** @@@@@@@ @@@@??< @B@@??<@@H@@@@L@@@@EUUL@@@@G?U@B@B@G?=@@@@@EUU@A@BK@@@@A_:@@@@@AO2G@@@@AL2@@@@@AL2C@@@@AL2@@@@@AL2@@@@@AL2H@@@@AL2@@@@@A\:@@@@@H_8 @@@@@@@H') ; colorMapFromArray:#[0 0 0 255 255 255 127 127 127 170 170 170]; mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'C?0@C?0@C?0PO?0PO?0XO?0X??@H??@H??O<?<XL?<_<?<_<@@_<@@_<@@_<@@_<@@_<@@_<@@_<@@_<@@_<@@G0') ; yourself); yourself]!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   264
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   265
findLastSnapshotIcon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   266
    "This resource specification was automatically generated
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   267
     by the ImageEditor of ST/X."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   268
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   269
    "Do not manually edit this!! If it is corrupted,
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   270
     the ImageEditor may not be able to read the specification."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   271
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   272
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   273
     ImageEditor openOnClass:self andSelector:#findLastSnapshotIcon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   274
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   275
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   276
    <resource: #image>
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   277
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   278
    ^Icon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   279
        constantNamed:#'NewChangesBrowser findLastSnapshotIcon'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   280
        ifAbsentPut:[(Depth2Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@EUUUW@A@F***(@@@F***(@@@F***(@@@F***(@@@F***(@@@F***(@@@F***(@A@F***(@M@F***(@H@F***(@@@F***(@@@F***(@I@L@@@@@@@@@@@@@A@P@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@') ; colorMapFromArray:#[0 0 0 255 255 255 255 0 0 170 170 170]; mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'C??@C??@C??@C??@C??@C??@C??@C??@C??@C??@C??@C??@C??@C??B@@@B@C@B@G B@O0@@_8@@G @@G @@G @') ; yourself); yourself]!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   281
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   282
findNextSnapshotIcon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   283
    "This resource specification was automatically generated
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   284
     by the ImageEditor of ST/X."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   285
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   286
    "Do not manually edit this!! If it is corrupted,
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   287
     the ImageEditor may not be able to read the specification."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   288
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   289
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   290
     ImageEditor openOnClass:self andSelector:#findNextSnapshotIcon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   291
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   292
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   293
    <resource: #image>
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   294
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   295
    ^Icon
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   296
        constantNamed:#'NewChangesBrowser findNextSnapshotIcon'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   297
        ifAbsentPut:[(Depth2Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@DA@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@D@B@@@@@@@@@@@@@@@E@@@@@@@@@EUUUW@N@F***(@@@F***(@@@F***(@@@F***(@@@F***(@@@F***(@@@V***(@H@F***(@@@F***(@@@F***(@@@F***(@@@F***(@@@L@@@@@@') ; colorMapFromArray:#[0 0 0 255 255 255 255 0 0 170 170 170]; mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@G @@G @@G @@_8@@O0@@G @@C@@@@@@C??@C??@C??@C??@C??@C??BC??BC??BC??BC??@C??@C??@C??@C??@') ; yourself); yourself]! !
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   298
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   299
!NewChangesBrowser class methodsFor:'interface specs'!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   300
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   301
windowSpec
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   302
    "This resource specification was automatically generated
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   303
     by the UIPainter of ST/X."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   304
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   305
    "Do not manually edit this!! If it is corrupted,
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   306
     the UIPainter may not be able to read the specification."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   307
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   308
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   309
     UIPainter new openOnClass:NewChangesBrowser andSelector:#windowSpec
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   310
     NewChangesBrowser new openInterface:#windowSpec
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   311
     NewChangesBrowser open
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   312
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   313
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   314
    <resource: #canvas>
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   315
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   316
    ^
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   317
     
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   318
       #(#FullSpec
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   319
          #window: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   320
           #(#WindowSpec
1556
tz
parents: 1554
diff changeset
   321
              #name: 'Changes Browser'
1569
96d29b2efc76 revised
tz
parents: 1568
diff changeset
   322
              #layout: #(#LayoutFrame 51 0 149 0 550 0 548 0)
1556
tz
parents: 1554
diff changeset
   323
              #label: 'Changes Browser'
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   324
              #min: #(#Point 10 10)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   325
              #max: #(#Point 1152 900)
1569
96d29b2efc76 revised
tz
parents: 1568
diff changeset
   326
              #bounds: #(#Rectangle 51 149 551 549)
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   327
              #menu: #menu
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   328
              #usePreferredExtent: false
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   329
          )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   330
          #component: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   331
           #(#SpecCollection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   332
              #collection: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   333
               #(
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   334
                 #(#MenuPanelSpec
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   335
                    #name: 'menuToolbarView'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   336
                    #layout: #(#LayoutFrame 0 0.0 0 0 0 1.0 32 0)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   337
                    #menu: #menuToolbar
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   338
                    #style: #(#FontDescription #helvetica #medium #roman 10)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   339
                    #showSeparatingLines: true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   340
                )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   341
                 #(#VariableVerticalPanelSpec
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   342
                    #name: 'variableVerticalPanel1'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   343
                    #layout: #(#LayoutFrame 0 0.0 34 0 0 1.0 -26 1.0)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   344
                    #component: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   345
                     #(#SpecCollection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   346
                        #collection: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   347
                         #(
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   348
                           #(#ViewSpec
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   349
                              #name: 'Box1'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   350
                              #component: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   351
                               #(#SpecCollection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   352
                                  #collection: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   353
                                   #(
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   354
                                     #(#DataSetSpec
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   355
                                        #name: 'changesDataSetView'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   356
                                        #layout: #(#LayoutFrame 0 0.0 0 0.0 0 1.0 -28 1.0)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   357
                                        #model: #selectionOfChange
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   358
                                        #menu: #menuTable
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   359
                                        #hasHorizontalScrollBar: true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   360
                                        #hasVerticalScrollBar: true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   361
                                        #miniScrollerHorizontal: true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   362
                                        #dataList: #listOfChanges
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   363
                                        #useIndex: false
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   364
                                        #has3Dsepartors: true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   365
                                        #doubleClickSelector: #doBrowseClass
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   366
                                        #columnHolder: #listOfChangeColumns
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   367
                                        #valueChangeSelector: #changeSelected:
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   368
                                    )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   369
                                     #(#ViewSpec
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   370
                                        #name: 'Box2'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   371
                                        #layout: #(#LayoutFrame 0 0.0 -28 1 0 1.0 0 1.0)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   372
                                        #component: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   373
                                         #(#SpecCollection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   374
                                            #collection: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   375
                                             #(
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   376
                                               #(#LabelSpec
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   377
                                                  #name: 'filterLabel'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   378
                                                  #layout: #(#AlignmentOrigin 37 0 13 0.0 1 0.5)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   379
                                                  #label: 'Filter:'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   380
                                                  #style: #(#FontDescription #helvetica #medium #roman 10)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   381
                                                  #adjust: #left
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   382
                                              )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   383
                                               #(#InputFieldSpec
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   384
                                                  #name: 'filterField'
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   385
                                                  #layout: #(#LayoutFrame 41 0.0 3 0 250 0 25 0)
1556
tz
parents: 1554
diff changeset
   386
                                                  #activeHelpKey: #filterField
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   387
                                                  #model: #valueOfFilter
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   388
                                                  #immediateAccept: false
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   389
                                              )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   390
                                               #(#ProgressIndicatorSpec
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   391
                                                  #name: 'readProgressIndicator'
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   392
                                                  #layout: #(#LayoutFrame 41 0 3 0 250 0 25 0)
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   393
                                                  #model: #valueOfReadProgress
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   394
                                                  #foregroundColor: #(#Color 0.0 60.0 60.0)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   395
                                              )
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   396
                                               #(#ActionButtonSpec
b37202441764 revised
tz
parents: 1556
diff changeset
   397
                                                  #name: 'allButton'
b37202441764 revised
tz
parents: 1556
diff changeset
   398
                                                  #layout: #(#LayoutFrame 258 0.0 2 0.0 268 0 13 0)
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   399
                                                  #label: ' '
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   400
                                                  #model: #doFilter:
b37202441764 revised
tz
parents: 1556
diff changeset
   401
                                                  #actionValue: ''
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   402
                                              )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   403
                                               #(#LabelSpec
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   404
                                                  #name: 'allLabel'
b37202441764 revised
tz
parents: 1556
diff changeset
   405
                                                  #layout: #(#LayoutFrame 273 0 0 0.0 310 0 14 0)
b37202441764 revised
tz
parents: 1556
diff changeset
   406
                                                  #label: '= all'
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   407
                                                  #style: #(#FontDescription #helvetica #medium #roman 10)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   408
                                                  #adjust: #left
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   409
                                              )
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   410
                                               #(#ActionButtonSpec
b37202441764 revised
tz
parents: 1556
diff changeset
   411
                                                  #name: 'methodChangesButton'
b37202441764 revised
tz
parents: 1556
diff changeset
   412
                                                  #layout: #(#LayoutFrame 300 0.0 2 0.0 310 0 13 0)
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   413
                                                  #label: ' '
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   414
                                                  #backgroundColor: #(#Color 100.0 100.0 100.0)
b37202441764 revised
tz
parents: 1556
diff changeset
   415
                                                  #model: #doFilterType:
b37202441764 revised
tz
parents: 1556
diff changeset
   416
                                                  #actionValue: 'method'
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   417
                                              )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   418
                                               #(#LabelSpec
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   419
                                                  #name: 'methodChangesLabel'
b37202441764 revised
tz
parents: 1556
diff changeset
   420
                                                  #layout: #(#LayoutFrame 314 0 0 0.0 399 0 14 0)
b37202441764 revised
tz
parents: 1556
diff changeset
   421
                                                  #label: '= method changes'
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   422
                                                  #style: #(#FontDescription #helvetica #medium #roman 10)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   423
                                                  #adjust: #left
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   424
                                              )
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   425
                                               #(#ActionButtonSpec
b37202441764 revised
tz
parents: 1556
diff changeset
   426
                                                  #name: 'classChangesButton'
b37202441764 revised
tz
parents: 1556
diff changeset
   427
                                                  #layout: #(#LayoutFrame 408 0.0 2 0.0 418 0 13 0)
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   428
                                                  #label: ' '
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   429
                                                  #backgroundColor: #(#Color 50.0008 50.0008 50.0008)
b37202441764 revised
tz
parents: 1556
diff changeset
   430
                                                  #model: #doFilterType:
b37202441764 revised
tz
parents: 1556
diff changeset
   431
                                                  #actionValue: 'class'
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   432
                                              )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   433
                                               #(#LabelSpec
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   434
                                                  #name: 'classChangesLabel'
b37202441764 revised
tz
parents: 1556
diff changeset
   435
                                                  #layout: #(#LayoutFrame 423 0 0 0.0 501 0 14 0)
b37202441764 revised
tz
parents: 1556
diff changeset
   436
                                                  #label: '= class changes'
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   437
                                                  #style: #(#FontDescription #helvetica #medium #roman 10)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   438
                                                  #adjust: #left
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   439
                                              )
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   440
                                               #(#ActionButtonSpec
b37202441764 revised
tz
parents: 1556
diff changeset
   441
                                                  #name: 'snapshotButton'
b37202441764 revised
tz
parents: 1556
diff changeset
   442
                                                  #layout: #(#LayoutFrame 258 0.0 16 0.0 268 0 27 0)
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   443
                                                  #label: ' '
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   444
                                                  #backgroundColor: #(#Color 100.0 0.0 0.0)
b37202441764 revised
tz
parents: 1556
diff changeset
   445
                                                  #model: #doFilterType:
b37202441764 revised
tz
parents: 1556
diff changeset
   446
                                                  #actionValue: 'image'
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   447
                                              )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   448
                                               #(#LabelSpec
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   449
                                                  #name: 'snapshotLabel'
b37202441764 revised
tz
parents: 1556
diff changeset
   450
                                                  #layout: #(#LayoutFrame 273 0 14 0.0 337 0 28 0)
b37202441764 revised
tz
parents: 1556
diff changeset
   451
                                                  #label: '= snapshots'
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   452
                                                  #style: #(#FontDescription #helvetica #medium #roman 10)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   453
                                                  #adjust: #left
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   454
                                              )
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   455
                                               #(#ActionButtonSpec
b37202441764 revised
tz
parents: 1556
diff changeset
   456
                                                  #name: 'fileInButton'
b37202441764 revised
tz
parents: 1556
diff changeset
   457
                                                  #layout: #(#LayoutFrame 346 0.0 16 0.0 356 0 27 0)
b37202441764 revised
tz
parents: 1556
diff changeset
   458
                                                  #label: ' '
b37202441764 revised
tz
parents: 1556
diff changeset
   459
                                                  #backgroundColor: #(#Color 0.0 80.0 80.0)
b37202441764 revised
tz
parents: 1556
diff changeset
   460
                                                  #model: #doFilterFileIns
b37202441764 revised
tz
parents: 1556
diff changeset
   461
                                              )
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   462
                                               #(#LabelSpec
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   463
                                                  #name: 'fileInLabel'
b37202441764 revised
tz
parents: 1556
diff changeset
   464
                                                  #layout: #(#LayoutFrame 361 0 14 0.0 409 0 28 0)
1569
96d29b2efc76 revised
tz
parents: 1568
diff changeset
   465
                                                  #label: '= filings'
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   466
                                                  #style: #(#FontDescription #helvetica #medium #roman 10)
b37202441764 revised
tz
parents: 1556
diff changeset
   467
                                                  #adjust: #left
b37202441764 revised
tz
parents: 1556
diff changeset
   468
                                              )
b37202441764 revised
tz
parents: 1556
diff changeset
   469
                                               #(#ActionButtonSpec
b37202441764 revised
tz
parents: 1556
diff changeset
   470
                                                  #name: 'checkInButton'
b37202441764 revised
tz
parents: 1556
diff changeset
   471
                                                  #layout: #(#LayoutFrame 408 0.0 16 0.0 418 0 27 0)
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   472
                                                  #label: ' '
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   473
                                                  #backgroundColor: #(#Color 0.0 0.0 100.0)
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   474
                                                  #model: #doFilterCheckIns
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   475
                                              )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   476
                                               #(#LabelSpec
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   477
                                                  #name: 'checkInLabel'
b37202441764 revised
tz
parents: 1556
diff changeset
   478
                                                  #layout: #(#LayoutFrame 423 0 14 0.0 484 0 28 0)
b37202441764 revised
tz
parents: 1556
diff changeset
   479
                                                  #label: '= check ins'
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   480
                                                  #style: #(#FontDescription #helvetica #medium #roman 10)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   481
                                                  #adjust: #left
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   482
                                              )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   483
                                            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   484
                                        )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   485
                                    )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   486
                                  )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   487
                              )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   488
                          )
1636
14e3ccc3e7c6 use Workspace
tz
parents: 1569
diff changeset
   489
                           #(#WorkspaceSpec
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   490
                              #name: 'changeTextEditor'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   491
                              #model: #valueOfChangeText
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   492
                              #hasHorizontalScrollBar: true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   493
                              #hasVerticalScrollBar: true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   494
                              #miniScrollerHorizontal: true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   495
                              #isReadOnly: true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   496
                          )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   497
                        )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   498
                    )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   499
                    #handles: #(#Any 0.5 1.0)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   500
                )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   501
                 #(#UISubSpecification
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   502
                    #name: 'windowSpecForInfoBar'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   503
                    #layout: #(#LayoutFrame 0 0.0 -24 1 0 1.0 0 1.0)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   504
                    #majorKey: #ToolApplicationModel
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   505
                    #minorKey: #windowSpecForInfoBar
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   506
                )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   507
              )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   508
          )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   509
      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   510
! !
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   511
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   512
!NewChangesBrowser class methodsFor:'list specs'!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   513
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   514
specOfChangeColumns
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   515
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   516
^
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   517
#(
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   518
   #(#DataSetColumnSpec
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   519
      #rendererType: #rowSelector
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   520
      #backgroundSelector: #listColor
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   521
  )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   522
   #(#DataSetColumnSpec
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   523
      #label: 'Change'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   524
      #labelAlignment: #left
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   525
      #model: #string
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   526
      #canSelect: false
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   527
  )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   528
   #(#DataSetColumnSpec
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   529
      #label: 'Category'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   530
      #labelAlignment: #left
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   531
      #model: #category
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   532
      #canSelect: false
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   533
  )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   534
   #(#DataSetColumnSpec
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   535
      #label: 'Delta Info'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   536
      #labelAlignment: #left
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   537
      #model: #delta
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   538
      #canSelect: false
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   539
  )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   540
   #(#DataSetColumnSpec
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   541
      #label: 'Time Stamp'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   542
      #labelAlignment: #left
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   543
      #model: #timeStamp
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   544
      #canSelect: false
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   545
  )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   546
   #(#DataSetColumnSpec
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   547
      #label: 'Type'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   548
      #labelAlignment: #left
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   549
      #model: #type
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   550
      #canSelect: false
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   551
  )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   552
   #(#DataSetColumnSpec
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   553
      #label: 'Positions'
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   554
      #labelAlignment: #left
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   555
      #model: #positions
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   556
      #canSelect: false
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   557
  )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   558
)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   559
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   560
! !
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   561
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   562
!NewChangesBrowser class methodsFor:'menu specs'!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   563
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   564
menu
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   565
    "This resource specification was automatically generated
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   566
     by the MenuEditor of ST/X."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   567
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   568
    "Do not manually edit this!! If it is corrupted,
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   569
     the MenuEditor may not be able to read the specification."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   570
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   571
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   572
     MenuEditor new openOnClass:NewChangesBrowser andSelector:#menu
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   573
     (Menu new fromLiteralArrayEncoding:(NewChangesBrowser menu)) startUp
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   574
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   575
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   576
    <resource: #menu>
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   577
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   578
    ^
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   579
     
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   580
       #(#Menu
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   581
          
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   582
           #(
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   583
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   584
                #label: 'About'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   585
                #activeHelpKey: #about
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   586
                #labelImage: #(#ResourceRetriever nil #menuIcon)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   587
                #submenuChannel: #menuAbout
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   588
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   589
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   590
                #label: 'File'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   591
                #activeHelpKey: #file
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   592
                #submenu: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   593
                 #(#Menu
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   594
                    
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   595
                     #(
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   596
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   597
                          #label: 'Reload'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   598
                          #value: #doReload
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   599
                          #activeHelpKey: #fileReload
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   600
                          #enabled: #valueOfNotReading
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   601
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   602
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   603
                          #label: '-'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   604
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   605
                       #(#MenuItem
1556
tz
parents: 1554
diff changeset
   606
                          #label: 'Load...'
tz
parents: 1554
diff changeset
   607
                          #value: #doLoad
tz
parents: 1554
diff changeset
   608
                          #activeHelpKey: #fileLoad
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   609
                          #enabled: #valueOfNotSaving
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   610
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   611
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   612
                          #label: '-'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   613
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   614
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   615
                          #label: 'Save'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   616
                          #value: #doSave
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   617
                          #activeHelpKey: #fileSave
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   618
                          #enabled: #valueOfNotReading
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   619
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   620
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   621
                          #label: '-'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   622
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   623
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   624
                          #label: 'Browse Class'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   625
                          #value: #doBrowseClass
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   626
                          #activeHelpKey: #fileBrowseClass
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   627
                          #enabled: #valueOfHavingChangeSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   628
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   629
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   630
                          #label: '-'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   631
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   632
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   633
                          #label: 'Exit'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   634
                          #value: #closeRequest
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   635
                          #activeHelpKey: #fileExit
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   636
                          #enabled: #valueOfNotSaving
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   637
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   638
                    ) nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   639
                    nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   640
                )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   641
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   642
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   643
                #label: 'Apply'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   644
                #submenu: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   645
                 #(#Menu
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   646
                    
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   647
                     #(
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   648
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   649
                          #label: 'Line'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   650
                          #value: #doApply
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   651
                          #activeHelpKey: #applyLine
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   652
                          #enabled: #valueOfHavingChangeSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   653
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   654
                       #(#MenuItem
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
   655
                          #label: '-'
ffea21e237ed revised
tz
parents: 1545
diff changeset
   656
                      )
ffea21e237ed revised
tz
parents: 1545
diff changeset
   657
                       #(#MenuItem
ffea21e237ed revised
tz
parents: 1545
diff changeset
   658
                          #label: 'All'
ffea21e237ed revised
tz
parents: 1545
diff changeset
   659
                          #value: #doApplyAll
ffea21e237ed revised
tz
parents: 1545
diff changeset
   660
                          #activeHelpKey: #applyAll
ffea21e237ed revised
tz
parents: 1545
diff changeset
   661
                          #enabled: #valueOfNotReading
ffea21e237ed revised
tz
parents: 1545
diff changeset
   662
                      )
ffea21e237ed revised
tz
parents: 1545
diff changeset
   663
                       #(#MenuItem
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   664
                          #label: 'To End'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   665
                          #value: #doApplyToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   666
                          #activeHelpKey: #applyToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   667
                          #enabled: #valueOfHavingSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   668
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   669
                       #(#MenuItem
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
   670
                          #label: 'All For Class'
ffea21e237ed revised
tz
parents: 1545
diff changeset
   671
                          #value: #doApplyAllForClass
ffea21e237ed revised
tz
parents: 1545
diff changeset
   672
                          #activeHelpKey: #applyForClassToEnd
ffea21e237ed revised
tz
parents: 1545
diff changeset
   673
                          #enabled: #valueOfHavingChangeSelection
ffea21e237ed revised
tz
parents: 1545
diff changeset
   674
                      )
ffea21e237ed revised
tz
parents: 1545
diff changeset
   675
                       #(#MenuItem
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   676
                          #label: 'For Class To End'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   677
                          #value: #doApplyForClassToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   678
                          #activeHelpKey: #applyForClassToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   679
                          #enabled: #valueOfHavingChangeSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   680
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   681
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   682
                          #label: '-'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   683
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   684
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   685
                          #label: 'From Last Snapshot'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   686
                          #value: #doApplyFromLastSnapshot
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   687
                          #activeHelpKey: #applyFromLastSnapshot
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   688
                          #enabled: #valueOfNotReading
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   689
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   690
                    ) nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   691
                    nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   692
                )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   693
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   694
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   695
                #label: 'Delete'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   696
                #activeHelpKey: #edit
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   697
                #submenu: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   698
                 #(#Menu
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   699
                    
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   700
                     #(
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   701
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   702
                          #label: 'Line'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   703
                          #value: #doDelete
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   704
                          #activeHelpKey: #deleteLine
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   705
                          #enabled: #valueOfHavingSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   706
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   707
                       #(#MenuItem
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
   708
                          #label: '-'
ffea21e237ed revised
tz
parents: 1545
diff changeset
   709
                      )
ffea21e237ed revised
tz
parents: 1545
diff changeset
   710
                       #(#MenuItem
ffea21e237ed revised
tz
parents: 1545
diff changeset
   711
                          #label: 'All'
ffea21e237ed revised
tz
parents: 1545
diff changeset
   712
                          #value: #doDeleteAll
ffea21e237ed revised
tz
parents: 1545
diff changeset
   713
                          #activeHelpKey: #deleteAll
ffea21e237ed revised
tz
parents: 1545
diff changeset
   714
                          #enabled: #valueOfNotReading
ffea21e237ed revised
tz
parents: 1545
diff changeset
   715
                      )
ffea21e237ed revised
tz
parents: 1545
diff changeset
   716
                       #(#MenuItem
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   717
                          #label: 'To End'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   718
                          #value: #doDeleteToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   719
                          #activeHelpKey: #deleteToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   720
                          #enabled: #valueOfHavingSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   721
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   722
                       #(#MenuItem
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
   723
                          #label: 'All For Class'
ffea21e237ed revised
tz
parents: 1545
diff changeset
   724
                          #value: #doDeleteAllForClass
ffea21e237ed revised
tz
parents: 1545
diff changeset
   725
                          #activeHelpKey: #applyForClassToEnd
ffea21e237ed revised
tz
parents: 1545
diff changeset
   726
                          #enabled: #valueOfHavingChangeSelection
ffea21e237ed revised
tz
parents: 1545
diff changeset
   727
                      )
ffea21e237ed revised
tz
parents: 1545
diff changeset
   728
                       #(#MenuItem
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   729
                          #label: 'For Class To End'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   730
                          #value: #doDeleteForClassToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   731
                          #activeHelpKey: #deleteForClassToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   732
                          #enabled: #valueOfHavingChangeSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   733
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   734
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   735
                          #label: '-'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   736
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   737
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   738
                          #label: 'Compress'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   739
                          #value: #doCompress
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   740
                          #activeHelpKey: #deleteCompress
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   741
                          #enabled: #valueOfNotReading
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   742
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   743
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   744
                          #label: 'Compress For Class'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   745
                          #value: #doCompressForClass
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   746
                          #activeHelpKey: #deleteCompressForClass
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   747
                          #enabled: #valueOfHavingChangeSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   748
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   749
                    ) nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   750
                    nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   751
                )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   752
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   753
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   754
                #label: 'Test'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   755
                #activeHelpKey: #test
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   756
                #submenu: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   757
                 #(#Menu
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   758
                    
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   759
                     #(
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   760
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   761
                          #label: 'Find Last Snapshot'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   762
                          #value: #doFindSnapshot:
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   763
                          #activeHelpKey: #testFindLastSnapshot
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   764
                          #enabled: #valueOfHavingSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   765
                          #argument: 'last'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   766
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   767
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   768
                          #label: 'Find Next Snapshot'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   769
                          #value: #doFindSnapshot:
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   770
                          #activeHelpKey: #testFindNextSnapshot
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   771
                          #enabled: #valueOfHavingSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   772
                          #argument: 'next'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   773
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   774
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   775
                          #label: '-'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   776
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   777
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   778
                          #label: 'Compare With Current Version'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   779
                          #value: #doCompare
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   780
                          #activeHelpKey: #testCompareWithCurrentVersion
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   781
                          #enabled: #valueOfHavingChangeSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   782
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   783
                    ) nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   784
                    nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   785
                )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   786
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   787
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   788
                #label: 'Settings'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   789
                #activeHelpKey: #settings
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   790
                #submenu: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   791
                 #(#Menu
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   792
                    
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   793
                     #(
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   794
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   795
                          #label: 'Auto Update'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   796
                          #activeHelpKey: #settingsAutoUpdate
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   797
                          #enabled: #valueOfNotReading
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   798
                          #indication: #autoUpdateMode:
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   799
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   800
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   801
                          #label: '-'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   802
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   803
                       #(#MenuItem
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
   804
                          #label: 'Private As Separate'
ffea21e237ed revised
tz
parents: 1545
diff changeset
   805
                          #activeHelpKey: #settingsPrivateAsSeparate
ffea21e237ed revised
tz
parents: 1545
diff changeset
   806
                          #enabled: #valueOfNotReading
ffea21e237ed revised
tz
parents: 1545
diff changeset
   807
                          #indication: #privateAsSeparate:
ffea21e237ed revised
tz
parents: 1545
diff changeset
   808
                      )
ffea21e237ed revised
tz
parents: 1545
diff changeset
   809
                       #(#MenuItem
ffea21e237ed revised
tz
parents: 1545
diff changeset
   810
                          #label: '-'
ffea21e237ed revised
tz
parents: 1545
diff changeset
   811
                      )
ffea21e237ed revised
tz
parents: 1545
diff changeset
   812
                       #(#MenuItem
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   813
                          #label: 'Columns'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   814
                          #activeHelpKey: #settingsColumns
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   815
                          #submenu: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   816
                           #(#Menu
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   817
                              
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   818
                               #(
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   819
                                 #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   820
                                    #label: 'Category'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   821
                                    #activeHelpKey: #settingsColumnsCategory
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   822
                                    #indication: #categoryColumn:
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   823
                                )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   824
                                 #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   825
                                    #label: 'Delta Info'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   826
                                    #activeHelpKey: #settingsColumnsDeltaInfo
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   827
                                    #indication: #deltaInfoColumn:
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   828
                                )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   829
                                 #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   830
                                    #label: 'Type'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   831
                                    #activeHelpKey: #settingsColumnsType
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   832
                                    #indication: #typeColumn:
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   833
                                )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   834
                                 #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   835
                                    #label: 'Time Stamp'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   836
                                    #activeHelpKey: #settingsColumnsTimeStamp
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   837
                                    #indication: #timeStampColumn:
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   838
                                )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   839
                                 #(#MenuItem
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   840
                                    #label: 'Positions'
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   841
                                    #activeHelpKey: #settingsColumnsPosition
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   842
                                    #indication: #positionsColumn:
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   843
                                )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   844
                              ) nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   845
                              nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   846
                          )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   847
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   848
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   849
                          #label: '-'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   850
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   851
                       #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   852
                          #label: 'Fonts'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   853
                          #enabled: #valueOfNotReading
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   854
                          #submenuChannel: #menuFont
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   855
                      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   856
                    ) nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   857
                    nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   858
                )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   859
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   860
             #(#MenuItem
1568
b37202441764 revised
tz
parents: 1556
diff changeset
   861
                #label: 'History'
b37202441764 revised
tz
parents: 1556
diff changeset
   862
                #submenuChannel: #menuHistory
b37202441764 revised
tz
parents: 1556
diff changeset
   863
            )
b37202441764 revised
tz
parents: 1556
diff changeset
   864
             #(#MenuItem
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   865
                #label: 'Help'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   866
                #startGroup: #right
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   867
                #activeHelpKey: #help
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   868
                #submenuChannel: #menuHelp
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   869
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   870
          ) nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   871
          nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   872
      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   873
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   874
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   875
menuTable
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   876
    "This resource specification was automatically generated
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   877
     by the MenuEditor of ST/X."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   878
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   879
    "Do not manually edit this!! If it is corrupted,
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   880
     the MenuEditor may not be able to read the specification."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   881
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   882
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   883
     MenuEditor new openOnClass:NewChangesBrowser andSelector:#menuTable
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   884
     (Menu new fromLiteralArrayEncoding:(NewChangesBrowser menuTable)) startUp
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   885
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   886
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   887
    <resource: #menu>
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   888
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   889
    ^
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   890
     
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   891
       #(#Menu
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   892
          
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   893
           #(
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   894
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   895
                #label: 'Apply'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   896
                #value: #doApply
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   897
                #activeHelpKey: #applyLine
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   898
                #enabled: #valueOfHavingChangeSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   899
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   900
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   901
                #label: 'Apply To End'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   902
                #value: #doApplyToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   903
                #activeHelpKey: #applyToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   904
                #enabled: #valueOfHavingSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   905
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   906
             #(#MenuItem
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
   907
                #label: 'Apply All For Class'
ffea21e237ed revised
tz
parents: 1545
diff changeset
   908
                #value: #doApplyAllForClass
ffea21e237ed revised
tz
parents: 1545
diff changeset
   909
                #activeHelpKey: #applyForClassToEnd
ffea21e237ed revised
tz
parents: 1545
diff changeset
   910
                #enabled: #valueOfHavingChangeSelection
ffea21e237ed revised
tz
parents: 1545
diff changeset
   911
            )
ffea21e237ed revised
tz
parents: 1545
diff changeset
   912
             #(#MenuItem
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   913
                #label: 'Apply For Class To End'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   914
                #value: #doApplyForClassToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   915
                #activeHelpKey: #applyForClassToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   916
                #enabled: #valueOfHavingChangeSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   917
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   918
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   919
                #label: '-'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   920
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   921
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   922
                #label: 'Delete'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   923
                #value: #doDelete
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   924
                #activeHelpKey: #deleteLine
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   925
                #enabled: #valueOfHavingSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   926
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   927
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   928
                #label: 'Delete To End'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   929
                #value: #doDeleteToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   930
                #activeHelpKey: #deleteToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   931
                #enabled: #valueOfHavingSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   932
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   933
             #(#MenuItem
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
   934
                #label: 'Delete All For Class'
ffea21e237ed revised
tz
parents: 1545
diff changeset
   935
                #value: #doDeleteAllForClass
ffea21e237ed revised
tz
parents: 1545
diff changeset
   936
                #activeHelpKey: #applyForClassToEnd
ffea21e237ed revised
tz
parents: 1545
diff changeset
   937
                #enabled: #valueOfHavingChangeSelection
ffea21e237ed revised
tz
parents: 1545
diff changeset
   938
            )
ffea21e237ed revised
tz
parents: 1545
diff changeset
   939
             #(#MenuItem
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   940
                #label: 'Delete For Class To End'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   941
                #value: #doDeleteForClassToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   942
                #activeHelpKey: #deleteForClassToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   943
                #enabled: #valueOfHavingChangeSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   944
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   945
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   946
                #label: '-'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   947
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   948
             #(#MenuItem
1556
tz
parents: 1554
diff changeset
   949
                #label: 'Browse Class'
tz
parents: 1554
diff changeset
   950
                #value: #doBrowseClass
tz
parents: 1554
diff changeset
   951
                #activeHelpKey: #fileBrowseClass
tz
parents: 1554
diff changeset
   952
                #enabled: #valueOfHavingChangeSelection
tz
parents: 1554
diff changeset
   953
            )
tz
parents: 1554
diff changeset
   954
             #(#MenuItem
tz
parents: 1554
diff changeset
   955
                #label: '-'
tz
parents: 1554
diff changeset
   956
            )
tz
parents: 1554
diff changeset
   957
             #(#MenuItem
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   958
                #label: 'Compress For Class'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   959
                #value: #doCompressForClass
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   960
                #activeHelpKey: #deleteCompressForClass
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   961
                #enabled: #valueOfHavingChangeSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   962
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   963
          ) nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   964
          nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   965
      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   966
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   967
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   968
menuToolbar
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   969
    "This resource specification was automatically generated
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   970
     by the MenuEditor of ST/X."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   971
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   972
    "Do not manually edit this!! If it is corrupted,
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   973
     the MenuEditor may not be able to read the specification."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   974
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   975
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   976
     MenuEditor new openOnClass:NewChangesBrowser andSelector:#menuToolbar
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   977
     (Menu new fromLiteralArrayEncoding:(NewChangesBrowser menuToolbar)) startUp
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   978
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   979
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   980
    <resource: #menu>
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   981
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   982
    ^
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   983
     
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   984
       #(#Menu
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   985
          
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   986
           #(
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   987
             #(#MenuItem
1556
tz
parents: 1554
diff changeset
   988
                #label: 'Load'
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   989
                #isButton: true
1556
tz
parents: 1554
diff changeset
   990
                #value: #doLoad
tz
parents: 1554
diff changeset
   991
                #activeHelpKey: #fileLoad
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   992
                #enabled: #valueOfNotReading
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   993
                #labelImage: #(#ResourceRetriever nil #loadIcon)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   994
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   995
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   996
                #label: 'Save'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   997
                #isButton: true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   998
                #value: #doSave
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
   999
                #activeHelpKey: #fileSave
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  1000
                #enabled: #valueOfNotSaving
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1001
                #labelImage: #(#ResourceRetriever nil #saveIcon)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1002
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1003
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1004
                #label: ''
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1005
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1006
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1007
                #label: 'Compress'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1008
                #isButton: true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1009
                #value: #doCompress
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1010
                #activeHelpKey: #deleteCompress
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1011
                #enabled: #valueOfNotReading
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1012
                #labelImage: #(#ResourceRetriever nil #compressIcon)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1013
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1014
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1015
                #label: ''
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1016
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1017
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1018
                #label: 'Apply'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1019
                #isButton: true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1020
                #value: #doApply
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1021
                #activeHelpKey: #applyLine
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1022
                #enabled: #valueOfHavingChangeSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1023
                #labelImage: #(#ResourceRetriever nil #applyIcon)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1024
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1025
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1026
                #label: 'Apply To End'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1027
                #isButton: true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1028
                #value: #doApplyToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1029
                #activeHelpKey: #applyToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1030
                #enabled: #valueOfHavingSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1031
                #labelImage: #(#ResourceRetriever nil #applyToEndIcon)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1032
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1033
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1034
                #label: 'Apply From Last Snapshot'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1035
                #isButton: true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1036
                #value: #doApplyFromLastSnapshot
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1037
                #activeHelpKey: #applyFromLastSnapshot
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1038
                #enabled: #valueOfNotReading
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1039
                #labelImage: #(#ResourceRetriever nil #applyFromLastSnapshotIcon)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1040
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1041
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1042
                #label: ''
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1043
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1044
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1045
                #label: 'Delete'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1046
                #isButton: true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1047
                #value: #doDelete
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1048
                #activeHelpKey: #deleteLine
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1049
                #enabled: #valueOfHavingSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1050
                #labelImage: #(#ResourceRetriever nil #deleteIcon)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1051
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1052
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1053
                #label: 'Delete To End'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1054
                #isButton: true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1055
                #value: #doDeleteToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1056
                #activeHelpKey: #deleteToEnd
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1057
                #enabled: #valueOfHavingSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1058
                #labelImage: #(#ResourceRetriever nil #deleteToEndIcon)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1059
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1060
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1061
                #label: ''
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1062
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1063
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1064
                #label: 'Find Last Snapshot'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1065
                #isButton: true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1066
                #value: #doFindSnapshot:
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1067
                #activeHelpKey: #testFindLastSnapshot
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1068
                #enabled: #valueOfHavingSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1069
                #argument: 'last'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1070
                #labelImage: #(#ResourceRetriever nil #findLastSnapshotIcon)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1071
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1072
             #(#MenuItem
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1073
                #label: 'Find Next Snapshot'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1074
                #isButton: true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1075
                #value: #doFindSnapshot:
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1076
                #activeHelpKey: #testFindNextSnapshot
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1077
                #enabled: #valueOfHavingSelection
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1078
                #argument: 'next'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1079
                #labelImage: #(#ResourceRetriever nil #findNextSnapshotIcon)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1080
            )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1081
          ) nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1082
          nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1083
      )
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1084
! !
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1085
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1086
!NewChangesBrowser methodsFor:'accesssing - columns'!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1087
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1088
categoryColumn
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1089
    "returns whether the column for the category attribute of the changes is shown"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1090
1553
eaeafd6f8cbe checkin from browser
tz
parents: 1546
diff changeset
  1091
    ^CategoryColumn ? (CategoryColumn := false)
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1092
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1093
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1094
categoryColumn: aBoolean
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1095
    "sets whether the column for the category attribute of the changes is shown"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1096
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1097
    self changeColumn: 'Category' add: (CategoryColumn := aBoolean)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1098
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1099
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1100
deltaInfoColumn
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1101
    "returns whether the column for the delta info attribute of the changes is shown"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1102
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1103
    ^DeltaInfoColumn ? (DeltaInfoColumn := false)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1104
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1105
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1106
deltaInfoColumn: aBoolean
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1107
    "sets whether the column for the delta info attribute of the changes is shown; and updates"
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1108
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1109
    self changeColumn: 'Delta Info' add: (DeltaInfoColumn := aBoolean).
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1110
    (self window notNil and: [DeltaInfoColumn]) ifTrue: [self doReload]
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1111
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1112
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  1113
positionsColumn
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1114
    "returns whether the column for the position attribute of the changes is shown"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1115
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  1116
    ^PositionsColumn ? (PositionsColumn := false)
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1117
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1118
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  1119
positionsColumn: aBoolean
b37202441764 revised
tz
parents: 1556
diff changeset
  1120
    "sets whether the column for the positions attribute of the changes is shown"
b37202441764 revised
tz
parents: 1556
diff changeset
  1121
b37202441764 revised
tz
parents: 1556
diff changeset
  1122
    self changeColumn: 'Positions' add: (PositionsColumn := aBoolean)
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1123
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1124
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1125
timeStampColumn
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1126
    "returns whether the column for the time stamp attribute of the changes is shown"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1127
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1128
    ^TimeStampColumn ? (TimeStampColumn := false)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1129
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1130
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1131
timeStampColumn: aBoolean
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1132
    "sets whether the column for the time stamp attribute of the changes is shown"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1133
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1134
    self changeColumn: 'Time Stamp' add: (TimeStampColumn := aBoolean)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1135
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1136
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1137
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1138
typeColumn
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1139
    "returns whether the column for the type attribute of the changes is shown"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1140
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1141
    ^TypeColumn ? (TypeColumn := false)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1142
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1143
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1144
typeColumn: aBoolean
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1145
    "sets whether the column for the type attribute of the changes is shown"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1146
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1147
    self changeColumn: 'Type' add: (TypeColumn := aBoolean)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1148
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1149
! !
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1150
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1151
!NewChangesBrowser methodsFor:'accesssing - views'!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1152
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  1153
changeTextEditor
b37202441764 revised
tz
parents: 1556
diff changeset
  1154
    "returns the view of the changeTextEditor"
b37202441764 revised
tz
parents: 1556
diff changeset
  1155
b37202441764 revised
tz
parents: 1556
diff changeset
  1156
    ^builder componentAt: #changeTextEditor
b37202441764 revised
tz
parents: 1556
diff changeset
  1157
b37202441764 revised
tz
parents: 1556
diff changeset
  1158
b37202441764 revised
tz
parents: 1556
diff changeset
  1159
b37202441764 revised
tz
parents: 1556
diff changeset
  1160
!
b37202441764 revised
tz
parents: 1556
diff changeset
  1161
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1162
filterField
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1163
    "returns the view of the filterField"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1164
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1165
    ^builder componentAt: #filterField
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1166
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1167
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1168
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1169
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1170
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1171
filterLabel
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1172
    "returns the view of the filterLabel"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1173
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1174
    ^builder componentAt: #filterLabel
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1175
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1176
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1177
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1178
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1179
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1180
readProgressIndicator
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1181
    "returns the view of the readProgressIndicator"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1182
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1183
    ^builder componentAt: #readProgressIndicator
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1184
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1185
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1186
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1187
! !
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1188
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1189
!NewChangesBrowser methodsFor:'aspects'!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1190
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1191
listOfChangeColumns
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1192
    "initializes (during the startup) and returns the value holder for the columns"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1193
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1194
    |holder|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1195
    (holder := builder bindingAt:#listOfChangeColumns) isNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1196
        builder aspectAt:#listOfChangeColumns put:(holder := List new).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1197
        self changeColumn: nil add: true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1198
        self changeColumn: 'Change' add: true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1199
        self categoryColumn: self categoryColumn.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1200
        self timeStampColumn: self timeStampColumn.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1201
        self typeColumn: self typeColumn.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1202
        self deltaInfoColumn: self deltaInfoColumn.
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  1203
        self positionsColumn: self positionsColumn.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1204
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1205
    ^ holder
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1206
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1207
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1208
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1209
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1210
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1211
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1212
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1213
listOfChanges
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1214
    "returns the value holder for the changes"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1215
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1216
    |holder| 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1217
    (holder := builder bindingAt:#listOfChanges) isNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1218
        builder aspectAt:#listOfChanges put:(holder := List new)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1219
    ].   
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1220
    ^ holder
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1221
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1222
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1223
selectionOfChange
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1224
    "returns the value holder for the selected change"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1225
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1226
    |holder|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1227
    (holder := builder bindingAt:#selectionOfChange) isNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1228
        builder aspectAt:#selectionOfChange put:(holder :=  ValueHolder new).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1229
    ].                                           
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1230
    ^ holder
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1231
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1232
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1233
valueOfChangeText
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1234
    "returns the value holder for the source code of the selected change"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1235
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1236
    |holder|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1237
    (holder := builder bindingAt:#valueOfChangeText) isNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1238
        builder aspectAt:#valueOfChangeText put:(holder :=  ValueHolder new).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1239
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1240
    ^ holder
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1241
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1242
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1243
valueOfFilter
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1244
    "returns the value holder for the string of the filter"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1245
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1246
    |holder|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1247
    (holder := builder bindingAt:#valueOfFilter) isNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1248
        builder aspectAt:#valueOfFilter put:(holder :=  ValueHolder new).
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1249
        holder addDependent: self
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1250
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1251
    ^ holder
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1252
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1253
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1254
valueOfHavingChangeSelection
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1255
    "returns whether the selected change can be applied as value holder"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1256
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1257
    |holder|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1258
    (holder := builder bindingAt:#valueOfHavingChangeSelection) isNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1259
        builder aspectAt:#valueOfHavingChangeSelection put:(holder :=  false asValue).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1260
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1261
    ^ holder
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1262
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1263
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1264
valueOfHavingSelection
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1265
    "returns whether a change is selected as value holder"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1266
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1267
    |holder|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1268
    (holder := builder bindingAt:#valueOfHavingSelection) isNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1269
        builder aspectAt:#valueOfHavingSelection put:(holder :=  false asValue).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1270
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1271
    ^ holder
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1272
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1273
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1274
valueOfNotReading
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1275
    "returns whether it is not reading or compressing as value holder"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1276
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1277
    |holder|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1278
    (holder := builder bindingAt:#valueOfReading) isNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1279
        builder aspectAt:#valueOfReading put:(holder :=  true asValue).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1280
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1281
    ^ holder
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1282
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1283
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  1284
valueOfNotSaving
b37202441764 revised
tz
parents: 1556
diff changeset
  1285
    "returns whether it is not saving as value holder"
b37202441764 revised
tz
parents: 1556
diff changeset
  1286
b37202441764 revised
tz
parents: 1556
diff changeset
  1287
    |holder|
b37202441764 revised
tz
parents: 1556
diff changeset
  1288
    (holder := builder bindingAt:#valueOfNotSaving) isNil ifTrue:[
b37202441764 revised
tz
parents: 1556
diff changeset
  1289
        builder aspectAt:#valueOfNotSaving put:(holder :=  true asValue).
b37202441764 revised
tz
parents: 1556
diff changeset
  1290
    ].
b37202441764 revised
tz
parents: 1556
diff changeset
  1291
    ^ holder
b37202441764 revised
tz
parents: 1556
diff changeset
  1292
!
b37202441764 revised
tz
parents: 1556
diff changeset
  1293
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1294
valueOfReadProgress
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1295
    "returns the stage of reading or compressing as value holder"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1296
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1297
    |holder|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1298
    (holder := builder bindingAt:#valueOfReadProgress) isNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1299
        builder aspectAt:#valueOfReadProgress put:(holder :=  ValueHolder with: 0).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1300
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1301
    ^ holder
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1302
! !
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1303
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1304
!NewChangesBrowser methodsFor:'callbacks'!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1305
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1306
changeSelected: lineNr
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1307
    "fetches the source code of the change and shows it in the codeView"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1308
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1309
    |aStream sawExcla chunk selectedRow changeNr|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1310
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1311
    lineNr == 0 ifTrue: [^nil].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1312
    changeNr := changes indexOf: (self listOfChanges at: lineNr).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1313
    aStream := self streamForChange: (changes at: changeNr).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1314
    aStream isNil ifTrue:[^ self].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1315
    sawExcla := aStream peekFor:(aStream class chunkSeparator).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1316
    chunk := aStream nextChunk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1317
    sawExcla ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1318
        chunk := aStream nextChunk
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1319
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1320
    aStream close.        
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1321
    self valueOfChangeText value:chunk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1322
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1323
    self updateChannels
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1324
! !
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1325
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1326
!NewChangesBrowser methodsFor:'change & update'!
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1327
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1328
update:something with:aParameter from:changedObject
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1329
    "evaluates the filterCompletionBlock after returning the filter string"
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1330
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1331
    super update:something with:aParameter from:changedObject.
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1332
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1333
    changedObject == self valueOfFilter 
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  1334
    ifTrue: 
1636
14e3ccc3e7c6 use Workspace
tz
parents: 1569
diff changeset
  1335
    [                           
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  1336
        filterCompletionBlock value: changedObject value. 
b37202441764 revised
tz
parents: 1556
diff changeset
  1337
        self listOfChanges size > 0 ifTrue: [self addToHistory: changedObject value -> #doFilter:] 
b37202441764 revised
tz
parents: 1556
diff changeset
  1338
    ]
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1339
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1340
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1341
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1342
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1343
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1344
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1345
!
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1346
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1347
updateChannels
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1348
    "updates my channels"
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1349
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1350
    |change|           
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1351
    (change := self selectionOfChange value) notNil
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1352
    ifTrue:
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1353
    [
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1354
        self valueOfHavingSelection value: true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1355
        self valueOfHavingChangeSelection value: 
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1356
            ((change type = 'method') or: [(change type = 'class')])
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1357
    ]
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1358
    ifFalse:
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1359
    [
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1360
        self valueOfHavingSelection value: false.
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1361
        self valueOfHavingChangeSelection value: false
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1362
    ]
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1363
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1364
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1365
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1366
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1367
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1368
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1369
! !
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1370
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1371
!NewChangesBrowser methodsFor:'compiler interface'!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1372
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1373
wantChangeLog
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1374
    "sent by the compiler to ask if a changeLog entry should
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1375
     be written. Return false here."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1376
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1377
    ^ false
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1378
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1379
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1380
! !
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1381
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  1382
!NewChangesBrowser methodsFor:'error handling'!
b37202441764 revised
tz
parents: 1556
diff changeset
  1383
b37202441764 revised
tz
parents: 1556
diff changeset
  1384
correctableError:aString position:relPos to:relEndPos from:aCompiler
b37202441764 revised
tz
parents: 1556
diff changeset
  1385
    "compiler notifys us of an error - this should really not happen since
b37202441764 revised
tz
parents: 1556
diff changeset
  1386
     changes ought to be correct (did someone edit the changes file ??).
b37202441764 revised
tz
parents: 1556
diff changeset
  1387
     Show the bad change in the codeView and let codeView hilight the error;
b37202441764 revised
tz
parents: 1556
diff changeset
  1388
     no corrections allowed here therefore return false"
b37202441764 revised
tz
parents: 1556
diff changeset
  1389
b37202441764 revised
tz
parents: 1556
diff changeset
  1390
    self error:aString position:relPos to:relEndPos from:aCompiler.
b37202441764 revised
tz
parents: 1556
diff changeset
  1391
    ^ false
b37202441764 revised
tz
parents: 1556
diff changeset
  1392
!
b37202441764 revised
tz
parents: 1556
diff changeset
  1393
b37202441764 revised
tz
parents: 1556
diff changeset
  1394
error:aString position:relPos to:relEndPos from:aCompiler
b37202441764 revised
tz
parents: 1556
diff changeset
  1395
    "compiler notifys us of an error - this should really not happen since
b37202441764 revised
tz
parents: 1556
diff changeset
  1396
     changes ought to be correct (did someone edit the changes file ??).
b37202441764 revised
tz
parents: 1556
diff changeset
  1397
     Show the bad change in the codeView and let codeView hilight the error"
b37202441764 revised
tz
parents: 1556
diff changeset
  1398
b37202441764 revised
tz
parents: 1556
diff changeset
  1399
    |action|
b37202441764 revised
tz
parents: 1556
diff changeset
  1400
b37202441764 revised
tz
parents: 1556
diff changeset
  1401
    (skipSignal notNil) ifTrue:[
b37202441764 revised
tz
parents: 1556
diff changeset
  1402
b37202441764 revised
tz
parents: 1556
diff changeset
  1403
        self changeTextEditor highlightingErrorPosition:relPos to:relEndPos do:[
b37202441764 revised
tz
parents: 1556
diff changeset
  1404
            |box|
b37202441764 revised
tz
parents: 1556
diff changeset
  1405
b37202441764 revised
tz
parents: 1556
diff changeset
  1406
            "
b37202441764 revised
tz
parents: 1556
diff changeset
  1407
             start dialog - make certain cleanup is done
b37202441764 revised
tz
parents: 1556
diff changeset
  1408
            "
b37202441764 revised
tz
parents: 1556
diff changeset
  1409
            action := OptionBox 
b37202441764 revised
tz
parents: 1556
diff changeset
  1410
                          request:aString
b37202441764 revised
tz
parents: 1556
diff changeset
  1411
                          label:'Error'
b37202441764 revised
tz
parents: 1556
diff changeset
  1412
                          form:(WarningBox iconBitmap)
b37202441764 revised
tz
parents: 1556
diff changeset
  1413
                          buttonLabels:#('cancel' 'skip' 'continue')
b37202441764 revised
tz
parents: 1556
diff changeset
  1414
                          values:#(#abort #skip #continue)
b37202441764 revised
tz
parents: 1556
diff changeset
  1415
                          default:#continue.
b37202441764 revised
tz
parents: 1556
diff changeset
  1416
        ].
b37202441764 revised
tz
parents: 1556
diff changeset
  1417
b37202441764 revised
tz
parents: 1556
diff changeset
  1418
        action == #abort ifTrue:[
b37202441764 revised
tz
parents: 1556
diff changeset
  1419
            Object abortSignal raise.
b37202441764 revised
tz
parents: 1556
diff changeset
  1420
            ^ false
b37202441764 revised
tz
parents: 1556
diff changeset
  1421
        ].
b37202441764 revised
tz
parents: 1556
diff changeset
  1422
        action == #skip ifTrue:[
b37202441764 revised
tz
parents: 1556
diff changeset
  1423
            skipSignal raise.
b37202441764 revised
tz
parents: 1556
diff changeset
  1424
            ^ false
b37202441764 revised
tz
parents: 1556
diff changeset
  1425
        ].
b37202441764 revised
tz
parents: 1556
diff changeset
  1426
        ^  false 
b37202441764 revised
tz
parents: 1556
diff changeset
  1427
    ].
b37202441764 revised
tz
parents: 1556
diff changeset
  1428
    ^self changeTextEditor error:aString position:relPos to:relEndPos from:aCompiler
b37202441764 revised
tz
parents: 1556
diff changeset
  1429
b37202441764 revised
tz
parents: 1556
diff changeset
  1430
!
b37202441764 revised
tz
parents: 1556
diff changeset
  1431
b37202441764 revised
tz
parents: 1556
diff changeset
  1432
warning:aString position:relPos to:relEndPos from:aCompiler
b37202441764 revised
tz
parents: 1556
diff changeset
  1433
    "compiler notifys us of a warning - ignore it"
b37202441764 revised
tz
parents: 1556
diff changeset
  1434
b37202441764 revised
tz
parents: 1556
diff changeset
  1435
    ^ self
b37202441764 revised
tz
parents: 1556
diff changeset
  1436
b37202441764 revised
tz
parents: 1556
diff changeset
  1437
! !
b37202441764 revised
tz
parents: 1556
diff changeset
  1438
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1439
!NewChangesBrowser methodsFor:'help'!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1440
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1441
defaultInfoLabel
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1442
    "returns the default label for the info bar"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1443
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1444
    changeFileName asFilename exists ifTrue: [^changeFileName].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1445
    ^'No change file name defined.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1446
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1447
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1448
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1449
! !
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1450
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1451
!NewChangesBrowser methodsFor:'initialization'!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1452
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1453
initialize
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1454
    "initializes the instance variables"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1455
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1456
    super initialize.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1457
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1458
    changes           := List new.
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1459
    self changeFileName: ObjectMemory nameForChanges. 
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1460
    AutoUpdate        := AutoUpdate ? false.                                     
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1461
    PrivateAsSeparate := PrivateAsSeparate ? false.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1462
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1463
    ObjectMemory addDependent:self.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1464
! !
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1465
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1466
!NewChangesBrowser methodsFor:'menu modes'!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1467
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1468
autoUpdateMode
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1469
    "returns whether autoUpdate is on/off"
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1470
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1471
    ^AutoUpdate
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1472
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1473
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1474
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1475
autoUpdateMode: aMode
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1476
    "sets the autoUpdate to aMode"
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1477
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1478
    AutoUpdate := aMode
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1479
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1480
!
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1481
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1482
privateAsSeparate
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1483
    "returns whether private classes are handled as separate changes"
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1484
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1485
    ^PrivateAsSeparate
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1486
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1487
!
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1488
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1489
privateAsSeparate: aMode
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1490
    "sets the PrivateAsSeparate to aMode"
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1491
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1492
    PrivateAsSeparate := aMode
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1493
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1494
! !
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1495
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1496
!NewChangesBrowser methodsFor:'private'!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1497
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1498
applyChange:aChange
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1499
    "applies aChange"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1500
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1501
    |aStream nm applyAction changeNr|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1502
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1503
    aStream := self streamForChange:aChange.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1504
    aStream isNil ifTrue:[^ self].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1505
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1506
    nm := self classNameOfChange:aChange.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1507
    nm notNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1508
        |cls|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1509
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1510
        cls := Smalltalk at:(nm asSymbol) ifAbsent:[].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1511
        cls notNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1512
            cls isLoaded ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1513
                cls autoload
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1514
            ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1515
        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1516
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1517
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1518
    applyAction := [
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1519
        |sig|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1520
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1521
        (skipSignal notNil) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1522
            sig := skipSignal
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1523
        ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1524
            sig := Object abortSignal
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1525
        ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1526
        sig catch:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1527
            |reader doItChunk methodsForChunk|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1528
1556
tz
parents: 1554
diff changeset
  1529
            "/ a followup methodsFor: chunk...
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1530
            aChange followUp ifTrue:[
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1531
                methodsForChunk := aChange chunk.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1532
            ] ifFalse:[
1556
tz
parents: 1554
diff changeset
  1533
                doItChunk := aStream nextChunk.   "/ an empty chunk sometimes...
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1534
                doItChunk notEmpty ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1535
                    Compiler evaluate:doItChunk notifying:self.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1536
                ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1537
                    methodsForChunk := aStream nextChunk.   "/ the real one
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1538
                ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1539
            ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1540
            methodsForChunk notNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1541
                Class methodRedefinitionSignal handle:[:ex |
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1542
                    ex proceedWith:#keep
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1543
                ] do:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1544
                    reader := Compiler evaluate:methodsForChunk notifying:self.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1545
                    reader fileInFrom:aStream notifying:self passChunk:false single:true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1546
                ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1547
            ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1548
        ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1549
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1550
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1551
    "/
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1552
    "/ if I am showing the changes file, dont update it
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1553
    "/
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1554
    changeFileName = ObjectMemory nameForChanges ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1555
        Class withoutUpdatingChangesDo:applyAction
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1556
    ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1557
        applyAction value
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1558
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1559
    aStream close
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1560
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1561
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1562
autoSelectChange:aChange
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1563
    "selects aChange"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1564
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1565
    self class autoSelectNext ifTrue:[         
1569
96d29b2efc76 revised
tz
parents: 1568
diff changeset
  1566
        ((self listOfChanges indexOf: aChange) <= self listOfChanges size) ifTrue:[
96d29b2efc76 revised
tz
parents: 1568
diff changeset
  1567
            self selectionOfChange value: aChange.  
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1568
            self changeSelected:(self listOfChanges indexOf: aChange).
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1569
            self updateChannels.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1570
            ^ self
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1571
        ]
1569
96d29b2efc76 revised
tz
parents: 1568
diff changeset
  1572
    ].         
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1573
    self updateChannels.
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1574
    self unselectChange
1569
96d29b2efc76 revised
tz
parents: 1568
diff changeset
  1575
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1576
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1577
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1578
autoSelectLast
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1579
    "selects the last change"
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1580
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1581
    self autoSelectChange: (self listOfChanges at: self listOfChanges size ifAbsent: nil).
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1582
    self updateChannels.
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1583
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1584
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1585
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1586
autoSelectOrEnd:aChange
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1587
    "selects aChange or the last"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1588
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1589
    |last|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1590
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1591
    last := self listOfChanges size.
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1592
    aChange notNil ifTrue:[  
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1593
        self autoSelectChange:aChange
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1594
    ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1595
        self selectionOfChange value: (self listOfChanges at: last ifAbsent: nil).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1596
        self changeSelected: last
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1597
    ].
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1598
    self updateChannels
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1599
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1600
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1601
changeColumn: aColumnLabel add: addOrRemove
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1602
    "adds or removes a attribute column to the table"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1603
1569
96d29b2efc76 revised
tz
parents: 1568
diff changeset
  1604
    |newListOfChangeColumns|
96d29b2efc76 revised
tz
parents: 1568
diff changeset
  1605
96d29b2efc76 revised
tz
parents: 1568
diff changeset
  1606
    newListOfChangeColumns := self listOfChangeColumns asOrderedCollection.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1607
    addOrRemove
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1608
    ifTrue:
1569
96d29b2efc76 revised
tz
parents: 1568
diff changeset
  1609
    [    
96d29b2efc76 revised
tz
parents: 1568
diff changeset
  1610
        newListOfChangeColumns add: 
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  1611
            ((self class specOfChangeColumns collect: [:i| i decodeAsLiteralArray]) detect: [:column| column label = aColumnLabel])
b37202441764 revised
tz
parents: 1556
diff changeset
  1612
    ]
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1613
    ifFalse:
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1614
    [
1569
96d29b2efc76 revised
tz
parents: 1568
diff changeset
  1615
        newListOfChangeColumns remove: 
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  1616
            (self listOfChangeColumns detect: [:column| column label = aColumnLabel] ifNone: nil) ifAbsent: nil
1553
eaeafd6f8cbe checkin from browser
tz
parents: 1546
diff changeset
  1617
    ].
1569
96d29b2efc76 revised
tz
parents: 1568
diff changeset
  1618
    self listOfChangeColumns contents: newListOfChangeColumns.
1553
eaeafd6f8cbe checkin from browser
tz
parents: 1546
diff changeset
  1619
    self autoSelectLast
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1620
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1621
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1622
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1623
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1624
changeFileName:aFileName
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1625
    "sets the name of the file with the changes"
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1626
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1627
    changeFileName := (Filename currentDirectory asAbsoluteFilename construct: aFileName) name.
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1628
!
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1629
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1630
checkClassIsLoaded:aClass
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1631
    "returns true if aClass is loaded"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1632
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1633
    |cls|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1634
    aClass isMeta ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1635
        cls := aClass soleInstance
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1636
    ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1637
        cls := aClass
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1638
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1639
    cls isLoaded ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1640
        (self confirm:(cls name , ' is an autoloaded class.\I can only compare the methods texts if its loaded first.\\Load the class first ?') withCRs)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1641
        ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1642
            cls autoload
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1643
        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1644
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1645
    ^ cls isLoaded
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1646
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1647
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1648
checkIfFileHasChanged
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1649
    "checks if changes file has changed"
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1650
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1651
    |f info|
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1652
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1653
    Processor removeTimedBlock:autoUpdateBlock.   
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1654
    f := changeFileName asFilename.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1655
    (info := f info) isNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1656
        self newLabel:'unaccessable'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1657
    ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1658
        (info modified) > changeFileTimestamp ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1659
            self newLabel:'outdated'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1660
            AutoUpdate ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1661
                self doReload
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1662
            ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1663
        ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1664
            self newLabel:''
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1665
        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1666
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1667
    Processor addTimedBlock:autoUpdateBlock afterSeconds:5.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1668
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1669
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1670
classNameOfChange:aChange
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1671
    "returns the classname of aChange 
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1672
     (for classChanges (i.e. xxx class), the non-metaClassName (i.e. xxx) is returned)"
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1673
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1674
    |name|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1675
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1676
    name := self fullClassNameOfChange:aChange.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1677
    name isNil ifTrue:[^ nil].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1678
    (name endsWith:' class') ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1679
        ^ name copyWithoutLast:6
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1680
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1681
    ^ name
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1682
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1683
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1684
compareChange:aChange
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1685
    "compares aChange with the current version"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1686
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1687
    |aStream chunk sawExcla parseTree thisClass cat oldSource newSource
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1688
     parser sel oldMethod outcome showDiff d t1 t2 selector isLoaded
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1689
     method beep|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1690
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1691
    aStream := self streamForChange:aChange.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1692
    aStream isNil ifTrue:[^ self].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1693
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1694
    showDiff := false.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1695
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1696
    aChange followUp ifFalse:[
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1697
        sawExcla := aStream peekFor:(aStream class chunkSeparator).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1698
        chunk := aStream nextChunk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1699
    ] ifTrue:[
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1700
        chunk := aChange chunk.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1701
        sawExcla := true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1702
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1703
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1704
    beep := false.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1705
    sawExcla ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1706
        outcome := 'Cannot compare this change\(i.e. this is not a method change)!!'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1707
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1708
        parseTree := Parser parseExpression:chunk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1709
        (parseTree notNil and:[parseTree isMessage]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1710
            ((selector := parseTree selector) == #removeSelector:) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1711
                thisClass := (parseTree receiver evaluate).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1712
                thisClass isBehavior ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1713
                    (self checkClassIsLoaded:thisClass) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1714
                        selector := (parseTree arg1 evaluate).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1715
                        (thisClass includesSelector:selector) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1716
                            outcome := 'Change removes the #' , selector , ' method from ' , thisClass name.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1717
                        ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1718
                            outcome := 'Change has no effect\(there is no method for #' , selector , ' in ' , thisClass name , ')'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1719
                        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1720
                    ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1721
                        beep := true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1722
                        outcome := 'Cannot compare this change (compare requires class to be loaded)!!'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1723
                    ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1724
                ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1725
            ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1726
            selector == #category: ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1727
                parseTree receiver isMessage ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1728
                    parseTree receiver selector == #compiledMethodAt: ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1729
                        (method := parseTree receiver evaluate) isMethod ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1730
                            method category = parseTree arg1 evaluate ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1731
                                outcome := 'Change has no effect\(same category)'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1732
                            ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1733
                                outcome := 'Category is different (''' , method category , ''' vs. ''' , parseTree arg1 evaluate , ''')'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1734
                            ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1735
                        ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1736
                            beep := true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1737
                            outcome := 'There is no such method!!'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1738
                        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1739
                    ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1740
                ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1741
            ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1742
        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1743
    ] ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1744
        parseTree := Parser parseExpression:chunk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1745
        (parseTree notNil 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1746
         and:[parseTree ~~ #Error
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1747
         and:[parseTree isMessage]]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1748
            (parseTree selector == #methodsFor:) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1749
                thisClass := (parseTree receiver evaluate).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1750
                thisClass isBehavior ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1751
                    (isLoaded := self checkClassIsLoaded:thisClass) ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1752
                        outcome := 'Cannot compare this change\(compare requires class to be loaded)!!'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1753
                    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1754
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1755
                    cat := parseTree arg1 evaluate.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1756
                    newSource := aStream nextChunk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1757
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1758
                    parser := Parser parseMethod:newSource in:thisClass.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1759
                    (parser notNil and:[parser ~~ #Error]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1760
                        sel := parser selector.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1761
                        oldMethod := thisClass compiledMethodAt:sel.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1762
                        oldMethod notNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1763
                            (oldMethod category = cat) ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1764
                                Transcript showCR:'Category changed.'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1765
                            ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1766
                            oldSource := oldMethod source.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1767
                            (oldSource = newSource) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1768
                                outcome := 'Same source.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1769
                            ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1770
                                oldSource isNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1771
                                    beep := true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1772
                                    outcome := 'No source for compare.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1773
                                ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1774
                                    "/
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1775
                                    "/ compare for tabulator <-> space changes
1556
tz
parents: 1554
diff changeset
  1776
                                    "/ before showing diff...
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1777
                                    "/
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1778
                                    t1 := oldSource asCollectionOfLines collect:[:s | s withTabsExpanded].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1779
                                    t2 := newSource asCollectionOfLines collect:[:s | s withTabsExpanded].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1780
                                    t1 = t2 ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1781
                                        outcome := 'Same source.'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1782
                                    ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1783
                                        outcome := 'Source changed!!'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1784
                                        showDiff := true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1785
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1786
                                        "/
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1787
                                        "/ check if only historyLine diffs
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1788
                                        "/
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1789
                                        (HistoryManager notNil 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1790
                                        and:[HistoryManager isActive]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1791
                                            (HistoryManager withoutHistoryLines:newSource)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1792
                                            =
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1793
                                            (HistoryManager withoutHistoryLines:oldSource)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1794
                                            ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1795
                                                outcome := 'Same source (history only).'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1796
                                                showDiff := false.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1797
                                            ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1798
                                        ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1799
                                    ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1800
                                ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1801
                            ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1802
                        ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1803
                            isLoaded ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1804
                                beep := true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1805
                                outcome := 'Method does not exist!!'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1806
                            ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1807
                        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1808
                    ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1809
                        outcome := 'Change unparsable!!'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1810
                    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1811
                    (showDiff and:[oldSource notNil and:[newSource notNil]]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1812
                        d := DiffTextView 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1813
                                openOn:oldSource label:'Current version (in image)'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1814
                                and:newSource label:'Change version'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1815
                        d label:'method differences'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1816
                    ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1817
                ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1818
                    beep := true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1819
                    outcome := 'Class does not exist!!'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1820
                ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1821
            ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1822
                beep := true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1823
                outcome := 'Not comparable!!'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1824
            ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1825
        ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1826
            beep := true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1827
            outcome := 'Not comparable!!'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1828
        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1829
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1830
    aStream close.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1831
    showDiff ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1832
        beep ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1833
            self warn:outcome withCRs.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1834
        ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1835
            self information:outcome withCRs.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1836
        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1837
    ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1838
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1839
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1840
compressForClass:aClassNameOrNil
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1841
    "compresses the list of changes; 
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1842
     this replaces multiple method-changes by the last (i.e. the most recent) change.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1843
     If the class argument is nil, compress for all classes.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1844
     otherwise, only changes for that class are compressed."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1845
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1846
    |aStream searchIndex anyMore deleteSet index  
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1847
     str snapshotProto snapshotPrefix snapshotNameIndex fileName|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1848
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1849
    aStream := FileStream readonlyFileNamed:changeFileName.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1850
    aStream isNil ifTrue:[^ self].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1851
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1852
    aClassNameOrNil isNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1853
        self newLabel:'compressing...'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1854
    ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1855
        self newLabel:'compressing for ' , aClassNameOrNil.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1856
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1857
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1858
    CompressSnapshotInfo == true ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1859
        "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1860
         get a prototype snapshot record (to be independent of
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1861
         the actual format ..
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1862
        "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1863
        str := WriteStream on:String new.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1864
        Class addChangeRecordForSnapshot:'foo' to:str.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1865
        snapshotProto := str contents.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1866
        snapshotPrefix := snapshotProto copyTo:10.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1867
        snapshotNameIndex := snapshotProto findString:'foo'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1868
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1869
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1870
    self valueOfNotReading value: false.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1871
    self valueOfHavingSelection value: false.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1872
    self valueOfHavingChangeSelection value: false.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1873
    self valueOfReadProgress value: 0.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1874
    self readProgressIndicator raise.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1875
    self filterLabel label: 'Comp:'; redraw.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1876
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1877
    self withExecuteCursorDo:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1878
        |numChanges classes selectors types excla sawExcla
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1879
         changeNr chunk aParseTree parseTreeChunk
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1880
         thisClass thisSelector codeChunk codeParser
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1881
         compressThis oldValue|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1882
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1883
        numChanges := changes size.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1884
        classes := Array new:numChanges.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1885
        selectors := Array new:numChanges.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1886
        types := Array new:numChanges.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1887
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1888
        "starting at the end, get the change class and change selector;
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1889
         collect all in classes / selectors"
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1890
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1891
        changeNr := numChanges.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1892
        excla := aStream class chunkSeparator.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1893
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1894
        [changeNr >= 1] whileTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1895
            oldValue := self valueOfReadProgress value.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1896
                self valueOfReadProgress value: (100 - ((aStream position/aStream size) * 100) rounded).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1897
                oldValue ~~ self valueOfReadProgress value
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1898
                    ifTrue: [self readProgressIndicator redrawEdges;redraw].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1899
            aStream position:(changes at: changeNr) position.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1900
            sawExcla := aStream peekFor:excla.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1901
            chunk := aStream nextChunk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1902
            sawExcla ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1903
                "optimize a bit if multiple methods for same category arrive"
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1904
                (chunk = parseTreeChunk) ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1905
                    aParseTree := Parser parseExpression:chunk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1906
                    parseTreeChunk := chunk
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1907
                ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1908
                (aParseTree notNil 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1909
                and:[(aParseTree ~~ #Error) 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1910
                and:[aParseTree isMessage]]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1911
                    (aParseTree selector == #methodsFor:) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1912
                        thisClass := (aParseTree receiver evaluate).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1913
                        codeChunk := aStream nextChunk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1914
                        codeParser := Parser 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1915
                                          parseMethodSpecification:codeChunk
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1916
                                          in:thisClass
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1917
                                          ignoreErrors:true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1918
                                          ignoreWarnings:true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1919
                        (codeParser notNil and:[codeParser ~~ #Error]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1920
                            selectors at:changeNr put:(codeParser selector).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1921
                            classes at:changeNr put:thisClass.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1922
                            types at:changeNr put:#methodsFor
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1923
                        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1924
                    ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1925
                ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1926
            ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1927
                aParseTree := Parser parseExpression:chunk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1928
                parseTreeChunk := chunk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1929
                (aParseTree notNil 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1930
                and:[(aParseTree ~~ #Error) 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1931
                and:[aParseTree isMessage]]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1932
                    (aParseTree selector == #removeSelector:) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1933
                        selectors at:changeNr put:(aParseTree arg1 value ).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1934
                        classes at:changeNr put:(aParseTree receiver evaluate).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1935
                        types at:changeNr put:#removeSelector
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1936
                    ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1937
                ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1938
                    CompressSnapshotInfo == true ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1939
                        (chunk startsWith:snapshotPrefix) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1940
                            str := chunk readStream position:snapshotNameIndex.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1941
                            fileName := str upTo:(Character space).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1942
                            "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1943
                             kludge to allow use of match-check below
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1944
                            "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1945
                            selectors at:changeNr put:snapshotPrefix.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1946
                            classes at:changeNr put:fileName.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1947
                        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1948
                    ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1949
                ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1950
            ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1951
            changeNr := changeNr - 1
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1952
        ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1953
        aStream close.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1954
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1955
        "for all changes, look for another class/selector occurence later
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1956
         in the list and, if there is one, add change number to the delete set"
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1957
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1958
        deleteSet := OrderedCollection new.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1959
        changeNr := 1.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1960
        [changeNr < changes size] whileTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1961
            thisClass := classes at:changeNr.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1962
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1963
            compressThis := false.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1964
            aClassNameOrNil isNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1965
                compressThis := true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1966
            ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1967
                "/ skipping unloaded/unknown classes
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1968
                thisClass isBehavior ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1969
                    thisClass isMeta ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1970
                        compressThis := aClassNameOrNil = thisClass soleInstance name. 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1971
                    ] ifFalse:[
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1972
                        compressThis := aClassNameOrNil = thisClass name.
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1973
                        (PrivateAsSeparate not and: [thisClass isPrivate])
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1974
                            ifTrue:[compressThis := aClassNameOrNil = thisClass owningClass name]
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1975
                    ]
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  1976
                 ]
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1977
            ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1978
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1979
            compressThis ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1980
                thisSelector := selectors at:changeNr.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1981
                searchIndex := changeNr.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1982
                anyMore := true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1983
                [anyMore] whileTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1984
                    searchIndex := classes indexOf:thisClass
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1985
                                        startingAt:(searchIndex + 1).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1986
                    (searchIndex ~~ 0) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1987
                        ((selectors at:searchIndex) == thisSelector) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1988
                            thisClass notNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1989
                                deleteSet add:changeNr.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1990
                                anyMore := false
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1991
                            ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1992
                        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1993
                    ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1994
                        anyMore := false      
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1995
                    ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1996
                ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1997
            ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1998
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  1999
            changeNr := changeNr + 1
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2000
        ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2001
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2002
        "finally delete what has been found"
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2003
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2004
        (deleteSet size > 0) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2005
            index := deleteSet size.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2006
            [index > 0] whileTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2007
                self silentDeleteChange: (changes at: (deleteSet at:index)).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2008
                index := index - 1
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2009
            ].
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2010
            self setChangeList
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2011
        ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2012
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2013
    self valueOfNotReading value: true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2014
    self filterField raise.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2015
    self filterLabel label: 'Filter:'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2016
    self newLabel: ''
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2017
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2018
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2019
contractClass:className selector:selector to:maxLen
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2020
    |s l|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2021
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2022
    s := className , ' ', selector.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2023
    s size > maxLen ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2024
        l := maxLen - 1 - selector size max:20.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2025
        s := (className contractTo:l) , ' ' , selector.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2026
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2027
        s size > maxLen ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2028
            l := maxLen - 1 - className size max:20.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2029
            s := className , ' ', (selector contractTo:l).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2030
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2031
            s size > maxLen ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2032
                s := (className contractTo:(maxLen // 2 - 1)) , ' ' , (selector contractTo:maxLen // 2)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2033
            ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2034
        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2035
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2036
    ^ s
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2037
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2038
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2039
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2040
deleteChangesFrom:start to:stop
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2041
    "deletes a range of changes"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2042
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2043
    self unselectChange.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2044
    stop to:start by:-1 do:[:changeNr|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2045
        self silentDeleteChange:(self listOfChanges at: changeNr)
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2046
    ].
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2047
    self setChangeList
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2048
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2049
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2050
fullClassNameOfChange:aChange
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2051
    "returns the full classname of aChange 
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2052
     (for classChanges (i.e. xxx class), a string ending in ' class' is returned.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2053
     - since parsing ascii methods is slow, keep result cached in 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2054
       changeClassNames for the next query"
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2055
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2056
    |chunk aParseTree recTree sel name arg1Tree isMeta prevMethodDefNr
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2057
     words changeStream fullParseTree ownerTree ownerName oldDollarSetting|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2058
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2059
    aChange isNil ifTrue:[^ nil].
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2060
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2061
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2062
     first look, if not already known
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2063
    "
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2064
    name := aChange className.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2065
    name notNil ifTrue:[^ name].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2066
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2067
    prevMethodDefNr := changes indexOf: aChange.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2068
    [(changes at:prevMethodDefNr) followUp] whileTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2069
        prevMethodDefNr := prevMethodDefNr - 1.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2070
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2071
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2072
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2073
     get the chunk
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2074
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2075
    chunk := (changes at:prevMethodDefNr) chunk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2076
    chunk isNil ifTrue:[^ nil].       "mhmh - empty"
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2077
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2078
    (chunk startsWith:'''---') ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2079
        words := chunk asCollectionOfWords.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2080
        words size > 2 ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2081
            (words at:2) = 'checkin' ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2082
                name := words at:3.
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2083
                aChange className: name.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2084
                ^ name
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2085
            ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2086
        ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2087
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2088
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2089
    "/ fix it - otherwise, it cannot be parsed
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2090
    (chunk endsWith:'primitiveDefinitions:') ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2091
        chunk := chunk , ''''''
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2092
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2093
    (chunk endsWith:'primitiveFunctions:') ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2094
        chunk := chunk , ''''''
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2095
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2096
    (chunk endsWith:'primitiveVariables:') ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2097
        chunk := chunk , ''''''
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2098
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2099
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2100
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2101
     use parser to construct a parseTree
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2102
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2103
    oldDollarSetting := Parser allowDollarInIdentifier.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2104
    [
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2105
        Parser allowDollarInIdentifier:true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2106
        aParseTree := Parser parseExpression:chunk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2107
    ] valueNowOrOnUnwindDo:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2108
        Parser allowDollarInIdentifier:oldDollarSetting
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2109
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2110
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2111
    (aParseTree isNil or:[aParseTree == #Error]) ifTrue:[
1556
tz
parents: 1554
diff changeset
  2112
        ^ nil        "seems strange... (could be a comment)"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2113
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2114
    aParseTree isMessage ifFalse:[
1556
tz
parents: 1554
diff changeset
  2115
        ^ nil        "very strange... (whats that ?)"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2116
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2117
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2118
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2119
     ask parser for selector
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2120
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2121
    sel := aParseTree selector.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2122
    recTree := aParseTree receiver.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2123
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2124
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2125
     is it a method-change, methodRemove or comment-change ?
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2126
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2127
    (#(#'methodsFor:' 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2128
       #'privateMethodsFor:' 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2129
       #'protectedMethodsFor:' 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2130
       #'publicMethodsFor:' 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2131
       #'removeSelector:' 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2132
       #'comment:'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2133
       #'primitiveDefinitions:'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2134
       #'primitiveFunctions:'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2135
       #'primitiveVariables:'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2136
       #'renameCategory:to:'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2137
       #'instanceVariableNames:'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2138
    ) includes:sel) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2139
        "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2140
         yes, the className is the receiver
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2141
        "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2142
        (recTree notNil and:[recTree ~~ #Error]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2143
            isMeta := false.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2144
            recTree isUnaryMessage ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2145
                (recTree selector ~~ #class) ifTrue:[^ nil].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2146
                "id class methodsFor:..."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2147
                recTree := recTree receiver.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2148
                isMeta := true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2149
            ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2150
            recTree isPrimary ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2151
                name := recTree name.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2152
                isMeta ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2153
                    name := name , ' class'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2154
                ].
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2155
                aChange className: name.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2156
                ^ name
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2157
            ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2158
        ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2159
        "more strange things"
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2160
        ^ nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2161
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2162
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2163
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2164
     is it a change in a class-description ?
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2165
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2166
    (('subclass:*' match:sel) 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2167
    or:[('variable*subclass:*' match:sel)]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2168
        "/ must parse the full changes text, to get
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2169
        "/ privacy information.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2170
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2171
        changeStream := self streamForChange:aChange.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2172
        changeStream notNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2173
            chunk := changeStream nextChunk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2174
            changeStream close.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2175
            fullParseTree := Parser parseExpression:chunk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2176
            (fullParseTree isNil or:[fullParseTree == #Error]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2177
                fullParseTree := nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2178
            ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2179
            fullParseTree isMessage ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2180
                fullParseTree := nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2181
            ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2182
            "/ actually, the nil case cannot happen
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2183
            fullParseTree notNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2184
                aParseTree := fullParseTree.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2185
                sel := aParseTree selector.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2186
            ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2187
        ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2188
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2189
        arg1Tree := aParseTree arg1.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2190
        (arg1Tree notNil and:[arg1Tree isConstant]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2191
            name := arg1Tree value asString.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2192
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2193
            "/ is it a private-class ?
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2194
            ('*privateIn:' match:sel) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2195
                ownerTree := aParseTree args last.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2196
                ownerName := ownerTree name asString.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2197
                name := ownerName , '::' , name
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2198
            ].
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2199
            aChange className: name.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2200
            ^ name
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2201
        ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2202
        "very strange"
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2203
        ^ nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2204
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2205
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2206
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2207
     is it a class remove ?
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2208
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2209
    (sel == #removeClass:) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2210
        (recTree notNil 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2211
        and:[recTree ~~ #Error
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2212
        and:[recTree isPrimary
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2213
        and:[recTree name = 'Smalltalk']]]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2214
            arg1Tree := aParseTree arg1.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2215
            (arg1Tree notNil and:[arg1Tree isPrimary]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2216
                name := arg1Tree name.
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2217
                aChange className: name.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2218
                ^ name
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2219
            ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2220
        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2221
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2222
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2223
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2224
     is it a method category change ?
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2225
    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2226
    ((sel == #category:)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2227
    or:[sel == #privacy:]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2228
        (recTree notNil 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2229
        and:[recTree ~~ #Error
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2230
        and:[recTree isMessage
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2231
        and:[recTree selector == #compiledMethodAt:]]]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2232
            isMeta := false.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2233
            recTree := recTree receiver.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2234
            recTree isUnaryMessage ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2235
                (recTree selector ~~ #class) ifTrue:[^ nil].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2236
                "id class "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2237
                recTree := recTree receiver
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2238
            ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2239
            recTree isPrimary ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2240
                isMeta ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2241
                    name := name , ' class'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2242
                ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2243
                name := recTree name.
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2244
                aChange className: name.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2245
                ^ name
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2246
            ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2247
        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2248
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2249
    ^ nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2250
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2251
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2252
newLabel:how
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2253
    "sets the label"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2254
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2255
    how size = 0 ifTrue: [^self window label:self class label].
1556
tz
parents: 1554
diff changeset
  2256
    self window label:self class label, ' (', how, ')'
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2257
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2258
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2259
readChangesFileInBackground:inBackground
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2260
    "reads the changes file, creates a list of header-lines (changeChunks)
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2261
     and a list of chunk-positions (changePositions).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2262
     Starting with 2.10.3, the entries are multi-col entries;
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2263
     the cols are:
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2264
        1   delta (only if comparing)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2265
                '+' -> new method (w.r.t. current state)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2266
                '-' -> removed method (w.r.t. current state)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2267
                '?' -> class does not exist currently
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2268
                '=' -> change is same as current methods source
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2269
        2   class/selector
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2270
        3   type of change
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2271
                doit
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2272
                method
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2273
                category change
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2274
        4   timestamp
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2275
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2276
     since comparing slows down startup time, it is now disabled by
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2277
     default and can be enabled via a toggle."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2278
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2279
    |aStream maxLen i f|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2280
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2281
    self valueOfNotReading value: false.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2282
    self valueOfHavingSelection value: false.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2283
    self valueOfHavingChangeSelection value: false.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2284
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2285
    editingClassSource := false.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2286
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2287
    maxLen := 60.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2288
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2289
    f := changeFileName asFilename.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2290
    aStream :=  f readStream.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2291
    aStream isNil ifTrue:[^ nil].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2292
1556
tz
parents: 1554
diff changeset
  2293
    self newLabel:'updating...'.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2294
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2295
    i := f info.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2296
    changeFileTimestamp := i modified.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2297
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2298
    self valueOfReadProgress value: 0.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2299
    self readProgressIndicator raise.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2300
    self filterLabel label: 'Read:'; redraw.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2301
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2302
    self withReadCursorDo:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2303
        |myProcess myPriority|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2304
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2305
        "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2306
         this is a time consuming operation (especially, if reading an
1556
tz
parents: 1554
diff changeset
  2307
         NFS-mounted directory; therefore lower my priority...
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2308
        "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2309
        inBackground ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2310
            myProcess := Processor activeProcess.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2311
            myPriority := myProcess priority.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2312
            myProcess priority:(Processor userBackgroundPriority).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2313
        ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2314
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2315
        [
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  2316
            |excla timeStampInfo lastChange|
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2317
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2318
            excla := aStream class chunkSeparator.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2319
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2320
            [aStream atEnd] whileFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2321
                |change changeDelta changeString changeType changeCategory
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2322
                 line s l changeClass sawExcla category 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2323
                 chunkText chunkPos sel oldValue|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2324
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2325
                change := Change new.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2326
                "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2327
                 get a chunk (separated by excla)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2328
                "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2329
                oldValue := self valueOfReadProgress value.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2330
                self valueOfReadProgress value: (((aStream position/aStream size) * 100) rounded).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2331
                oldValue ~~ self valueOfReadProgress value
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2332
                    ifTrue: [self readProgressIndicator redrawEdges;redraw].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2333
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2334
                aStream skipSeparators.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2335
                chunkPos := aStream position.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2336
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2337
                sawExcla := aStream peekFor:excla.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2338
                chunkText := aStream nextChunk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2339
                chunkText notNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2340
                    |index headerLine cls|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2341
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2342
                    (chunkText startsWith:'''---- timestamp ') ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2343
                        timeStampInfo := (chunkText copyFrom:16 to:(chunkText size - 6)) withoutSpaces.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2344
                    ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2345
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2346
                        "
1556
tz
parents: 1554
diff changeset
  2347
                         only first line is saved in changeChunks...
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2348
                        "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2349
                        index := chunkText indexOf:(Character cr).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2350
                        (index ~~ 0) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2351
                            chunkText := chunkText copyTo:(index - 1).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2352
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2353
                            "take care for comment changes - must still be a
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2354
                             valid expression for classNameOfChange: to work"
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2355
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2356
                            (chunkText endsWith:'comment:''') ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2357
                                chunkText := chunkText , '...'''
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2358
                            ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2359
                            (chunkText endsWith:'primitiveDefinitions:''') ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2360
                                sel := 'primitiveDefinitions:'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2361
                                chunkText := chunkText copyWithoutLast:1
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2362
                            ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2363
                            (chunkText endsWith:'primitiveVariables:''') ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2364
                                sel := 'primitiveVariables:'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2365
                                chunkText := chunkText copyWithoutLast:1
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2366
                            ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2367
                            (chunkText endsWith:'primitiveFunctions:''') ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2368
                                sel := 'primitiveFunctions:'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2369
                                chunkText := chunkText copyWithoutLast:1
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2370
                            ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2371
                        ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2372
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2373
                        change chunk: chunkText.
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  2374
                        change position: chunkPos. 
b37202441764 revised
tz
parents: 1556
diff changeset
  2375
                        lastChange notNil ifTrue: [lastChange lastPosition: chunkPos - 1].
b37202441764 revised
tz
parents: 1556
diff changeset
  2376
                        lastChange := change.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2377
                        change timeStamp: timeStampInfo.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2378
                        change followUp: false.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2379
                        headerLine := nil.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2380
                        changeDelta := ' '.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2381
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2382
                        sawExcla ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2383
                            (chunkText startsWith:'''---- snap') ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2384
                                changeType := ''.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2385
                                headerLine := chunkText.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2386
                                changeString := (chunkText contractTo:maxLen).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2387
                                timeStampInfo := nil.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2388
                            ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2389
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2390
                                |p cls|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2391
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2392
                                headerLine := chunkText , ' (doIt)'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2393
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2394
                                "
1556
tz
parents: 1554
diff changeset
  2395
                                 first, assume doIt - then lets have a more detailed look...
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2396
                                "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2397
                                ((chunkText startsWith:'''---- file')
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2398
                                or:[(chunkText startsWith:'''---- check')]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2399
                                    changeType := ''.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2400
                                    timeStampInfo := nil.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2401
                                ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2402
                                    changeType := 'doIt'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2403
                                ].    
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2404
                                changeString := (chunkText contractTo:maxLen).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2405
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2406
                                p := Parser parseExpression:chunkText inNameSpace:Smalltalk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2407
                                (p notNil 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2408
                                 and:[p ~~ #Error
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2409
                                 and:[p isMessage]]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2410
                                    sel := p selector.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2411
                                ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2412
                                (sel == #removeSelector:) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2413
                                    p receiver isUnaryMessage ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2414
                                        cls := p receiver receiver name.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2415
                                        changeClass := (Smalltalk classNamed:cls) class.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2416
                                        cls := cls , ' class'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2417
                                    ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2418
                                        cls := p receiver name.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2419
                                        changeClass := (Smalltalk classNamed:cls)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2420
                                    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2421
                                    sel := (p args at:1) evaluate.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2422
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2423
                                    DeltaInfoColumn ifTrue:[
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2424
                                        (changeClass isNil or:[changeClass isLoaded not]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2425
                                            changeDelta := '?'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2426
                                        ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2427
                                            (changeClass implements:sel asSymbol) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2428
                                                changeDelta := '-'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2429
                                            ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2430
                                        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2431
                                    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2432
                                    changeType := 'remove'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2433
                                    changeString := self contractClass:cls selector:sel to:maxLen.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2434
                                ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2435
                                (p ~~ #Error
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2436
                                and:[p isMessage 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2437
                                and:[p receiver isMessage
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2438
                                and:[p receiver selector == #compiledMethodAt:]]]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2439
                                    p receiver receiver isUnaryMessage ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2440
                                        cls := p receiver receiver receiver name.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2441
                                        changeClass := (Smalltalk classNamed:cls) class.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2442
                                        cls := cls , ' class'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2443
                                    ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2444
                                        cls := p receiver receiver name.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2445
                                        changeClass := (Smalltalk classNamed:cls)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2446
                                    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2447
                                    (sel == #category:) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2448
                                        sel := (p receiver args at:1) evaluate.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2449
                                        changeType := '(category change)'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2450
                                        changeString := self contractClass:cls selector:sel to:maxLen.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2451
                                    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2452
                                    (sel == #privacy:) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2453
                                        sel := (p receiver args at:1) evaluate.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2454
                                        changeType := 'privacy change'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2455
                                        changeString := self contractClass:cls selector:sel to:maxLen.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2456
                                    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2457
                                ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2458
                                (#(#'subclass:'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2459
                                  #'variableSubclass:'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2460
                                  #'variableByteSubclass:'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2461
                                  #'variableWordSubclass:'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2462
                                  #'variableLongSubclass:'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2463
                                  #'variableFloatSubclass:'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2464
                                  #'variableDoubleSubclass:'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2465
                                  #'primitiveDefinitions:'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2466
                                  #'primitiveFunctions:'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2467
                                  #'primitiveVariables:'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2468
                                 ) includes:sel) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2469
                                    changeType := 'class definition'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2470
                                ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2471
                            ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2472
                        ] ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2473
                            |done first p className cls text methodPos|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2474
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2475
                            "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2476
                             method definitions actually consist of
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2477
                             two (or more) chunks; skip next chunk(s)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2478
                             up to an empty one.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2479
                             The system only writes one chunk,
1556
tz
parents: 1554
diff changeset
  2480
                             and we cannot handle more in this ChangesBrowser....
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2481
                            "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2482
                            className := nil.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2483
                            p := Parser parseExpression:chunkText inNameSpace:Smalltalk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2484
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2485
                            (p notNil and:[p ~~ #Error]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2486
                                sel := p selector.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2487
                                (sel == #methodsFor:) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2488
                                    p receiver isUnaryMessage ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2489
                                        className := p receiver receiver name.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2490
                                        changeClass := (Smalltalk classNamed:className) class.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2491
                                        className := className , ' class'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2492
                                    ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2493
                                        className := p receiver name.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2494
                                        changeClass := Smalltalk classNamed:className
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2495
                                    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2496
                                    category := (p args at:1) evaluate.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2497
                                ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2498
                            ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2499
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2500
                            done := false.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2501
                            first := true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2502
                            [done] whileFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2503
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2504
                                changeDelta := ' '.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2505
                                methodPos := aStream position.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2506
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2507
                                text := aStream nextChunk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2508
                                text isNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2509
                                    done := true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2510
                                ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2511
                                    done := text isEmpty
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2512
                                ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2513
                                done ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2514
                                    first ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2515
                                        change := Change new.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2516
                                        change chunk: chunkText.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2517
                                        change string:changeString.
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  2518
                                        change position: methodPos. 
b37202441764 revised
tz
parents: 1556
diff changeset
  2519
                                        lastChange notNil ifTrue: [lastChange lastPosition: methodPos - 1].
b37202441764 revised
tz
parents: 1556
diff changeset
  2520
                                        lastChange := change.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2521
                                        change timeStamp: timeStampInfo.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2522
                                        change followUp: true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2523
                                        editingClassSource := true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2524
                                    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2525
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2526
                                    first := false.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2527
                                    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2528
                                     try to find the selector
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2529
                                    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2530
                                    sel := nil.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2531
                                    className notNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2532
                                        p := Parser 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2533
                                                 parseMethodSpecification:text
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2534
                                                 in:nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2535
                                                 ignoreErrors:true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2536
                                                 ignoreWarnings:true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2537
                                        (p notNil and:[p ~~ #Error]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2538
                                            sel := p selector.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2539
                                        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2540
                                    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2541
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2542
                                    sel isNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2543
                                        changeString := (chunkText contractTo:maxLen).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2544
                                        changeType := 'change'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2545
                                        headerLine := chunkText , ' (change)'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2546
                                    ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2547
                                        changeString :=  self contractClass:className selector:sel to:maxLen.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2548
                                        changeType := 'method definition'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2549
                                        changeCategory := category.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2550
                                        headerLine := className , ' ' , sel , ' ' , '(change category: ''' , category , ''')'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2551
                                    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2552
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2553
                                    DeltaInfoColumn ifTrue:[ 
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2554
                                        changeClass isNil ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2555
                                            changeClass isMeta ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2556
                                                cls := changeClass soleInstance
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2557
                                            ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2558
                                                cls := changeClass
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2559
                                            ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2560
                                        ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2561
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2562
                                        (changeClass isNil or:[cls isLoaded not]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2563
                                            changeDelta := '?'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2564
                                        ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2565
                                            (changeClass implements:sel asSymbol) ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2566
                                                changeDelta := '+'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2567
                                            ] ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2568
                                                |m currentText t1 t2|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2569
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2570
                                                m := changeClass compiledMethodAt:sel asSymbol.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2571
                                                currentText := m source.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2572
                                                currentText notNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2573
                                                    text asString = currentText asString ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2574
                                                        changeDelta := '='
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2575
                                                    ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2576
                                                        t1 := currentText asCollectionOfLines collect:[:s | s withTabsExpanded].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2577
                                                        t2 := text asCollectionOfLines collect:[:s | s withTabsExpanded].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2578
                                                        t1 = t2 ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2579
                                                            changeDelta := '='
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2580
                                                        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2581
                                                    ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2582
                                                ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2583
                                            ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2584
                                        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2585
                                    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2586
                                    change delta:changeDelta.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2587
                                    change string:changeString.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2588
                                    change type:changeType.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2589
                                    change category: changeCategory.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2590
                                    change timeStamp:timeStampInfo.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2591
                                    changes add:change.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2592
                                ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2593
                                changeString := nil.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2594
                                headerLine := nil.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2595
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2596
                            ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2597
                        ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2598
                        changeString notNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2599
                            change delta:changeDelta.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2600
                            change string:changeString.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2601
                            change type:changeType.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2602
                            change timeStamp:timeStampInfo.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2603
                            changes add:change.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2604
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2605
                        ] ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2606
                            headerLine notNil ifTrue:[     
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2607
                                changes add: change.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2608
                            ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2609
                        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2610
                    ]
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  2611
                ]. 
b37202441764 revised
tz
parents: 1556
diff changeset
  2612
                change lastPosition: aStream position.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2613
            ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2614
            modified := false.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2615
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2616
        ] valueNowOrOnUnwindDo:[ 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2617
            aStream close.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2618
            inBackground ifTrue:[myProcess priority:myPriority].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2619
        ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2620
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2621
    self setChangeList.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2622
    self valueOfNotReading value: true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2623
    self filterField raise.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2624
    self filterLabel label: 'Filter:'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2625
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2626
    self checkIfFileHasChanged. 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2627
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2628
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2629
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2630
selectorOfMethodChange:aChange
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2631
    "returns the selector of the method change, or nil if it is not a method change"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2632
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2633
    |source parser sel|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2634
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2635
    source := self sourceOfMethodChange:aChange.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2636
    source isNil ifTrue:[^ nil].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2637
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2638
    parser := Parser 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2639
                parseMethod:source 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2640
                in:nil 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2641
                ignoreErrors:true 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2642
                ignoreWarnings:true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2643
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2644
    (parser notNil and:[parser ~~ #Error]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2645
        sel := parser selector.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2646
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2647
    ^ sel
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2648
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2649
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2650
setChangeList
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2651
    "sets the list of changes into the list for the table by evaluating filterCompletionBlock"
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2652
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2653
    self unselectChange.
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2654
    filterCompletionBlock value: self valueOfFilter value.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2655
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2656
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2657
silentDeleteChange:aChange
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2658
    "delete aChange do not update changeListView"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2659
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2660
    modified := true.      
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2661
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2662
    changes remove:aChange
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2663
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2664
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2665
silentDeleteChangesFor:aClassName from:start to:stop
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2666
    "deletes changes for aChange in the range [start,stop]
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2667
     and returns the number of the deleted changes"
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2668
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2669
    |index numDeleted clsName|
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2670
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2671
    numDeleted := 0.
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2672
    index := stop.          
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2673
    [index >= start] whileTrue:
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2674
    [                                         
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2675
        ((clsName := self classNameOfChange:(self listOfChanges at: index)) notNil and:
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2676
        [(clsName = aClassName or: [PrivateAsSeparate not and: [(clsName upTo: $:) = aClassName]])])
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2677
        ifTrue:
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2678
        [     
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2679
            self silentDeleteChange:(self listOfChanges at: index).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2680
            numDeleted := numDeleted + 1.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2681
        ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2682
        index := index - 1
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2683
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2684
    ^ numDeleted
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2685
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2686
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2687
sourceOfMethodChange:aChange
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2688
    "returns the source code of the method change, or nil if it is not a method change."
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2689
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2690
    |aStream chunk sawExcla parseTree sourceChunk|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2691
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2692
    aStream := self streamForChange:aChange. 
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2693
    aStream isNil ifTrue:[^ nil].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2694
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2695
    aChange followUp ifFalse:[
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2696
        sawExcla := aStream peekFor:(aStream class chunkSeparator).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2697
        chunk := aStream nextChunk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2698
    ] ifTrue:[
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2699
        chunk := aChange chunk.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2700
        sawExcla := true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2701
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2702
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2703
    sawExcla ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2704
        parseTree := Parser parseExpression:chunk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2705
        (parseTree notNil and:[parseTree isMessage]) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2706
            (parseTree selector == #methodsFor:) ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2707
                sourceChunk := aStream nextChunk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2708
            ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2709
        ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2710
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2711
    aStream close.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2712
    ^ sourceChunk
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2713
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2714
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2715
streamForChange:aChange
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2716
    "returns the stream for aChange"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2717
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2718
    |aStream|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2719
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2720
    aStream := FileStream readonlyFileNamed:changeFileName.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2721
    aStream isNil ifTrue:[^ nil].
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2722
    aStream position:aChange position.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2723
    ^ aStream
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2724
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2725
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2726
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2727
unselectChange
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2728
    "unselects the current change"
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2729
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2730
    self selectionOfChange value: nil.
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2731
    self valueOfChangeText value: nil
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2732
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2733
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2734
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2735
withSelectedChangeDo:aBlock
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2736
    "just a helper, check for a selected change and evaluate aBlock
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2737
     with busy cursor"
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2738
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2739
    |change|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2740
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2741
    (change := self selectionOfChange value) notNil 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2742
    ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2743
        self withExecuteCursorDo:[aBlock value:change]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2744
    ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2745
! !
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2746
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2747
!NewChangesBrowser methodsFor:'startup / release'!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2748
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2749
closeRequest
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2750
    "asks for saving before closing"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2751
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  2752
    self valueOfNotSaving value ifFalse: [^nil].
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2753
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2754
    modified ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2755
        (OptionBox 
1636
14e3ccc3e7c6 use Workspace
tz
parents: 1569
diff changeset
  2756
              request:(resources at:'Changes list was modified!!') withCRs
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2757
              label:'Changes Browser'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2758
              form:(WarningBox iconBitmap)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2759
              buttonLabels:#('Cancel' ' Waste it and proceed ')
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2760
              values:#(#abort #ignore)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2761
              default:#save
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2762
        ) == #abort ifTrue:[^self].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2763
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2764
    super closeRequest
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2765
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2766
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2767
postOpenWith:aBuilder
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2768
    "starts reading the changes from the file and
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2769
     builds entryCompletionBlock for the filterField before opening"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2770
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2771
    super postOpenWith:aBuilder.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2772
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2773
    builder namedComponents do: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2774
    [:aView|    
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2775
        aView allSubViewsDo: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2776
        [:v|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2777
            v redraw
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2778
        ] 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2779
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2780
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2781
    autoUpdateBlock := [self checkIfFileHasChanged].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2782
    Processor addTimedBlock:autoUpdateBlock afterSeconds:5.  
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2783
    self updateInfoLabel.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2784
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2785
    self filterField entryCompletionBlock:
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2786
    (filterCompletionBlock := [:value|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2787
        |filter filters i changesCopy|
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2788
        self unselectChange.
1636
14e3ccc3e7c6 use Workspace
tz
parents: 1569
diff changeset
  2789
        filter := self filterField contents.
14e3ccc3e7c6 use Workspace
tz
parents: 1569
diff changeset
  2790
        (filters := filter asArrayOfSubstrings) size > 0 ifTrue: 
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2791
        [
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2792
            i := 0.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2793
            changesCopy := changes copy.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2794
            filters do: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2795
            [:filter|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2796
                i := i + 1.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2797
                changesCopy contents: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2798
                    (changesCopy select: [:row| 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2799
                        filter match: (row string asArrayOfSubstrings at: i ifAbsent: [''''])])
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2800
            ].            
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2801
            self listOfChanges contents: changesCopy
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2802
        ] 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2803
        ifFalse: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2804
        [
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2805
            self listOfChanges contents: changes
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2806
        ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2807
        self autoSelectLast.
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2808
    ]).
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2809
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2810
    self readChangesFileInBackground:true.
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2811
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2812
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2813
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2814
uninitialize
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2815
    "removes the autoUpdateBlock from the Processor and myself from the ObjectMemory"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2816
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2817
    Processor removeTimedBlock:autoUpdateBlock.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2818
    ObjectMemory removeDependent:self
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2819
! !
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2820
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2821
!NewChangesBrowser methodsFor:'user actions'!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2822
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2823
doApply
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2824
    "applies the selected change"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2825
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2826
    self withSelectedChangeDo:[:change|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2827
        skipSignal := nil.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2828
        self applyChange:change.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2829
        self autoSelectChange: (self listOfChanges at: (self listOfChanges indexOf: change) ifAbsent: nil)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2830
    ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2831
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2832
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2833
doApplyAll
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2834
    "applies all changes"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2835
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2836
    self withExecuteCursorDo:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2837
        |change|
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2838
        self unselectChange.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2839
        skipSignal isNil ifTrue:[skipSignal := Signal new].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2840
        1 to:self listOfChanges size do:[:changeNr |
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2841
            self selectionOfChange value:(change := self listOfChanges at: changeNr).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2842
            self applyChange:change
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2843
        ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2844
        self autoSelectLast
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2845
    ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2846
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2847
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2848
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2849
doApplyAllForClass
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2850
    "applies all changes having the same class like the selected one"
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2851
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2852
    self doApplyForClassToEndFrom: 1
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2853
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2854
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2855
!
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2856
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2857
doApplyForClassToEnd
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2858
    "applies all changes having the same class like the selected one from the selected to the end"
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2859
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2860
    self doApplyForClassToEndFrom: (self listOfChanges indexOf: self selectionOfChange value)
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2861
!
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2862
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2863
doApplyForClassToEndFrom: start
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2864
    "applies changes with same class like the selected one from start to end"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2865
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2866
    self withSelectedChangeDo:[:change|
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2867
        |classNameToApply thisClassName lastChange change2|
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2868
        (classNameToApply := self classNameOfChange:change) notNil 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2869
        ifTrue:
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2870
        [             
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2871
            self unselectChange.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2872
            skipSignal isNil ifTrue:[skipSignal := Signal new].
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2873
            start to:self listOfChanges size do:
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2874
            [:changeNr|
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2875
                change2 := self listOfChanges at: changeNr.
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2876
                ((thisClassName := self classNameOfChange:change2) notNil and:
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2877
                [thisClassName = classNameToApply or:
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2878
                [PrivateAsSeparate not and: [(thisClassName upTo: $:) = classNameToApply]]])
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2879
                ifTrue:
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2880
                [                           
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2881
                    self selectionOfChange value: change2.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2882
                    self applyChange:change2.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2883
                    lastChange := change2
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2884
                ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2885
            ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2886
            self autoSelectChange:lastChange.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2887
        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2888
    ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2889
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2890
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2891
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2892
doApplyFromLastSnapshot
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2893
    "applies all changes made since the last snapshot"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2894
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2895
    self autoSelectLast.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2896
    (self doFindSnapshot: 'last') ifTrue: [self doApplyToEnd]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2897
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2898
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2899
doApplyToEnd
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2900
    "applies all changes from selected one to be end"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2901
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2902
    self withSelectedChangeDo:[:change|
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2903
        self unselectChange.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2904
        skipSignal isNil ifTrue:[skipSignal := Signal new].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2905
        (self listOfChanges indexOf: change) to: self listOfChanges size do:[:changeNr|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2906
            self selectionOfChange value:(self listOfChanges at: changeNr).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2907
            self applyChange:(self listOfChanges at: changeNr)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2908
        ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2909
        self autoSelectChange:self listOfChanges last
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2910
    ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2911
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2912
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2913
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2914
doBrowseClass
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2915
    "opens a System Browser on the class of a change (and selector)"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2916
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2917
    |className cls isMeta|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2918
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2919
    className := self fullClassNameOfChange:self selectionOfChange value.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2920
    className notNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2921
        isMeta := false.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2922
        (className endsWith:' class') ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2923
            className := className copyWithoutLast:6.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2924
            isMeta := true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2925
        ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2926
        (cls := Smalltalk classNamed:className) notNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2927
            isMeta ifTrue:[cls := cls class].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2928
            SystemBrowser 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2929
                openInClass:cls 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2930
                selector:(self selectorOfMethodChange:self selectionOfChange value)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2931
        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2932
    ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2933
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2934
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2935
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2936
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2937
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2938
doCompare
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2939
    "compares a change with the current system version"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2940
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2941
    |change|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2942
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2943
    (change := self selectionOfChange value) notNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2944
        self withExecuteCursorDo:[self compareChange:change]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2945
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2946
    self newLabel:''
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2947
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2948
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2949
doCompress
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2950
    "compresses the changes, i.e. replaces multiple changes by the last change"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2951
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2952
    |changesSizeBefore|
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2953
    (changesSizeBefore := changes size) == 0 ifTrue: [^self warn: 'Nothing to compress!!'].
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2954
    self setChangeList.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2955
    self unselectChange.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2956
    self compressForClass:nil.
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2957
    self setChangeList.    
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2958
    self updateInfoLabel.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2959
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2960
    self information: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2961
        'Compression Rate:   ', (((changesSizeBefore - changes size)/changesSizeBefore) * 100) rounded printString, '%\' withCRs,
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  2962
        'Obselete Changes: ', (changesSizeBefore - changes size) printString, ' from ', changesSizeBefore printString
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2963
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2964
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2965
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2966
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2967
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2968
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2969
doCompressForClass
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2970
    "compresses changes for the selected class.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2971
     this replaces multiple method-changes by the last (i.e. the most recent) change."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2972
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2973
    self withSelectedChangeDo:[:change|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2974
        | classNameToCompress |
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2975
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2976
        (classNameToCompress := self classNameOfChange:change) notNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2977
            self compressForClass:classNameToCompress.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2978
            filterCompletionBlock value: self valueOfFilter value.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2979
            self autoSelectLast
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2980
        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2981
    ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2982
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2983
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2984
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2985
doDelete
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2986
    "deletes the selected change"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2987
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2988
    |change selectionIndex|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2989
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2990
    (change := self selectionOfChange value) notNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2991
        selectionIndex := self listOfChanges indexOf: change.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2992
        self unselectChange.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2993
        self silentDeleteChange:change.
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2994
        self listOfChanges remove:change.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2995
        self autoSelectOrEnd: (self listOfChanges at: selectionIndex ifAbsent: [nil]).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  2996
    ]
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2997
!
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2998
ffea21e237ed revised
tz
parents: 1545
diff changeset
  2999
doDeleteAll
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3000
    "deletes all changes"
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3001
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3002
    self unselectChange.
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3003
    self deleteChangesFrom:1 to: self listOfChanges size.
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3004
    self autoSelectOrEnd: nil
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3005
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3006
!
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3007
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3008
doDeleteAllForClass
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3009
    "deletes all changes having the same class like the selected one"
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3010
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3011
    self doDeleteForClassToEndFrom: 1
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3012
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3013
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3014
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3015
doDeleteForClassToEnd
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3016
    "deletes all changes having the same class like the selected one from the selected to the end"
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3017
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3018
    self withSelectedChangeDo:[:change|
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3019
        self doDeleteForClassToEndFrom: (self listOfChanges indexOf: change)
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3020
    ]
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3021
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3022
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3023
!
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3024
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3025
doDeleteForClassToEndFrom: start
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3026
    "deletes changes with same class like the selected one from start to end"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3027
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3028
    self withSelectedChangeDo:[:change|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3029
        |classNameToDelete|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3030
        (classNameToDelete := self classNameOfChange:change) notNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3031
            self unselectChange.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3032
            self silentDeleteChangesFor:classNameToDelete 
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3033
                                   from:start
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3034
                                     to:self listOfChanges size.
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3035
            self setChangeList.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3036
            self autoSelectOrEnd: nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3037
        ]
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3038
    ].
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3039
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3040
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3041
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3042
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3043
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3044
doDeleteToEnd
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3045
    "deletes all changes from selected one to be end"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3046
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3047
    |changeNr|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3048
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3049
    changeNr := (self listOfChanges indexOf: self selectionOfChange value).
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3050
    changeNr ~~ 0 ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3051
        self deleteChangesFrom:changeNr to: self listOfChanges size.
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3052
        self unselectChange.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3053
        self autoSelectOrEnd: nil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3054
    ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3055
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3056
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3057
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  3058
doFilter: aFilterString
b37202441764 revised
tz
parents: 1556
diff changeset
  3059
    "filter the changes with aFilterString"
b37202441764 revised
tz
parents: 1556
diff changeset
  3060
1569
96d29b2efc76 revised
tz
parents: 1568
diff changeset
  3061
    self selectionOfChange value: nil.
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  3062
    self valueOfFilter value: aFilterString withoutNotifying: self.
b37202441764 revised
tz
parents: 1556
diff changeset
  3063
    self valueOfFilter changed.
b37202441764 revised
tz
parents: 1556
diff changeset
  3064
    self autoSelectLast
b37202441764 revised
tz
parents: 1556
diff changeset
  3065
!
b37202441764 revised
tz
parents: 1556
diff changeset
  3066
b37202441764 revised
tz
parents: 1556
diff changeset
  3067
doFilterCheckIns
b37202441764 revised
tz
parents: 1556
diff changeset
  3068
    "filter the check in changes"
b37202441764 revised
tz
parents: 1556
diff changeset
  3069
1569
96d29b2efc76 revised
tz
parents: 1568
diff changeset
  3070
    self selectionOfChange value: nil.
96d29b2efc76 revised
tz
parents: 1568
diff changeset
  3071
    self listOfChanges contents: #().
96d29b2efc76 revised
tz
parents: 1568
diff changeset
  3072
    self valueOfFilter value: '' withoutNotifying: self.
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  3073
    self listOfChanges contents: (changes select: [:change| change type = 'source']).
1569
96d29b2efc76 revised
tz
parents: 1568
diff changeset
  3074
    self valueOfFilter value: '* checkin'.
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  3075
b37202441764 revised
tz
parents: 1556
diff changeset
  3076
!
b37202441764 revised
tz
parents: 1556
diff changeset
  3077
b37202441764 revised
tz
parents: 1556
diff changeset
  3078
doFilterFileIns
b37202441764 revised
tz
parents: 1556
diff changeset
  3079
    "filter the file in changes"
b37202441764 revised
tz
parents: 1556
diff changeset
  3080
1569
96d29b2efc76 revised
tz
parents: 1568
diff changeset
  3081
    self selectionOfChange value: nil.
96d29b2efc76 revised
tz
parents: 1568
diff changeset
  3082
    self listOfChanges contents: #().
96d29b2efc76 revised
tz
parents: 1568
diff changeset
  3083
    self valueOfFilter value: '' withoutNotifying: self.
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  3084
    self listOfChanges contents: (changes select: [:change| change type = 'source']).
1636
14e3ccc3e7c6 use Workspace
tz
parents: 1569
diff changeset
  3085
    self valueOfFilter value: '* file*'.  
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  3086
b37202441764 revised
tz
parents: 1556
diff changeset
  3087
!
b37202441764 revised
tz
parents: 1556
diff changeset
  3088
b37202441764 revised
tz
parents: 1556
diff changeset
  3089
doFilterType: aFilterTypeString
b37202441764 revised
tz
parents: 1556
diff changeset
  3090
    "filter the changes with aFilterTypeString"
b37202441764 revised
tz
parents: 1556
diff changeset
  3091
1569
96d29b2efc76 revised
tz
parents: 1568
diff changeset
  3092
    self selectionOfChange value: nil.
96d29b2efc76 revised
tz
parents: 1568
diff changeset
  3093
    self valueOfFilter value: '' withoutNotifying: self.
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  3094
    self listOfChanges contents: (changes select: [:change| change type = aFilterTypeString]).
b37202441764 revised
tz
parents: 1556
diff changeset
  3095
    self autoSelectLast
b37202441764 revised
tz
parents: 1556
diff changeset
  3096
b37202441764 revised
tz
parents: 1556
diff changeset
  3097
!
b37202441764 revised
tz
parents: 1556
diff changeset
  3098
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3099
doFindSnapshot: what
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3100
    "finds the last made snapshot and selects it"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3101
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3102
    self listOfChanges detect: [:change| change type = 'image'] ifNone: [^self warn: 'No snapshot found!!'].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3103
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3104
    self withSelectedChangeDo:[:change|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3105
        |snapshotNr snapshotFound|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3106
        snapshotNr := self listOfChanges indexOf: change.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3107
        snapshotFound := false.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3108
        [snapshotNr > 0 and: [snapshotFound not]] 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3109
        whileTrue: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3110
        [
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3111
            what = 'last'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3112
            ifTrue:
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3113
            [
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3114
                snapshotNr := snapshotNr - 1.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3115
                snapshotNr == 0 ifTrue: [snapshotNr := self listOfChanges size].   
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3116
            ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3117
            ifFalse:
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3118
            [
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3119
                snapshotNr := snapshotNr + 1.
1556
tz
parents: 1554
diff changeset
  3120
                snapshotNr > self listOfChanges size ifTrue: [snapshotNr := 1].
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3121
            ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3122
            (self listOfChanges at: snapshotNr ifAbsent: [^self autoSelectChange: (what = 'last' ifTrue: [self listOfChanges last] ifFalse: [self listOfChanges first])]) type = 'image'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3123
            ifTrue: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3124
            [
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3125
                snapshotFound := true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3126
                self autoSelectChange:(self listOfChanges at: snapshotNr)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3127
            ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3128
        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3129
    ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3130
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3131
1556
tz
parents: 1554
diff changeset
  3132
doLoad
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3133
    "opens a dialog for loading changes from a file"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3134
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3135
    |fileName|
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3136
    (fileName :=
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3137
        (FileSelectionBrowser
1556
tz
parents: 1554
diff changeset
  3138
            request: 'Load Changes List'
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3139
            fileName: changeFileName
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3140
            withFileFilters: #('c*'))) notNil
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3141
    ifTrue:
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3142
    [
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3143
        changeFileName := fileName.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3144
        changes removeAll.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3145
        self readChangesFileInBackground:true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3146
        self unselectChange.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3147
        Processor addTimedBlock:autoUpdateBlock afterSeconds:5.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3148
        self updateInfoLabel.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3149
        self autoSelectLast
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3150
    ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3151
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3152
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3153
doReload
1546
ffea21e237ed revised
tz
parents: 1545
diff changeset
  3154
    "reloads the changes from the file"
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3155
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3156
    changes removeAll.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3157
    self unselectChange.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3158
    self readChangesFileInBackground:true.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3159
    self autoSelectLast
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3160
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3161
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3162
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3163
doSave
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3164
    "write back the changes file. To avoid problems when the disk is full
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3165
     or a crash occurs while writing (well, or someone kills us), 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3166
     first write the stuff to a new temporary file. If this works ok,
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3167
     rename the old change-file to a .bak file and finally rename the
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3168
     tempfile back to the change-file. 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3169
     That way, if anything happens, either the original file is left unchanged,
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3170
     or we have at least a backup of the previous change file."
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3171
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  3172
    |inStream outStream tempfile stamp f| 
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3173
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3174
    self valueOfNotReading value ifFalse: [^nil].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3175
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3176
    editingClassSource ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3177
        (self confirm:'You are editing a classes sourceFile (not a changeFile) !!\Are you certain, you want to overwrite it ?' withCRs)
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3178
        ifFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3179
            ^ false
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3180
        ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3181
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3182
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3183
    tempfile := Filename newTemporaryIn:nil.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3184
    tempfile exists ifTrue:[tempfile remove].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3185
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3186
    outStream := tempfile writeStream.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3187
    outStream isNil ifTrue:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3188
        self warn:'Cannot create temporary file in current directory.'.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3189
        ^ false
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3190
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3191
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3192
    inStream := FileStream readonlyFileNamed:changeFileName.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3193
    inStream isNil ifTrue:[^ false].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3194
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3195
    self withCursor:(Cursor write) do:[
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  3196
        |excla sawExcla done first chunk
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3197
         nChanges "{Class:SmallInteger}" |
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3198
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3199
        Stream writeErrorSignal handle:[:ex |
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3200
            self warn:('Could not update the changes file.\\' , ex errorString) withCRs.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3201
            ^ false
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3202
        ] do:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3203
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  3204
            self valueOfNotSaving value: false.
b37202441764 revised
tz
parents: 1556
diff changeset
  3205
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3206
            excla := inStream class chunkSeparator.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3207
            nChanges := changes size.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3208
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3209
            1 to:nChanges do:[:index |     
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3210
                inStream position: (changes at: index) position.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3211
                sawExcla := inStream peekFor:excla.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3212
                chunk := inStream nextChunk.
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  3213
b37202441764 revised
tz
parents: 1556
diff changeset
  3214
                (chunk notNil
b37202441764 revised
tz
parents: 1556
diff changeset
  3215
                and:[(chunk startsWith:'''---- snap') not]) ifTrue:[
b37202441764 revised
tz
parents: 1556
diff changeset
  3216
                    (stamp := (changes at:index) timeStamp) notNil ifTrue:[
b37202441764 revised
tz
parents: 1556
diff changeset
  3217
                        outStream nextPutAll:'''---- timestamp ' , stamp , ' ----'''.
b37202441764 revised
tz
parents: 1556
diff changeset
  3218
                        outStream nextPut:excla; cr.
b37202441764 revised
tz
parents: 1556
diff changeset
  3219
                    ].
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3220
                ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3221
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  3222
                sawExcla ifTrue:[     
b37202441764 revised
tz
parents: 1556
diff changeset
  3223
                    outStream nextPut:excla.   
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3224
                    outStream nextChunkPut:chunk.
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  3225
                    outStream cr; cr.
b37202441764 revised
tz
parents: 1556
diff changeset
  3226
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3227
                    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3228
                     a method-definition chunk - skip followups
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3229
                    "
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3230
                    done := false.
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  3231
                    first := true.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3232
                    [done] whileFalse:[
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3233
                        chunk := inStream nextChunk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3234
                        chunk isNil ifTrue:[
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  3235
                            outStream cr; cr.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3236
                            done := true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3237
                        ] ifFalse:[
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  3238
                            chunk isEmpty ifTrue:[
b37202441764 revised
tz
parents: 1556
diff changeset
  3239
                                outStream space; nextChunkPut:chunk; cr; cr.
b37202441764 revised
tz
parents: 1556
diff changeset
  3240
                                done := true.
b37202441764 revised
tz
parents: 1556
diff changeset
  3241
                            ] ifFalse:[
b37202441764 revised
tz
parents: 1556
diff changeset
  3242
                                first ifFalse:[
b37202441764 revised
tz
parents: 1556
diff changeset
  3243
                                    outStream cr; cr.
b37202441764 revised
tz
parents: 1556
diff changeset
  3244
                                ].
b37202441764 revised
tz
parents: 1556
diff changeset
  3245
                                outStream nextChunkPut:chunk.
b37202441764 revised
tz
parents: 1556
diff changeset
  3246
                            ].
b37202441764 revised
tz
parents: 1556
diff changeset
  3247
                        ].
b37202441764 revised
tz
parents: 1556
diff changeset
  3248
                        first := false.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3249
                    ].
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  3250
                ] ifFalse:[
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3251
                    outStream nextChunkPut:chunk.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3252
                    outStream cr
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3253
                ]
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3254
            ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3255
            outStream close.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3256
            inStream close.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3257
        ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3258
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3259
        f := changeFileName asFilename.
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3260
        f renameTo:(f withSuffix:'bak').
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3261
        tempfile renameTo:changeFileName.
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  3262
        self doReload.
b37202441764 revised
tz
parents: 1556
diff changeset
  3263
        modified := false.
b37202441764 revised
tz
parents: 1556
diff changeset
  3264
        self valueOfNotSaving value: true.
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3265
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3266
    ^ true
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3267
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3268
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3269
! !
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3270
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3271
!NewChangesBrowser::Change methodsFor:'accessing'!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3272
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3273
category
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3274
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3275
    ^category
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3276
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3277
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3278
category: aValue
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3279
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3280
    category := aValue
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3281
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3282
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3283
chunk
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3284
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3285
    ^chunk
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3286
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3287
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3288
chunk: aValue
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3289
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3290
    chunk := aValue
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3291
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3292
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3293
className
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3294
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3295
    ^className
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3296
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3297
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3298
className: aValue
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3299
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3300
    className := aValue
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3301
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3302
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3303
delta
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3304
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3305
    delta size = 0 ifTrue: [^''].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3306
    delta = '='    ifTrue: [^'Current'].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3307
    delta = '?'    ifTrue: [^'No class'].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3308
    delta = '-'    ifTrue: [^'Removed'].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3309
    delta = '+'    ifTrue: [^'New'].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3310
    ^delta
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3311
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3312
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3313
delta: aValue
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3314
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3315
    delta := aValue
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3316
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3317
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3318
followUp
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3319
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3320
    ^followUp
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3321
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3322
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3323
followUp: aValue
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3324
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3325
    followUp := aValue
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3326
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3327
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  3328
lastPosition: aValue
b37202441764 revised
tz
parents: 1556
diff changeset
  3329
b37202441764 revised
tz
parents: 1556
diff changeset
  3330
    lastPosition := aValue
b37202441764 revised
tz
parents: 1556
diff changeset
  3331
!
b37202441764 revised
tz
parents: 1556
diff changeset
  3332
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3333
listColor
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3334
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3335
    (string at: 3) ~~ $- ifTrue: 
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3336
    [
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3337
        (self type = 'class') ifTrue: [^Color gray].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3338
        ^Color white
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3339
    ].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3340
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3341
    (string includesMatchString: '---- s') ifTrue: [^Color red].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3342
    (string includesMatchString: '---- f') ifTrue: [^Color cyan: 100 magenta: 20 yellow: 20].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3343
    (string includesMatchString: '---- c') ifTrue: [^Color blue].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3344
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3345
    ^Color white
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3346
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3347
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3348
position
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3349
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3350
    ^position
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3351
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3352
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3353
position: aValue
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3354
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3355
    position := aValue
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3356
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3357
1568
b37202441764 revised
tz
parents: 1556
diff changeset
  3358
positions
b37202441764 revised
tz
parents: 1556
diff changeset
  3359
b37202441764 revised
tz
parents: 1556
diff changeset
  3360
    ^position printString, ' - ', lastPosition printString
b37202441764 revised
tz
parents: 1556
diff changeset
  3361
!
b37202441764 revised
tz
parents: 1556
diff changeset
  3362
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3363
string
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3364
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3365
    ^string
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3366
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3367
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3368
string: aValue
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3369
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3370
    string := aValue
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3371
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3372
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3373
timeStamp
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3374
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3375
    ^timeStamp
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3376
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3377
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3378
timeStamp: aValue
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3379
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3380
    timeStamp := aValue
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3381
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3382
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3383
type
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3384
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3385
    (type = 'doIt' or: [type = 'remove']) ifTrue: [^'class'].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3386
    (type size = 0) ifTrue: [(string includesMatchString: '---- s') ifTrue: [^'image'] ifFalse: [^'source']].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3387
    (self category = nil) ifTrue: [^'class'].
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3388
    ^'method'
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3389
!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3390
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3391
type: aValue
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3392
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3393
    type := aValue
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3394
! !
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3395
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3396
!NewChangesBrowser class methodsFor:'documentation'!
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3397
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3398
version
1636
14e3ccc3e7c6 use Workspace
tz
parents: 1569
diff changeset
  3399
    ^ '$Header: /cvs/stx/stx/libtool/NewChangesBrowser.st,v 1.8 1998-05-12 15:59:35 tz Exp $'
1545
e2d6f6ca36ef initial checkin
tz
parents:
diff changeset
  3400
! !