Issue #1298 Comments on GridMangerView on why SaveParameterDialog and KillJobsOnExit must stay blocking.

Change-Id: I034b1f02eb3b1ac623c8d2d4b9a953e53534dba0

Former-commit-id: a155a8522e [formerly 3b96d312cd] [formerly 8952e1cef8] [formerly a155a8522e [formerly 3b96d312cd] [formerly 8952e1cef8] [formerly e37a097596 [formerly 8952e1cef8 [formerly 6dc43f8d58b82a4b59a3945cc41ad8dcdda47a11]]]]
Former-commit-id: e37a097596
Former-commit-id: f141ad90bb [formerly 2cbd0000ad] [formerly 42e63af20cadfda9fc5ab4e408df2ddcc69ae6d4 [formerly b93dcebdc0]]
Former-commit-id: bc16f5ad0a375c883d0169452b9a89428cadf8ab [formerly 6c9c5a0a5f]
Former-commit-id: 6d49470c36
This commit is contained in:
Roger Ferrel 2012-10-30 12:33:52 -05:00
parent 3e225faa8b
commit 155cbf4110
2 changed files with 13 additions and 3 deletions

View file

@ -54,6 +54,7 @@ import com.raytheon.viz.ui.color.IBackgroundColorChangedListener.BGColorMode;
* 06/11/2009 #1947 rjpeter Updated to add saving of parms on close,
* adding cancel capability and if error on
* save then the close is cancelled.
* 10/30/2012 #1298 rferrel Must keep blocking dialogs to work with eclipse plugins.
* </pre>
*
* @author dfitch
@ -129,6 +130,11 @@ public class GridManagerView extends ViewPart implements ISaveablePart2 {
return view;
}
/*
* (non-Javadoc)
*
* @see org.eclipse.ui.ISaveablePart2#promptToSaveOnClose()
*/
@Override
public int promptToSaveOnClose() {
// Check for any running/queued jobs.
@ -137,6 +143,8 @@ public class GridManagerView extends ViewPart implements ISaveablePart2 {
.getShell();
KillJobsOnExitDialog dialog = new KillJobsOnExitDialog(shell);
// Must keep modal and blocking in order to work with eclipse
// plugins.
dialog.setBlockOnOpen(true);
int returnCode = dialog.open();
if (returnCode == IDialogConstants.CANCEL_ID) {
@ -154,7 +162,8 @@ public class GridManagerView extends ViewPart implements ISaveablePart2 {
SaveParameterDialog dialog = new SaveParameterDialog(shell,
dataManager);
// Must keep modal and blocking in order to work with eclipse
// plugins.
dialog.setBlockOnOpen(true);
int returnCode = dialog.open();

View file

@ -59,6 +59,7 @@ import com.raytheon.viz.ui.dialogs.CaveJFACEDialog;
* Date Ticket# Engineer Description
* ------------ ---------- ----------- --------------------------
* Oct 26, 2011 randerso Initial creation
* Oct 30, 2012 1298 rferrel Code clean for non-blocking dialog.
*
* </pre>
*
@ -68,10 +69,10 @@ import com.raytheon.viz.ui.dialogs.CaveJFACEDialog;
public abstract class AbstractSaveParameterDialog extends CaveJFACEDialog
implements DisposeListener {
private static final transient IUFStatusHandler statusHandler = UFStatus
private final transient IUFStatusHandler statusHandler = UFStatus
.getHandler(AbstractSaveParameterDialog.class);
protected static final int MAX_CONCURRENT_SAVES = 5;
private final int MAX_CONCURRENT_SAVES = 5;
protected DataManager dataManager;