1
2
3
4
5
6
7
8
9
10
11
12
13
14
15 package net.curre.prefcount.gui;
16
17 import java.beans.PropertyChangeEvent;
18 import java.beans.PropertyChangeListener;
19 import java.util.ResourceBundle;
20 import javax.swing.*;
21
22 import net.curre.prefcount.App;
23 import net.curre.prefcount.PrefCountRegistry;
24 import net.curre.prefcount.gui.aa.AAJOptionPane;
25
26
27
28
29
30
31
32
33 public class AboutJOptionPane extends AAJOptionPane implements PropertyChangeListener {
34
35 private static ImageIcon ICON;
36
37 static {
38 ICON = new ImageIcon(App.class.getResource("images/PrefCount-48x48.png"));
39 }
40
41
42 public AboutJOptionPane() {
43 super(ResourceBundle.getBundle("default").getString("pref.aboutFrame.message"),
44 JOptionPane.INFORMATION_MESSAGE,
45 JOptionPane.DEFAULT_OPTION,
46 ICON);
47 super.addPropertyChangeListener(this);
48 }
49
50
51 public void propertyChange(PropertyChangeEvent propertyChangeEvent) {
52 if (propertyChangeEvent.getPropertyName().equals(JOptionPane.VALUE_PROPERTY)) {
53 PrefCountRegistry.getInstance().getMainWindow().closeAnimatedInnerPanel();
54 }
55 }
56
57 }