[squeak-dev] The Trunk: Morphic-mt.2093.mcz
commits at source.squeak.org
commits at source.squeak.org
Thu Feb 23 14:22:41 UTC 2023
Marcel Taeumel uploaded a new version of Morphic to project The Trunk:
http://source.squeak.org/trunk/Morphic-mt.2093.mcz
==================== Summary ====================
Name: Morphic-mt.2093
Author: mt
Time: 23 February 2023, 3:22:39.829976 pm
UUID: 16263c0a-3cc5-cb4c-8cf3-53eda4c76b4e
Ancestors: Morphic-mt.2092
Tree widgets: when collapsing a node via mouse-click, do not select that parent unless there was actually a prior selection (in that collapsed sub-tree).
=============== Diff against Morphic-mt.2092 ===============
Item was changed:
----- Method: SimpleHierarchicalListMorph>>mouseDown: (in category 'event handling') -----
mouseDown: evt
| aMorph selectors |
aMorph := self itemFromPoint: evt position.
evt yellowButtonPressed "First check for option (menu) click"
ifTrue: [
(PluggableListMorph menuRequestUpdatesSelection and: [model okToChange]) ifTrue: [
aMorph == selectedMorph
ifFalse: [self setSelectedMorph: aMorph]].
^ self yellowButtonActivity: evt shiftPressed].
aMorph ifNil: [^ super mouseDown: evt].
(aMorph notNil and:[aMorph inToggleArea: (aMorph point: evt position from: self)])
+ ifTrue: [ | priorSelection |
+ priorSelection := self selectedMorph.
- ifTrue: [
self toggleExpandedState: aMorph event: evt.
+ (priorSelection notNil and: [self selectedMorph isNil]) ifTrue: [
- self selectedMorph ifNil: [
self setProperty: #changeSelectionOnMouseUp toValue: true.
self setProperty: #selectedMorph toValue: aMorph].
^ self].
PluggableListMorph highlightPreSelection ifTrue: [
aMorph highlightedForMouseDown: true.
self setProperty: #highlightedMorph toValue: aMorph].
self setProperty: #changeSelectionOnMouseUp toValue: true.
selectors := Array
with: #click:
with: (self doubleClickEnabled ifTrue: [#doubleClick:] ifFalse: [nil])
with: nil
with: (self dragEnabled ifTrue:[#startDrag:] ifFalse:[nil]).
evt hand waitForClicksOrDrag: self event: evt selectors: selectors threshold: HandMorph dragThreshold "pixels".!
More information about the Squeak-dev
mailing list
|