problems with popup menus under OS 9?

Richard Gaskin ambassador at fourthworld.com
Sat Oct 23 20:41:14 EDT 2004


william griffin wrote:
>>> see bug 1781
>>> http://support.runrev.com/bugdatabase/show_bug.cgi?id=1781
>>> There Tuviah says we can have 25,000 submenus now (wee!)
>>> He didn't say what rev version though....
>>
>> I'm impressed that you were able to find that bug in the Mac OS API, but
>> its obscure nature has me curious: what sort of app needs more than 256
>> submenus?
>>
> A file menu that contains a list of scripts in a folder, a list of 3D 
> poseable scriptable model, a list of importable models, a list of level 
> folders which contain scripts and models, and throw in a list of folders 
> which contain textures and WHAM you have menuMode bug.
> 
>>  Is that in a single menu, or aggregate across all active menus at the 
>> time?
> 
> I don't know for sure. I would guess a single menu at least thats how i 
> found the bug.
> File>
>     Levels >
>         110 lines
>     Scripts
>         about 111 submenus (1 for the scripts folder, 1 for each level 
> folder)
>     make >
>         300 models or so (lines)
>     import >
>         460 or so    (lines)
>         110 submenus (1 for each level folder)
>     Export >
>         5 lines
>     Textures >
>         3 submenus
>             lots of lines  each
> 
> I think it came out to like 1600 lines or so total. It was weird I ran 
> dynamic tests
> with lots and lots of submenus and nothing went wrong, sometimes,
> It was truly baffling, because IDE instability wasn't instantly 
> apparent, and once that instability occured
> it usually ended up after I touched a menu Button with just 4 lines in 
> it, so I spent forever trouble
> shooting stuff that wasn't actually the cause of the trouble.
> 
> Right now my filemenu has 488 items in it (not all submenus mind you), 
> so far no trouble. <knock on wood>

There's a reason Apple built that limitation into the OS -- from the HIG:
----------------
Because submenus add complexity to the interface and are physically more 
difficult to use, you should use them only when you have more menus than 
fit in the menu bar or for closely related commands. Use only one level 
of submenus. If a submenu contains more than five items, consider giving 
it its own menu.
 
<http://developer.apple.com/documentation/UserExperience/Conceptual/OSXHIGuidelines/index.html>
----------------

I'm generally first in line to blow off OS-specific edicts, but given my 
own frustration with submenus I wonder if a hierarchical browser 
(multi-list perhaps, like the Finder's NeXT-style view) would be a 
smoother ride for the user....

-- 
  Richard Gaskin
  Fourth World Media Corporation
  ___________________________________________________________
  Ambassador at FourthWorld.com       http://www.FourthWorld.com


More information about the use-livecode mailing list