Details
-
Bug
-
Status: Closed
-
Minor
-
Resolution: Later
-
Adobe Flex SDK Previous
-
None
-
None
-
Affected OS(s): Windows
Affected OS(s): Windows XP
Language Found: English
Description
Steps to reproduce:
1.
//method 1
private function onMenuBarInitialize():void {
var menu:Menu;
for (var i:int = 0; i < menuBar.menus.length; i++)
}
//method 2
private function onMenuShow(event:MenuEvent):void {
var t:MenuBar = event.currentTarget as MenuBar;
event.menu.variableRowHeight = true;
}
2.
<mx:MenuBar id="menuBar" width="100%" labelField="@label"
initialize="onMenuBarInitialize" iconField="@icon" styleName="menuBar"
itemClick="onMenuBar(event)" menuShow="//onMenuShow(event)">
<mx:XMLList>
<menuitem label="File">
<menuitem label="New" icon="documentIcon" />
<menuitem label="Open..." icon="documentIcon"/>
<menuitem type="separator" />
<menuitem label="Close" />
<menuitem type="separator" />
<menuitem label="Save" />
<menuitem label="Save as..." />
<menuitem type="separator" />
<menuitem label="Import..." />
<menuitem label="Export..." />
<menuitem type="separator" />
<menuitem label="Exit" />
</menuitem>
<menuitem label="Edit">
<menuitem label="Cut" />
<menuitem label="Copy" />
<menuitem label="Paste" />
<menuitem type="separator" />
<menuitem label="Select All" />
<menuitem type="separator" />
<menuitem label="Find" />
</menuitem>
</mx:XMLList>
</mx:MenuBar>
Actual Results:
The FIRST time I click the MenuBar, the sub-menu show as below:
-----------
New |
-----------
Open |
-----------
Close |
-----------
Save |
Saveas.. |
-----------
Import... |
Export... |
-----------
Exit |
-----------
The SECOND time I click the MenuBar, the sub-menu show as below:
-----------
New |
-----------
Open |
-----------
Close |
-----------
Save |
Saveas.. |
-----------
Import... |
Export... |
-----------
Exit |
-----------
Expected Results:
Workaround (if any):