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

commits at source.squeak.org commits at source.squeak.org
Mon Jan 3 22:35:03 UTC 2022


A new version of Morphic was added to project The Inbox:
http://source.squeak.org/inbox/Morphic-ct.1842.mcz

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

Name: Morphic-ct.1842
Author: ct
Time: 3 January 2022, 11:34:56.949397 pm
UUID: 2278fc82-96e5-7c47-a89f-99b0ad45d8a8
Ancestors: Morphic-ct.1841

Fixes a bug that prevented UI themes from being applied to collapsed windows.

"self userInterfaceTheme" answers a UserInterfaceThemeRequest rather than a UserInterfaceTheme, and sending #applyTo: to this request caused the local UI property "#applyTo" being set to "self allMorphs" rather than actually applying the UI theme.

=============== Diff against Morphic-ct.1841 ===============

Item was changed:
  ----- Method: SystemWindow>>collapseOrExpand (in category 'resize/collapse') -----
  collapseOrExpand
  	"Collapse or expand the window, depending on existing state"
  	| cf |
  	isCollapsed
  		ifTrue: 
  			["Expand -- restore panes to morphics structure"
  			isCollapsed := false.
  			self beKeyWindow.  "Bring to frint first"
  			Preferences collapseWindowsInPlace
  				ifTrue: 
  					[fullFrame := fullFrame align: fullFrame topLeft with: self getBoundsWithFlex topLeft]
  				ifFalse:
  					[collapsedFrame := self getBoundsWithFlex].
  			collapseBox ifNotNil: [collapseBox setBalloonText: 'collapse this window' translated].
  			self setBoundsWithFlex: fullFrame.
  			paneMorphs reverseDo: 
  					[:m |  self addMorph: m unlock.
  					self world startSteppingSubmorphsOf: m].
  			self addPaneSplitters.
  			(self hasProperty: #applyTheme) ifTrue: [
  				self removeProperty: #applyTheme.
+ 				UserInterfaceTheme current applyTo: self allMorphs]]
- 				self userInterfaceTheme applyTo: self allMorphs]]
  		ifFalse: 
  			["Collapse -- remove panes from morphics structure"
  			isCollapsed := true.
  			fullFrame := self getBoundsWithFlex.
  			"First save latest fullFrame"
  			paneMorphs do: [:m | m delete; releaseCachedState].
  			self removePaneSplitters.
  			self removeCornerGrips.
  			model modelSleep.
  			cf := self getCollapsedFrame.
  			(collapsedFrame isNil and: [Preferences collapseWindowsInPlace not]) ifTrue:
  				[collapsedFrame := cf].
  			self setBoundsWithFlex: cf.
  			collapseBox ifNotNil: [collapseBox setBalloonText: 'expand this window' translated ].
  			expandBox ifNotNil: [expandBox setBalloonText: 'expand this window' translated ].
  			self sendToBack].
  	self layoutChanged!



More information about the Squeak-dev mailing list