mirror of
https://github.com/haveno-dex/haveno.git
synced 2025-06-29 09:07:27 -04:00
Fix wrong close handler (#270)
This commit is contained in:
parent
d146a5a338
commit
0384c683c7
2 changed files with 3 additions and 3 deletions
|
@ -105,7 +105,7 @@ public class BitsquareApp extends Application {
|
||||||
// configure the system tray
|
// configure the system tray
|
||||||
|
|
||||||
SystemTray systemTray = new SystemTray(primaryStage, this::stop);
|
SystemTray systemTray = new SystemTray(primaryStage, this::stop);
|
||||||
primaryStage.setOnCloseRequest(e -> systemTray.hideStage());
|
primaryStage.setOnCloseRequest(e -> stop());
|
||||||
scene.setOnKeyReleased(keyEvent -> {
|
scene.setOnKeyReleased(keyEvent -> {
|
||||||
// For now we exit when closing/quit the app.
|
// For now we exit when closing/quit the app.
|
||||||
// Later we will only hide the window (systemTray.hideStage()) and use the exit item in the system tray for
|
// Later we will only hide the window (systemTray.hideStage()) and use the exit item in the system tray for
|
||||||
|
|
|
@ -140,8 +140,8 @@ public class TomP2PNode {
|
||||||
|
|
||||||
|
|
||||||
public void shutDown() {
|
public void shutDown() {
|
||||||
if (peerDHT != null && peerDHT.peer() != null)
|
if (peerDHT != null)
|
||||||
peerDHT.peer().shutdown();
|
peerDHT.shutdown();
|
||||||
}
|
}
|
||||||
|
|
||||||
public PeerDHT getPeerDHT() {
|
public PeerDHT getPeerDHT() {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue