use of org.eclipse.swt.widgets.Display in project ACS by ACS-Community.
the class LostSourcesContainer method refresh.
/**
* Refresh the content of the list
*/
private void refresh() {
if (!disposed) {
Display display = Display.getDefault();
display.syncExec(new Runnable() {
public void run() {
if (!disposed) {
viewer.refresh();
}
}
});
}
}
use of org.eclipse.swt.widgets.Display in project cubrid-manager by CUBRID.
the class ExportTableDefinitionProgress method export.
/**
* createDatabaseWithProgress return database name
*
* @return Catalog
*/
public boolean export() {
Display display = Display.getDefault();
display.syncExec(new Runnable() {
public void run() {
try {
new ProgressMonitorDialog(null).run(true, false, ExportTableDefinitionProgress.this);
} catch (Exception e) {
LOGGER.error("", e);
}
}
});
return success;
}
use of org.eclipse.swt.widgets.Display in project cubrid-manager by CUBRID.
the class LoadTableRecordCountsProgress method getTableCounts.
/**
* loadTablesInfo
*
* @return Catalog
*/
public void getTableCounts() {
Display display = Display.getDefault();
display.syncExec(new Runnable() {
public void run() {
try {
new ProgressMonitorDialog(null).run(true, true, LoadTableRecordCountsProgress.this);
} catch (Exception e) {
LOGGER.error("", e);
}
}
});
}
use of org.eclipse.swt.widgets.Display in project cubrid-manager by CUBRID.
the class OpenViewsDetailInfoPartProgress method loadViewsInfo.
/**
* loadViewsInfo
*
* @return Catalog
*/
public void loadViewsInfo() {
Display display = Display.getDefault();
display.syncExec(new Runnable() {
public void run() {
try {
new ProgressMonitorDialog(null).run(true, false, OpenViewsDetailInfoPartProgress.this);
} catch (Exception e) {
LOGGER.error(e.getMessage(), e);
}
}
});
}
use of org.eclipse.swt.widgets.Display in project cubrid-manager by CUBRID.
the class TaskExecutor method openErrorBox.
/**
*
* Open error box in task executor
*
* @param shell the Shell object
* @param msg the message
* @param monitor the IProgressMonitor
* @return <code>true</code> if has error and monitor do not canceled;
* <code>false</code> otherwise
*/
public boolean openErrorBox(final Shell shell, final String msg, IProgressMonitor monitor) {
if (msg != null && msg.length() > 0 && !monitor.isCanceled()) {
monitor.done();
Display display = Display.getDefault();
display.syncExec(new Runnable() {
public void run() {
CommonUITool.openErrorBox(shell, msg);
}
});
return true;
}
return false;
}
Aggregations