JFrame from JPanel
This is e real newbie problem.
I created a JPanel :
public class P1 extends JPanel implements ActionListener {
some code
}
On a different file, but in the same dir, I have a JFrame:
public class F1 {
JFrame ditframe = new JFrame {
some code
}
I try to start the JFrame from the JPanel somewhere under:
public void actionPerformed(Action Event e) {
.....
}
How d I call the JFrame?
Thanks,
.
Relevant Pages
- Re: JFrame from JPanel
... I created a JPanel: ... public class P1 extends JPanel implements ActionListener { ... On a different file, but in the same dir, I have a JFrame: ... JFrame ditframe = new JFrame { ... (comp.lang.java.gui) - Re: JPanel will not show ( and no more top posting either)
... public class MainPanel extends JPanel implements ActionListener { ... // JFrame addPrinterFrame, deletePrinterFrame, changePrinterFrame; ... JPanel buttonPanel, scrollPanePanel; ... You make your panel appear by adding it to a top level container and then showing the container. ... (comp.lang.java.gui) - Re: JFrame from JPanel
... public class P1 extends JPanel implements ActionListener { ... On a different file, but in the same dir, I have a JFrame: ... I assumed petoeter had some good reason for wanting to "start the JFrame" from within the JPanel's ActionListener. ... (comp.lang.java.gui) - Re: JPanelGraphics..
... to it on each paint of the component, however, when I add it to the JFrame, I only see a blank JPanel. ... public class JPanelGraphics extends JPanel{ ... If you don't need a RenderedImage, ... (comp.lang.java.gui) - get the value of the position of JPanel inside the JFrame
... I have a JFrame and inside two JPanel one of them is on NORTH and the second ... And When I get the Container which is the JPanel, ... Les informations contenues dans le present message et dans tous les fichiers electroniques qui y sont attaches, sont strictement confidentielles et ne sont destinees qu'a l'usage de la personne dont le nom apparait ci-dessus et de toute autre personne specifiquement autorisee a les recevoir. ... (comp.lang.java.programmer) |
|