Board Logo

Menu object structure / finding width
jollygreenfat - 6/1/2007 at 03:11 PM

I have a (working) menu on my page created via:

var MainMenu = new menu (MENU_ITEMS, MENU_TPL, {'frames':[[]]});

What I can't find a clear answer on is the structure of a "menu" object -- in other words, what are the member variables / function I can access via "MainMenu.xxx"? I've looked through menu.js, but it's going to be very time-consuming to try to decipher it all. Specifically, I'm trying to figure out the menu's overall width (even being able to determine the width of a top-level item would be better than nothing -- and I'm not talking via the css).


tigra - 6/1/2007 at 05:12 PM

There is no publicly accessible, documented API for that. Since all the sizes are defined in the menu's configuration you call pull that information from MENU_ITEMS and MENU_TPL structures (which you know format of).


Softcomplex: http://www.softcomplex.com/
Back to forum: http://www.softcomplex.com/forum/