  | |  | AW: [Flashcoders] Updated menuitem in menubar | AW: [Flashcoders] Updated menuitem in menubar 2004-03-09 - By Andr? Knuth
Back Answering myself:
function onEditMenuChange(eventObject:Object):Void { var aMenu = eventObject.menu; var aMenuItem = eventObject.menuItem; switch (aMenuItem) { case aMenu.setHistoryMark: aMenu.getHistoryMark.attributes.enabled true; aMenu.modelChanged({eventName:"updateTree"});
The last line ist the most important one, it fires an event, that updates the menu.
Hi there,
I am changing a attribute of a menu(flash2004 component), like this:
aMenu.getHistoryMark.attributes.enabled = true;
that was enabled?lse before(set by dataprovider-xml). When I open that menu again to see if the menuitem is enabled, it is still displayed as disabled, but when I roll over the item it is shown as enabled. Is there a way to manually update the menuitem so that it is being displayed correctly?
I tried:
var aProvider = menubar.dataProvider; menubar.dataProvider = aProvider;
which has a nasty sideeffect that the menu blinks as it is being redisplayed.
Thanks in advance, Andr? Knuth
=-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- -- Supported by Fig Leaf Software =-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- -- Be sure to check the archives and the wiki: http://chattyfig.figleaf.com/ =-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- -- http://chattyfig.figleaf.com/cgi-bin/ezmlm-cgi?1:mss:105989 =-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- -- To unsubscribe send a blank e-mail to: Normal Mode: flashcoders-unsubscribe@(protected) Digest Mode: flashcoders-digest-unsubscrive@(protected)
=-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- -- Supported by Fig Leaf Software =-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- -- Be sure to check the archives and the wiki: http://chattyfig.figleaf.com/ =-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- -- http://chattyfig.figleaf.com/cgi-bin/ezmlm-cgi?1:mss:106424 =-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- -- To unsubscribe send a blank e-mail to: Normal Mode: flashcoders-unsubscribe@(protected) Digest Mode: flashcoders-digest-unsubscrive@(protected)
Earn $52 per hosting referral at Lunarpages.
|
|
 |