From 0417dab63ac557755d765b04ff083995763080be Mon Sep 17 00:00:00 2001 From: jprocter Date: Fri, 17 Dec 2010 16:48:26 +0000 Subject: [PATCH] refined modification test --- src/jalview/ws/rest/RestClient.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/jalview/ws/rest/RestClient.java b/src/jalview/ws/rest/RestClient.java index 04c9561..64333c6 100644 --- a/src/jalview/ws/rest/RestClient.java +++ b/src/jalview/ws/rest/RestClient.java @@ -175,14 +175,17 @@ public class RestClient extends WSClient implements WSClientI, */ protected boolean isAlignmentModified() { - if (undoredo == null) + if (undoredo == null || av==null || av.getAlignment()==null) { + // always return modified if we don't have access to live GUI elements anymore. return true; } if (av.isUndoRedoHashModified(undoredo)) { - + // alignment has been modified in some way. + return true; } + // TODO: look deeper into modification of selection state, etc that may affect RestJobThread.realiseResults(boolean merge); return false; } -- 1.7.10.2