[squeak-dev] The Trunk: ToolBuilder-Morphic-ct.281.mcz

Thiede, Christoph Christoph.Thiede at student.hpi.uni-potsdam.de
Thu Dec 2 20:47:28 UTC 2021


The only real change in this version was the addition of this line:


+        widget updateColumns.

I am sorry, I had forgotten that prettyPrintWithDiffs was turned on in my image. Immediately turning it off now ... Maybe we should have something like an .editorconfig for every Monticello package. :-)


Best,

Christoph

________________________________
Von: Squeak-dev <squeak-dev-bounces at lists.squeakfoundation.org> im Auftrag von commits at source.squeak.org <commits at source.squeak.org>
Gesendet: Donnerstag, 2. Dezember 2021 21:43:22
An: squeak-dev at lists.squeakfoundation.org; packages at lists.squeakfoundation.org
Betreff: [squeak-dev] The Trunk: ToolBuilder-Morphic-ct.281.mcz

Christoph Thiede uploaded a new version of ToolBuilder-Morphic to project The Trunk:
http://source.squeak.org/trunk/ToolBuilder-Morphic-ct.281.mcz

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

Name: ToolBuilder-Morphic-ct.281
Author: ct
Time: 2 December 2021, 9:42:51.429746 pm
UUID: 3714f3d3-013d-644c-ac49-363076421856
Ancestors: ToolBuilder-Morphic-mt.280

Fixes a layout slip for multi-column lists with #shrinkWrap'ped column resizings. Update the column widths eagerly to avoid an incorrect default layout when the list enters the world.

The original bug can be reproduced by searching in SqueakInboxTalk for the conversation "PSA | Slow .changes access | Real-time protection in Windows Defender".

=============== Diff against ToolBuilder-Morphic-mt.280 ===============

Item was changed:
  ----- Method: MorphicToolBuilder>>buildPluggableMultiColumnList: (in category 'widgets required') -----
  buildPluggableMultiColumnList: aSpec
+
         | widget listClass getIndex setIndex |
+        aSpec getSelected
+                ifNil: [
+                        listClass := self multiColumnListClass.
+                        getIndex := aSpec getIndex.
+                        setIndex := aSpec setIndex]
+                ifNotNil: [
+                        listClass := self multiColumnListByItemClass.
+                        getIndex := aSpec getSelected.
+                        setIndex := aSpec setSelected].
+        widget := listClass
+                on: aSpec model
+                list: aSpec list
+                selected: getIndex
+                changeSelected: setIndex
+                menu: aSpec menu
+                keystroke: aSpec keyPress.
-        aSpec getSelected ifNil:[
-                listClass := self multiColumnListClass.
-                getIndex := aSpec getIndex.
-                setIndex := aSpec setIndex.
-        ] ifNotNil: [
-                listClass := self multiColumnListByItemClass.
-                getIndex := aSpec getSelected.
-                setIndex := aSpec setSelected.
-        ].
-        widget := listClass on: aSpec model
-                                list: aSpec list
-                                selected: getIndex
-                                changeSelected: setIndex
-                                menu: aSpec menu
-                                keystroke: aSpec keyPress.
         self register: widget id: aSpec name.

+        "       widget
- "     widget
                 dragItemSelector: aSpec dragItem;
                 dropItemSelector: aSpec dropItem;
                 wantsDropSelector: aSpec dropAccept;
                 dragStartedSelector: aSpec dragStarted."
+
-
         self setListPropertiesFor: widget spec: aSpec.

         "Be sure to enable the horizontal scrollbar if not all columns are #spaceFill."
+        (aSpec columnResizings anySatisfy: [:sym | sym ~= #spaceFill]) ifTrue: [widget hScrollBarPolicy: #whenNeeded].
+
-        (aSpec columnResizings anySatisfy: [:sym | sym ~= #spaceFill])
-                ifTrue: [widget hScrollBarPolicy: #whenNeeded].
-
         widget
                 cellPositioningForColumns: aSpec itemAlignments;
                 cellInsetForColumns: aSpec itemPaddings;
                 hResizingForColumns: aSpec columnResizings;
                 spaceFillWeightForColumns: aSpec columnSpaceFillWeights.
+        widget updateColumns.

+        ^ widget!
-        ^widget!


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20211202/b2e41c35/attachment.html>


More information about the Squeak-dev mailing list