2 * Copyright (C) 2015-2017 Canonical Ltd.
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; version 3.
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
18import QtQuick.Layouts 1.1
19import Lomiri.Components 1.3
20import Lomiri.Components.ListItems 1.3
21import Lomiri.Components.Popups 1.3
25 objectName: "modeSwitchWarningDialog"
27 property alias model: appRepeater.model
33 text: i18n.tr("Apps may have unsaved data:")
44 Layout.preferredHeight: units.gu(2)
45 Layout.preferredWidth: units.gu(2)
47 sourceSize.width: width
48 sourceSize.height: height
51 Layout.fillWidth: true
60 text: i18n.ctr("Re-dock means connect the device again to an external screen/mouse/keyboard", "Re-dock, save your work and close these apps to continue.")
61 wrapMode: Text.WordWrap
67 text: i18n.tr("Or force close now (unsaved data will be lost).")
68 wrapMode: Text.WordWrap
72 ThinDivider { width: parent.width }
77 objectName: "reconnectLabel"
78 Layout.fillWidth: true
79 property bool clicked: false
80 property string notClickedText: i18n.tr("OK, I will reconnect")
81 property string clickedText: i18n.tr("Reconnect now!")
82 text: clicked ? clickedText : notClickedText
87 onClicked: parent.clicked = true;
93 objectName: "forceCloseButton"
94 text: i18n.tr("Close all")
95 color: theme.palette.normal.negative