On 5/13/12 2:27 PM, Peter Haworth wrote:

What I have so far, which seems to work, is:

- on preOpenCard, check for the clipboard containing text and
enable/disable Paste accordingly

- a mouseMove handler for any editable fields that checks the selectedtext
and enables/disables the Edit menu cut/copy/clear items appropriately.

I guess I'm just wondering if mouseMove is the standard way to do this.  I
wanted to use mouseUp but apparently mouseUp doesn't get sent to unlocked
text fields.

Typically all the menu settings are adjusted in a mouseDown handler in the menu group script. It's nearly impossible to track everything as it happens. Just set up the menus when the user is actually interacting with them.

On OS X, menu manipulations are slow, so be sure to "lock menus", do the alterations, and then "unlock menus" in your mousedown script.

--
Jacqueline Landman Gay         |     jac...@hyperactivesw.com
HyperActive Software           |     http://www.hyperactivesw.com

_______________________________________________
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Reply via email to