[squeak-dev] The Trunk: Tools-fbs.494.mcz

commits at source.squeak.org commits at source.squeak.org
Wed Sep 11 18:03:04 UTC 2013


Frank Shearar uploaded a new version of Tools to project The Trunk:
http://source.squeak.org/trunk/Tools-fbs.494.mcz

==================== Summary ====================

Name: Tools-fbs.494
Author: fbs
Time: 11 September 2013, 7:02:17.414 pm
UUID: 1752cd19-0ce6-d244-a65b-01706c5df971
Ancestors: Tools-tpr.493

Browser >> #defineMessage:notifying: is nearly identical to #defineMessageFrom:notifying:, only it has no senders.

Turn it into a proper copy by delegating to the preferred method, and deprecate.

=============== Diff against Tools-tpr.493 ===============

Item was changed:
  ----- Method: Browser>>defineMessage:notifying: (in category 'message functions') -----
+ defineMessage: aString notifying: aController
+ 	self deprecated: 'Use Browser >> #defineMessageFrom:notifying:. This returns a Symbol or nil, not a Boolean.'.
+ 	^ (self defineMessageFrom: aString notifying: aController) notNil.!
- defineMessage: aString notifying: aController 
- 	"Compile the expressions in aString. Notify aController if a syntax error 
- 	occurs. Install the compiled method in the selected class classified under 
- 	the currently selected message category name. Answer true if 
- 	compilation succeeds, false otherwise."
- 	| selectedMessageName selector category oldMessageList |
- 	selectedMessageName := self selectedMessageName.
- 	oldMessageList := self messageList.
- 	contents := nil.
- 	selector := self selectedClassOrMetaClass
- 				compile: aString
- 				classified: (category := self selectedMessageCategoryName)
- 				notifying: aController.
- 	selector == nil ifTrue: [^ false].
- 	contents := aString copy.
- 	selector ~~ selectedMessageName
- 		ifTrue: 
- 			[category = ClassOrganizer nullCategory
- 				ifTrue: [self changed: #classSelectionChanged.
- 						self changed: #classList.
- 						self messageCategoryListIndex: 1].
- 			self setClassOrganizer.  "In case organization not cached"
- 			(oldMessageList includes: selector)
- 				ifFalse: [self changed: #messageList].
- 			self messageListIndex: (self messageList indexOf: selector)].
- 	^ true!



More information about the Squeak-dev mailing list