Warning, /education/marble/src/apps/marble-maps/SettingsDialog.qml is written in an unsupported language. File is not indexed.

0001 // SPDX-License-Identifier: LGPL-2.1-or-later
0002 //
0003 // SPDX-FileCopyrightText: 2016 Dennis Nienhüser <nienhueser@kde.org>
0004 //
0005 
0006 import QtQuick 2.3
0007 import QtQuick.Controls 1.3
0008 import QtQuick.Window 2.2
0009 import QtQuick.Layouts 1.1
0010 
0011 import org.kde.marble 0.20
0012 
0013 Item {
0014     id: root
0015     height: column.height + Screen.pixelDensity * 4
0016 
0017     SystemPalette {
0018         id: palette
0019         colorGroup: SystemPalette.Active
0020     }
0021 
0022     Settings {
0023         id: settings
0024 
0025         Component.onDestruction: {
0026             settings.setValue("Network", "wlanOnly", wlanOnly.checked ? "true" : "false")
0027         }
0028     }
0029 
0030     Rectangle {
0031         anchors.fill: parent
0032         color: palette.base
0033     }
0034 
0035     Column {
0036         id: column
0037         anchors {
0038             left: parent.left
0039             right: parent.right
0040             top: parent.top
0041             margins: Screen.pixelDensity * 2
0042         }
0043 
0044         spacing: Screen.pixelDensity * 2
0045 
0046         Text {
0047             id: text
0048             text: qsTr("Network Settings")
0049         }
0050 
0051         CheckBox {
0052             id: wlanOnly
0053             text: qsTr("Download Maps via WLAN only")
0054             checked: settings.value("Network", "wlanOnly") === "true"
0055             onCheckedChanged: marbleMaps.wlanOnly = checked
0056         }
0057     }
0058 }