mirror of https://github.com/zlatinb/muwire
avoid exception on preview
parent
b04179631c
commit
3e51bca077
|
@ -27,10 +27,12 @@ class DownloadPreviewer extends SwingWorker {
|
|||
public void done() {
|
||||
File previewFile = get()
|
||||
view.dialog.setVisible(false)
|
||||
view.mvcGroup.destroy()
|
||||
if (previewFile == null)
|
||||
JOptionPane.showMessageDialog(null, "Generating preview file failed", "Preview Failed", JOptionPane.ERROR_MESSAGE)
|
||||
else
|
||||
Desktop.getDesktop().open(previewFile)
|
||||
else {
|
||||
try {
|
||||
Desktop.getDesktop().open(previewFile)
|
||||
} catch (IOException ignore) {}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue