Chris Muller uploaded a new version of Installer-Core to project The Trunk:
http://source.squeak.org/trunk/Installer-Core-cmm.443.mcz
==================== Summary ====================
Name: Installer-Core-cmm.443
Author: cmm
Time: 15 January 2022, 12:07:10.110797 am
UUID: 490e147c-d8f7-4e14-8e5c-ba144e54178e
Ancestors: Installer-Core-mt.442
Actually lazily initialize the Installer's 'localRepository' to avoid keeping hitting one's local SqueakSource server many times unnecessarily.
=============== Diff against Installer-Core-mt.442 ===============
Item was changed:
----- Method: Installer class>>localRepository (in category 'repository-overrides') -----
localRepository
+ ^ localRepository ifNil: [localRepository := self defaultLocalRepository]!
- ^ localRepository ifNil: [self defaultLocalRepository]!
Marcel Taeumel uploaded a new version of Tools to project The Trunk:
http://source.squeak.org/trunk/Tools-mt.1106.mcz
==================== Summary ====================
Name: Tools-mt.1106
Author: mt
Time: 14 January 2022, 5:25:52.988796 pm
UUID: b34a81cd-911f-374c-921e-a40071c98798
Ancestors: Tools-mt.1105
Revise last commit in favor of what Christoph (ct) proposed.
Note that I am still not so sure that it is a good idea to integrate debugging tools into regular widgets like this. Warnings seem much better suited for this case, leaving the UI clean.
=============== Diff against Tools-mt.1105 ===============
Item was removed:
- Warning subclass: #MenuBuilderFailed
- instanceVariableNames: 'builderError'
- classVariableNames: ''
- poolDictionaries: ''
- category: 'Tools-Menus'!
Item was removed:
- ----- Method: MenuBuilderFailed class>>signal:for: (in category 'instance creation') -----
- signal: signalerText for: builderError
-
- ^ self suppressed
- ifTrue: [nil]
- ifFalse: [self new
- builderError: builderError;
- signal: signalerText]!
Item was removed:
- ----- Method: MenuBuilderFailed>>builderError (in category 'accessing') -----
- builderError
-
- ^ builderError!
Item was removed:
- ----- Method: MenuBuilderFailed>>builderError: (in category 'accessing') -----
- builderError: anObject
-
- builderError := anObject.!
Item was removed:
- ----- Method: MenuBuilderFailed>>defaultAction (in category 'priv handling') -----
- defaultAction
-
- super defaultAction.
- self builderError pass.!
Item was changed:
----- Method: Model>>buildMenu:withBuilders:shifted: (in category '*Tools-pluggable menus') -----
buildMenu: aMenu withBuilders: builders shifted: aBoolean
" We let every builder modify the menu. Skip erroneous builders silently.
The builder should indicate whether to abort by returning nil."
| menu |
menu := aMenu.
+ builders do: [:builder | | buildBlock |
+ buildBlock := [menu := self perform: builder method selector withEnoughArguments: {menu . aBoolean}].
+ buildBlock
+ on: Error, Warning, Halt do: [:ex |
+ menu add: ('<menu builder failed: {1}>' translated format: {ex}) action: buildBlock]].
+ ^ menu!
- builders do: [:builder |
- menu := [self perform: builder method selector withEnoughArguments: { menu . aBoolean }]
- on: Error do: [:ex |
- MenuBuilderFailed
- signal: ('Menu builder failed.\\{1}\\Proceed to debug the error. Suppress and cancel this warning to not see it again. Read on.' withCRs translated format: {ex message})
- for: ex.
- menu].
- menu ifNil: [^ aMenu]].
- ^ menu
- !
Marcel Taeumel uploaded a new version of Tools to project The Trunk:
http://source.squeak.org/trunk/Tools-mt.1105.mcz
==================== Summary ====================
Name: Tools-mt.1105
Author: mt
Time: 14 January 2022, 4:50:22.513919 pm
UUID: d5036460-6e47-7642-a323-a0f40b3dd559
Ancestors: Tools-eem.1104
When a menu builder fails, show a warning that can be suppressed if too annoying. Proceed that warning to open a debugger for the exception that made the menu builder fail.
Note that this is the first time that we use a warning to maybe mask an exception via the "suppress warning" feature.
=============== Diff against Tools-eem.1104 ===============
Item was added:
+ Warning subclass: #MenuBuilderFailed
+ instanceVariableNames: 'builderError'
+ classVariableNames: ''
+ poolDictionaries: ''
+ category: 'Tools-Menus'!
Item was added:
+ ----- Method: MenuBuilderFailed class>>signal:for: (in category 'instance creation') -----
+ signal: signalerText for: builderError
+
+ ^ self suppressed
+ ifTrue: [nil]
+ ifFalse: [self new
+ builderError: builderError;
+ signal: signalerText]!
Item was added:
+ ----- Method: MenuBuilderFailed>>builderError (in category 'accessing') -----
+ builderError
+
+ ^ builderError!
Item was added:
+ ----- Method: MenuBuilderFailed>>builderError: (in category 'accessing') -----
+ builderError: anObject
+
+ builderError := anObject.!
Item was added:
+ ----- Method: MenuBuilderFailed>>defaultAction (in category 'priv handling') -----
+ defaultAction
+
+ super defaultAction.
+ self builderError pass.!
Item was changed:
----- Method: Model>>buildMenu:withBuilders:shifted: (in category '*Tools-pluggable menus') -----
buildMenu: aMenu withBuilders: builders shifted: aBoolean
" We let every builder modify the menu. Skip erroneous builders silently.
The builder should indicate whether to abort by returning nil."
| menu |
menu := aMenu.
builders do: [:builder |
menu := [self perform: builder method selector withEnoughArguments: { menu . aBoolean }]
+ on: Error do: [:ex |
+ MenuBuilderFailed
+ signal: ('Menu builder failed.\\{1}\\Proceed to debug the error. Suppress and cancel this warning to not see it again. Read on.' withCRs translated format: {ex message})
+ for: ex.
+ menu].
- ifError: [:msg | Transcript showln: 'Menu builder failed: ', msg. menu].
menu ifNil: [^ aMenu]].
^ menu
!
Chris Muller uploaded a new version of ToolBuilder-Morphic to project The Treated Inbox:
http://source.squeak.org/treated/ToolBuilder-Morphic-cmm.285.mcz
==================== Summary ====================
Name: ToolBuilder-Morphic-cmm.285
Author: cmm
Time: 13 January 2022, 12:06:18.53413 am
UUID: fdfc0020-4e12-4f5c-a2bc-f632794ce0c3
Ancestors: ToolBuilder-Morphic-mt.284
Render field help text in the color used for comments.
=============== Diff against ToolBuilder-Morphic-mt.284 ===============
Item was changed:
----- Method: PluggableTextMorphPlus>>drawBalloonTextOn: (in category 'drawing') -----
drawBalloonTextOn: aCanvas
"Show balloon text in the text morph if it has no contents."
textMorph contents ifNotEmpty: [ ^ self ].
([ self balloonText ]
on: Error
do: [ : err | 'error in balloonText' ]) ifNotNil:
[ : text | aCanvas
drawString: text
in: (self innerBounds insetBy: (5 @ 2 corner: 0 @ 0))
font: (self userInterfaceTheme balloonTextFont ifNil: [TextStyle defaultFont])
+ color: ((self userInterfaceTheme get: #comment for: SHTextStylerST80) first ifNil: [Color gray darker]) ]!
- color: (self userInterfaceTheme balloonTextColor ifNil: [Color gray: 0.7]) ]!