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