Focus on a stringMorph embedded in a PastupMorph

Hilaire Fernandes hilaire at ofset.org
Sat Jan 26 19:52:04 UTC 2008


I have a pasteupmorph with a StringMorph into it.
When I request (through an external command) edit with the
launchMiniEditor, I immediately lose the the focus of the string
morph. To get it working I first need to click in the background of
the PasteUpMorph.
I have tried various message for keyboard/mouse focus without success.

Kazuhiro Abe suggested to us a MouseButtonEvent as follow:

anEvent := MouseButtonEvent new
        setType: #mouseDown
        position: aStringMorph bounds center
        which: 4
        buttons: 12
        hand: aStringMorph currentHand
        stamp: nil.
anEvent handler: aStringMorph owner.
aStringMorph launchMiniEditor: anEvent.


But it does not help. Any clue?

Hilaire




More information about the Squeak-dev mailing list