File tree Expand file tree Collapse file tree 1 file changed +14
-4
lines changed
src/org/netbeans/modules/php/cake3/ui Expand file tree Collapse file tree 1 file changed +14
-4
lines changed Original file line number Diff line number Diff line change @@ -116,13 +116,23 @@ public Dimension getPreferredSize() {
116
116
return panel ;
117
117
}
118
118
119
- private void setVersion (String version ) {
120
- assert SwingUtilities .isEventDispatchThread ();
119
+ private void setVersion (final String version ) {
120
+ Runnable runnable = new Runnable () {
121
+ @ Override
122
+ public void run () {
123
+ versionLabel .setText (version );
124
+ versionLabel .setIcon (CAKE_ICON );
125
+ }
126
+ };
121
127
if (CakeVersion .UNNKOWN .equals (version )) {
122
128
clearLabel ();
129
+ return ;
130
+ }
131
+
132
+ if (SwingUtilities .isEventDispatchThread ()) {
133
+ runnable .run ();
123
134
} else {
124
- versionLabel .setText (version );
125
- versionLabel .setIcon (CAKE_ICON );
135
+ SwingUtilities .invokeLater (runnable );
126
136
}
127
137
}
128
138
You can’t perform that action at this time.
0 commit comments