Defining interactively the target of a button

Ned Konz ned at bike-nomad.com
Thu Jul 31 15:29:28 UTC 2003


On Wednesday 30 July 2003 12:26 pm, Stephane Ducasse wrote:
> Hi
>
> I would like to be able to drag a button, assign the select
> clearTurtleTrails and set the target to the World by using only
> mouse and interaction
>
> I saw that I can change the selector, arguments....but not the
> target Is it possible? Do am I missing it?

Oh, I forgot two more ways, neither of which will work for you <g>:

1. You can open a properties sheet on your button (halo, properties; 
maybe need to use shift depending on your Preference)

Then go to the "button" tab. There's an area where you can drop a 
phrase tile. However, it doesn't seem to work right (at least it 
didn't for me), and it doesn't accept a regular tile morph (which 
would be needed for the World).

2. And yet another:

SimpleButtonMorph and its subclasses actually have a "set target" menu 
choice. See SimpleButtonMorph>>addCustomMenuItems:hand. But I've 
forgotten how it was supposed to work, and maybe we've broken it 
somehow. The idea was that you'd look at the position of the event 
that popped up the menu, and then if that was over a Morph (but not 
the World), the menu would offer to let you set the target to that 
Morph.

-- 
Ned Konz
http://bike-nomad.com
GPG key ID: BEEA7EFE



More information about the Squeak-dev mailing list