[squeak-dev] The Trunk: PreferenceBrowser-mt.107.mcz

commits at source.squeak.org commits at source.squeak.org
Sun Oct 11 11:44:29 UTC 2020


Marcel Taeumel uploaded a new version of PreferenceBrowser to project The Trunk:
http://source.squeak.org/trunk/PreferenceBrowser-mt.107.mcz

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

Name: PreferenceBrowser-mt.107
Author: mt
Time: 11 October 2020, 1:44:28.154652 pm
UUID: bc1ccf63-9978-b446-aca4-cf62ab263e26
Ancestors: PreferenceBrowser-mt.106

Refactoring 'Active' variables -- Step 2 of 2. Removes all uses of Active(World|Hand|Event) by replacing those with "self current(World|Hand|Event)" or "Project current world" when required to not add/cement Morphic dependency.

See http://forum.world.st/Changeset-Eliminating-global-state-from-Morphic-td5121690.html

=============== Diff against PreferenceBrowser-mt.106 ===============

Item was changed:
  ----- Method: PreferenceWizardMorph>>adjustSettingsForLowPerformance (in category 'support') -----
  adjustSettingsForLowPerformance
  
  	self updateLowPerformanceLabel: 'Please wait, optimizing performance...' translated.
  	self refreshWorld.
  	
  	self stateGradients "flat look" ifFalse: [self toggleGradients].
  	self stateBlinkingCursor ifTrue: [self toggleBlinkingCursor].
  	self stateFastDrag ifFalse: [self toggleFastDrag].
  	
  	self stateSoftShadows ifTrue: [self toggleSoftShadows].
  	self stateHardShadows ifTrue: [self toggleHardShadows].
  	
  	self stateRoundedWindowLook ifTrue: [self toggleRoundedWindowLook].
  	self stateRoundedButtonLook ifTrue: [self toggleRoundedButtonLook].
  	
  	self stateAttachToolsToMouse ifTrue: [self toggleAttachToolsToMouse].
  	self stateToolAndMenuIcons ifTrue: [self toggleToolAndMenuIcons].
  	
  	self stateSmartHorizontalSplitters ifTrue: [self toggleSmartHorizontalSplitters].
  	self stateSmartVerticalSplitters ifTrue: [self toggleSmartVerticalSplitters].
  	
  	PluggableListMorph
  		highlightHoveredRow: false;
  		filterableLists: false;
  		highlightPreSelection: true; "Feedback is important!!"
  		flashOnErrors: false.
  	TheWorldMainDockingBar showSecondsInClock: false.
  	Preferences disable: #balloonHelpInMessageLists.
  	
  	
  	"Set simple background."
+ 	Project current world setAsBackground: MorphicProject defaultFill.
+ 	previewWorld fillStyle: Project current world fillStyle.
- 	ActiveWorld setAsBackground: MorphicProject defaultFill.
- 	previewWorld fillStyle: ActiveWorld fillStyle.
  	
  	"Done."
+ 	self updateLowPerformanceLabel: 'Settings were adjusted for optimal performance.' translated.!
- 	self updateLowPerformanceLabel: 'Settings were adjusted for optimal performance.' translated.
- 	!

Item was changed:
  ----- Method: PreferenceWizardMorph>>initializePreviewWorld (in category 'initialization') -----
  initializePreviewWorld
  
  	| w1 w2 w3 |
  
  	previewWorld := PasteUpMorph new
  		hResizing: #spaceFill;
  		vResizing: #spaceFill;
  		viewBox: (0 at 0 corner: 500 at 500);
  		layoutFrame: (LayoutFrame fractions: (0.3 @ 0 corner: 1.0 @ 1.0) offsets: (0@ titleMorph height corner: 0 @ buttonRowMorph height negated));
+ 		fillStyle: Project current world fillStyle;
- 		fillStyle: ActiveWorld fillStyle;
  		borderWidth: 2;
  		borderColor: Color white;
  		cornerStyle: (self hasLowPerformance ifTrue: [#square] ifFalse: [#rounded]);
  		yourself.
+ 	
- 
  	w1 := (ToolSet browse: Morph selector: #drawOn:) dependents detect: [:ea | ea isSystemWindow].
  	w2 := ToolSet browseMessageSet: (SystemNavigation default allCallsOn: #negated) name: 'Senders' translated autoSelect: 'negated'.
  	w3 := (Workspace new contents: '3+4 "Select and hit [CMD]+[P]."') openLabel: 'Workspace'.
+ 	
- 		
  	{w1. w2. w3} do: [:ea | 
  		ea makeUnclosable.
  		previewWorld addMorph: ea].
  	
  	self updateWindowBounds.!



More information about the Squeak-dev mailing list