public void onClick(MenuItem menuItem)
        {
            InventoryPopupMenu menu = (InventoryPopupMenu)menuItem.getMenu();
            Item item = menu.getSelectedItem();

                DropAllItem(item);

            menu.hide();
            toolTip.hide();
            menu.setSelectedItem(null);
        }
示例#2
0
        public void onClick(MenuItem menuItem)
        {
            if(menuItem==null)
                return;

            InventoryPopupMenu menu = (InventoryPopupMenu)menuItem.getMenu();
            Item item = menu.getSelectedItem();

                UseItem(item);

            menu.hide();
            toolTip.hide();
            menu.setSelectedItem(null);
        }