[squeak-dev] The Trunk: Protocols-ct.86.mcz

commits at source.squeak.org commits at source.squeak.org
Thu May 5 18:02:08 UTC 2022


Christoph Thiede uploaded a new version of Protocols to project The Trunk:
http://source.squeak.org/trunk/Protocols-ct.86.mcz

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

Name: Protocols-ct.86
Author: ct
Time: 5 May 2022, 8:02:07.164075 pm
UUID: 3aa16d9e-53f9-dc45-b5c9-8cf0925eefc4
Ancestors: Protocols-ct.85

Fixes slip from Protocols-ct.79. Code pane now works again even if no category for the selected message is selected.

=============== Diff against Protocols-ct.85 ===============

Item was changed:
+ ----- Method: InstanceBrowser>>setClassAndSelectorIn: (in category 'private') -----
- ----- Method: InstanceBrowser>>setClassAndSelectorIn: (in category 'as yet unclassified') -----
  setClassAndSelectorIn: csBlock
  	| cm |
  	super setClassAndSelectorIn: [:class :selector |
  		(class notNil and: [selector notNil]) ifTrue: [^ csBlock value: class value: selector].
  		cm := targetClass
  					lookupSelector: (self selection asString findTokens: Character space) first asSymbol.
  		cm ifNotNil: [^ csBlock value: (cm methodClass ifNil: [targetClass]) value: cm selector]].
  	^ csBlock value: nil value: nil!

Item was changed:
  ----- Method: Lexicon>>selectedMessage (in category 'selection') -----
  selectedMessage
  	"Answer the source method for the currently selected message."
  
- 	(categoryList notNil and: [(categoryListIndex isNil or: [categoryListIndex = 0])])
- 		ifTrue:
- 			[^ '---'].
- 
  	self setClassAndSelectorIn: [:class :selector | 
+ 		class ifNil: [^ 'here would go the documentation for the protocol category, if any.' translated].
- 		class ifNil: [^ 'here would go the documentation for the protocol category, if any.'].
  
  		self showingDecompile ifTrue: [^ self decompiledSourceIntoContents].
  		self showingDocumentation ifTrue: [^ self commentContents].
  
  		currentCompiledMethod := class compiledMethodAt: selector ifAbsent: [nil].
  		^ self sourceStringPrettifiedAndDiffed asText makeSelectorBoldIn: class]!



More information about the Squeak-dev mailing list