/** * Runs the event loop for the given shell. * * @param loopShell * the shell */ private void runEventLoop(Shell loopShell) { //Use the display provided by the shell if possible Display display; if (shell == null) { display = Display.getCurrent(); } else { display = loopShell.getDisplay(); } while (loopShell != null && !loopShell.isDisposed()) { try { if (!display.readAndDispatch()) { display.sleep(); } } catch (Throwable e) { exceptionHandler.handleException(e); } } if (!display.isDisposed()) display.update(); }
/** * Runs the event loop for the given shell. * * @param loopShell * the shell */ private void runEventLoop(Shell loopShell) { //Use the display provided by the shell if possible Display display; if (shell == null) { display = Display.getCurrent(); } else { display = loopShell.getDisplay(); } while (loopShell != null && !loopShell.isDisposed()) { try { if (!display.readAndDispatch()) { display.sleep(); } } catch (Throwable e) { exceptionHandler.handleException(e); } } if (!display.isDisposed()) display.update(); }
/** * Runs the event loop for the given shell. * * @param loopShell * the shell */ private void runEventLoop(Shell loopShell) { //Use the display provided by the shell if possible Display display; if (shell == null) { display = Display.getCurrent(); } else { display = loopShell.getDisplay(); } while (loopShell != null && !loopShell.isDisposed()) { try { if (!display.readAndDispatch()) { display.sleep(); } } catch (Throwable e) { // RAP [if] Session scoped exceptionHandler // exceptionHandler.handleException(e); getExceptionHandler().handleException( e ); } } if (!display.isDisposed()) display.update(); }
handler.handleException(e); } else { String msg = "Exception in Workbench.runUI after display was disposed"; //$NON-NLS-1$