Merge lp:~zeller-benjamin/qtcreator-plugin-ubuntu/reviewtasks into lp:qtcreator-plugin-ubuntu

Proposed by Benjamin Zeller
Status: Merged
Approved by: Zoltan Balogh
Approved revision: 277
Merged at revision: 281
Proposed branch: lp:~zeller-benjamin/qtcreator-plugin-ubuntu/reviewtasks
Merge into: lp:qtcreator-plugin-ubuntu
Diff against target: 1016 lines (+469/-384)
14 files modified
share/qtcreator/templates/wizards/ubuntu/scope/CMakeLists.txt (+11/-2)
share/qtcreator/templates/wizards/ubuntu/scope/manifest.json.in (+1/-0)
share/qtcreator/templates/wizards/ubuntu/scope/wizard.xml (+1/-1)
share/qtcreator/ubuntu/devicespage/DeviceAdvancedTab.qml (+0/-92)
share/qtcreator/ubuntu/devicespage/DeviceBuilderTab.qml (+0/-42)
share/qtcreator/ubuntu/devicespage/DeviceEmulatorTab.qml (+0/-71)
share/qtcreator/ubuntu/devicespage/DeviceKitManager.qml (+0/-62)
share/qtcreator/ubuntu/devicespage/DeviceLogTab.qml (+0/-12)
share/qtcreator/ubuntu/devicespage/DevicePage.qml (+314/-92)
share/qtcreator/ubuntu/devicespage/ScrollableView.qml (+55/-0)
share/qtcreator/ubuntu/devicespage/SectionItem.qml (+58/-0)
share/qtcreator/ubuntu/scripts/qtc_device_applaunch.py (+4/-1)
src/ubuntu/ubuntu.pro (+3/-6)
src/ubuntu/ubuntupackageoutputparser.cpp (+22/-3)
To merge this branch: bzr merge lp:~zeller-benjamin/qtcreator-plugin-ubuntu/reviewtasks
Reviewer Review Type Date Requested Status
Zoltan Balogh Approve
PS Jenkins bot continuous-integration Approve
Review via email: mp+236689@code.launchpad.net

Commit message

- Add a TaskHandler, so we can open the links directly from the Issues tab
- Removed unused Settings
- Review click packages before uploading them to the phone
- Show review errors in Issues output view

Description of the change

- Add a TaskHandler, so we can open the links directly from the Issues tab
- Removed unused Settings
- Review click packages before uploading them to the phone
- Show review errors in Issues output view

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
276. By Benjamin Zeller

- Automatically unlock phone and disable greeter
- Use regexp to match policy groups

277. By Benjamin Zeller

Remove unwanted output

Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
Revision history for this message
Zoltan Balogh (bzoltan) wrote :

OK

review: Approve
278. By Benjamin Zeller

Merge trunk

279. By Benjamin Zeller

- Fix Bug 1377090: "Overiding an app doesn't work"
- Fix Bug 1377094: "Click review errors prevent applications from being
deployed to the device"

280. By Benjamin Zeller

Merge

281. By Benjamin Zeller

- Refactor UI of devicespage
- Fix Bug #1372633 "Device tab content page needs to allow vertical
scrolling"

282. By Benjamin Zeller

- Scope templates should figure out the architecture automatically

283. By Benjamin Zeller

- Do not choke on debug policy errors

284. By Benjamin Zeller

- Do not choke on i386 error

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'share/qtcreator/templates/wizards/ubuntu/scope/CMakeLists.txt'
2--- share/qtcreator/templates/wizards/ubuntu/scope/CMakeLists.txt 2014-09-25 14:36:41 +0000
3+++ share/qtcreator/templates/wizards/ubuntu/scope/CMakeLists.txt 2014-10-09 08:07:05 +0000
4@@ -55,15 +55,24 @@
5 add_definitions(-DPACKAGE_NAME="%ClickDomain:l%.%ProjectName:l%")
6 add_definitions(-DSCOPE_NAME="%ClickDomain:l%.%ProjectName:l%_%ClickHookName:l%")
7
8+#This command figures out the target architecture and puts it into the manifest file
9+execute_process(
10+ COMMAND dpkg-architecture -qDEB_HOST_ARCH
11+ OUTPUT_VARIABLE CLICK_ARCH
12+ OUTPUT_STRIP_TRAILING_WHITESPACE
13+)
14+
15+configure_file(manifest.json.in ${CMAKE_CURRENT_BINARY_DIR}/manifest.json)
16+
17 # Install the click manifest
18-install(FILES manifest.json DESTINATION "/")
19+install(FILES ${CMAKE_CURRENT_BINARY_DIR}/manifest.json DESTINATION "/")
20 install(FILES "%ClickHookName:l%.apparmor" DESTINATION "/")
21
22 # Make this file show up in QtCreator
23 add_custom_target(hidden_files
24 ALL
25 SOURCES
26- manifest.json
27+ manifest.json.in
28 "%ClickHookName:l%.apparmor"
29 )
30
31
32=== renamed file 'share/qtcreator/templates/wizards/ubuntu/scope/manifest.json' => 'share/qtcreator/templates/wizards/ubuntu/scope/manifest.json.in'
33--- share/qtcreator/templates/wizards/ubuntu/scope/manifest.json 2014-08-18 15:29:28 +0000
34+++ share/qtcreator/templates/wizards/ubuntu/scope/manifest.json.in 2014-10-09 08:07:05 +0000
35@@ -5,6 +5,7 @@
36 "description": "A simple Unity scope that accesses local content",
37 @endif
38 "maintainer": "%ClickMaintainer%",
39+ "architecture": "@CLICK_ARCH@",
40 "name": "%ClickDomain:l%.%ProjectName:l%",
41 "title": "%ProjectName:l%",
42 "hooks": {
43
44=== modified file 'share/qtcreator/templates/wizards/ubuntu/scope/wizard.xml'
45--- share/qtcreator/templates/wizards/ubuntu/scope/wizard.xml 2014-09-23 12:28:39 +0000
46+++ share/qtcreator/templates/wizards/ubuntu/scope/wizard.xml 2014-10-09 08:07:05 +0000
47@@ -40,7 +40,7 @@
48
49 <file source="CMakeLists.txt" openproject="true"/>
50 <file source="displayName.apparmor" target="%ClickHookName:l%.apparmor"/>
51- <file source="manifest.json" openeditor="true"/>
52+ <file source="manifest.json.in" openeditor="true"/>
53 <file source="readme.txt"/>
54 </files>
55
56
57=== removed file 'share/qtcreator/ubuntu/devicespage/DeviceAdvancedTab.qml'
58--- share/qtcreator/ubuntu/devicespage/DeviceAdvancedTab.qml 2014-04-25 10:03:59 +0000
59+++ share/qtcreator/ubuntu/devicespage/DeviceAdvancedTab.qml 1970-01-01 00:00:00 +0000
60@@ -1,92 +0,0 @@
61-import QtQuick 2.0
62-import QtQuick.Controls 1.0 as Controls
63-import QtQuick.Layouts 1.0
64-import Ubuntu.Components 0.1
65-import Ubuntu.Components.ListItems 0.1 as ListItem
66-
67-
68-RowLayout {
69- Controls.ScrollView {
70- Layout.fillHeight: true
71- Layout.minimumWidth: units.gu(78)
72- UbuntuListView {
73- model: VisualItemModel{
74- Label {
75- text: "Device Control"
76- fontSize: "large"
77- anchors.left: parent.left
78- }
79- ListItem.Standard {
80- text:"Clone time config from Host to Device"
81- control: Button{
82- text: "Execute"
83- enabled: !deviceItemView.deviceBusy
84- onClicked: devicesModel.triggerCloneTimeConfig(deviceId)
85- }
86- }
87- ListItem.Standard {
88- text:"Enable port forwarding"
89- control: Button{
90- text: "Execute"
91- enabled: !deviceItemView.deviceBusy
92- onClicked: devicesModel.triggerPortForwarding(deviceId)
93- }
94- }
95- ListItem.Standard {
96- text:"Setup public key authentication"
97- control: Button{
98- text: "Execute"
99- enabled: !deviceItemView.deviceBusy
100- onClicked: devicesModel.triggerSSHSetup(deviceId)
101- }
102- }
103- ListItem.Standard {
104- text:"Open SSH connection to the device"
105- control: Button{
106- text: "Execute"
107- enabled: !deviceItemView.deviceBusy
108- onClicked: devicesModel.triggerSSHConnection(deviceId)
109- }
110- }
111- ListItem.Divider{}
112- Label {
113- text: "Device Mode"
114- fontSize: "large"
115- }
116- ListItem.Standard {
117- text:"Reboot"
118- control: Button{
119- text: "Execute"
120- enabled: !deviceItemView.deviceBusy
121- onClicked: devicesModel.triggerReboot(deviceId)
122- }
123- }
124- ListItem.Standard {
125- text:"Reboot to bootloader"
126- control: Button{
127- text: "Execute"
128- enabled: !deviceItemView.deviceBusy
129- onClicked: devicesModel.triggerRebootBootloader(deviceId)
130- }
131- }
132- ListItem.Standard {
133- text:"Reboot to recovery"
134- control: Button{
135- text: "Execute"
136- enabled: !deviceItemView.deviceBusy
137- onClicked: devicesModel.triggerRebootRecovery(deviceId)
138- }
139- }
140- ListItem.Standard {
141- text:"Shutdown"
142- control: Button{
143- text: "Execute"
144- enabled: !deviceItemView.deviceBusy
145- onClicked: devicesModel.triggerShutdown(deviceId)
146- }
147- }
148- }
149- }
150- }
151-}
152-
153
154=== removed file 'share/qtcreator/ubuntu/devicespage/DeviceBuilderTab.qml'
155--- share/qtcreator/ubuntu/devicespage/DeviceBuilderTab.qml 2014-04-25 10:03:59 +0000
156+++ share/qtcreator/ubuntu/devicespage/DeviceBuilderTab.qml 1970-01-01 00:00:00 +0000
157@@ -1,42 +0,0 @@
158-import QtQuick 2.0
159-import QtQuick.Controls 1.0 as Controls
160-import QtQuick.Layouts 1.0
161-import Ubuntu.Components 0.1
162-import Ubuntu.Components.ListItems 0.1 as ListItem
163-
164-RowLayout {
165- spacing: units.gu(1)
166- Controls.ScrollView {
167- Layout.fillHeight: true
168- Layout.minimumWidth: units.gu(78)
169-
170- ColumnLayout {
171- Layout.fillWidth: true
172- Label {
173- text: "Platform development"
174- fontSize: "large"
175- anchors.left: parent.left
176- Layout.fillWidth: true
177- }
178- Label {
179- text: "The connected device can be turned to be a native development environment.\n Use this feature with care and only if you know what are you doing."
180- }
181- FeatureStateItem {
182- text: "Has writeable image"
183- input: hasWriteableImage
184- inputRole: "hasWriteableImage"
185- height: 24
186- width: 300
187- checkable: !deviceItemView.deviceBusy
188- }
189- FeatureStateItem {
190- text: "Has device developer tools"
191- input: hasDeveloperTools
192- inputRole: "hasDeveloperTools"
193- height: 24
194- width: 300
195- checkable: !deviceItemView.deviceBusy
196- }
197- }
198- }
199-}
200
201=== removed file 'share/qtcreator/ubuntu/devicespage/DeviceEmulatorTab.qml'
202--- share/qtcreator/ubuntu/devicespage/DeviceEmulatorTab.qml 2014-08-11 10:46:51 +0000
203+++ share/qtcreator/ubuntu/devicespage/DeviceEmulatorTab.qml 1970-01-01 00:00:00 +0000
204@@ -1,71 +0,0 @@
205-import QtQuick 2.0
206-import QtQuick.Layouts 1.0
207-import QtQuick.Controls 1.0 as Controls
208-
209-import Ubuntu.Components 0.1
210-import Ubuntu.Components.ListItems 0.1 as ListItem
211-import Ubuntu.Components.Popups 0.1
212-
213-import Ubuntu.DevicesModel 0.1
214-
215-ColumnLayout {
216- UbuntuListView {
217- Layout.alignment: Qt.AlignLeft | Qt.AlignTop
218- width: units.gu(50)
219- height: childrenRect.height
220- model: VisualItemModel {
221- ListItem.SingleValue {
222- text: i18n.tr("Ubuntu version")
223- value: emuUbuntuVersion
224- }
225- ListItem.SingleValue {
226- text: i18n.tr("Device version")
227- value: emuDeviceVersion
228- }
229- ListItem.SingleValue {
230- text: i18n.tr("Image version")
231- value: emuImageVersion
232- }
233- ListItem.Standard {
234- //show this listitem only when device is not connected
235- visible: connectionState !== DeviceConnectionState.ReadyToUse && connectionState !== DeviceConnectionState.Connected
236- text: "Scale"
237- control: Controls.ComboBox {
238- id: emulatorScaleComboBox
239- model: ["1.0", "0.9", "0.8", "0.7", "0.6","0.5", "0.4", "0.3", "0.2","0.1"]
240- currentIndex: {
241- var idx = find(emulatorScaleFactor);
242- return idx >= 0 ? idx : 0;
243- }
244- onActivated: {
245- emulatorScaleFactor = textAt(index);
246- }
247- }
248- }
249-
250- ListItem.Standard {
251- //show this listitem only when device is not connected
252- visible: connectionState !== DeviceConnectionState.ReadyToUse && connectionState !== DeviceConnectionState.Connected
253- text: "Memory"
254- control: Controls.ComboBox {
255- id: emulatorMemoryComboBox
256- model: ["512", "768", "1024"]
257-
258- currentIndex: {
259- var idx = find(emulatorMemorySetting);
260- return idx >= 0 ? idx : 0;
261- }
262- onActivated: {
263- emulatorMemorySetting = textAt(index);
264- }
265- }
266- }
267- }
268- }
269- ListItem.Divider{}
270- DeviceKitManager{
271- Layout.alignment: Qt.AlignLeft | Qt.AlignTop
272- Layout.fillHeight: true
273- width: units.gu(50)
274- }
275-}
276
277=== removed file 'share/qtcreator/ubuntu/devicespage/DeviceKitManager.qml'
278--- share/qtcreator/ubuntu/devicespage/DeviceKitManager.qml 2014-08-11 10:46:51 +0000
279+++ share/qtcreator/ubuntu/devicespage/DeviceKitManager.qml 1970-01-01 00:00:00 +0000
280@@ -1,62 +0,0 @@
281-import QtQuick 2.0
282-import QtQuick.Controls 1.0 as Controls
283-import QtQuick.Layouts 1.0
284-import Ubuntu.Components 0.1
285-import Ubuntu.Components.ListItems 0.1 as ListItem
286-import Ubuntu.DevicesModel 0.1
287-
288-Item {
289- ColumnLayout {
290- anchors.fill: parent
291- Label {
292- text: "Device Kits"
293- fontSize: "large"
294- }
295-
296- Column {
297- Layout.fillWidth: true
298- Repeater {
299- model: kits
300- delegate: ListItem.Standard {
301- text: modelData.displayName
302- Layout.fillWidth: true
303- control: Button{
304- text: "Remove"
305- enabled: !deviceItemView.deviceBusy
306- onClicked: devicesModel.triggerKitRemove(deviceId,modelData.id)
307- }
308- }
309- }
310- }
311-
312- Item {
313- clip: true
314- visible: kits.length === 0
315- Layout.minimumHeight: units.gu(25)
316- Layout.fillWidth: true
317- Label {
318- id:label
319- anchors.centerIn: parent
320- anchors.bottom: button.top
321- fontSize: "large"
322- text: "There is currently no Kit defined for your device.\n In order to use the device in your Projects,\n you can either add a existing Kit "
323- +"\nor let Qt Creator autocreate one for you."
324- }
325- Button {
326- id: button
327- anchors.left: label.left
328- anchors.right: label.right
329- anchors.top: label.bottom
330- anchors.topMargin: units.gu(2)
331- text: "Autocreate"
332- enabled: !deviceItemView.deviceBusy
333- onClicked: devicesModel.triggerKitAutocreate(deviceId)
334- }
335- }
336-
337- //Spacer Item
338- Item {
339- Layout.fillHeight: true
340- }
341- }
342-}
343
344=== removed file 'share/qtcreator/ubuntu/devicespage/DeviceLogTab.qml'
345--- share/qtcreator/ubuntu/devicespage/DeviceLogTab.qml 2014-04-22 14:10:22 +0000
346+++ share/qtcreator/ubuntu/devicespage/DeviceLogTab.qml 1970-01-01 00:00:00 +0000
347@@ -1,12 +0,0 @@
348-import QtQuick 2.0
349-import QtQuick.Controls 1.0 as Controls
350-import QtQuick.Layouts 1.0
351-import Ubuntu.Components 0.1
352-import Ubuntu.Components.ListItems 0.1 as ListItem
353-
354-
355-Controls.TextArea {
356- readOnly: true
357- text: deviceLog
358- textFormat: TextEdit.AutoText
359-}
360
361=== modified file 'share/qtcreator/ubuntu/devicespage/DevicePage.qml'
362--- share/qtcreator/ubuntu/devicespage/DevicePage.qml 2014-08-11 11:58:08 +0000
363+++ share/qtcreator/ubuntu/devicespage/DevicePage.qml 2014-10-09 08:07:05 +0000
364@@ -153,15 +153,17 @@
365 }
366 }
367 }
368+
369 Item {
370 id: centerItem
371 Layout.minimumWidth: 400
372 Layout.fillWidth: true
373- property int currentIndex: devicesList.currentIndex
374+
375 Repeater {
376+ property int currentIndex: devicesList.currentIndex
377 model: devicesModel
378- anchors.fill: parent
379- Rectangle{
380+
381+ Rectangle {
382 id: deviceItemView
383 property bool deviceConnected: connectionState === DeviceConnectionState.ReadyToUse || connectionState === DeviceConnectionState.Connected
384 property bool deviceBusy: (detectionState != DeviceDetectionState.Done && detectionState != DeviceDetectionState.NotStarted)
385@@ -172,6 +174,7 @@
386 color: Qt.rgba(0.0, 0.0, 0.0, 0.01)
387 visible: index == devicesList.currentIndex
388
389+
390 Controls.ToolBar {
391 id: emulatorToolBar
392 height: visible ? units.gu(5) : 0
393@@ -205,95 +208,314 @@
394 }
395 }
396
397- Controls.TabView {
398- id: pagesTabView
399- anchors.left: parent.left
400- anchors.right: parent.right
401- anchors.top: emulatorToolBar.bottom
402- anchors.bottom: parent.bottom
403- anchors.margins: 12
404- visible: deviceConnected && !deviceBooting && !detectionError
405-
406- Component.onCompleted: {
407- addTab("Device", Qt.createComponent("DeviceStatusTab.qml"))
408- if(machineType === DeviceMachineType.Emulator)
409- addTab("Emulator", Qt.createComponent("DeviceEmulatorTab.qml"))
410- addTab("Advanced", Qt.createComponent("DeviceAdvancedTab.qml"))
411- addTab("Builder", Qt.createComponent("DeviceBuilderTab.qml"))
412- addTab("Log", Qt.createComponent("DeviceLogTab.qml"))
413- }
414- }
415-
416- ColumnLayout {
417- visible: !deviceConnected && !deviceBooting && !detectionError && (machineType !== DeviceMachineType.Emulator)
418- anchors.left: parent.left
419- anchors.top: emulatorToolBar.bottom
420- anchors.bottom: parent.bottom
421- anchors.margins: 10
422- width: units.gu(75)
423- spacing: units.gu(1)
424-
425- Label {
426- text:"Device Status: Disconnected"
427- fontSize: "large"
428- Layout.alignment: Qt.AlignLeft | Qt.AlignTop
429- Layout.fillWidth: true
430- }
431- ListItem.SingleValue {
432- Layout.alignment: Qt.AlignLeft | Qt.AlignTop
433- text:i18n.tr("Serial ID")
434- Layout.fillWidth: true
435- value: serial
436- }
437- ListItem.Divider{}
438- DeviceKitManager {
439- Layout.alignment: Qt.AlignLeft | Qt.AlignTop
440- Layout.fillHeight: true
441- Layout.fillWidth: true
442- }
443- }
444-
445- DeviceEmulatorTab {
446- id: emuSettings
447- visible: !deviceConnected && !deviceBooting && !detectionError && (machineType === DeviceMachineType.Emulator)
448- anchors.left: parent.left
449- anchors.right: parent.right
450- anchors.top: emulatorToolBar.bottom
451- anchors.bottom: parent.bottom
452- anchors.margins: 10
453- }
454-
455- Column {
456- visible: deviceBooting && !detectionError
457- anchors.centerIn: parent
458- spacing: units.gu(1)
459- Label {
460- text: i18n.tr("The device is currently booting.")
461- fontSize: "large"
462- anchors.horizontalCenter: parent.horizontalCenter
463- }
464- Label {
465- text: i18n.tr("If this text is still shown after the device has booted, press the refresh button.")
466- anchors.horizontalCenter: parent.horizontalCenter
467- }
468- ActivityIndicator {
469- running: deviceBooting
470- anchors.horizontalCenter: parent.horizontalCenter
471- }
472- }
473- Column {
474- visible: detectionError
475- anchors.centerIn: parent
476- spacing: units.gu(1)
477- Label {
478- text: i18n.tr("There was a error in the device detection, please press the redetect button to try again.")
479- fontSize: "large"
480- anchors.horizontalCenter: parent.horizontalCenter
481- }
482- Button {
483- text: "Redetect"
484- onClicked: devicesModel.triggerRedetect(deviceId)
485- anchors.horizontalCenter: parent.horizontalCenter
486+ ScrollableView {
487+ id: deviceView
488+ anchors.left: parent.left
489+ anchors.right: parent.right
490+ anchors.top: emulatorToolBar.bottom
491+ anchors.bottom: parent.bottom
492+ clip: true
493+
494+ ListItem.Empty {
495+ divider.visible: false
496+ visible: detectionError
497+ RowLayout {
498+ anchors.fill: parent
499+ anchors.leftMargin: units.gu(2)
500+ anchors.rightMargin: units.gu(4)
501+ Icon {
502+ id: errorIcon
503+ anchors.left: parent.left
504+ name: "security-alert"
505+ height:parent.height - units.gu(2)
506+ width: height
507+ }
508+ Label {
509+ id: errorText
510+ text: i18n.tr("There was a error in the device detection, check the log for details.")
511+ fontSize: "large"
512+ wrapMode: Text.Wrap
513+ Layout.fillWidth: true
514+ }
515+ Button {
516+ id: deviceRedetectButton
517+ text: "Redetect"
518+ onClicked: devicesModel.triggerRedetect(deviceId)
519+ }
520+ }
521+ }
522+
523+ ListItem.Empty {
524+ divider.visible: false
525+ visible: deviceItemView.deviceBooting
526+ RowLayout {
527+ anchors.fill: parent
528+ anchors.leftMargin: units.gu(2)
529+ anchors.rightMargin: units.gu(4)
530+ ActivityIndicator {
531+ running: deviceItemView.deviceBooting
532+ height:parent.height - units.gu(2)
533+ width: height
534+ }
535+ Label {
536+ text: i18n.tr("The device is currently booting, if this text is still shown after the device has booted, press the refresh button.")
537+ fontSize: "large"
538+ wrapMode: Text.Wrap
539+ Layout.fillWidth: true
540+ }
541+ Button {
542+ text: "Redetect"
543+ onClicked: devicesModel.triggerRedetect(deviceId)
544+ }
545+ }
546+ }
547+
548+ SectionItem {
549+ title: deviceItemView.deviceConnected ? "Device Status: "+detectionStateString : "Device Status: Disconnected"
550+ expanded: true
551+
552+ Column {
553+ anchors.left: parent.left
554+ anchors.right: parent.right
555+
556+ ListItem.SingleValue {
557+ visible: deviceItemView.deviceConnected || machineType !== DeviceMachineType.Emulator
558+ text:i18n.tr("Serial ID")
559+ value: serial
560+ }
561+ ListItem.SingleValue {
562+ text: i18n.tr("Ubuntu version")
563+ value: emuUbuntuVersion
564+ visible: machineType === DeviceMachineType.Emulator
565+ }
566+ ListItem.SingleValue {
567+ text: i18n.tr("Device version")
568+ value: emuDeviceVersion
569+ visible: machineType === DeviceMachineType.Emulator
570+ }
571+ ListItem.SingleValue {
572+ text: i18n.tr("Image version")
573+ value: emuImageVersion
574+ visible: machineType === DeviceMachineType.Emulator
575+ }
576+ ListItem.Standard {
577+ //show this listitem only when device is not connected
578+ visible: machineType === DeviceMachineType.Emulator && !deviceItemView.deviceConnected
579+ text: "Scale"
580+ control: Controls.ComboBox {
581+ id: emulatorScaleComboBox
582+ model: ["1.0", "0.9", "0.8", "0.7", "0.6","0.5", "0.4", "0.3", "0.2","0.1"]
583+ currentIndex: {
584+ var idx = find(emulatorScaleFactor);
585+ return idx >= 0 ? idx : 0;
586+ }
587+ onActivated: {
588+ emulatorScaleFactor = textAt(index);
589+ }
590+ }
591+ }
592+
593+ ListItem.Standard {
594+ //show this listitem only when device is not connected
595+ visible: machineType === DeviceMachineType.Emulator && !deviceItemView.deviceConnected
596+ text: "Memory"
597+ control: Controls.ComboBox {
598+ id: emulatorMemoryComboBox
599+ model: ["512", "768", "1024"]
600+
601+ currentIndex: {
602+ var idx = find(emulatorMemorySetting);
603+ return idx >= 0 ? idx : 0;
604+ }
605+ onActivated: {
606+ emulatorMemorySetting = textAt(index);
607+ }
608+ }
609+ }
610+ ListItem.SingleValue {
611+ text:i18n.tr("Device")
612+ value: deviceInfo
613+ visible: deviceItemView.deviceConnected
614+ }
615+ ListItem.SingleValue {
616+ text:i18n.tr("Model")
617+ value: modelInfo
618+ visible: deviceItemView.deviceConnected
619+ }
620+ ListItem.SingleValue {
621+ text:i18n.tr("Product")
622+ value: productInfo
623+ visible: deviceItemView.deviceConnected
624+ }
625+
626+ FeatureStateItem {
627+ text: "Has network connection"
628+ input: hasNetworkConnection
629+ inputRole: "hasNetworkConnection"
630+ checkable: hasNetworkConnection == FeatureState.NotAvailable && !deviceItemView.deviceBusy && !deviceItemView.detectionError
631+ visible: deviceItemView.deviceConnected
632+ }
633+ FeatureStateItem {
634+ text: "Has devloper mode enabled"
635+ input: developerModeEnabled
636+ inputRole: "developerModeEnabled"
637+ checkable: !deviceItemView.deviceBusy && !deviceItemView.detectionError
638+ visible: deviceItemView.deviceConnected
639+ }
640+ /*
641+ FeatureStateItem {
642+ text: "Has writeable image"
643+ input: hasWriteableImage
644+ inputRole: "hasWriteableImage"
645+ checkable: false
646+ visible: deviceItemView.deviceConnected
647+ }
648+ */
649+ }
650+ }
651+
652+ SectionItem {
653+ title: "Kits"
654+ expanded: true
655+
656+ Column {
657+ anchors.left: parent.left
658+ anchors.right: parent.right
659+
660+ Repeater {
661+ model: kits
662+ delegate: ListItem.Standard {
663+ text: modelData.displayName
664+ Layout.fillWidth: true
665+ control: Button{
666+ text: "Remove"
667+ enabled: !deviceItemView.deviceBusy
668+ onClicked: devicesModel.triggerKitRemove(deviceId,modelData.id)
669+ }
670+ }
671+ }
672+
673+ Item {
674+ clip: true
675+ visible: kits.length === 0
676+ height: label.contentHeight + units.gu(15)
677+ width: parent.width
678+ Label {
679+ id:label
680+ anchors.centerIn: parent
681+ anchors.bottom: button.top
682+ fontSize: "large"
683+ text: "There is currently no Kit defined for your device.\n In order to use the device in your Projects,\n you can either add a existing Kit "
684+ +"\nor let Qt Creator autocreate one for you."
685+ }
686+ Button {
687+ id: button
688+ anchors.left: label.left
689+ anchors.right: label.right
690+ anchors.top: label.bottom
691+ anchors.bottom: parent.bottom
692+ anchors.topMargin: units.gu(2)
693+ text: "Autocreate"
694+ enabled: !deviceItemView.deviceBusy
695+ onClicked: devicesModel.triggerKitAutocreate(deviceId)
696+ }
697+ }
698+
699+
700+ }
701+ }
702+
703+ SectionItem {
704+ title: "Control"
705+ visible: deviceItemView.deviceConnected
706+
707+ Column {
708+ anchors.left: parent.left
709+ anchors.right: parent.right
710+
711+ ListItem.Standard {
712+ text:"Clone time config from Host to Device"
713+ control: Button{
714+ text: "Execute"
715+ enabled: !deviceItemView.deviceBusy && !deviceItemView.detectionError
716+ onClicked: devicesModel.triggerCloneTimeConfig(deviceId)
717+ }
718+ }
719+ ListItem.Standard {
720+ text:"Enable port forwarding"
721+ control: Button{
722+ text: "Execute"
723+ enabled: !deviceItemView.deviceBusy && !deviceItemView.detectionError
724+ onClicked: devicesModel.triggerPortForwarding(deviceId)
725+ }
726+ }
727+ ListItem.Standard {
728+ text:"Setup public key authentication"
729+ control: Button{
730+ text: "Execute"
731+ enabled: !deviceItemView.deviceBusy && !deviceItemView.detectionError
732+ onClicked: devicesModel.triggerSSHSetup(deviceId)
733+ }
734+ }
735+ ListItem.Standard {
736+ text:"Open SSH connection to the device"
737+ control: Button{
738+ text: "Execute"
739+ enabled: !deviceItemView.deviceBusy && !deviceItemView.detectionError
740+ onClicked: devicesModel.triggerSSHConnection(deviceId)
741+ }
742+ }
743+ ListItem.Standard {
744+ text:"Reboot"
745+ control: Button{
746+ text: "Execute"
747+ enabled: !deviceItemView.deviceBusy && !deviceItemView.detectionError
748+ onClicked: devicesModel.triggerReboot(deviceId)
749+ }
750+ }
751+ ListItem.Standard {
752+ text:"Reboot to bootloader"
753+ control: Button{
754+ text: "Execute"
755+ enabled: !deviceItemView.deviceBusy && !deviceItemView.detectionError
756+ onClicked: devicesModel.triggerRebootBootloader(deviceId)
757+ }
758+ }
759+ ListItem.Standard {
760+ text:"Reboot to recovery"
761+ control: Button{
762+ text: "Execute"
763+ enabled: !deviceItemView.deviceBusy && !deviceItemView.detectionError
764+ onClicked: devicesModel.triggerRebootRecovery(deviceId)
765+ }
766+ }
767+ ListItem.Standard {
768+ text:"Shutdown"
769+ control: Button{
770+ text: "Execute"
771+ enabled: !deviceItemView.deviceBusy && !deviceItemView.detectionError
772+ onClicked: devicesModel.triggerShutdown(deviceId)
773+ }
774+ }
775+ }
776+ }
777+
778+ SectionItem {
779+ title: "Log"
780+ Column {
781+ anchors.left: parent.left
782+ anchors.right: parent.right
783+ TextArea {
784+ anchors.left: parent.left
785+ anchors.right: parent.right
786+ height: units.gu(60)
787+ highlighted: true
788+
789+ readOnly: true
790+ text: deviceLog
791+ textFormat: TextEdit.AutoText
792+ }
793+ }
794 }
795 }
796 }
797
798=== added file 'share/qtcreator/ubuntu/devicespage/ScrollableView.qml'
799--- share/qtcreator/ubuntu/devicespage/ScrollableView.qml 1970-01-01 00:00:00 +0000
800+++ share/qtcreator/ubuntu/devicespage/ScrollableView.qml 2014-10-09 08:07:05 +0000
801@@ -0,0 +1,55 @@
802+/*
803+ * Copyright 2013 Canonical Ltd.
804+ *
805+ * This program is free software; you can redistribute it and/or modify
806+ * it under the terms of the GNU Lesser General Public License as published by
807+ * the Free Software Foundation; version 3.
808+ *
809+ * This program is distributed in the hope that it will be useful,
810+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
811+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
812+ * GNU Lesser General Public License for more details.
813+ *
814+ * You should have received a copy of the GNU Lesser General Public License
815+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
816+ */
817+
818+import QtQuick 2.0
819+import Ubuntu.Components 0.1
820+
821+Item {
822+ id: template
823+
824+ width: units.gu(40)
825+ height: units.gu(75)
826+
827+ default property alias content: layout.children
828+ property alias spacing: layout.spacing
829+ property Item tools: null
830+ property Flickable flickable: flickable
831+
832+ Flickable {
833+ id: flickable
834+ objectName: "TemplateFlickable"
835+ anchors.fill: parent
836+ anchors.topMargin: units.gu(2)
837+ anchors.bottomMargin: units.gu(2)
838+ contentHeight: layout.height
839+ interactive: contentHeight > height
840+
841+ Column {
842+ id: layout
843+ spacing: units.gu(6)
844+ anchors.left: parent.left
845+ anchors.right: parent.right
846+ anchors.margins: units.gu(2)
847+ }
848+ }
849+
850+ Scrollbar {
851+ id: sb
852+ objectName: "TemplateScrollbar"
853+ flickableItem: flickable
854+ property alias interactive: sb.__interactive
855+ }
856+}
857
858=== added file 'share/qtcreator/ubuntu/devicespage/SectionItem.qml'
859--- share/qtcreator/ubuntu/devicespage/SectionItem.qml 1970-01-01 00:00:00 +0000
860+++ share/qtcreator/ubuntu/devicespage/SectionItem.qml 2014-10-09 08:07:05 +0000
861@@ -0,0 +1,58 @@
862+/*
863+ * Copyright 2013 Canonical Ltd.
864+ *
865+ * This program is free software; you can redistribute it and/or modify
866+ * it under the terms of the GNU Lesser General Public License as published by
867+ * the Free Software Foundation; version 3.
868+ *
869+ * This program is distributed in the hope that it will be useful,
870+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
871+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
872+ * GNU Lesser General Public License for more details.
873+ *
874+ * You should have received a copy of the GNU Lesser General Public License
875+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
876+ */
877+
878+import QtQuick 2.0
879+import Ubuntu.Components 0.1
880+import Ubuntu.Components.ListItems 0.1 as ListItem
881+
882+ListItem.Expandable {
883+ id: expandingColumnItem
884+ expandedHeight: contentColumn.height + units.gu(1)
885+ collapsedHeight: headerRow.childrenRect.height
886+ divider.visible: false
887+
888+ property string title
889+ default property alias data: contentColumn.data
890+
891+ onClicked: {
892+ expanded = !expanded;
893+ }
894+
895+ Column {
896+ id: contentColumn
897+ anchors { left: parent.left; right: parent.right }
898+ Row{
899+ id: headerRow
900+ anchors { left: parent.left; right: parent.right}
901+ height: childrenRect.height
902+ Icon {
903+ name: expandingColumnItem.expanded ? "view-collapse" : "view-expand"
904+ color: UbuntuColors.orange
905+ width: 24
906+ height: 24
907+ }
908+ Item{
909+ width: units.gu(1)
910+ height: parent.height
911+ }
912+ Label {
913+ id: label
914+ text: expandingColumnItem.title
915+ fontSize: "large"
916+ }
917+ }
918+ }
919+}
920
921=== modified file 'share/qtcreator/ubuntu/scripts/qtc_device_applaunch.py'
922--- share/qtcreator/ubuntu/scripts/qtc_device_applaunch.py 2014-10-02 08:11:21 +0000
923+++ share/qtcreator/ubuntu/scripts/qtc_device_applaunch.py 2014-10-09 08:07:05 +0000
924@@ -344,7 +344,10 @@
925 success = subprocess.call(["pkcon","remove",package_name+";"+package_version+";"+package_arch+";local:click","-p"],stdout=subprocess.DEVNULL)
926 if success != 0:
927 print("Sdk-Launcher> Uninstalling the application failed",flush=True)
928- sys.exit(1)
929+ # Continue even though we could not uninstall the app, the user wanted to override it anyway
930+ # but for scopes we need to stop, because the scope may still be running and we need a clean state
931+ if "scope" in manifest['hooks'][hook_name]:
932+ sys.exit(1)
933
934 #build the appid
935 app_id = None
936
937=== modified file 'src/ubuntu/ubuntu.pro'
938--- src/ubuntu/ubuntu.pro 2014-09-30 15:44:15 +0000
939+++ src/ubuntu/ubuntu.pro 2014-10-09 08:07:05 +0000
940@@ -38,16 +38,13 @@
941 $$QML_ROOT/welcome/Link.qml \
942 $$QML_ROOT/welcome/NewsBox.qml\
943 $$QML_ROOT/devicespage/main.qml \
944- $$QML_ROOT/devicespage/DeviceAdvancedTab.qml \
945- $$QML_ROOT/devicespage/DeviceBuilderTab.qml \
946- $$QML_ROOT/devicespage/DeviceLogTab.qml \
947 $$QML_ROOT/devicespage/DevicePage.qml \
948 $$QML_ROOT/devicespage/DeviceStatusTab.qml \
949 $$QML_ROOT/devicespage/FeatureStateItem.qml \
950 $$QML_ROOT/devicespage/NewEmulatorDialog.qml \
951- $$QML_ROOT/devicespage/LogPage.qml \
952- $$QML_ROOT/devicespage/DeviceEmulatorTab.qml \
953- $$QML_ROOT/devicespage/DeleteEmulatorDialog.qml
954+ $$QML_ROOT/devicespage/DeleteEmulatorDialog.qml \
955+ $$QML_ROOT/devicespage/ScrollableView.qml \
956+ $$QML_ROOT/devicespage/SectionItem.qml
957
958 OTHER_FILES += \
959 UbuntuProject.mimetypes.xml \
960
961=== modified file 'src/ubuntu/ubuntupackageoutputparser.cpp'
962--- src/ubuntu/ubuntupackageoutputparser.cpp 2014-10-02 08:07:54 +0000
963+++ src/ubuntu/ubuntupackageoutputparser.cpp 2014-10-09 08:07:05 +0000
964@@ -9,6 +9,10 @@
965 namespace Internal {
966
967 const QRegularExpression DEBUG_POLICY_REGEX(QStringLiteral("security_policy_groups_safe_\\S+\\s+\\((\\S+)\\)"));
968+const QRegularExpression DEBUG_SCOPE_POLICY_REGEX(QStringLiteral("security_policy_groups_scopes"));
969+const QRegularExpression DEBUG_SCOPE_TEXT_REGEX(QStringLiteral("found inappropriate policy groups:\\s+(.*)"));
970+const QRegularExpression ARCHITECTURE_ERROR_REGEX(QStringLiteral("lint_(control|manifest)_architecture_valid"));
971+const QString DEBUG_POLICY_NAME(QStringLiteral("debug"));
972
973 UbuntuPackageOutputParser::UbuntuPackageOutputParser() :
974 ProjectExplorer::IOutputParser(),
975@@ -33,7 +37,9 @@
976
977 bool UbuntuPackageOutputParser::hasFatalErrors() const
978 {
979- return IOutputParser::hasFatalErrors() || m_fatalError;
980+ //commented out due to bug lp:1377094 "Click review errors prevent applications from being deployed to the device"
981+ //return IOutputParser::hasFatalErrors() || m_fatalError;
982+ return IOutputParser::hasFatalErrors();
983 }
984
985 /*!
986@@ -89,7 +95,7 @@
987 desc.append(QStringLiteral("\n")).append(item->link.toString());
988
989 QRegularExpressionMatch match = DEBUG_POLICY_REGEX.match(item->type);
990- if(match.captured(1) == QStringLiteral("debug"))
991+ if(match.captured(1) == DEBUG_POLICY_NAME)
992 desc.append(QStringLiteral("\n")).append(tr("The debug policy group is automatically injected and should only be used for development.\nTo create a package for the store use the publish tab!"));
993
994 task.description = desc;
995@@ -103,7 +109,20 @@
996 //add other error item types here if we just want them treated as warnings
997 QRegularExpressionMatch match = DEBUG_POLICY_REGEX.match(item->type);
998 if(match.hasMatch()) {
999- if(match.captured(1) == QStringLiteral("debug"))
1000+ if(match.captured(1) == DEBUG_POLICY_NAME)
1001+ return false;
1002+ }
1003+ match = DEBUG_SCOPE_POLICY_REGEX.match(item->type);
1004+ if(match.hasMatch()) {
1005+ match = DEBUG_SCOPE_TEXT_REGEX.match(item->text);
1006+ if(match.hasMatch()) {
1007+ if(match.captured(1).contains(DEBUG_POLICY_NAME))
1008+ return false;
1009+ }
1010+ }
1011+ match = ARCHITECTURE_ERROR_REGEX.match(item->type);
1012+ if(match.hasMatch()) {
1013+ if(item->text.contains(QStringLiteral("i386")))
1014 return false;
1015 }
1016 }

Subscribers

People subscribed via source and target branches