From 8a1e95239518d3c4344122f66ad66a49d455e4dc Mon Sep 17 00:00:00 2001 From: Michal Klocek Date: Fri, 6 Nov 2015 20:59:40 +0100 Subject: [PATCH] Do not die when tab closed Do not show close button if there is only one tab left. Change-Id: I2c8cea42ca7da3149e2d8041fd8a5029ae0f8f7e Reviewed-by: Joerg Bornemann --- src/qml/PageView.qml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/qml/PageView.qml b/src/qml/PageView.qml index b78feaa..e82b759 100644 --- a/src/qml/PageView.qml +++ b/src/qml/PageView.qml @@ -419,8 +419,6 @@ Rectangle { listModel.remove(index) pathView.decrementCurrentIndex() pathView.interactive = true - if (listModel.count == 0) - engine.rootWindow.close() } function get(index) { @@ -558,7 +556,7 @@ Rectangle { Rectangle { enabled: index == pathView.currentIndex && !pathView.moving && !pathView.flicking && wrapper.visibility == 1.0 opacity: enabled ? 1.0 : 0.0 - visible: wrapper.visibility == 1.0 + visible: wrapper.visibility == 1.0 && listModel.count > 1 width: image.sourceSize.width height: image.sourceSize.height - 2 radius: width / 2 -- 2.39.2