From 2778a1bc20376661041c0d3ed38fd0c3ee327f9a Mon Sep 17 00:00:00 2001 From: Sander van Grieken Date: Tue, 27 Sep 2022 17:16:09 +0200 Subject: [PATCH] fix dialog stack handling when closing from outside --- electrum/gui/qml/components/main.qml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/electrum/gui/qml/components/main.qml b/electrum/gui/qml/components/main.qml index efaaa4261..18ffe0228 100644 --- a/electrum/gui/qml/components/main.qml +++ b/electrum/gui/qml/components/main.qml @@ -229,10 +229,11 @@ ApplicationWindow onClosing: { if (activeDialogs.length > 0) { - console.log('dialog on top') - var activeDialog = activeDialogs.pop() + var activeDialog = activeDialogs[activeDialogs.length - 1] if (activeDialog.allowClose) { activeDialog.close() + } else { + console.log('dialog disallowed close') } close.accepted = false return