[squeak-dev] The Trunk: Morphic-mt.1205.mcz

commits at source.squeak.org commits at source.squeak.org
Thu Jul 28 13:40:01 UTC 2016

Marcel Taeumel uploaded a new version of Morphic to project The Trunk:

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

Name: Morphic-mt.1205
Author: mt
Time: 28 July 2016, 3:39:20.355087 pm
UUID: aa6ba894-8f4a-344e-8506-25c7e6418266
Ancestors: Morphic-mt.1204

Provide a simple interface to avoid display updates. For example, if you change a bunch of things in, say, the PluggableButtonMorph and you happen to have one visible on the screen, transcripts or system progress bars will trigger visual updates at a time when code is in an inconsistent state.

=============== Diff against Morphic-mt.1204 ===============

Item was added:
+ ----- Method: MorphicProject>>noDisplayDuring: (in category 'display') -----
+ noDisplayDuring: block
+ 	self world noDisplayDuring: block.!

Item was changed:
  ----- Method: PasteUpMorph>>displayWorld (in category 'world state') -----
+ 	(self valueOfProperty: #shouldDisplayWorld ifAbsent: [true])
+ 		ifTrue: [worldState displayWorld: self submorphs: submorphs].!
- 	worldState displayWorld: self submorphs: submorphs.!

Item was added:
+ ----- Method: PasteUpMorph>>noDisplayDuring: (in category 'world state') -----
+ noDisplayDuring: block
+ 	"Some morphs insist on updating the display like the system progress bar does. However, some code might be in an inconsistent state. For this, you can use this method to be safe."
+ 	self
+ 		setProperty: #shouldDisplayWorld
+ 		toValue: false.
+ 	block ensure: [self removeProperty: #shouldDisplayWorld].!

Item was changed:
  ----- Method: PasteUpMorph>>restoreMorphicDisplay (in category 'world state') -----
+ 	self removeProperty: #shouldDisplayWorld.
- 	ThumbnailMorph recursionReset.
+ 	ThumbnailMorph recursionReset.
  		extent: Display extent;
  		viewBox: Display boundingBox;
  		handsDo: [:h | h visible: true; showTemporaryCursor: nil];
  		addDeferredUIMessage: [Cursor normal show].

More information about the Squeak-dev mailing list