File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed
tmc-plugin/src/fi/helsinki/cs/tmc/actions Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change 10
10
import java .util .Collection ;
11
11
import java .util .Iterator ;
12
12
import java .util .List ;
13
+
14
+ import javax .swing .SwingUtilities ;
15
+
13
16
import org .netbeans .api .project .FileOwnerQuery ;
14
17
import org .netbeans .api .project .Project ;
15
18
import org .openide .filesystems .FileObject ;
@@ -25,7 +28,9 @@ public AbstractExerciseSensitiveAction() {
25
28
TmcEventBus .getDefault ().subscribeDependent (new TmcEventListener () {
26
29
public void receive (CourseDb .ChangedEvent event ) throws Throwable {
27
30
boolean enable = AbstractExerciseSensitiveAction .this .enable (getActivatedNodes ());
28
- setEnabled (enable );
31
+ SwingUtilities .invokeLater (() -> {
32
+ setEnabled (enable );
33
+ });
29
34
}
30
35
}, this );
31
36
}
You can’t perform that action at this time.
0 commit comments