0 Replies Latest reply on May 31, 2007 1:53 PM by Kasem_Abotel

    Can not hide the menu

    Kasem_Abotel
      I have the following issue

      Clicking on menu item does not hide the menu, the only way to hide it is to Click somewhere outside the menu

      This is always reproducible

      - the menu is created programmatically via Menu.CreateMenu

      private function showMenu(event:Event):void {
      menu= Menu.createMenu(this, menuDP, false);
      menu.labelField="@label"
      menu.dataProvider = menuDP;
      menu.addEventListener("itemClick", itemClickHandler);
      var point1:Point = new Point();

      // Calculate position of Menu in Application's coordinates.
      point1.x=this.x;
      point1.y=this.y;
      point1=this.localToGlobal(point1);
      menu.show(point1.x , point1.y );
      }
      - I am using menu.hide( ) and even menu.visisble and includeLayout

      private function itemClickHandler(event:MenuEvent):void {
      menu.hide();
      // do the work
      }


      any help is appreciated

      Kasem