Use UI thread for warning popup

This commit is contained in:
Manfred Karrer 2016-03-16 23:39:36 +01:00
parent fff42d7d74
commit 8037c33e79

View file

@ -478,12 +478,12 @@ public class MainViewModel implements ViewModel {
"please file a bug report to the Github page.\n" + "please file a bug report to the Github page.\n" +
"Error=" + e.getMessage(); "Error=" + e.getMessage();
log.error(msg); log.error(msg);
new Popup<>().warning(msg) UserThread.execute(() -> new Popup<>().warning(msg)
.actionButtonText("Shut down") .actionButtonText("Shut down")
.onAction(() -> BitsquareApp.shutDownHandler.run()) .onAction(() -> BitsquareApp.shutDownHandler.run())
.closeButtonText("Report bug at Github issues") .closeButtonText("Report bug at Github issues")
.onClose(() -> Utilities.openWebPage("https://github.com/bitsquare/bitsquare/issues")) .onClose(() -> Utilities.openWebPage("https://github.com/bitsquare/bitsquare/issues"))
.show(); .show());
} }
} }