View Full Version : Context Menu Options

10-13-2003, 05:56 AM
I'm working on a project in which I need to have a 'right-click' menu. However I also need to have some options in he menu to appear as 'disabled', not just dissapearing.
Does the ContextMenu class have this 'disabeling' option rather than 'hiding' option?
:confused: :confused: :confused:


10-13-2003, 07:20 AM
welcome to the forms

no,I don't think so, but u can build in your own items just like the build in items and then u control them
also see the tutorials section for this

10-13-2003, 07:48 AM
Thanks for answering so soon, man.
Anyways, I finally found a way to do it :p (not A way, I guess rather THE way).
There are some properties in the ContextMenu class in wich you can set if it will be 'visible', 'enabled' or even if you want a 'separatorBefore' the element.
What I did was:

if (condition) {
myMenuItem.enabled = false;


Sorry if I bothered and hope this can be useful for anyone. :)

10-13-2003, 08:06 AM
but by MM dictionary this would work with the items u add, not the already build in items

10-13-2003, 08:17 AM
True, it appears that you may only disable items created by yourself, not the existing ones. Existing items can only be hidden (all at the same time, I guess).

10-13-2003, 12:21 PM
no, u can do it for any item u wantmy_cm.builtInItems.zoom = false

10-13-2003, 12:47 PM

Nice research!

But... this takes me to my next question... Could we hide the 'Settings...' and 'About Flash 7...' buttons?

Mortimer Jazz
10-13-2003, 03:51 PM
No, they're there for good :)