Repository navigation
Feature/settings refactoring pharo15 - #1556
Merged
demarey merged 9 commits intoOct 30, 2026
Merged
Conversation
Rename default: -> defaultValue: and parent: -> parentName: in the <systemsettings> declarations
StNewSettingsTree subclassed SettingTree, the tree of the old Morphic SettingBrowser removed from Pharo. It now subclasses Object and defines what it used from it: its nodeList instance variable, the sort of nodes by order then label, and #childrenOf:, which matches children with their parent setting instead of the parent name (setting names are not unique) and also orders all the children placed before the first ordered one (the old loop only did it for one of them). Methods only needed by the old setting nodes are removed: checkForUnknownTarget, newTreeHolder and settingsKeywords.
CmdShortcutActivation>>#asSettingPresenter:owner: displayed the value of CmdShortcutSetting, which is not used anymore and was removed from Pharo.
The settings browser uses StNewSettingsTree, built on the new settings model of Pharo. Remove the old one and what only served it: StSettingsTree, StSettingNode, StSettingTreeBuilder and StSettingNodeBuilder, the presenter extensions of the old setting classes (PragmaSetting, SettingDeclaration, ActionSettingDeclaration, PickOneSettingDeclaration), SystemSettingsPersistence>>#hasSettingsFile, the Spotter extension of StSettingsTree and the unused StSettingsAbstractPresenter>>#newNodePresenterFrom:level:.
Now that the settings tree of the old settings model is removed, its replacements take back their names: StNewSettingsTree becomes StSettingsTree and StNewSettingNode becomes StSettingNode (with StNewSettingsTreeTest and their Spotter extensions).
A button action may change other settings, and the page showing them had to be refreshed by the action itself, which received the Spec button and announced StSettingModelChanged to the presenter of its window, the settings browser, which forwarded it to its page. The settings page now gives the button item it creates its pagePresenter. The button item performs its action as a plain message to its target, then announces StSettingModelChanged to its page (StSettingDetailPresenter), which updates its settings. The settings browser does not need to forward the announcement anymore.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Build the settings browser on top of the new settings model.
requires pharo-project/pharo#20125