File tree Expand file tree Collapse file tree 1 file changed +10
-1
lines changed
tmc-plugin/src/fi/helsinki/cs/tmc/ui Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change 3
3
import java .awt .Dialog ;
4
4
import java .awt .event .ActionEvent ;
5
5
import java .awt .event .ActionListener ;
6
+ import java .awt .event .WindowAdapter ;
7
+ import java .awt .event .WindowEvent ;
6
8
import javax .swing .SwingUtilities ;
7
9
import org .openide .DialogDescriptor ;
8
10
import org .openide .DialogDisplayer ;
@@ -94,9 +96,16 @@ public void actionPerformed(ActionEvent e) {
94
96
"TMC Settings" ,
95
97
false ,
96
98
NotifyDescriptor .OK_CANCEL_OPTION ,
97
- NotifyDescriptor . PLAIN_MESSAGE ,
99
+ null ,
98
100
closeListener );
99
101
dialog = DialogDisplayer .getDefault ().createDialog (descriptor );
102
+ dialog .addWindowListener (new WindowAdapter () {
103
+ @ Override
104
+ public void windowClosed (WindowEvent we ) {
105
+ panel = null ;
106
+ dialog = null ;
107
+ }
108
+ });
100
109
SwingUtilities .invokeLater (new Runnable () {
101
110
@ Override
102
111
public void run () {
You can’t perform that action at this time.
0 commit comments