Merge lp:~roman2861/xda-developers-app/xda-developers-app into lp:xda-developers-app

Proposed by Roman Zonov
Status: Merged
Approved by: Michael Hall
Approved revision: 10
Merged at revision: 9
Proposed branch: lp:~roman2861/xda-developers-app/xda-developers-app
Merge into: lp:xda-developers-app
Diff against target: 541 lines (+354/-92)
8 files modified
Tabs.qml (+95/-0)
manifest.json (+15/-0)
ui/ForumList.qml (+3/-0)
ui/ThreadList.qml (+3/-0)
ui/TopicList.qml (+3/-0)
xda-developers.json (+6/-0)
xda-developers.qml (+93/-92)
xda-developers.qmlproject.user (+136/-0)
To merge this branch: bzr merge lp:~roman2861/xda-developers-app/xda-developers-app
Reviewer Review Type Date Requested Status
Michael Hall Approve
Review via email: mp+197288@code.launchpad.net

Description of the change

Updated UI. Mostly for more usability.

To post a comment you must log in.
10. By Roman Zonov

No Tabs.

Revision history for this message
Michael Hall (mhall119) wrote :

Great improvements, thanks!

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== added file '.excludes'
2=== added file 'Tabs.qml'
3--- Tabs.qml 1970-01-01 00:00:00 +0000
4+++ Tabs.qml 2013-11-30 19:34:24 +0000
5@@ -0,0 +1,95 @@
6+import QtQuick 2.0
7+import Ubuntu.Components 0.1
8+import "ui"
9+
10+Tabs {
11+ id: tabs
12+
13+ Tab {
14+ title: i18n.tr("XDA Forums")
15+ Page {
16+ anchors.fill: parent
17+
18+ /*
19+ Stack for Category, Forum, Topic and Thread ListViews
20+ */
21+ PageStack {
22+ anchors.fill: parent
23+ id: navStack
24+
25+ // Start with the Category Page
26+ Component.onCompleted: {
27+ navStack.push(categoryPage)
28+ }
29+
30+ Page {
31+ id: categoryPage
32+
33+ ForumList {
34+ id: categoryList
35+ anchors.fill: parent
36+
37+ current_forum: 0
38+ onSelected_forumChanged: {
39+ if (selected_forum > 0) {
40+ forumsList.current_forum = selected_forum
41+ navStack.push(forumsPage)
42+ }
43+ }
44+ }
45+ Scrollbar {
46+ flickableItem: categoryList
47+ align: Qt.AlignTrailing
48+ }
49+ }
50+ Page {
51+ id: forumsPage
52+ ForumList {
53+ id: forumsList
54+ anchors.fill: parent
55+
56+ onSelected_forumChanged: {
57+ if (selected_forum > 0) {
58+ topicList.current_forum = selected_forum
59+ navStack.push(topicPage)
60+ }
61+ }
62+ }
63+ Scrollbar {
64+ flickableItem: forumsList
65+ align: Qt.AlignTrailing
66+ }
67+
68+ }
69+ Page {
70+ id: topicPage
71+ TopicList {
72+ id: topicList
73+ anchors.fill: parent
74+
75+ onCurrent_topicChanged: {
76+ if (current_topic > 0) {
77+ threadList.current_topic = current_topic
78+ navStack.push(threadPage)
79+ }
80+ }
81+ }
82+ Scrollbar {
83+ flickableItem: topicList
84+ align: Qt.AlignTrailing
85+ }
86+ }
87+ Page {
88+ id: threadPage
89+
90+ ThreadList {
91+ id: threadList
92+ anchors.fill: parent
93+ }
94+ }
95+ }
96+
97+ }
98+
99+ }
100+}
101
102=== added file 'graphics/xdaLogo.png'
103Binary files graphics/xdaLogo.png 1970-01-01 00:00:00 +0000 and graphics/xdaLogo.png 2013-11-30 19:34:24 +0000 differ
104=== added file 'manifest.json'
105--- manifest.json 1970-01-01 00:00:00 +0000
106+++ manifest.json 2013-11-30 19:34:24 +0000
107@@ -0,0 +1,15 @@
108+{
109+ "architecture": "all",
110+ "description": "description of xda-developers",
111+ "framework": "ubuntu-sdk-13.10",
112+ "hooks": {
113+ "xda-developers": {
114+ "apparmor": "xda-developers.json",
115+ "desktop": "xda-developers.desktop"
116+ }
117+ },
118+ "maintainer": "",
119+ "name": "com.ubuntu.developer.username.xda-developers",
120+ "title": "xda-developers",
121+ "version": "0.1"
122+}
123
124=== modified file 'ui/ForumList.qml'
125--- ui/ForumList.qml 2013-08-09 18:30:01 +0000
126+++ ui/ForumList.qml 2013-11-30 19:34:24 +0000
127@@ -18,6 +18,7 @@
128 onTriggered: {
129 selected_forum = -1
130 selected_forum = model.id
131+ loading.running=true;
132 }
133 }
134
135@@ -39,9 +40,11 @@
136 //Component.onCompleted: __loadForums()
137 function __loadForums() {
138 var xhr = new XMLHttpRequest;
139+ categoryModel.xml="";
140 xhr.open("POST", xda_api_source);
141 xhr.onreadystatechange = function() {
142 if (xhr.readyState == XMLHttpRequest.DONE) {
143+ logo.visible=false; loadingapp.visible=false; loading.running=false; categoryPage.title="Forums"
144 categoryModel.xml = xhr.responseText;
145 //console.log('Data: '+ categoryModel.xml)
146 }
147
148=== modified file 'ui/ThreadList.qml'
149--- ui/ThreadList.qml 2013-08-10 04:43:36 +0000
150+++ ui/ThreadList.qml 2013-11-30 19:34:24 +0000
151@@ -36,9 +36,12 @@
152 //Component.onCompleted: __loadForums()
153 function __loadForums() {
154 var xhr = new XMLHttpRequest;
155+ threadModel.xml="";
156 xhr.open("POST", xda_api_source);
157 xhr.onreadystatechange = function() {
158 if (xhr.readyState == XMLHttpRequest.DONE) {
159+ loading.running=false;
160+ console.log();
161 threadModel.xml = xhr.responseText;
162 //console.log('Data: '+ threadModel.xml)
163 }
164
165=== modified file 'ui/TopicList.qml'
166--- ui/TopicList.qml 2013-08-10 04:42:43 +0000
167+++ ui/TopicList.qml 2013-11-30 19:34:24 +0000
168@@ -19,6 +19,7 @@
169 onTriggered: {
170 current_topic = -1
171 current_topic = model.id
172+ loading.running=true;
173 }
174 }
175
176@@ -45,9 +46,11 @@
177 }
178
179 var xhr = new XMLHttpRequest;
180+ topicModel.xml="";
181 xhr.open("POST", xda_api_source);
182 xhr.onreadystatechange = function() {
183 if (xhr.readyState == XMLHttpRequest.DONE) {
184+ loading.running=false;
185 topicModel.xml = xhr.responseText;
186 //console.log('Data: '+ topicModel.xml)
187 }
188
189=== added file 'xda-developers.json'
190--- xda-developers.json 1970-01-01 00:00:00 +0000
191+++ xda-developers.json 2013-11-30 19:34:24 +0000
192@@ -0,0 +1,6 @@
193+{
194+ "policy_groups": [
195+ "networking"
196+ ],
197+ "policy_version": 1
198+}
199
200=== modified file 'xda-developers.qml'
201--- xda-developers.qml 2013-08-10 04:44:01 +0000
202+++ xda-developers.qml 2013-11-30 19:34:24 +0000
203@@ -9,6 +9,7 @@
204 */
205
206 MainView {
207+ id: mainview
208 // objectName for functional testing purposes (autopilot-qt5)
209 objectName: "mainView"
210
211@@ -28,97 +29,97 @@
212 backgroundColor: "#9a4c02"
213 footerColor: "#d76c02"
214
215- Tabs {
216- id: tabs
217-
218- Tab {
219- title: i18n.tr("XDA Forums")
220-
221- Page {
222- anchors.fill: parent
223-
224- /*
225- Stack for Category, Forum, Topic and Thread ListViews
226- */
227- PageStack {
228- anchors.fill: parent
229- id: navStack
230-
231- // Start with the Category Page
232- Component.onCompleted: {
233- navStack.push(categoryPage)
234- }
235-
236- Page {
237- id: categoryPage
238-
239- ForumList {
240- id: categoryList
241- anchors.fill: parent
242-
243- current_forum: 0
244- onSelected_forumChanged: {
245- if (selected_forum > 0) {
246- forumsList.current_forum = selected_forum
247- navStack.push(forumsPage)
248- }
249- }
250- }
251- Scrollbar {
252- flickableItem: categoryList
253- align: Qt.AlignTrailing
254- }
255- }
256- Page {
257- id: forumsPage
258- ForumList {
259- id: forumsList
260- anchors.fill: parent
261-
262- onSelected_forumChanged: {
263- if (selected_forum > 0) {
264- topicList.current_forum = selected_forum
265- navStack.push(topicPage)
266- }
267- }
268- }
269- Scrollbar {
270- flickableItem: forumsList
271- align: Qt.AlignTrailing
272- }
273-
274- }
275- Page {
276- id: topicPage
277- TopicList {
278- id: topicList
279- anchors.fill: parent
280-
281- onCurrent_topicChanged: {
282- if (current_topic > 0) {
283- threadList.current_topic = current_topic
284- navStack.push(threadPage)
285- }
286- }
287- }
288- Scrollbar {
289- flickableItem: topicList
290- align: Qt.AlignTrailing
291- }
292- }
293- Page {
294- id: threadPage
295-
296- ThreadList {
297- id: threadList
298- anchors.fill: parent
299- }
300- }
301- }
302-
303- }
304-
305- }
306-
307+ Image {
308+ id: logo
309+ source: "graphics/xdaLogo.png"
310+ width: if(mainview.width*0.90<=315) { mainview.width*0.90 } else {315}
311+ anchors.centerIn: parent
312+ }
313+ ActivityIndicator {
314+ id: loadingapp
315+ anchors.horizontalCenter: parent.horizontalCenter
316+ anchors.bottom: parent.bottom
317+ anchors.bottomMargin: units.gu(10)
318+ running: true
319+ }
320+ ActivityIndicator {
321+ id: loading
322+ anchors.centerIn: parent
323+ }
324+ PageStack {
325+ anchors.fill: parent
326+ id: navStack
327+
328+ // Start with the Category Page
329+ Component.onCompleted: {
330+ navStack.push(categoryPage)
331+ }
332+
333+ Page {
334+ id: categoryPage
335+ ForumList {
336+ id: categoryList
337+ anchors.fill: parent
338+
339+ current_forum: 0
340+ onSelected_forumChanged: {
341+ if (selected_forum > 0) {
342+ forumsList.current_forum = selected_forum
343+ navStack.push(forumsPage)
344+ }
345+ }
346+ }
347+ Scrollbar {
348+ flickableItem: categoryList
349+ align: Qt.AlignTrailing
350+ }
351+ }
352+ Page {
353+ id: forumsPage
354+ title: "Forums"
355+ ForumList {
356+ id: forumsList
357+ anchors.fill: parent
358+
359+ onSelected_forumChanged: {
360+ if (selected_forum > 0) {
361+ topicList.current_forum = selected_forum
362+ navStack.push(topicPage)
363+ }
364+ }
365+ }
366+ Scrollbar {
367+ flickableItem: forumsList
368+ align: Qt.AlignTrailing
369+ }
370+
371+ }
372+ Page {
373+ id: topicPage
374+ title: "Topics"
375+ TopicList {
376+ id: topicList
377+ anchors.fill: parent
378+
379+ onCurrent_topicChanged: {
380+ if (current_topic > 0) {
381+ threadList.current_topic = current_topic
382+ navStack.push(threadPage)
383+ }
384+ }
385+ }
386+ Scrollbar {
387+ flickableItem: topicList
388+ align: Qt.AlignTrailing
389+ }
390+ }
391+ Page {
392+ id: threadPage
393+ title: "Thread"
394+ ThreadList {
395+ id: threadList
396+ anchors.fill: parent
397+ }
398+ }
399 }
400 }
401
402=== added file 'xda-developers.qmlproject.user'
403--- xda-developers.qmlproject.user 1970-01-01 00:00:00 +0000
404+++ xda-developers.qmlproject.user 2013-11-30 19:34:24 +0000
405@@ -0,0 +1,136 @@
406+<?xml version="1.0" encoding="UTF-8"?>
407+<!DOCTYPE QtCreatorProject>
408+<!-- Written by QtCreator 2.8.1, 2013-11-30T20:54:31. -->
409+<qtcreator>
410+ <data>
411+ <variable>ProjectExplorer.Project.ActiveTarget</variable>
412+ <value type="int">0</value>
413+ </data>
414+ <data>
415+ <variable>ProjectExplorer.Project.EditorSettings</variable>
416+ <valuemap type="QVariantMap">
417+ <value type="bool" key="EditorConfiguration.AutoIndent">true</value>
418+ <value type="bool" key="EditorConfiguration.AutoSpacesForTabs">false</value>
419+ <value type="bool" key="EditorConfiguration.CamelCaseNavigation">true</value>
420+ <valuemap type="QVariantMap" key="EditorConfiguration.CodeStyle.0">
421+ <value type="QString" key="language">Cpp</value>
422+ <valuemap type="QVariantMap" key="value">
423+ <value type="QString" key="CurrentPreferences">CppGlobal</value>
424+ </valuemap>
425+ </valuemap>
426+ <valuemap type="QVariantMap" key="EditorConfiguration.CodeStyle.1">
427+ <value type="QString" key="language">QmlJS</value>
428+ <valuemap type="QVariantMap" key="value">
429+ <value type="QString" key="CurrentPreferences">QmlJSGlobal</value>
430+ </valuemap>
431+ </valuemap>
432+ <value type="int" key="EditorConfiguration.CodeStyle.Count">2</value>
433+ <value type="QByteArray" key="EditorConfiguration.Codec">UTF-8</value>
434+ <value type="bool" key="EditorConfiguration.ConstrainTooltips">false</value>
435+ <value type="int" key="EditorConfiguration.IndentSize">4</value>
436+ <value type="bool" key="EditorConfiguration.KeyboardTooltips">false</value>
437+ <value type="bool" key="EditorConfiguration.MouseNavigation">true</value>
438+ <value type="int" key="EditorConfiguration.PaddingMode">1</value>
439+ <value type="bool" key="EditorConfiguration.ScrollWheelZooming">true</value>
440+ <value type="int" key="EditorConfiguration.SmartBackspaceBehavior">0</value>
441+ <value type="bool" key="EditorConfiguration.SpacesForTabs">true</value>
442+ <value type="int" key="EditorConfiguration.TabKeyBehavior">0</value>
443+ <value type="int" key="EditorConfiguration.TabSize">8</value>
444+ <value type="bool" key="EditorConfiguration.UseGlobal">true</value>
445+ <value type="int" key="EditorConfiguration.Utf8BomBehavior">1</value>
446+ <value type="bool" key="EditorConfiguration.addFinalNewLine">true</value>
447+ <value type="bool" key="EditorConfiguration.cleanIndentation">true</value>
448+ <value type="bool" key="EditorConfiguration.cleanWhitespace">true</value>
449+ <value type="bool" key="EditorConfiguration.inEntireDocument">false</value>
450+ </valuemap>
451+ </data>
452+ <data>
453+ <variable>ProjectExplorer.Project.PluginSettings</variable>
454+ <valuemap type="QVariantMap"/>
455+ </data>
456+ <data>
457+ <variable>ProjectExplorer.Project.Target.0</variable>
458+ <valuemap type="QVariantMap">
459+ <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Desktop</value>
460+ <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Desktop</value>
461+ <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">{4e54895a-368d-48e4-a4e0-70929598ba68}</value>
462+ <value type="int" key="ProjectExplorer.Target.ActiveBuildConfiguration">-1</value>
463+ <value type="int" key="ProjectExplorer.Target.ActiveDeployConfiguration">0</value>
464+ <value type="int" key="ProjectExplorer.Target.ActiveRunConfiguration">0</value>
465+ <value type="int" key="ProjectExplorer.Target.BuildConfigurationCount">0</value>
466+ <valuemap type="QVariantMap" key="ProjectExplorer.Target.DeployConfiguration.0">
467+ <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
468+ <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">0</value>
469+ <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Deploy</value>
470+ <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
471+ <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Deploy</value>
472+ </valuemap>
473+ <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">1</value>
474+ <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Deploy locally</value>
475+ <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
476+ <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.DefaultDeployConfiguration</value>
477+ </valuemap>
478+ <value type="int" key="ProjectExplorer.Target.DeployConfigurationCount">1</value>
479+ <valuemap type="QVariantMap" key="ProjectExplorer.Target.PluginSettings"/>
480+ <valuemap type="QVariantMap" key="ProjectExplorer.Target.RunConfiguration.0">
481+ <value type="bool" key="Analyzer.Project.UseGlobal">true</value>
482+ <valuelist type="QVariantList" key="Analyzer.Valgrind.AddedSuppressionFiles"/>
483+ <value type="bool" key="Analyzer.Valgrind.Callgrind.CollectBusEvents">false</value>
484+ <value type="bool" key="Analyzer.Valgrind.Callgrind.CollectSystime">false</value>
485+ <value type="bool" key="Analyzer.Valgrind.Callgrind.EnableBranchSim">false</value>
486+ <value type="bool" key="Analyzer.Valgrind.Callgrind.EnableCacheSim">false</value>
487+ <value type="bool" key="Analyzer.Valgrind.Callgrind.EnableEventToolTips">true</value>
488+ <value type="double" key="Analyzer.Valgrind.Callgrind.MinimumCostRatio">0.01</value>
489+ <value type="double" key="Analyzer.Valgrind.Callgrind.VisualisationMinimumCostRatio">10</value>
490+ <value type="bool" key="Analyzer.Valgrind.FilterExternalIssues">true</value>
491+ <value type="int" key="Analyzer.Valgrind.NumCallers">25</value>
492+ <valuelist type="QVariantList" key="Analyzer.Valgrind.RemovedSuppressionFiles"/>
493+ <value type="bool" key="Analyzer.Valgrind.TrackOrigins">true</value>
494+ <value type="QString" key="Analyzer.Valgrind.ValgrindExecutable">valgrind</value>
495+ <valuelist type="QVariantList" key="Analyzer.Valgrind.VisibleErrorKinds">
496+ <value type="int">0</value>
497+ <value type="int">1</value>
498+ <value type="int">2</value>
499+ <value type="int">3</value>
500+ <value type="int">4</value>
501+ <value type="int">5</value>
502+ <value type="int">6</value>
503+ <value type="int">7</value>
504+ <value type="int">8</value>
505+ <value type="int">9</value>
506+ <value type="int">10</value>
507+ <value type="int">11</value>
508+ <value type="int">12</value>
509+ <value type="int">13</value>
510+ <value type="int">14</value>
511+ </valuelist>
512+ <value type="int" key="PE.EnvironmentAspect.Base">0</value>
513+ <valuelist type="QVariantList" key="PE.EnvironmentAspect.Changes"/>
514+ <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName"></value>
515+ <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">QML Scene</value>
516+ <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QmlProjectManager.QmlRunConfiguration.QmlScene</value>
517+ <value type="QString" key="QmlProjectManager.QmlRunConfiguration.MainScript">CurrentFile</value>
518+ <value type="QString" key="QmlProjectManager.QmlRunConfiguration.QDeclarativeViewerArguments"></value>
519+ <value type="uint" key="RunConfiguration.QmlDebugServerPort">3768</value>
520+ <value type="bool" key="RunConfiguration.UseCppDebugger">false</value>
521+ <value type="bool" key="RunConfiguration.UseCppDebuggerAuto">true</value>
522+ <value type="bool" key="RunConfiguration.UseMultiProcess">false</value>
523+ <value type="bool" key="RunConfiguration.UseQmlDebugger">true</value>
524+ <value type="bool" key="RunConfiguration.UseQmlDebuggerAuto">false</value>
525+ </valuemap>
526+ <value type="int" key="ProjectExplorer.Target.RunConfigurationCount">1</value>
527+ </valuemap>
528+ </data>
529+ <data>
530+ <variable>ProjectExplorer.Project.TargetCount</variable>
531+ <value type="int">1</value>
532+ </data>
533+ <data>
534+ <variable>ProjectExplorer.Project.Updater.EnvironmentId</variable>
535+ <value type="QByteArray">{7f679a69-b53d-40b7-b80f-beaebabb3963}</value>
536+ </data>
537+ <data>
538+ <variable>ProjectExplorer.Project.Updater.FileVersion</variable>
539+ <value type="int">14</value>
540+ </data>
541+</qtcreator>

Subscribers

People subscribed via source and target branches