use of org.springsource.ide.eclipse.dashboard.ui.actions.ShowDashboardAction in project eclipse-integration-commons by spring-projects.
the class IdeUiPlugin method start.
@Override
public void start(BundleContext context) throws Exception {
super.start(context);
plugin = this;
// avoid cyclic startup dependency on org.eclipse.mylyn.tasks.ui
Job startupJob = new UIJob("Spring Tool Suite Initialization") {
@Override
public IStatus runInUIThread(IProgressMonitor monitor) {
migrateBlogFeeds();
Display.getDefault().asyncExec(new Runnable() {
public void run() {
IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
if (window != null) {
// prevent loading if already opened by workspace
// restore
IEditorReference[] references = window.getActivePage().getEditorReferences();
for (IEditorReference reference : references) {
if (DashboardEditorInputFactory.FACTORY_ID.equals(reference.getFactoryId())) {
return;
}
}
if (getPreferenceStore().getBoolean(IIdeUiConstants.PREF_OPEN_DASHBOARD_STARTUP)) {
// don't show if welcome page is visible
if (window.getWorkbench().getIntroManager().getIntro() != null) {
// scheduleUpdateJob();
return;
}
ShowDashboardAction showDashboard = new ShowDashboardAction();
showDashboard.init(window);
showDashboard.run(null);
return;
}
}
// scheduleUpdateJob();
}
});
return Status.OK_STATUS;
}
};
startupJob.setSystem(true);
startupJob.schedule();
}
Aggregations