blob: 724a07d0a5ad1213cb49aa88d2dcb36706e84a8f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
|
/* Listing3611.java */
import java.awt.*;
import javax.swing.*;
public class Listing3611
extends JFrame
{
public Listing3611()
{
super("Debug-Grafik");
addWindowListener(new WindowClosingAdapter(true));
Container cp = getContentPane();
DebugGraphics.setFlashTime(100);
DebugGraphics.setFlashCount(3);
JButton button = new JButton("DEBUG-Button");
RepaintManager repaintManager = RepaintManager.currentManager(button);
repaintManager.setDoubleBufferingEnabled(false);
button.setDebugGraphicsOptions(DebugGraphics.FLASH_OPTION);
cp.add(button);
}
public static void main(String[] args)
{
Listing3611 frame = new Listing3611();
frame.setLocation(100, 100);
frame.setSize(300, 200);
frame.setVisible(true);
}
}
|