Help coderanch get a
new server
by contributing to the fundraiser
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

menu bars?

 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
i'm confused about the question "Where can menu bars be added?"
from my readings, it said that any object that implements MenuContainer interface can have a menubar, since Component implements MenuContainer, all components could have menubars
one mock exam gave me this answer..
however, in other mock exams, and i believe RH - they say that only frames can have menu bars....
confused? what is the real answer?
thanks...
 
Ranch Hand
Posts: 100
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Marie,
There is nothing like MenuContainer interface. MenuComponent class is the super class of all menu related components. Incidentally this is an abstract class. MenuBar, MenuItem are subclasses of MenuComponent.
Yes. Frame is the only component that can have menubar.
 
Leverager of our synergies
Posts: 10065
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Marie,
Maha Anna did research for this complicated question
here: http://www.javaranch.com/ubb/Forum24/HTML/000703.html
and here: http://www.javaranch.com/ubb/Forum24/HTML/001392.html
 
Marie
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
so let me get this straight...
the difference in RH and Bill Brogden's is the phrasing of the question...
MenuBars can only be added to Frames
but menus, in the form of a menu bar (misleading) or a pop-up menu (this was the key word in the question) may be added to any subclass of Component
 
Bartender
Posts: 612
7
Mac OS X Python
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
"SpaceBunny", take a look at this link:
http://www.javaranch.com/ubb/Forum10/HTML/000180.html
 
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
actually, by the time you posted your reply, ihave already registered...
 
Trailboss
Posts: 23815
IntelliJ IDE Firefox Browser Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Unfortunately, you need to register again. If you are not comfortable with giving your last name, use something that "looks normal". "Monroe"?
 
It's never done THAT before. Explain it to me tiny ad:
We need your help - Coderanch server fundraiser
https://coderanch.com/t/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic