Opened 16 years ago

Closed 16 years ago

Last modified 15 years ago

#820 closed defect (fixed)

if MenuItem2 is created after the menubar has been used, popupmenu2 css is not ok on FF

Reported by: [email protected] Owned by: bill
Priority: high Milestone:
Component: Widgets Version: 0.3
Keywords: Cc:
Blocked By: Blocking:


Full example follows. Click 'Bookmarks' -> 'Add..', and type a name. The new bookmark (MenuItem2) is added under the 'Bookmarks' submenu, but the CSS for the item is incorrect:

  <script src='dojo.js' type='text/javascript'></script>
  <script language='javascript'>
  var bookmarkCount = 1;
  function addBookmark() {
	var bookMark = prompt( 'Bookmark Name:', 'testName' );
	if ( bookMark ) {
	    var submenu = dojo.widget.byId( 'submenu1' );
	    var newItem = dojo.widget.createWidget( "MenuItem2", { id: 'menuitem_1_' + ( ++bookmarkCount ), caption: bookMark } );
	    submenu.addChild( newItem );
            //submenu.layoutMenu(); // Fixes Safari, but not FF
   <div dojoType='MenuBar2' id='menubar_1'>
    <div dojoType='MenuBarItem2' id='menuitem_1' submenuId='submenu1' caption='Bookmarks'></div>
   <div dojoType='PopupMenu2' widgetId='submenu1'>
    <div dojoType='MenuItem2' id='menuitem_1_1' onClick='addBookmark(); return false;' caption='Add...'></div>

Change History (4)

comment:1 Changed 16 years ago by dylan

Milestone: 0.5

comment:2 Changed 16 years ago by bill

Milestone: 0.50.4
Owner: changed from anonymous to bill

I tried this in FF; it is already fixed due to the Menu2 rewrite.

comment:3 Changed 16 years ago by bill

Resolution: fixed
Status: newclosed

comment:4 Changed 15 years ago by (none)

Milestone: 0.4

Milestone 0.4 deleted

Note: See TracTickets for help on using tickets.