publishEvent( new LifecycleApplicationEvent( LifecycleApplicationEvent.MODIFIED, object ) );
}
public void openEditor( @NotNull final Object editorRoot ) {
//Prefetch it
final BlockingBackgroundActionRunner actionRunner = new BlockingBackgroundActionRunner( getApplication().getActiveWindow(), new BackgroundAction( "prefetching.data" ) {
@Override
protected void executeInBackground() throws Exception {
prepareOpenEditor( editorRoot );
}
@Override
protected void finished() {
//First get the object (from terracotta)
log.info( "----> Opening Editor for " + editorRoot );
publishEvent( new OpenEditorEvent( editorRoot ) );
}
} );
SwingUtilities.invokeLater( new Runnable() {
@Override
public void run() {
actionRunner.run();
}
} );
}