[squeak-dev] The Inbox: Morphic-ct.1791.mcz

commits at source.squeak.org commits at source.squeak.org
Mon Nov 1 17:59:43 UTC 2021

A new version of Morphic was added to project The Inbox:

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

Name: Morphic-ct.1791
Author: ct
Time: 1 November 2021, 6:59:37.506014 pm
UUID: c33323b2-7221-9d4f-b3af-d723dd256645
Ancestors: Morphic-eem.1784

Documentation: Adds example of #add:subMenu:target:selector:argumentList: to MenuMorph example.

=============== Diff against Morphic-eem.1784 ===============

Item was changed:
  ----- Method: MenuMorph class>>example (in category 'example') -----
  	"MenuMorph example popUpInWorld"
  	| menu |
  	menu := MenuMorph new.
  	menu addTitle: 'Fruit' translated.
  	menu addStayUpItem.
  	menu add: 'apples' action: #apples.
  	menu add: 'oranges' action: #oranges.
  	menu addLine.
  	menu addLine.  "extra lines ignored"
  	menu add: 'peaches' action: #peaches.
  	menu addLine.
  	menu add: 'pears' action: #pears.
  	menu addLine.
+ 	menu add: 'test' subMenu: (MenuMorph new
+ 		defaultTarget: #peaches;
+ 		add: 'foo' action: #inspect;
+ 		yourself) target: 42 selector: #inform: argumentList: #('hello').
+ 	^ menu!
- 	^ menu
- !

More information about the Squeak-dev mailing list