blob: 74687b3aefae84451ccbff3baa6465743c48dc85 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
|
import QtQuick 2.0
import "../com/neusoft/auto/widgets"
import "../windowsList.js" as WindowsList
import "../layoutList.js" as Layout
import "mirrorlinkEvent.js" as MirrorEvent
import Label 2.0
Item {
width: 800
height: 346
property string imagePath: mirrorlinkCtrl.acImagePath
property int appCount: mirrorlinkCtrl.appCount
property bool intoApp : false
property bool appEnable : true
GridView{
id : appgrid
width: 800
height: 346
model:mirrorlinkCtrl.getApplist()
delegate: model_delegate
cellHeight: 200
cellWidth: 200
interactive:false
}
Component{
id: model_delegate
Item{
width : 200
height: 180
HMIButton{
id:icon
btnImg: icon.pressed? imagePath+model.modelData.appImageNamePush
:imagePath+model.modelData.appImageName
enabled : appEnable
onClicked: {
console.log("-----------Mirrorlink_Half----click app ID-------------------------------",model.modelData.uiId);
intoApp = true;
mirrorlinkCtrl.sendMessageToPhonelink(66, model.modelData.uiId);
//ScreenManager.changeForm(Layout.FM_MAXIMIZE,WindowsList.MIRRORLINK_MAIN);
appEnable = false;
//ADD BY lizhe in 20170825
cancelAppEnableTimer.restart();
}
}
HMILabel{
//x:24
y:110
width:180
height:26
anchors.horizontalCenter:icon.horizontalCenter
text: systemCtrl.iLanguage === 1? model.modelData.appNameCN: model.modelData.appName
}
}
}
//ADD BY lizhe in 20170825 start
Timer
{
id : cancelAppEnableTimer
interval: 1500
onTriggered:
{
appEnable = true;
}
}
//ADD BY lizhe in 20170825 end
Connections{
target: mirrorlinkCtrl
onAppListChanged:{
appgrid.model = mirrorlinkCtrl.getApplist();
}
onSigPhonelinkDisplay:
{
console.log("!!!!!!!!!!!!!!!!!!!!!!!!!!onSigPhonelinkDisplay!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!");
//MODIFY BY lizhe in 20170825 start
if((ScreenManager.getFormInfo(WindowsList.MIRRORLINK_MAIN) &7) != 0 && (ScreenManager.getFormInfo(WindowsList.MIRRORLINK_MAIN) &7) != 4)
{
console.log("-[HMI]-[Mirrirlink_Half.qml]-------mirrorlink is show----------------");
ScreenManager.changeForm(Layout.FM_MAXIMIZE,WindowsList.MIRRORLINK_MAIN);
appEnable = true;
}
else
{
console.log("-[HMI]-[Mirrirlink_Half.qml]-------mirrorlink is hided,need to return mirrorlink home----------------");
mirrorlinkCtrl.sendMessageToPhonelink(51,2);
appEnable = true;
}
//MODIFY BY lizhe in 20170825 end
}
}
}
|