2 * Copyright (C) 2016 The Qt Company Ltd.
3 * Copyright (C) 2016 Mentor Graphics Development (Deutschland) GmbH
5 * Licensed under the Apache License, Version 2.0 (the "License");
6 * you may not use this file except in compliance with the License.
7 * You may obtain a copy of the License at
9 * http://www.apache.org/licenses/LICENSE-2.0
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
19 import QtQuick.Layouts 1.1
20 import QtQuick.Controls 1.0
26 signal languageChanged
30 anchors.topMargin: -218
31 anchors.bottomMargin: -215
32 source: './images/AGL_HMI_Background_Car-01.png'
38 anchors.horizontalCenter: parent.horizontalCenter
39 anchors.top: parent.top
41 source: './images/B14-90.png'
47 anchors.left: parent.left
48 anchors.leftMargin: 20
49 anchors.top: parent.top
51 source: './images/us_flag.png'
58 anchors.right: parent.right
59 anchors.rightMargin: 20
60 anchors.top: parent.top
62 source: './images/visa.png'
66 anchors.top: parent.bottom
68 anchors.horizontalCenter: parent.horizontalCenter
69 horizontalAlignment: Text.AlignHCenter
78 anchors.horizontalCenter: parent.horizontalCenter
79 anchors.bottom: parent.bottom
80 anchors.bottomMargin: 40
84 anchors.centerIn: parent
86 text: "No Authenticated User"
89 SequentialAnimation on font.letterSpacing {
92 NumberAnimation { from: 0; to: 50; easing.type: Easing.InQuad; duration: 3000 }
98 helloText.font.letterSpacing = 0
103 SequentialAnimation on opacity {
106 NumberAnimation { from: 1; to: 0; duration: 2600 }
107 PauseAnimation { duration: 400 }
111 function showHello(helloString) {
112 helloText.text = helloString
113 animation1.running = true;
114 animation2.running = true;
117 function showSign90(show) {
118 sign90.visible = show
121 function showVisa(show, num) {
123 cardNumber.text = num;
125 function changeFlag(flagImage) {
126 flagLanguage.source = flagImage
130 anchors.centerIn: parent
131 width: cellHeight * 3
132 height: cellHeight * 3
137 model: ApplicationModel {}
138 delegate: MouseArea {
144 source: './images/HMI_AppLauncher_%1_%2-01.png'.arg(model.icon).arg(pressed ? 'Active' : 'Inactive')
147 anchors.horizontalCenter: parent.horizontalCenter
148 horizontalAlignment: Text.AlignHCenter
151 font.family: "Roboto"
153 text: '%1'.arg(model.name)
154 function myChangeLanguage() {
155 text = '%1'.arg(model.name)
156 appImage.source = './images/HMI_AppLauncher_%1_%2-01.png'.arg(model.icon).arg(pressed ? 'Active' : 'Inactive')
158 Component.onCompleted: {
159 root.languageChanged.connect(myChangeLanguage)
164 console.log("app is ", model.id)
165 pid = launcher.launch(model.id)
167 layoutHandler.makeMeVisible(pid)
169 applicationArea.visible = true
170 appLauncherAreaLauncher.visible = false
171 layoutHandler.showAppLayer(pid)
174 console.warn("app cannot be launched!")