X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fjalview%2Fio%2FFileLoader.java;h=0fc4aa86af4e812147062be4bef39a366332c8ca;hb=c9c74c082bdd9323850a864144dc8a9b36399157;hp=f7208045907cab2aef42c267128806d350d767bb;hpb=e44514b727077d5cd7edb5d8184ab85cbc2eed13;p=jalview.git diff --git a/src/jalview/io/FileLoader.java b/src/jalview/io/FileLoader.java index f720804..0fc4aa8 100755 --- a/src/jalview/io/FileLoader.java +++ b/src/jalview/io/FileLoader.java @@ -122,8 +122,12 @@ public class FileLoader AlignFrame af; + public void run() { + if (Desktop.instance != null) + Desktop.instance.startLoading(file); + SequenceI[] sequences = null; if (format.equalsIgnoreCase("Jalview")) @@ -164,11 +168,6 @@ public class FileLoader Desktop.addInternalFrame(af, file, AlignFrame.NEW_WINDOW_WIDTH, AlignFrame.NEW_WINDOW_HEIGHT); - if(jalview.bin.Cache.getDefault("WRAP_ALIGNMENT", false)) - { - af.wrapMenuItem.setSelected(true); - af.wrapMenuItem_actionPerformed(null); - } try { af.setMaximum(jalview.bin.Cache.getDefault("SHOW_FULLSCREEN", false)); @@ -177,10 +176,12 @@ public class FileLoader { } } - } else { + if (Desktop.instance != null) + Desktop.instance.stopLoading(); + JOptionPane.showInternalMessageDialog(Desktop.desktop, "Couldn't load file " + file + "\n" @@ -194,6 +195,10 @@ public class FileLoader { updateRecentlyOpened(); } + + if (Desktop.instance != null) + Desktop.instance.stopLoading(); + } }