COMP2396
Loading...
Searching...
No Matches
SimpleGUI3 Class Reference
Inheritance diagram for SimpleGUI3:
Collaboration diagram for SimpleGUI3:

Public Member Functions

void actionPerformed (ActionEvent event)
 
void go ()
 

Static Public Member Functions

static void main (String[] args)
 

Detailed Description

Definition at line 5 of file SimpleGUI3.java.

Member Function Documentation

◆ actionPerformed()

void SimpleGUI3.actionPerformed ( ActionEvent event)
inline

Definition at line 25 of file SimpleGUI3.java.

25 {
26 frame.repaint();
27 }

◆ go()

void SimpleGUI3.go ( )
inline

Definition at line 13 of file SimpleGUI3.java.

13 {
14 frame = new JFrame();
15 frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
16 JButton button = new JButton("Change colors");
17 button.addActionListener(this);
18 MyDrawPanel2 drawPanel = new MyDrawPanel2();
19 frame.add(button, BorderLayout.SOUTH);
20 frame.add(drawPanel, BorderLayout.CENTER);
21 frame.setSize(300, 300);
22 frame.setVisible(true);
23 }

Referenced by main().

Here is the caller graph for this function:

◆ main()

static void SimpleGUI3.main ( String[] args)
inlinestatic

Definition at line 8 of file SimpleGUI3.java.

8 {
9 SimpleGUI3 gui = new SimpleGUI3();
10 gui.go();
11 }

References go().

Here is the call graph for this function:

The documentation for this class was generated from the following file: