The Inbox: Morphic-ct.1626.mcz

Previous Topic Next Topic
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

The Inbox: Morphic-ct.1626.mcz

Christoph Thiede uploaded a new version of Morphic to project The Inbox:

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

Name: Morphic-ct.1626
Author: ct
Time: 10 February 2020, 11:59:37.194089 am
UUID: 4909a268-ae09-b641-ae4c-a59a49cd99e5
Ancestors: Morphic-cmm.1618

Revise/fix #addMorphNearBack: implementation

Instead of deleting and re-adding aMorph, simply use #addMorphBack:. This also fixes the problem that backmostMorphs were sent #intoWorld: after minimizing a window, for example.

=============== Diff against Morphic-cmm.1618 ===============

Item was changed:
  ----- Method: Morph>>addMorphNearBack: (in category 'submorphs-add/remove') -----
  addMorphNearBack: aMorph
+ | backmostMorph |
+ backmostMorph := self submorphs atLast: 1 ifAbsent: [nil].
+ ^ (backmostMorph notNil and: [backmostMorph mustBeBackmost])
+ ifTrue: [self addMorph: aMorph inFrontOf: backmostMorph]
+ ifFalse: [self addMorphBack: aMorph]!
- | bg |
- (submorphs notEmpty and: [submorphs last mustBeBackmost])
- ifTrue:
- [bg := submorphs last.
- bg privateDelete].
- self addMorphBack: aMorph.
- bg ifNotNil: [self addMorphBack: bg]!