summaryrefslogtreecommitdiff
path: root/Main.qml
diff options
context:
space:
mode:
authorDominik Holland <dominik.holland@pelagicore.com>2016-03-18 09:04:57 +0100
committerDominik Holland <dominik.holland@pelagicore.com>2016-03-18 13:07:52 +0000
commit97a8516378751904e2cf29aa3ced2d562684f490 (patch)
tree74fe165b7b0a74395acbc9fbb4ad3ba77e6a5cff /Main.qml
parentd350c1ee30be866c59650db3ebdc6100882eae1f (diff)
downloadneptune-ui-97a8516378751904e2cf29aa3ced2d562684f490.tar.gz
Improved the Style singleton to support different style configs
The different styleConfigs are loaded using the styleConfig variable in am-config.yaml. By default it's set to "auto" which will try to adapt the UI to the current screen size. Also consolidated all the different Main*.qml files into two versions Main.qml for displaying the HUD and ClusterAndHUD.qml for showing the InstrumentCluster in a separate Window together with the HUD. Change-Id: I8332cb97528db5de4fcb478e4f943ed93174d84f Task-number: QTAUTO-21 Reviewed-by: Nedim Hadzic <nedim.hadzic@pelagicore.com>
Diffstat (limited to 'Main.qml')
-rw-r--r--Main.qml62
1 files changed, 62 insertions, 0 deletions
diff --git a/Main.qml b/Main.qml
new file mode 100644
index 0000000..3d5bbbd
--- /dev/null
+++ b/Main.qml
@@ -0,0 +1,62 @@
+/****************************************************************************
+**
+** Copyright (C) 2016 Pelagicore AG
+** Contact: http://www.qt.io/ or http://www.pelagicore.com/
+**
+** This file is part of the Neptune IVI UI.
+**
+** $QT_BEGIN_LICENSE:GPL3-PELAGICORE$
+** Commercial License Usage
+** Licensees holding valid commercial Pelagicore Neptune IVI UI
+** licenses may use this file in accordance with the commercial license
+** agreement provided with the Software or, alternatively, in accordance
+** with the terms contained in a written agreement between you and
+** Pelagicore. For licensing terms and conditions, contact us at:
+** http://www.pelagicore.com.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPLv3 included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3 requirements will be
+** met: http://www.gnu.org/licenses/gpl-3.0.html.
+**
+** $QT_END_LICENSE$
+**
+** SPDX-License-Identifier: GPL-3.0
+**
+****************************************************************************/
+
+import QtQuick 2.1
+import QtQuick.Window 2.2
+import "sysui"
+import controls 1.0
+import utils 1.0
+
+Rectangle {
+ id: root
+
+ color: "black"
+ width: Style.screenWidth
+ height: Style.screenHeight
+
+ Item {
+ width: Style.screenWidth
+ height: Style.screenHeight
+
+ DisplayBackground {
+ id: background
+ anchors.fill: display
+ }
+
+ Display {
+ id: display
+ anchors.fill: parent
+ }
+
+ DisplayGrid {
+ anchors.fill: display
+ }
+ }
+}