VersionDiffBrowser.st
changeset 12512 072f76033d49
parent 11962 1d931eea22af
child 12571 b2e5fdb702cb
child 12865 7c68b472c4a6
equal deleted inserted replaced
12511:2edbe2a9d758 12512:072f76033d49
  1005 
  1005 
  1006 methodInChangedDoubleClicked:index
  1006 methodInChangedDoubleClicked:index
  1007     self browseClassInM.
  1007     self browseClassInM.
  1008 !
  1008 !
  1009 
  1009 
       
  1010 removeSelectedChangeInBFromImage
       
  1011     |change cls sel op|
       
  1012 
       
  1013     change := self selectedChangeInB.
       
  1014     change isMethodChange ifTrue:[
       
  1015 	(cls := change changeClass) notNil ifTrue:[
       
  1016 	    (sel := change selector) notNil ifTrue:[
       
  1017 		RefactoryChangeManager notNil ifTrue:[
       
  1018 		    op := RemoveMethodChange remove:sel from:cls.
       
  1019 		    RefactoryChangeManager performChange: op.
       
  1020 		] ifFalse:[
       
  1021 		    cls removeSelector:sel
       
  1022 		]
       
  1023 	    ]
       
  1024 	]
       
  1025     ]
       
  1026 
       
  1027     "Modified: / 15-08-2010 / 21:35:00 / cg"
       
  1028 ! !
       
  1029 
       
  1030 !VersionDiffBrowser methodsFor:'aspects'!
       
  1031 
       
  1032 boxAVisible
       
  1033     boxAVisible isNil ifTrue:[
       
  1034 	boxAVisible := true asValue.
       
  1035     ].
       
  1036     ^ boxAVisible.
       
  1037 !
       
  1038 
       
  1039 boxBVisible
       
  1040     boxBVisible isNil ifTrue:[
       
  1041 	boxBVisible := true asValue.
       
  1042     ].
       
  1043     ^ boxBVisible.
       
  1044 !
       
  1045 
       
  1046 boxMVisible
       
  1047     boxMVisible isNil ifTrue:[
       
  1048 	boxMVisible := true asValue.
       
  1049     ].
       
  1050     ^ boxMVisible.
       
  1051 !
       
  1052 
       
  1053 canIncludeExtensionsHolder
       
  1054     "can include extensions ? (menu item enabler)"
       
  1055 
       
  1056     canIncludeExtensionsHolder isNil ifTrue:[
       
  1057 	canIncludeExtensionsHolder := true asValue.
       
  1058     ].
       
  1059     ^ canIncludeExtensionsHolder.
       
  1060 !
       
  1061 
       
  1062 changedLabelHolder
       
  1063     "
       
  1064     aspect for the label of the changed method box.
       
  1065 
       
  1066     <return: ValueHolder on: nil>
       
  1067     "
       
  1068 
       
  1069     changedLabelHolder isNil ifTrue:[
       
  1070 	changedLabelHolder := ValueHolder new.
       
  1071     ].
       
  1072     ^ changedLabelHolder.
       
  1073 !
       
  1074 
       
  1075 diffTextLabelA
       
  1076     "
       
  1077     aspect for the label for version A.
       
  1078 
       
  1079     <return: ValueHolder on: nil>
       
  1080     "
       
  1081 
       
  1082     diffTextLabelA isNil ifTrue:[
       
  1083 	diffTextLabelA := ValueHolder new.
       
  1084     ].
       
  1085     ^ diffTextLabelA.
       
  1086 !
       
  1087 
       
  1088 diffTextLabelB
       
  1089     "
       
  1090     aspect for the label for version B.
       
  1091 
       
  1092     <return: ValueHolder on: nil>
       
  1093     "
       
  1094 
       
  1095     diffTextLabelB isNil ifTrue:[
       
  1096 	diffTextLabelB := ValueHolder new.
       
  1097     ].
       
  1098     ^ diffTextLabelB.
       
  1099 !
       
  1100 
       
  1101 diffTextView
       
  1102     "
       
  1103     return the component for the diff text view.
       
  1104 
       
  1105     <return: HVScrollableView>
       
  1106     "
       
  1107     |v|
       
  1108 
       
  1109     diffTextView isNil ifTrue:[
       
  1110 	v := DiffCodeView basicNew.
       
  1111 	v textViewClass:CodeView.
       
  1112 	v initialize.
       
  1113 	diffTextView := HVScrollableView
       
  1114 			   forView:v
       
  1115 			   miniScrollerH:true miniScrollerV:false.
       
  1116 	diffTextView addNextPreviousButtons.
       
  1117     ].
       
  1118     ^ diffTextView
       
  1119 
       
  1120     "Modified: / 06-10-2006 / 14:30:42 / cg"
       
  1121 !
       
  1122 
       
  1123 includeCategoryChanges
       
  1124     ^ self includeCategoryChangesHolder value
       
  1125 
       
  1126     "Created: / 17-07-2012 / 18:22:34 / cg"
       
  1127 !
       
  1128 
       
  1129 includeCategoryChanges:aBoolean
       
  1130     self includeCategoryChangesHolder value:aBoolean
       
  1131 
       
  1132     "Created: / 17-07-2012 / 17:50:41 / cg"
       
  1133 !
       
  1134 
       
  1135 includeCategoryChangesHolder
       
  1136     includeCategoryChangesHolder isNil ifTrue:[
       
  1137         includeCategoryChangesHolder := true asValue.
       
  1138         includeCategoryChangesHolder addDependent:self.
       
  1139     ].
       
  1140     ^ includeCategoryChangesHolder.
       
  1141 
       
  1142     "Modified: / 06-03-2012 / 15:36:52 / cg"
       
  1143     "Created: / 17-07-2012 / 16:47:58 / cg"
       
  1144 !
       
  1145 
       
  1146 includeExtensions
       
  1147     ^ self includeExtensionsHolder value
       
  1148 
       
  1149     "Created: / 13-09-2011 / 11:48:51 / cg"
       
  1150 !
       
  1151 
       
  1152 includeExtensions:aBoolean
       
  1153     self includeExtensionsHolder value:aBoolean
       
  1154 
       
  1155     "Created: / 13-09-2011 / 11:48:41 / cg"
       
  1156 !
       
  1157 
       
  1158 includeExtensionsHolder
       
  1159     "only compare base-methods or include extensions ?"
       
  1160 
       
  1161     includeExtensionsHolder isNil ifTrue:[
       
  1162 	includeExtensionsHolder := false asValue.
       
  1163 	includeExtensionsHolder addDependent:self.
       
  1164     ].
       
  1165     ^ includeExtensionsHolder.
       
  1166 
       
  1167     "Modified: / 06-03-2012 / 15:36:52 / cg"
       
  1168 !
       
  1169 
       
  1170 includeVersionMethods
       
  1171     ^ self includeVersionMethodsHolder value
       
  1172 
       
  1173     "Created: / 13-09-2011 / 11:48:51 / cg"
       
  1174 !
       
  1175 
       
  1176 includeVersionMethods:aBoolean
       
  1177     self includeVersionMethodsHolder value:aBoolean
       
  1178 
       
  1179     "Created: / 13-09-2011 / 11:48:41 / cg"
       
  1180 !
       
  1181 
       
  1182 includeVersionMethodsHolder
       
  1183     includeVersionMethodsHolder isNil ifTrue:[
       
  1184         includeVersionMethodsHolder := true asValue.
       
  1185         includeVersionMethodsHolder addDependent:self.
       
  1186     ].
       
  1187     ^ includeVersionMethodsHolder.
       
  1188 
       
  1189     "Modified: / 06-03-2012 / 15:36:52 / cg"
       
  1190     "Created: / 17-07-2012 / 16:47:58 / cg"
       
  1191 !
       
  1192 
       
  1193 infoHolder
       
  1194     infoHolder isNil ifTrue:[
       
  1195 	infoHolder := ValueHolder new.
       
  1196     ].
       
  1197     ^ infoHolder.
       
  1198 !
       
  1199 
       
  1200 methodText
       
  1201     "
       
  1202     aspect for the text in the method text view.
       
  1203 
       
  1204     <return: ValueHolder on: nil>
       
  1205     "
       
  1206 
       
  1207     methodText isNil ifTrue:[
       
  1208 	methodText := ValueHolder new.
       
  1209     ].
       
  1210     ^ methodText.
       
  1211 !
       
  1212 
       
  1213 methodsChanged
       
  1214     "
       
  1215     aspect for the 'changed method' list.
       
  1216 
       
  1217     <return: List>
       
  1218     "
       
  1219 
       
  1220     methodsChanged isNil ifTrue:[
       
  1221 	methodsChanged := List new.
       
  1222     ].
       
  1223     ^ methodsChanged.
       
  1224 !
       
  1225 
       
  1226 methodsChangedSelection
       
  1227     "
       
  1228     aspect for the selection holder of 'changed method'-list.
       
  1229 
       
  1230     <return: ValueHolder on: nil>
       
  1231     "
       
  1232 
       
  1233     methodsChangedSelection isNil ifTrue:[
       
  1234 	methodsChangedSelection := ValueHolder new.
       
  1235     ].
       
  1236     ^ methodsChangedSelection.
       
  1237 !
       
  1238 
       
  1239 methodsOnlyInA
       
  1240     "aspect for the 'method only in version A' list."
       
  1241 
       
  1242     methodsOnlyInA isNil ifTrue:[
       
  1243 	methodsOnlyInA := List new.
       
  1244     ].
       
  1245     ^ methodsOnlyInA.
       
  1246 
       
  1247     "Modified: / 25-07-2006 / 11:14:43 / cg"
       
  1248 !
       
  1249 
       
  1250 methodsOnlyInASelection
       
  1251     "aspect for the selection holder of 'method only in version A'-list."
       
  1252 
       
  1253     methodsOnlyInASelection isNil ifTrue:[
       
  1254 	methodsOnlyInASelection := ValueHolder new.
       
  1255     ].
       
  1256     ^ methodsOnlyInASelection.
       
  1257 
       
  1258     "Modified: / 25-07-2006 / 11:14:53 / cg"
       
  1259 !
       
  1260 
       
  1261 methodsOnlyInB
       
  1262     "aspect for the 'method only in version B' list"
       
  1263 
       
  1264     methodsOnlyInB isNil ifTrue:[
       
  1265 	methodsOnlyInB := List new.
       
  1266     ].
       
  1267     ^ methodsOnlyInB.
       
  1268 
       
  1269     "Modified: / 25-07-2006 / 11:14:48 / cg"
       
  1270 !
       
  1271 
       
  1272 methodsOnlyInBSelection
       
  1273     "aspect for the selection holder of 'method only in version B'-list."
       
  1274 
       
  1275     methodsOnlyInBSelection isNil ifTrue:[
       
  1276 	methodsOnlyInBSelection := ValueHolder new.
       
  1277     ].
       
  1278     ^ methodsOnlyInBSelection.
       
  1279 
       
  1280     "Modified: / 25-07-2006 / 11:15:00 / cg"
       
  1281 !
       
  1282 
       
  1283 onlyInALabelHolder
       
  1284     "aspect for the label for 'method only in version A'."
       
  1285 
       
  1286     onlyInALabelHolder isNil ifTrue:[
       
  1287 	onlyInALabelHolder := ValueHolder new.
       
  1288     ].
       
  1289     ^ onlyInALabelHolder.
       
  1290 
       
  1291     "Modified: / 25-07-2006 / 11:15:12 / cg"
       
  1292 !
       
  1293 
       
  1294 onlyInBLabelHolder
       
  1295     "aspect for the label for 'method only in version B'."
       
  1296 
       
  1297     onlyInBLabelHolder isNil ifTrue:[
       
  1298 	onlyInBLabelHolder := ValueHolder new.
       
  1299     ].
       
  1300     ^ onlyInBLabelHolder.
       
  1301 
       
  1302     "Modified: / 25-07-2006 / 11:15:07 / cg"
       
  1303 ! !
       
  1304 
       
  1305 !VersionDiffBrowser methodsFor:'aspects-exported'!
       
  1306 
       
  1307 changedLabelHolder:aValueHolder
       
  1308     builder aspectAt:#changedLabelHolder put:aValueHolder.
       
  1309 
       
  1310 !
       
  1311 
       
  1312 classHolder:aValueHolder
       
  1313     classHolder notNil ifTrue:[
       
  1314 	classHolder removeDependent:self
       
  1315     ].
       
  1316     classHolder := aValueHolder.
       
  1317     classHolder notNil ifTrue:[
       
  1318 	classHolder addDependent:self
       
  1319     ]
       
  1320 !
       
  1321 
       
  1322 onlyInALabelHolder:aValueHolder
       
  1323     builder aspectAt:#onlyInALabelHolder put:aValueHolder.
       
  1324 !
       
  1325 
       
  1326 onlyInBLabelHolder:aValueHolder
       
  1327     builder aspectAt:#onlyInBLabelHolder put:aValueHolder.
       
  1328 !
       
  1329 
       
  1330 versionAHolder:aValueHolder
       
  1331     versionAHolder notNil ifTrue:[
       
  1332 	versionAHolder removeDependent:self
       
  1333     ].
       
  1334     versionAHolder := aValueHolder.
       
  1335     versionAHolder notNil ifTrue:[
       
  1336 	versionAHolder addDependent:self
       
  1337     ]
       
  1338 !
       
  1339 
       
  1340 versionBHolder:aValueHolder
       
  1341     versionBHolder notNil ifTrue:[
       
  1342 	versionBHolder removeDependent:self
       
  1343     ].
       
  1344     versionBHolder := aValueHolder.
       
  1345     versionBHolder notNil ifTrue:[
       
  1346 	versionBHolder addDependent:self
       
  1347     ]
       
  1348 ! !
       
  1349 
       
  1350 !VersionDiffBrowser methodsFor:'aspects-menu'!
       
  1351 
       
  1352 canAcceptInCodeView
       
  1353     ^ self hasChangeSelectedInA
       
  1354       or:[self hasChangeSelectedInB
       
  1355       or:[self hasChangeSelectedInM]]
       
  1356 !
       
  1357 
       
  1358 hasChangeSelectedInA
       
  1359     ^ self selectedChangeInA notNil
       
  1360 !
       
  1361 
       
  1362 hasChangeSelectedInB
       
  1363     ^ self selectedChangeInB notNil
       
  1364 !
       
  1365 
       
  1366 hasChangeSelectedInM
       
  1367     ^ self methodsChangedSelection value notNil
       
  1368 ! !
       
  1369 
       
  1370 !VersionDiffBrowser methodsFor:'change & update'!
       
  1371 
  1010 methodsChangedSelectionChanged
  1372 methodsChangedSelectionChanged
  1011     "
  1373     "
  1012     the selection in the list of the 'changed methods' changed.
  1374     the selection in the list of the 'changed methods' changed.
  1013     Reset the selection of the two other lists and calc the method change.
  1375     Reset the selection of the two other lists and calc the method change.
  1014 
  1376 
  1039                         ]
  1401                         ]
  1040                     ]
  1402                     ]
  1041                 ].
  1403                 ].
  1042             ].
  1404             ].
  1043             self diffTextView
  1405             self diffTextView
  1044                 text1:(changeA prettyPrintedSource) text2:(changeB prettyPrintedSource);
  1406                 text1:(changeA prettyPrintedSource) 
  1045                 moveToNextChanged
  1407                 text2:(changeB prettyPrintedSource)        
  1046         ].
  1408         ].
  1047         self showDiffTextView.
  1409         self showDiffTextView.
       
  1410         self diffTextView moveToNextChanged
  1048     ]
  1411     ]
  1049 
  1412 
  1050     "Modified: / 03-09-1999 / 15:01:30 / ps"
  1413     "Modified: / 03-09-1999 / 15:01:30 / ps"
  1051     "Modified: / 17-07-2012 / 18:27:06 / cg"
  1414     "Modified: / 17-07-2012 / 18:27:06 / cg"
  1052 !
  1415 !
  1096         self showSingleTextView.
  1459         self showSingleTextView.
  1097     ]
  1460     ]
  1098 
  1461 
  1099     "Modified: / 17-07-2012 / 18:31:32 / cg"
  1462     "Modified: / 17-07-2012 / 18:31:32 / cg"
  1100 !
  1463 !
  1101 
       
  1102 removeSelectedChangeInBFromImage
       
  1103     |change cls sel op|
       
  1104 
       
  1105     change := self selectedChangeInB.
       
  1106     change isMethodChange ifTrue:[
       
  1107 	(cls := change changeClass) notNil ifTrue:[
       
  1108 	    (sel := change selector) notNil ifTrue:[
       
  1109 		RefactoryChangeManager notNil ifTrue:[
       
  1110 		    op := RemoveMethodChange remove:sel from:cls.
       
  1111 		    RefactoryChangeManager performChange: op.
       
  1112 		] ifFalse:[
       
  1113 		    cls removeSelector:sel
       
  1114 		]
       
  1115 	    ]
       
  1116 	]
       
  1117     ]
       
  1118 
       
  1119     "Modified: / 15-08-2010 / 21:35:00 / cg"
       
  1120 ! !
       
  1121 
       
  1122 !VersionDiffBrowser methodsFor:'aspects'!
       
  1123 
       
  1124 boxAVisible
       
  1125     boxAVisible isNil ifTrue:[
       
  1126 	boxAVisible := true asValue.
       
  1127     ].
       
  1128     ^ boxAVisible.
       
  1129 !
       
  1130 
       
  1131 boxBVisible
       
  1132     boxBVisible isNil ifTrue:[
       
  1133 	boxBVisible := true asValue.
       
  1134     ].
       
  1135     ^ boxBVisible.
       
  1136 !
       
  1137 
       
  1138 boxMVisible
       
  1139     boxMVisible isNil ifTrue:[
       
  1140 	boxMVisible := true asValue.
       
  1141     ].
       
  1142     ^ boxMVisible.
       
  1143 !
       
  1144 
       
  1145 canIncludeExtensionsHolder
       
  1146     "can include extensions ? (menu item enabler)"
       
  1147 
       
  1148     canIncludeExtensionsHolder isNil ifTrue:[
       
  1149 	canIncludeExtensionsHolder := true asValue.
       
  1150     ].
       
  1151     ^ canIncludeExtensionsHolder.
       
  1152 !
       
  1153 
       
  1154 changedLabelHolder
       
  1155     "
       
  1156     aspect for the label of the changed method box.
       
  1157 
       
  1158     <return: ValueHolder on: nil>
       
  1159     "
       
  1160 
       
  1161     changedLabelHolder isNil ifTrue:[
       
  1162 	changedLabelHolder := ValueHolder new.
       
  1163     ].
       
  1164     ^ changedLabelHolder.
       
  1165 !
       
  1166 
       
  1167 diffTextLabelA
       
  1168     "
       
  1169     aspect for the label for version A.
       
  1170 
       
  1171     <return: ValueHolder on: nil>
       
  1172     "
       
  1173 
       
  1174     diffTextLabelA isNil ifTrue:[
       
  1175 	diffTextLabelA := ValueHolder new.
       
  1176     ].
       
  1177     ^ diffTextLabelA.
       
  1178 !
       
  1179 
       
  1180 diffTextLabelB
       
  1181     "
       
  1182     aspect for the label for version B.
       
  1183 
       
  1184     <return: ValueHolder on: nil>
       
  1185     "
       
  1186 
       
  1187     diffTextLabelB isNil ifTrue:[
       
  1188 	diffTextLabelB := ValueHolder new.
       
  1189     ].
       
  1190     ^ diffTextLabelB.
       
  1191 !
       
  1192 
       
  1193 diffTextView
       
  1194     "
       
  1195     return the component for the diff text view.
       
  1196 
       
  1197     <return: HVScrollableView>
       
  1198     "
       
  1199     |v|
       
  1200 
       
  1201     diffTextView isNil ifTrue:[
       
  1202 	v := DiffCodeView basicNew.
       
  1203 	v textViewClass:CodeView.
       
  1204 	v initialize.
       
  1205 	diffTextView := HVScrollableView
       
  1206 			   forView:v
       
  1207 			   miniScrollerH:true miniScrollerV:false.
       
  1208 	diffTextView addNextPreviousButtons.
       
  1209     ].
       
  1210     ^ diffTextView
       
  1211 
       
  1212     "Modified: / 06-10-2006 / 14:30:42 / cg"
       
  1213 !
       
  1214 
       
  1215 includeCategoryChanges
       
  1216     ^ self includeCategoryChangesHolder value
       
  1217 
       
  1218     "Created: / 17-07-2012 / 18:22:34 / cg"
       
  1219 !
       
  1220 
       
  1221 includeCategoryChanges:aBoolean
       
  1222     self includeCategoryChangesHolder value:aBoolean
       
  1223 
       
  1224     "Created: / 17-07-2012 / 17:50:41 / cg"
       
  1225 !
       
  1226 
       
  1227 includeCategoryChangesHolder
       
  1228     includeCategoryChangesHolder isNil ifTrue:[
       
  1229         includeCategoryChangesHolder := true asValue.
       
  1230         includeCategoryChangesHolder addDependent:self.
       
  1231     ].
       
  1232     ^ includeCategoryChangesHolder.
       
  1233 
       
  1234     "Modified: / 06-03-2012 / 15:36:52 / cg"
       
  1235     "Created: / 17-07-2012 / 16:47:58 / cg"
       
  1236 !
       
  1237 
       
  1238 includeExtensions
       
  1239     ^ self includeExtensionsHolder value
       
  1240 
       
  1241     "Created: / 13-09-2011 / 11:48:51 / cg"
       
  1242 !
       
  1243 
       
  1244 includeExtensions:aBoolean
       
  1245     self includeExtensionsHolder value:aBoolean
       
  1246 
       
  1247     "Created: / 13-09-2011 / 11:48:41 / cg"
       
  1248 !
       
  1249 
       
  1250 includeExtensionsHolder
       
  1251     "only compare base-methods or include extensions ?"
       
  1252 
       
  1253     includeExtensionsHolder isNil ifTrue:[
       
  1254 	includeExtensionsHolder := false asValue.
       
  1255 	includeExtensionsHolder addDependent:self.
       
  1256     ].
       
  1257     ^ includeExtensionsHolder.
       
  1258 
       
  1259     "Modified: / 06-03-2012 / 15:36:52 / cg"
       
  1260 !
       
  1261 
       
  1262 includeVersionMethods
       
  1263     ^ self includeVersionMethodsHolder value
       
  1264 
       
  1265     "Created: / 13-09-2011 / 11:48:51 / cg"
       
  1266 !
       
  1267 
       
  1268 includeVersionMethods:aBoolean
       
  1269     self includeVersionMethodsHolder value:aBoolean
       
  1270 
       
  1271     "Created: / 13-09-2011 / 11:48:41 / cg"
       
  1272 !
       
  1273 
       
  1274 includeVersionMethodsHolder
       
  1275     includeVersionMethodsHolder isNil ifTrue:[
       
  1276         includeVersionMethodsHolder := true asValue.
       
  1277         includeVersionMethodsHolder addDependent:self.
       
  1278     ].
       
  1279     ^ includeVersionMethodsHolder.
       
  1280 
       
  1281     "Modified: / 06-03-2012 / 15:36:52 / cg"
       
  1282     "Created: / 17-07-2012 / 16:47:58 / cg"
       
  1283 !
       
  1284 
       
  1285 infoHolder
       
  1286     infoHolder isNil ifTrue:[
       
  1287 	infoHolder := ValueHolder new.
       
  1288     ].
       
  1289     ^ infoHolder.
       
  1290 !
       
  1291 
       
  1292 methodText
       
  1293     "
       
  1294     aspect for the text in the method text view.
       
  1295 
       
  1296     <return: ValueHolder on: nil>
       
  1297     "
       
  1298 
       
  1299     methodText isNil ifTrue:[
       
  1300 	methodText := ValueHolder new.
       
  1301     ].
       
  1302     ^ methodText.
       
  1303 !
       
  1304 
       
  1305 methodsChanged
       
  1306     "
       
  1307     aspect for the 'changed method' list.
       
  1308 
       
  1309     <return: List>
       
  1310     "
       
  1311 
       
  1312     methodsChanged isNil ifTrue:[
       
  1313 	methodsChanged := List new.
       
  1314     ].
       
  1315     ^ methodsChanged.
       
  1316 !
       
  1317 
       
  1318 methodsChangedSelection
       
  1319     "
       
  1320     aspect for the selection holder of 'changed method'-list.
       
  1321 
       
  1322     <return: ValueHolder on: nil>
       
  1323     "
       
  1324 
       
  1325     methodsChangedSelection isNil ifTrue:[
       
  1326 	methodsChangedSelection := ValueHolder new.
       
  1327     ].
       
  1328     ^ methodsChangedSelection.
       
  1329 !
       
  1330 
       
  1331 methodsOnlyInA
       
  1332     "aspect for the 'method only in version A' list."
       
  1333 
       
  1334     methodsOnlyInA isNil ifTrue:[
       
  1335 	methodsOnlyInA := List new.
       
  1336     ].
       
  1337     ^ methodsOnlyInA.
       
  1338 
       
  1339     "Modified: / 25-07-2006 / 11:14:43 / cg"
       
  1340 !
       
  1341 
       
  1342 methodsOnlyInASelection
       
  1343     "aspect for the selection holder of 'method only in version A'-list."
       
  1344 
       
  1345     methodsOnlyInASelection isNil ifTrue:[
       
  1346 	methodsOnlyInASelection := ValueHolder new.
       
  1347     ].
       
  1348     ^ methodsOnlyInASelection.
       
  1349 
       
  1350     "Modified: / 25-07-2006 / 11:14:53 / cg"
       
  1351 !
       
  1352 
       
  1353 methodsOnlyInB
       
  1354     "aspect for the 'method only in version B' list"
       
  1355 
       
  1356     methodsOnlyInB isNil ifTrue:[
       
  1357 	methodsOnlyInB := List new.
       
  1358     ].
       
  1359     ^ methodsOnlyInB.
       
  1360 
       
  1361     "Modified: / 25-07-2006 / 11:14:48 / cg"
       
  1362 !
       
  1363 
       
  1364 methodsOnlyInBSelection
       
  1365     "aspect for the selection holder of 'method only in version B'-list."
       
  1366 
       
  1367     methodsOnlyInBSelection isNil ifTrue:[
       
  1368 	methodsOnlyInBSelection := ValueHolder new.
       
  1369     ].
       
  1370     ^ methodsOnlyInBSelection.
       
  1371 
       
  1372     "Modified: / 25-07-2006 / 11:15:00 / cg"
       
  1373 !
       
  1374 
       
  1375 onlyInALabelHolder
       
  1376     "aspect for the label for 'method only in version A'."
       
  1377 
       
  1378     onlyInALabelHolder isNil ifTrue:[
       
  1379 	onlyInALabelHolder := ValueHolder new.
       
  1380     ].
       
  1381     ^ onlyInALabelHolder.
       
  1382 
       
  1383     "Modified: / 25-07-2006 / 11:15:12 / cg"
       
  1384 !
       
  1385 
       
  1386 onlyInBLabelHolder
       
  1387     "aspect for the label for 'method only in version B'."
       
  1388 
       
  1389     onlyInBLabelHolder isNil ifTrue:[
       
  1390 	onlyInBLabelHolder := ValueHolder new.
       
  1391     ].
       
  1392     ^ onlyInBLabelHolder.
       
  1393 
       
  1394     "Modified: / 25-07-2006 / 11:15:07 / cg"
       
  1395 ! !
       
  1396 
       
  1397 !VersionDiffBrowser methodsFor:'aspects-exported'!
       
  1398 
       
  1399 changedLabelHolder:aValueHolder
       
  1400     builder aspectAt:#changedLabelHolder put:aValueHolder.
       
  1401 
       
  1402 !
       
  1403 
       
  1404 classHolder:aValueHolder
       
  1405     classHolder notNil ifTrue:[
       
  1406 	classHolder removeDependent:self
       
  1407     ].
       
  1408     classHolder := aValueHolder.
       
  1409     classHolder notNil ifTrue:[
       
  1410 	classHolder addDependent:self
       
  1411     ]
       
  1412 !
       
  1413 
       
  1414 onlyInALabelHolder:aValueHolder
       
  1415     builder aspectAt:#onlyInALabelHolder put:aValueHolder.
       
  1416 !
       
  1417 
       
  1418 onlyInBLabelHolder:aValueHolder
       
  1419     builder aspectAt:#onlyInBLabelHolder put:aValueHolder.
       
  1420 !
       
  1421 
       
  1422 versionAHolder:aValueHolder
       
  1423     versionAHolder notNil ifTrue:[
       
  1424 	versionAHolder removeDependent:self
       
  1425     ].
       
  1426     versionAHolder := aValueHolder.
       
  1427     versionAHolder notNil ifTrue:[
       
  1428 	versionAHolder addDependent:self
       
  1429     ]
       
  1430 !
       
  1431 
       
  1432 versionBHolder:aValueHolder
       
  1433     versionBHolder notNil ifTrue:[
       
  1434 	versionBHolder removeDependent:self
       
  1435     ].
       
  1436     versionBHolder := aValueHolder.
       
  1437     versionBHolder notNil ifTrue:[
       
  1438 	versionBHolder addDependent:self
       
  1439     ]
       
  1440 ! !
       
  1441 
       
  1442 !VersionDiffBrowser methodsFor:'aspects-menu'!
       
  1443 
       
  1444 canAcceptInCodeView
       
  1445     ^ self hasChangeSelectedInA
       
  1446       or:[self hasChangeSelectedInB
       
  1447       or:[self hasChangeSelectedInM]]
       
  1448 !
       
  1449 
       
  1450 hasChangeSelectedInA
       
  1451     ^ self selectedChangeInA notNil
       
  1452 !
       
  1453 
       
  1454 hasChangeSelectedInB
       
  1455     ^ self selectedChangeInB notNil
       
  1456 !
       
  1457 
       
  1458 hasChangeSelectedInM
       
  1459     ^ self methodsChangedSelection value notNil
       
  1460 ! !
       
  1461 
       
  1462 !VersionDiffBrowser methodsFor:'change & update'!
       
  1463 
  1464 
  1464 update:something with:parameter from:changedObject
  1465 update:something with:parameter from:changedObject
  1465     ((changedObject == includeExtensionsHolder)
  1466     ((changedObject == includeExtensionsHolder)
  1466     or:[ changedObject == includeCategoryChangesHolder
  1467     or:[ changedObject == includeCategoryChangesHolder
  1467     or:[ changedObject == includeVersionMethodsHolder ]]) ifTrue:[
  1468     or:[ changedObject == includeVersionMethodsHolder ]]) ifTrue:[
  2444 ! !
  2445 ! !
  2445 
  2446 
  2446 !VersionDiffBrowser class methodsFor:'documentation'!
  2447 !VersionDiffBrowser class methodsFor:'documentation'!
  2447 
  2448 
  2448 version
  2449 version
  2449     ^ '$Header: /cvs/stx/stx/libtool/VersionDiffBrowser.st,v 1.111 2012-10-30 16:04:26 cg Exp $'
  2450     ^ '$Header: /cvs/stx/stx/libtool/VersionDiffBrowser.st,v 1.112 2013-03-23 11:37:08 cg Exp $'
  2450 !
  2451 !
  2451 
  2452 
  2452 version_CVS
  2453 version_CVS
  2453     ^ '$Header: /cvs/stx/stx/libtool/VersionDiffBrowser.st,v 1.111 2012-10-30 16:04:26 cg Exp $'
  2454     ^ '$Header: /cvs/stx/stx/libtool/VersionDiffBrowser.st,v 1.112 2013-03-23 11:37:08 cg Exp $'
  2454 ! !
  2455 ! !
       
  2456