summaryrefstree
path: root/usr/bin/qml/Mirrorlink/Mirrorlink_Instructions.qml
blob: bd7de26877e8ea0c1f6e2753f9d968b9e41b62b3 (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
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
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 {
    id: instructionItem
    width: 960
    height: 400
    //property int listCurIndex: 0
    property bool closeed : false

    onCloseedChanged:
    {
        if (!instructionItem.closeed)
        {
            //changed by lizhe for 171074 start
            instructionList.positionViewAtIndex(0,instructionList.Beginning)
            instructionList.currentIndex = 0;
            //listCurIndex = 0;
            //changed by lizhe for 171074 end
        }
    }

    HMILabel{
        y:25
        anchors.horizontalCenter: parent.horizontalCenter
        height: 32
        width:  150
        text: systemCtrl.iLanguage == 1?"连接说明":"Connection"
	font.family:  systemCtrl.iLanguage == 1?"方正兰亭黑简体" :"Arial Regular"
        font.pixelSize:30
    }

    ListModel{
        id : instructionModel

        ListElement{
            instructionText: "1.iPhone手机可进入App Store,"
            instructionText1:"下载“九州行地图【互联版】” ,"
            instructionText2:"并安装;"
            instructionTextE1:"1.IPhone users can enter App"
            instructionTextE2:"Store to download and install"
            instructionTextE3:"\"九州行地图【互联版】\"APP"
            instructionTextE4:"by phone side."
            instructionImg1: "../Material/Type_J_I_Link/M8X_Instructions_01-1_iPhone.png"
            instructionImg2: ""
        }
        ListElement{
            instructionText: "或者扫描该二维码,下载“九州"
            instructionText1:"行地图【互联版】”,并安装。"
            instructionText2:""
            instructionTextE1:"Users can scan the QR code to"
            instructionTextE2:"download and install \"九州行地"
            instructionTextE3:"图【互联版】\" APP also."
            instructionTextE4:""
            instructionImg1: "../../qml_link/images/AppLink/Type_I_Home/I_02_Home/M8X_Instructions_01-2_iPhone.png"
			//"../Material/Type_J_I_Link/M8X_Instructions_01-2_iPhone.png"
            instructionImg2: ""
        }
        ListElement{
            instructionText: "2.安卓手机可进入应用宝,下载"
            instructionText1:"“九州行地图互联版”,并安装。"
            instructionText2:""
            instructionTextE1:"2.Android users can enter \"应用"
            instructionTextE2:"宝\" to download and install \"九"
            instructionTextE3:"州行地图互联版\"APP by phone"
            instructionTextE4:"side."
            instructionImg1: "../Material/Type_J_I_Link/M8X_Instructions_01-2_Android.png"
            instructionImg2: ""
        }
        ListElement{
            instructionText: "或者扫描该二维码,下载“九州"
            instructionText1:"行地图互联版”,并安装。"
            instructionText2:""
            instructionTextE1:"Users can scan the QR code to"
            instructionTextE2:"download and install \"九州行地"
            instructionTextE3:"图互联版\" APP also."
            instructionTextE4:""
            instructionImg1: "../../qml_link/images/AppLink/Type_I_Home/I_02_Home/M8X_Instructions_02-2_Android.png"
			//"../Material/Type_J_I_Link/M8X_Instructions_02_Android.png"
            instructionImg2: ""
        }
        ListElement{
            instructionText: "3.使用USB数据线连接手机和车"
            instructionText1:"机后,可进入智能互联界面。"
            instructionText2:""
            instructionTextE1:"3.Use the USB data cable to  "
            instructionTextE2:"connect the phone and car,and"
            instructionTextE3:"then entry i-Link APP interface."
            instructionTextE4:""
            instructionImg1:"../Material/Type_J_I_Link/M8X_Instructions_03_Android.png"
            instructionImg2: "../Material/Type_J_I_Link/M8X_Instructions_USB.png"
        }
        ListElement{
            instructionText: "备注:车机和手机通过蓝牙建立"
            instructionText1:"连接后,车机端才能够播放手机"
            instructionText2:"端声音。"
            instructionTextE1:"Note:When the phone and car"
            instructionTextE2:"are connected via BT, car side"
            instructionTextE3:"play mobile phone voice."
            instructionTextE4:""
            instructionImg1:"../Material/Type_J_I_Link/M8X_Instructions_Notes_02.png"
            instructionImg2: "../Material/Type_J_I_Link/M8X_Instructions_BT.png"
        }
    }

    Component {
        id: instructionDelegate
        Item{
                x:0
                y:73
                width:960
                height: 560-233
                HMILabel{
                    id:wenben1
                    font.pixelSize: 30
                    wrapMode: Label.WordWrap
                    color: "white"
                    anchors.left: parent.left
                    anchors.leftMargin: 120
                    anchors.top: parent.top
                    anchors.topMargin: 32
                    horizontalAlignment:Label.AlignLeft
                    width:460
                    height:30
                    //lineHeightMode:Text.FixedHeight
                    //lineHeight:60.0
                    font.family: systemCtrl.iLanguage == 1? "方正兰亭黑简体":"Arial"
                    text:systemCtrl.iLanguage == 1?instructionText:instructionTextE1
                }
                HMILabel{
                    id:wenben2
                    font.pixelSize: 30
                    wrapMode: Label.WordWrap
                    color: "white"
                    anchors.left: parent.left
                    anchors.leftMargin: 120
                    anchors.top: wenben1.top
                    anchors.topMargin: 60
                    horizontalAlignment:Label.AlignLeft
                    width:460
                    height:30
                    //lineHeightMode:Text.FixedHeight
                    //lineHeight:60.0
                    font.family: systemCtrl.iLanguage == 1? "方正兰亭黑简体":"Arial"
                    text:systemCtrl.iLanguage == 1?instructionText1:instructionTextE2
                }
                HMILabel{
                    id:wenben3
                    font.pixelSize: 30
                    wrapMode: Label.WordWrap
                    color: "white"
                    anchors.left: parent.left
                    anchors.leftMargin: 120
                    anchors.top: wenben2.top
                    anchors.topMargin: 60
                    horizontalAlignment:Label.AlignLeft
                    width:460
                    height:30
                    //lineHeightMode:Text.FixedHeight
                    //lineHeight:60.0
                    font.family: systemCtrl.iLanguage == 1? "方正兰亭黑简体":"Arial"
                    text:systemCtrl.iLanguage == 1?instructionText2:instructionTextE3
                }
                HMILabel{
                    id:wenben4
                    font.pixelSize: 30
                    wrapMode: Label.WordWrap
                    color: "white"
                    anchors.left: parent.left
                    anchors.leftMargin: 120
                    anchors.top: wenben3.top
                    anchors.topMargin: 60
                    horizontalAlignment:Label.AlignLeft
                    width:460
                    height:30
                    //lineHeightMode:Text.FixedHeight
                    //lineHeight:60.0
                    font.family: systemCtrl.iLanguage == 1? "方正兰亭黑简体":"Arial"
                    text:instructionTextE4
                    visible:systemCtrl.iLanguage == 1?false:true
                }

                Image{
                    //id:instructionImg1
                    anchors.right: parent.right
                    anchors.rightMargin: 114
                    anchors.top: parent.top
                    anchors.topMargin: 0
                    source:instructionImg1
                }
                Image{
                    //id:instructionImg2
                    anchors.left: parent.left
                    anchors.leftMargin: 177
                    anchors.bottom: parent.bottom
                    anchors.bottomMargin: 13
                    source:instructionImg2
                }
            }

    }
    ListView {
        id: instructionList
        y:233-160
        width: 960
        height: 560-233
        model: instructionModel
        delegate: instructionDelegate
        snapMode:ListView.SnapOneItem
        clip:true
        boundsBehavior: Flickable.StopAtBounds
        spacing:40
		highlightRangeMode: ListView.StrictlyEnforceRange
        currentIndex:0
		onCurrentIndexChanged:{
            //console.log("----------------------------------------- "+instructionList.currentIndex)
            mirrorlinkCtrl.sendMessageToPhonelink(79,instructionList.currentIndex);
        }
    }

    Connections
    {
        target:mirrorlinkCtrl
        onSigInstructionListChanged:
        {
            //changed by lizhe for 171074 start
            console.log("-------------------onSigInstructionListChanged-------------------");
            instructionList.positionViewAtIndex(index,instructionList.Beginning)
            instructionList.currentIndex = index;
            //listCurIndex = index;
            //changed by lizhe for 171074 end
        }
    }

}