How to get referende to parrent component?
Printable View
How to get referende to parrent component?
super();
Thanks
is there any way to find top most component without looping?
What do you mean by that? The top most level is the Object class. Are you talking about trying to get a reference to a component that is at the very top of the frame?
just have a reference of the topmost frame w/in your class. :)... If you don't want to loop it. :D
I think he means component in the swing sense, which you get by calling getParent().
Corect you are CornedBee. Nice to see you are back.
Back from where? I've been here all the time - just didn't find many questions that tickled my fancy.
In fact, I'll be gone for three weeks now.
:lol: I was just kidding.Quote:
Posted by CornedBee
Back from where? I've been here all the time - just didn't find many questions that tickled my fancy.
I don't remember authorizing any vacation time. ;)Quote:
In fact, I'll be gone for three weeks now.
I mean, to get reference to the JFrame but getParent() gives me contentpane.
I am using my menu in a different class and and I attached it to Jframe in diffrent class now I want to reference the JFrame for the menu.