Merge lp:~nik90/cliffhanger/convergence-1 into lp:cliffhanger

Proposed by Nekhelesh Ramananthan
Status: Needs review
Proposed branch: lp:~nik90/cliffhanger/convergence-1
Merge into: lp:cliffhanger
Diff against target: 11825 lines (+11078/-0) (has conflicts)
116 files modified
.bzrignore (+1/-0)
Flashback.desktop (+10/-0)
Flashback.json (+6/-0)
Flashback.qml (+286/-0)
Flashback.qmlproject (+46/-0)
Makefile (+18/-0)
backend/backend.js (+204/-0)
backend/sha1.js (+202/-0)
components/BlurredBackground.qml (+50/-0)
components/Carousel.qml (+125/-0)
components/DesaturatedThumbnail.qml (+60/-0)
components/DetailCarousel.qml (+192/-0)
components/Development.qml (+25/-0)
components/Grid.qml (+278/-0)
components/ImageLabel.qml (+53/-0)
components/ListViewExpandable.qml (+80/-0)
components/LoadingIndicator.qml (+60/-0)
components/Notification.qml (+190/-0)
components/NowWatching.qml (+147/-0)
components/RatingChooser.qml (+106/-0)
components/Rotater.qml (+66/-0)
components/SearchBox.qml (+57/-0)
components/SearchPage.qml (+74/-0)
components/SidebarMenuItem.qml (+155/-0)
components/StatusIcons.qml (+68/-0)
components/TabletSidebar.qml (+58/-0)
components/Thumbnail.qml (+41/-0)
components/TraktAction.qml (+28/-0)
components/TraktPopup.qml (+123/-0)
components/TraktRating.qml (+56/-0)
debian/changelog (+27/-0)
debian/compat (+1/-0)
debian/control (+23/-0)
debian/copyright (+28/-0)
debian/install (+9/-0)
debian/rules (+7/-0)
debian/source/format (+1/-0)
graphics/find@32.svg (+140/-0)
graphics/play@32.svg (+98/-0)
graphics/search_icon@8.svg (+153/-0)
graphics/settings@32.svg (+138/-0)
graphics/share@32.svg (+96/-0)
manifest.json (+15/-0)
models/Activity.qml (+97/-0)
models/AiringShows.qml (+66/-0)
models/BaseModel.qml (+58/-0)
models/BasePostModel.qml (+64/-0)
models/Cast.qml (+38/-0)
models/Crew.qml (+37/-0)
models/Episode.qml (+55/-0)
models/Genres.qml (+35/-0)
models/Movie.qml (+57/-0)
models/Movies.qml (+37/-0)
models/People.qml (+36/-0)
models/Person.qml (+48/-0)
models/PersonCast.qml (+40/-0)
models/PersonCrew.qml (+40/-0)
models/SeasonEpisodes.qml (+38/-0)
models/Show.qml (+65/-0)
models/ShowSeasons.qml (+37/-0)
models/Shows.qml (+42/-0)
models/Trailer.qml (+37/-0)
models/TraktAccount.qml (+28/-0)
models/TraktCast.qml (+37/-0)
models/TraktCheckIn.qml (+39/-0)
models/TraktComments.qml (+39/-0)
models/TraktRatingModel.qml (+82/-0)
models/TraktRecommendedMovies.qml (+38/-0)
models/TraktSeen.qml (+39/-0)
models/TraktShowWatchlist.qml (+52/-0)
models/TraktUserComment.qml (+35/-0)
models/TraktUserRating.qml (+35/-0)
models/TraktUserWatchlist.qml (+48/-0)
models/TraktWatchlist.qml (+33/-0)
models/TrendingMovies.qml (+40/-0)
po/Cliffhanger.pot (+404/-0)
tests/TestModel.qml (+40/-0)
tests/autopilot/Cliffhanger/__init__.py (+131/-0)
tests/autopilot/Cliffhanger/main/__init__.py (+1/-0)
tests/autopilot/Cliffhanger/main/test_main.py (+23/-0)
tests/autopilot/run (+11/-0)
ui/About.qml (+79/-0)
ui/CastPage.qml (+48/-0)
ui/CommentsPage.qml (+316/-0)
ui/CrewPage.qml (+46/-0)
ui/EpisodePage.qml (+325/-0)
ui/HomeTab.qml (+351/-0)
ui/HomeTabTablet.qml (+134/-0)
ui/MovieByGenre.qml (+86/-0)
ui/MovieByRating.qml (+50/-0)
ui/MovieByRecommendation.qml (+52/-0)
ui/MoviePage.qml (+540/-0)
ui/MovieTab.qml (+169/-0)
ui/MovieTabTablet.qml (+160/-0)
ui/PersonPage.qml (+309/-0)
ui/PersonTab.qml (+71/-0)
ui/SearchAll.qml (+114/-0)
ui/SearchMovie.qml (+41/-0)
ui/SearchPerson.qml (+41/-0)
ui/SearchTv.qml (+41/-0)
ui/SeasonPage.qml (+299/-0)
ui/SettingPage.qml (+137/-0)
ui/Trakt.qml (+95/-0)
ui/TraktCheckIn.qml (+185/-0)
ui/TraktLogin.qml (+284/-0)
ui/TvPage.qml (+448/-0)
ui/TvSeasons.qml (+62/-0)
ui/TvTab.qml (+176/-0)
walkthrough/Slide1.qml (+76/-0)
walkthrough/Slide2.qml (+71/-0)
walkthrough/Slide3.qml (+66/-0)
walkthrough/Slide4.qml (+66/-0)
walkthrough/Slide5.qml (+65/-0)
walkthrough/Slide6.qml (+108/-0)
walkthrough/Slide7.qml (+97/-0)
walkthrough/Walkthrough.qml (+187/-0)
Conflict adding file Flashback.desktop.  Moved existing file to Flashback.desktop.moved.
Conflict adding file Flashback.json.  Moved existing file to Flashback.json.moved.
Conflict adding file Flashback.qml.  Moved existing file to Flashback.qml.moved.
Conflict adding file Flashback.qmlproject.  Moved existing file to Flashback.qmlproject.moved.
Conflict adding file Makefile.  Moved existing file to Makefile.moved.
Conflict adding file backend.  Moved existing file to backend.moved.
Conflict adding file components.  Moved existing file to components.moved.
Conflict adding file debian.  Moved existing file to debian.moved.
Conflict adding file design.jpg.  Moved existing file to design.jpg.moved.
Conflict adding file flashback.png.  Moved existing file to flashback.png.moved.
Conflict adding file graphics.  Moved existing file to graphics.moved.
Conflict adding file manifest.json.  Moved existing file to manifest.json.moved.
Conflict adding file models.  Moved existing file to models.moved.
Conflict adding file po.  Moved existing file to po.moved.
Conflict adding file tests.  Moved existing file to tests.moved.
Conflict adding file ui.  Moved existing file to ui.moved.
Conflict adding file walkthrough.  Moved existing file to walkthrough.moved.
To merge this branch: bzr merge lp:~nik90/cliffhanger/convergence-1
Reviewer Review Type Date Requested Status
Nekhelesh Ramananthan Pending
Review via email: mp+219568@code.launchpad.net

Description of the change

test code diff

To post a comment you must log in.

Unmerged revisions

67. By Nekhelesh Ramananthan

Added hometab convergence

66. By Nekhelesh Ramananthan

Miscellaneous fixes

65. By Nekhelesh Ramananthan

Tweaked grid behaviour

64. By Nekhelesh Ramananthan

Fixed the height of ImageLabel component

63. By Nekhelesh Ramananthan

Added workaround for Layout bug

62. By Nekhelesh Ramananthan

Added workaround for layouts bug

61. By Nekhelesh Ramananthan

Finalised movie tab tablet UI

60. By Nekhelesh Ramananthan

Moved sidebar to a new component

59. By Nekhelesh Ramananthan

Finalised sidebar menu item implementation

58. By Nekhelesh Ramananthan

MovieTab workaround for layouts visibility issue

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== added file '.bzrignore'
--- .bzrignore 1970-01-01 00:00:00 +0000
+++ .bzrignore 2014-05-14 17:33:57 +0000
@@ -0,0 +1,1 @@
1*.qmlproject.user
02
=== added file 'Flashback.desktop'
--- Flashback.desktop 1970-01-01 00:00:00 +0000
+++ Flashback.desktop 2014-05-14 17:33:57 +0000
@@ -0,0 +1,10 @@
1[Desktop Entry]
2Version=1.0
3Name=Flashback
4Comment=My project description
5Exec=qmlscene $@ /usr/share/flashback/Flashback.qml
6Icon=flashback.png
7Terminal=false
8Type=Application
9Keywords=Movie,Film,TV,Show,Entertainment;
10X-Ubuntu-Touch=true
011
=== renamed file 'Flashback.desktop' => 'Flashback.desktop.moved'
=== added file 'Flashback.json'
--- Flashback.json 1970-01-01 00:00:00 +0000
+++ Flashback.json 2014-05-14 17:33:57 +0000
@@ -0,0 +1,6 @@
1{
2 "policy_groups": [
3 "networking"
4 ],
5 "policy_version": 1.1
6}
0\ No newline at end of file7\ No newline at end of file
18
=== renamed file 'Flashback.json' => 'Flashback.json.moved'
=== added file 'Flashback.qml'
--- Flashback.qml 1970-01-01 00:00:00 +0000
+++ Flashback.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,286 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import U1db 1.0 as U1db
21import Ubuntu.Components 0.1
22import "backend/backend.js" as Backend
23import "models"
24import "ui"
25
26MainView {
27 id: mainView
28
29 // objectName for functional testing purposes (autopilot-qt5)
30 objectName: "mainView"
31
32 // Note! applicationName needs to match the "name" field of the click manifest
33 applicationName: "com.ubuntu.developer.nik90.flashback"
34
35 /*
36 This property enables the application to change orientation
37 when the device is rotated. The default is false.
38 */
39 automaticOrientation: true
40
41 /*
42 This property is to ensure that the input text fields are not hidden
43 by the on-screen keyboard
44 */
45 anchorToKeyboard: true
46
47 width: units.gu(50)
48 height: units.gu(100)
49
50 // TODO: This is a temporary app background. Final background color needs to be decided.
51 backgroundColor: UbuntuColors.coolGrey
52
53 // Property to determine if the tablet view should be shown
54 property bool tabletLandscapeForm: mainView.width >= units.gu(130)
55 property bool tabletPortraitForm: mainView.width >= units.gu(80) && mainView.width < units.gu(130)
56
57 actions: [
58 Action {
59 id: appSettingsAction
60 text: i18n.tr("Settings")
61 keywords: i18n.tr("Settings;Setting;Configuration;Account;Authenticate")
62 description: i18n.tr("Application Settings")
63 iconSource: Qt.resolvedUrl("graphics/settings.svg")
64 onTriggered: pagestack.push(Qt.resolvedUrl("ui/SettingPage.qml"))
65 },
66 Action {
67 id: returnHomeAction
68 text: i18n.tr("Home")
69 keywords: i18n.tr("Return;Navigate;Home;Page;Tab")
70 description: i18n.tr("Get back to the first page")
71 iconSource: Qt.resolvedUrl("graphics/home.png")
72 onTriggered: {
73 while(pagestack.depth !== 1)
74 pagestack.pop()
75 }
76 }
77 ]
78
79 // Database to store app data locally
80 U1db.Database {
81 id: db
82 path: "settings"
83 }
84
85 // Document to store the firstrun value of the app
86 U1db.Document {
87 id: firstRunDocument
88 database: db
89 docId: "firstRun"
90 create: true
91 defaults: { "firstrun": "true" }
92 }
93
94 // Document to store user's Trakt account credentials (password encrypted before storage)
95 U1db.Document {
96 id: traktLogin
97 database: db
98 docId: "traktLoginCredentials"
99 create: true
100 defaults: { "username": "johnDoe", "password": "password", "status": "disabled" }
101 Component.onCompleted: pagestack.account_status = contents.status
102 onContentsChanged: {
103 if(traktLogin.contents.status === "disabled")
104 userActivityLoader.sourceComponent = undefined;
105 else
106 userActivityLoader.sourceComponent = userActivity
107 }
108 }
109
110 // Document to store the user's movie activity on Trakt
111 U1db.Document {
112 id: movieActivityDocument
113 database: db
114 docId: "traktMovieActivity"
115 create: true
116 defaults: { "name": "default", "id": "default", "imdb": "default", "runtime": "default", "year": "default", "trailer": "default","poster": "default", "fanart": "default" }
117 function setValues(Name, Id, Imdb, Runtime, Year, Trailer, Poster, Fanart) {
118 movieActivityDocument.contents = {
119 name: Name,
120 id: Id,
121 imdb: Imdb,
122 runtime: Runtime,
123 year: Year,
124 trailer: Trailer,
125 poster: Poster,
126 fanart: Fanart
127 }
128 }
129 }
130
131 // Document to store the user's tv activity on Trakt
132 U1db.Document {
133 id: showActivityDocument
134 database: db
135 docId: "traktShowActivity"
136 create: true
137 defaults: { "name": "default", "id": "default", "imdb": "default", "episode_title": "default", "season": "default", "number": "default" ,"poster": "default", "fanart": "default" }
138 function setValues(Name, Id, Imdb, Episode_title, Season, number, Poster, Fanart) {
139 showActivityDocument.contents = {
140 name: Name,
141 id: Id,
142 imdb: Imdb,
143 episode_title: Episode_title,
144 season: Season,
145 number: number,
146 poster: Poster,
147 fanart: Fanart
148 }
149 }
150 }
151
152 // Document to store the user's watchlist activity on Trakt
153 U1db.Document {
154 id: watchlistActivityDocument
155 database: db
156 docId: "traktWatchlistActivity"
157 create: true
158 defaults: { "movie": "default", "show": "default" }
159 }
160
161 // Document to track user show's episode seen/unseen activity on Trakt
162 U1db.Document {
163 id: episodeSeenActivityDocument
164 database: db
165 docId: "traktEpisodeSeenActivity"
166 create: true
167 defaults: { "episode": "default" }
168 }
169
170 Loader { id: userActivityLoader }
171
172 Component {
173 id: userActivity
174 Activity {
175 id: _userActivity
176
177 username: traktLogin.contents.username
178 password: traktLogin.contents.password
179
180 onActivityDocumentChanged: {
181 if(activityDocument.type === "movie") {
182 showActivityDocument.setValues("default", "default", "default", "default", "default", "default", "default", "default")
183 movieActivityDocument.setValues(activityDocument.name, activityDocument.id, activityDocument.imdb, activityDocument.runtime, activityDocument.year, activityDocument.trailer, activityDocument.poster, activityDocument.fanart)
184 }
185 else if(activityDocument.type === "episode") {
186 movieActivityDocument.setValues("default", "default", "default", "default", "default", "default", "default", "default")
187 showActivityDocument.setValues(activityDocument.name, activityDocument.id, activityDocument.imdb, activityDocument.episode_title, activityDocument.season, activityDocument.number, activityDocument.poster, activityDocument.fanart)
188 }
189 // If user is not watching anything, set both documents to default
190 else if(activityDocument.type === "default") {
191 movieActivityDocument.setValues("default", "default", "default", "default", "default", "default", "default", "default")
192 showActivityDocument.setValues("default", "default", "default", "default", "default", "default", "default", "default")
193 }
194 }
195 }
196 }
197
198 PageStack {
199 id: pagestack
200
201 // Properties to hold the application details which are then used throughout the application for consistency
202 property string app_version: "0.3.3"
203 property string app_name: "Flashback"
204 property string last_updated: "28 March 2014"
205
206 // Property to hold the trakt account status to allow for detecting account changes after the app is open
207 property string account_status
208
209 // Property to hold the user movie/show status to allow for activity changes after the app is open
210 property string movieName
211 property string showName
212
213 Component.onCompleted: {
214 if(String(firstRunDocument.contents.firstrun) === "true") {
215 console.log("[LOG]: Running app for the first time. Opening Walkthrough: " + firstRunDocument.contents.firstrun)
216 push(Qt.resolvedUrl("walkthrough/Walkthrough.qml"));
217 }
218 else
219 push(rootComponent);
220 }
221
222 Component {
223 id: rootComponent
224 Tabs {
225 id: root
226
227 onSelectedTabChanged: {
228 if(root.selectedTab == moviesTab)
229 movieLoader.source = Qt.resolvedUrl("ui/MovieTab.qml")
230 else if(root.selectedTab == tvTab)
231 tvLoader.source = Qt.resolvedUrl("ui/TvTab.qml")
232 else if(root.selectedTab == peopleTab)
233 peopleLoader.source = Qt.resolvedUrl("ui/PersonTab.qml")
234 }
235
236 Tab {
237 id: homeTab
238 title: i18n.tr("Home")
239 page: HomeTab {}
240 }
241
242 Tab {
243 id: moviesTab
244 title: i18n.tr("Movies")
245 page: Loader {
246 id: movieLoader
247 parent: moviesTab
248 anchors {
249 left: parent.left
250 right: parent.right
251 bottom: parent.bottom
252 }
253 }
254 }
255
256 Tab {
257 id: tvTab
258 title: i18n.tr("TV")
259 page: Loader {
260 id: tvLoader
261 parent: tvTab
262 anchors {
263 left: parent.left
264 right: parent.right
265 bottom: parent.bottom
266 }
267 }
268 }
269
270 Tab {
271 id: peopleTab
272 title: i18n.tr("Celeb")
273 page: Loader {
274 id: peopleLoader
275 parent: peopleTab
276 anchors {
277 left: parent.left
278 right: parent.right
279 bottom: parent.bottom
280 }
281 }
282 }
283 }
284 }
285 }
286}
0287
=== renamed file 'Flashback.qml' => 'Flashback.qml.moved'
=== added file 'Flashback.qmlproject'
--- Flashback.qmlproject 1970-01-01 00:00:00 +0000
+++ Flashback.qmlproject 2014-05-14 17:33:57 +0000
@@ -0,0 +1,46 @@
1/* File generated by Qt Creator (with Ubuntu Plugin), version 2.8.1 */
2
3import QmlProject 1.1
4
5Project {
6 mainFile: "Flashback.qml"
7
8 /* Include .qml, .js, and image files from current directory and subdirectories */
9 QmlFiles {
10 directory: "."
11 }
12 JavaScriptFiles {
13 directory: "."
14 }
15 ImageFiles {
16 directory: "."
17 }
18 Files {
19 filter: "*.desktop"
20 }
21 Files {
22 filter: "Makefile"
23 }
24 Files {
25 directory: "html"
26 filter: "*"
27 }
28 Files {
29 directory: "img/"
30 filter: "*"
31 }
32 Files {
33 directory: "css/"
34 filter: "*"
35 }
36 Files {
37 directory: "tests/"
38 filter: "*"
39 }
40 Files {
41 directory: "debian"
42 filter: "*"
43 }
44 /* List of plugin directories passed to QML runtime */
45 importPaths: [ "." ,"/usr/bin","/usr/lib/x86_64-linux-gnu/qt5/qml" ]
46}
047
=== renamed file 'Flashback.qmlproject' => 'Flashback.qmlproject.moved'
=== added file 'Makefile'
--- Makefile 1970-01-01 00:00:00 +0000
+++ Makefile 2014-05-14 17:33:57 +0000
@@ -0,0 +1,18 @@
1# More information: https://wiki.ubuntu.com/Touch/Testing
2#
3# Notes for autopilot tests:
4# -----------------------------------------------------------
5# In order to run autopilot tests:
6# sudo apt-add-repository ppa:autopilot/ppa
7# sudo apt-get update
8# sudo apt-get install python-autopilot autopilot-qt
9#############################################################
10
11all:
12
13autopilot:
14 chmod +x tests/autopilot/run
15 tests/autopilot/run
16
17run:
18 /usr/bin/qmlscene $@ Flashback.qml
019
=== renamed file 'Makefile' => 'Makefile.moved'
=== added directory 'backend'
=== renamed directory 'backend' => 'backend.moved'
=== added file 'backend/backend.js'
--- backend/backend.js 1970-01-01 00:00:00 +0000
+++ backend/backend.js 2014-05-14 17:33:57 +0000
@@ -0,0 +1,204 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19var credentials = {
20 baseUrl: "http://api.themoviedb.org/3",
21 apiKey: "d0a2929acb64b7c203071e87a621dfb3",
22 trakt_apiKey: "20a7a6b2d0c3b58acbd81841c40355b04b46c475",
23 trakt_baseUrl: "http://api.trakt.tv"
24}
25
26/*
27 Movies
28 */
29
30function nowPlayingMoviesUrl() {
31 return credentials.baseUrl + "/movie/now_playing" + "?api_key=" + credentials.apiKey;
32}
33
34function trendingMoviesUrl() {
35 return credentials.trakt_baseUrl + "/movies/trending.json/" + credentials.trakt_apiKey;
36}
37
38function similarMoviesUrl(movie_id) {
39 return credentials.baseUrl + "/movie/" + movie_id + "/similar_movies" + "?api_key=" + credentials.apiKey;
40}
41
42function upcomingMoviesUrl() {
43 return credentials.baseUrl + "/movie/upcoming" + "?api_key=" + credentials.apiKey;
44}
45
46function topRatedMoviesUrl() {
47 return credentials.baseUrl + "/movie/top_rated" + "?api_key=" + credentials.apiKey;
48}
49
50function movieUrl(movie_id, options) {
51 options = options || {};
52 var base = credentials.baseUrl + "/movie/"+ movie_id + "?api_key=" + credentials.apiKey;
53 if ( options.appendToResponse )
54 return base + "&append_to_response=" + options.appendToResponse.join(',');
55 else
56 return base;
57}
58
59function traktMovieUrl(movie_id) {
60 return credentials.trakt_baseUrl + "/movie/summary.json/" + credentials.trakt_apiKey + "/" + movie_id;
61}
62
63function filterByGenreUrl(genre_id) {
64 return credentials.baseUrl + "/genre/" + genre_id + "/movies" + "?api_key=" + credentials.apiKey;
65}
66
67//Genre
68function genreUrl() {
69 return credentials.baseUrl + "/genre/list" + "?api_key=" + credentials.apiKey;
70}
71
72// Cast
73function movieCastUrl(movie_id) {
74 return credentials.baseUrl + "/movie/"+ movie_id + "/credits" + "?api_key=" + credentials.apiKey;
75}
76
77// Crew
78function movieCrewUrl(movie_id) {
79 return credentials.baseUrl + "/movie/"+ movie_id + "/credits" + "?api_key=" + credentials.apiKey;
80}
81
82function trendingShowsUrl() {
83 return credentials.trakt_baseUrl + "/shows/trending.json/" + credentials.trakt_apiKey;
84}
85
86/*
87 TV Shows
88 */
89
90function tvUrl(tv_id) {
91 return credentials.trakt_baseUrl + "/show/summary.json/" + credentials.trakt_apiKey + "/" + tv_id;
92}
93
94function tvSeasons(tv_id) {
95 return credentials.trakt_baseUrl + "/show/seasons.json/" + credentials.trakt_apiKey + "/" + tv_id;
96}
97
98function tvSeasonUrl(tv_id, season_number) {
99 return credentials.trakt_baseUrl + "/show/season.json/" + credentials.trakt_apiKey + "/" + tv_id + "/" + season_number;
100}
101
102function tvEpisodeUrl(tv_id, season_number, episode_number) {
103 return credentials.trakt_baseUrl + "/show/episode/summary.json/" + credentials.trakt_apiKey + "/" + tv_id + "/" + season_number + "/" + episode_number;
104}
105
106/*
107 People
108 */
109
110function popularPeopleUrl() {
111 return credentials.baseUrl + "/person/popular" + "?api_key=" + credentials.apiKey;
112}
113
114function personUrl(person_id, options) {
115 options = options || {};
116 var base = credentials.baseUrl + "/person/"+ person_id + "?api_key=" + credentials.apiKey;
117 if ( options.appendToResponse )
118 return base + "&append_to_response=" + options.appendToResponse.join(',');
119 else
120 return base;
121}
122
123/*
124 Search - Movies, TV and People
125 */
126
127function searchUrl(type, term) {
128 if(type === "tv")
129 return credentials.trakt_baseUrl + "/search/shows.json/" + credentials.trakt_apiKey + "?query=" + encodeURIComponent(term);
130 else
131 return credentials.baseUrl + "/search/"+ type + "?api_key=" + credentials.apiKey + "&query=" + encodeURIComponent(term);
132}
133
134/*
135 Trakt Services - Check-in, comments, user subscribed shows etc
136 */
137
138function traktVerifyUrl() {
139 return credentials.trakt_baseUrl + "/account/test/" + credentials.trakt_apiKey
140}
141
142function traktCreateAccount() {
143 return credentials.trakt_baseUrl + "/account/create/" + credentials.trakt_apiKey
144}
145
146function userActivity(username) {
147 return credentials.trakt_baseUrl + "/user/watching.json/" + credentials.trakt_apiKey + "/" + username
148}
149
150function recommendedMoviesUrl() {
151 return credentials.trakt_baseUrl + "/recommendations/movies/" + credentials.trakt_apiKey
152}
153
154function traktAddRatingUrl(type) {
155 return credentials.trakt_baseUrl + "/rate/" + type + "/" + credentials.trakt_apiKey
156}
157
158function traktAddCommentUrl(type) {
159 return credentials.trakt_baseUrl + "/comment/" + type + "/" + credentials.trakt_apiKey
160}
161
162function traktCommentsUrl(type, id) {
163 return credentials.trakt_baseUrl + "/" + type + "/comments.json/" + credentials.trakt_apiKey + "/" + id
164}
165
166function traktEpisodeCommentsUrl(id, season, episode) {
167 return credentials.trakt_baseUrl + "/show/episode/comments.json/" + credentials.trakt_apiKey + "/" + id + "/" + season + "/" + episode
168}
169
170function traktCheckInUrl(type) {
171 return credentials.trakt_baseUrl + "/" + type + "/checkin/" + credentials.trakt_apiKey
172}
173
174function cancelTraktCheckIn(type) {
175 return credentials.trakt_baseUrl + "/" + type + "/cancelcheckin/" + credentials.trakt_apiKey
176}
177
178function traktSeenUrl(type) {
179 return credentials.trakt_baseUrl + "/" + type + "/seen/" + credentials.trakt_apiKey
180}
181
182function cancelTraktSeen(type) {
183 return credentials.trakt_baseUrl + "/" + type + "/unseen/" + credentials.trakt_apiKey
184}
185
186function userShowWatchlist(username) {
187 return credentials.trakt_baseUrl + "/user/watchlist/shows.json/" + credentials.trakt_apiKey + "/" + username
188}
189
190function userShows(username, startDate, noOfDays) {
191 return credentials.trakt_baseUrl + "/user/calendar/shows.json/" + credentials.trakt_apiKey + "/" + username + "/" + startDate + "/" + noOfDays
192}
193
194function traktWatchlistUrl(type) {
195 return credentials.trakt_baseUrl + "/" + type + "/watchlist/" + credentials.trakt_apiKey
196}
197
198function traktUnwatchlistUrl(type) {
199 return credentials.trakt_baseUrl + "/" + type + "/unwatchlist/" + credentials.trakt_apiKey
200}
201
202function userWatchlistMovies(username) {
203 return credentials.trakt_baseUrl + "/user/watchlist/movies.json/" + credentials.trakt_apiKey + "/" + username
204}
0205
=== added file 'backend/sha1.js'
--- backend/sha1.js 1970-01-01 00:00:00 +0000
+++ backend/sha1.js 2014-05-14 17:33:57 +0000
@@ -0,0 +1,202 @@
1/*
2 * A JavaScript implementation of the Secure Hash Algorithm, SHA-1, as defined
3 * in FIPS PUB 180-1
4 * Version 2.1a Copyright Paul Johnston 2000 - 2002.
5 * Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet
6 * Distributed under the BSD License
7 * See http://pajhome.org.uk/crypt/md5 for details.
8 */
9
10/*
11 * Configurable variables. You may need to tweak these to be compatible with
12 * the server-side, but the defaults work in most cases.
13 */
14var hexcase = 0; /* hex output format. 0 - lowercase; 1 - uppercase */
15var b64pad = ""; /* base-64 pad character. "=" for strict RFC compliance */
16var chrsz = 8; /* bits per input character. 8 - ASCII; 16 - Unicode */
17
18/*
19 * These are the functions you'll usually want to call
20 * They take string arguments and return either hex or base-64 encoded strings
21 */
22function sha1(s){return binb2hex(core_sha1(str2binb(s),s.length * chrsz));}
23function b64_sha1(s){return binb2b64(core_sha1(str2binb(s),s.length * chrsz));}
24function str_sha1(s){return binb2str(core_sha1(str2binb(s),s.length * chrsz));}
25function hex_hmac_sha1(key, data){ return binb2hex(core_hmac_sha1(key, data));}
26function b64_hmac_sha1(key, data){ return binb2b64(core_hmac_sha1(key, data));}
27function str_hmac_sha1(key, data){ return binb2str(core_hmac_sha1(key, data));}
28
29/*
30 * Perform a simple self-test to see if the VM is working
31 */
32function sha1_vm_test()
33{
34 return sha1("abc") == "a9993e364706816aba3e25717850c26c9cd0d89d";
35}
36
37/*
38 * Calculate the SHA-1 of an array of big-endian words, and a bit length
39 */
40function core_sha1(x, len)
41{
42 /* append padding */
43 x[len >> 5] |= 0x80 << (24 - len % 32);
44 x[((len + 64 >> 9) << 4) + 15] = len;
45
46 var w = Array(80);
47 var a = 1732584193;
48 var b = -271733879;
49 var c = -1732584194;
50 var d = 271733878;
51 var e = -1009589776;
52
53 for(var i = 0; i < x.length; i += 16)
54 {
55 var olda = a;
56 var oldb = b;
57 var oldc = c;
58 var oldd = d;
59 var olde = e;
60
61 for(var j = 0; j < 80; j++)
62 {
63 if(j < 16) w[j] = x[i + j];
64 else w[j] = rol(w[j-3] ^ w[j-8] ^ w[j-14] ^ w[j-16], 1);
65 var t = safe_add(safe_add(rol(a, 5), sha1_ft(j, b, c, d)),
66 safe_add(safe_add(e, w[j]), sha1_kt(j)));
67 e = d;
68 d = c;
69 c = rol(b, 30);
70 b = a;
71 a = t;
72 }
73
74 a = safe_add(a, olda);
75 b = safe_add(b, oldb);
76 c = safe_add(c, oldc);
77 d = safe_add(d, oldd);
78 e = safe_add(e, olde);
79 }
80 return Array(a, b, c, d, e);
81
82}
83
84/*
85 * Perform the appropriate triplet combination function for the current
86 * iteration
87 */
88function sha1_ft(t, b, c, d)
89{
90 if(t < 20) return (b & c) | ((~b) & d);
91 if(t < 40) return b ^ c ^ d;
92 if(t < 60) return (b & c) | (b & d) | (c & d);
93 return b ^ c ^ d;
94}
95
96/*
97 * Determine the appropriate additive constant for the current iteration
98 */
99function sha1_kt(t)
100{
101 return (t < 20) ? 1518500249 : (t < 40) ? 1859775393 :
102 (t < 60) ? -1894007588 : -899497514;
103}
104
105/*
106 * Calculate the HMAC-SHA1 of a key and some data
107 */
108function core_hmac_sha1(key, data)
109{
110 var bkey = str2binb(key);
111 if(bkey.length > 16) bkey = core_sha1(bkey, key.length * chrsz);
112
113 var ipad = Array(16), opad = Array(16);
114 for(var i = 0; i < 16; i++)
115 {
116 ipad[i] = bkey[i] ^ 0x36363636;
117 opad[i] = bkey[i] ^ 0x5C5C5C5C;
118 }
119
120 var hash = core_sha1(ipad.concat(str2binb(data)), 512 + data.length * chrsz);
121 return core_sha1(opad.concat(hash), 512 + 160);
122}
123
124/*
125 * Add integers, wrapping at 2^32. This uses 16-bit operations internally
126 * to work around bugs in some JS interpreters.
127 */
128function safe_add(x, y)
129{
130 var lsw = (x & 0xFFFF) + (y & 0xFFFF);
131 var msw = (x >> 16) + (y >> 16) + (lsw >> 16);
132 return (msw << 16) | (lsw & 0xFFFF);
133}
134
135/*
136 * Bitwise rotate a 32-bit number to the left.
137 */
138function rol(num, cnt)
139{
140 return (num << cnt) | (num >>> (32 - cnt));
141}
142
143/*
144 * Convert an 8-bit or 16-bit string to an array of big-endian words
145 * In 8-bit function, characters >255 have their hi-byte silently ignored.
146 */
147function str2binb(str)
148{
149 var bin = Array();
150 var mask = (1 << chrsz) - 1;
151 for(var i = 0; i < str.length * chrsz; i += chrsz)
152 bin[i>>5] |= (str.charCodeAt(i / chrsz) & mask) << (32 - chrsz - i%32);
153 return bin;
154}
155
156/*
157 * Convert an array of big-endian words to a string
158 */
159function binb2str(bin)
160{
161 var str = "";
162 var mask = (1 << chrsz) - 1;
163 for(var i = 0; i < bin.length * 32; i += chrsz)
164 str += String.fromCharCode((bin[i>>5] >>> (32 - chrsz - i%32)) & mask);
165 return str;
166}
167
168/*
169 * Convert an array of big-endian words to a hex string.
170 */
171function binb2hex(binarray)
172{
173 var hex_tab = hexcase ? "0123456789ABCDEF" : "0123456789abcdef";
174 var str = "";
175 for(var i = 0; i < binarray.length * 4; i++)
176 {
177 str += hex_tab.charAt((binarray[i>>2] >> ((3 - i%4)*8+4)) & 0xF) +
178 hex_tab.charAt((binarray[i>>2] >> ((3 - i%4)*8 )) & 0xF);
179 }
180 return str;
181}
182
183/*
184 * Convert an array of big-endian words to a base-64 string
185 */
186function binb2b64(binarray)
187{
188 var tab = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
189 var str = "";
190 for(var i = 0; i < binarray.length * 4; i += 3)
191 {
192 var triplet = (((binarray[i >> 2] >> 8 * (3 - i %4)) & 0xFF) << 16)
193 | (((binarray[i+1 >> 2] >> 8 * (3 - (i+1)%4)) & 0xFF) << 8 )
194 | ((binarray[i+2 >> 2] >> 8 * (3 - (i+2)%4)) & 0xFF);
195 for(var j = 0; j < 4; j++)
196 {
197 if(i * 8 + j * 6 > binarray.length * 32) str += b64pad;
198 else str += tab.charAt((triplet >> 6*(3-j)) & 0x3F);
199 }
200 }
201 return str;
202}
0203
=== added directory 'components'
=== renamed directory 'components' => 'components.moved'
=== added file 'components/BlurredBackground.qml'
--- components/BlurredBackground.qml 1970-01-01 00:00:00 +0000
+++ components/BlurredBackground.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,50 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import Ubuntu.Components 0.1
21import QtGraphicalEffects 1.0
22
23Rectangle {
24 id: blurredBackground
25
26 property alias background: backgroundImage.source
27
28 anchors.fill: parent
29 z: -1
30
31 // Background Image
32 Image {
33 id: backgroundImage
34 anchors.fill: parent
35 }
36
37 // Element to blur the background image
38 FastBlur {
39 anchors.fill: backgroundImage
40 source: backgroundImage
41 radius: units.gu(8)
42 }
43
44 // Element to add a black curtain (dimmer) to increase the readiblity of the text
45 Rectangle {
46 color: "black"
47 opacity: 0.7
48 anchors.fill: parent
49 }
50}
051
=== added file 'components/Carousel.qml'
--- components/Carousel.qml 1970-01-01 00:00:00 +0000
+++ components/Carousel.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,125 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import Ubuntu.Components 0.1
21import Ubuntu.Components.ListItems 0.1
22
23/*
24 The carousel is an element which displays a header title with a flickable row of ubuntu shape thumbnails.
25 */
26Column {
27 id: carousel
28
29 // Header Title
30 property alias header: header.text
31
32 // Carousel Data Model
33 property alias dataModel: carouselList.model
34
35 // Carousel Thumbnail size (On the phone, show 2 + 2/3 cover art always by dynamically adjusting the size)
36 property real size: parent.width < units.gu(50) ? (3 * (parent.width - 2*carouselList.spacing))/8 : units.gu(17)
37
38 // Property to hold the watched status
39 property bool showTraktUserStatus: false
40
41 // Signal triggered when a thumb
42 signal thumbClicked(var model)
43
44 width: parent.width
45 spacing: units.gu(1)
46 /*
47 WORKAROUND: Due to bug https://bugs.launchpad.net/ubuntu-ui-toolkit/+bug/1300668, the opacity and height are used
48 to show/hide the carousel. Previously the declaration was,
49
50 visible: carouselList.model.count > 0
51 height: header.height + carouselList.height
52 */
53 opacity: carouselList.model.count > 0 ? 1 : 0
54 height: opacity === 1 ? header.height + carouselList.height : 0
55
56 Behavior on height {
57 UbuntuNumberAnimation {}
58 }
59
60 Header {
61 id: header
62 text: i18n.tr("Default Header Title")
63 }
64
65 ListView {
66 id: carouselList
67
68 width: parent.width
69 height: 1.5*carousel.size + units.gu(5)
70 orientation: Qt.Horizontal
71 spacing: units.gu(2)
72
73 // Element consists of a Picture and a text label below it.
74 delegate: Item {
75 id: thumbContainer
76
77 width: carousel.size
78 height: thumbColumn.height
79
80 StatusIcons {
81 id: traktStatusContainer
82
83 showWatchedIcon: traktStatusContainer.visible ? watched ? (watched === "true" ? true : false) : false : false
84 showWatchListIcon: traktStatusContainer.visible ? watchlist ? (watchlist === "true" ? true : false) : false : false
85 visible: carousel.showTraktUserStatus
86
87 anchors {
88 top: parent.top
89 left: parent.left
90 }
91 }
92
93 Column {
94 id: thumbColumn
95 spacing: units.gu(0.5)
96
97 // Widget to curve edges and encase the thumbnail
98 Thumbnail {
99 id: carouselThumb
100 width: carousel.size
101 height: 1.5*carousel.size
102 thumbSource: thumb_url
103 }
104
105 // Label showing the movie/tv show name
106 Label {
107 id: carouselThumbDescription
108
109 text: name
110 maximumLineCount: 2
111 elide: Text.ElideRight
112 wrapMode: Text.WordWrap
113 width: carouselThumb.width
114 horizontalAlignment: Text.AlignHCenter
115 }
116 }
117
118 MouseArea {
119 anchors.fill: parent
120 onClicked: carousel.thumbClicked(model)
121 }
122 }
123 }
124}
125
0126
=== added file 'components/DesaturatedThumbnail.qml'
--- components/DesaturatedThumbnail.qml 1970-01-01 00:00:00 +0000
+++ components/DesaturatedThumbnail.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,60 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import Ubuntu.Components 0.1
21import QtGraphicalEffects 1.0
22
23/*
24 Component to wrap up an image in a ubuntu shape container and desaturate it. This is very similar to the
25 Thumbnail component except with the desaturation.
26 */
27UbuntuShape {
28 id: desaturatedThumb
29
30 property alias thumbSource: thumbPic.source
31 property alias ready: loading.running
32
33 image: Image {
34 id: thumbPic
35 fillMode: Image.PreserveAspectFit
36 visible: false
37 }
38
39 HueSaturation {
40 id: saturated
41 anchors.fill: parent
42 source: thumbPic
43 hue: 0
44 saturation: -1.0
45 lightness: 0
46 visible: false
47 }
48
49 OpacityMask {
50 anchors.fill: saturated
51 source: saturated
52 maskSource: desaturatedThumb
53 }
54
55 ActivityIndicator {
56 id: loading
57 running: thumbPic.status != Image.Ready
58 anchors.centerIn: parent
59 }
60}
061
=== added file 'components/DetailCarousel.qml'
--- components/DetailCarousel.qml 1970-01-01 00:00:00 +0000
+++ components/DetailCarousel.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,192 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import Ubuntu.Components 0.1
21import Ubuntu.Components.ListItems 0.1
22
23/*
24 The Detail Carousel is very similar to Carousel. It shows additional information such as Episode title,
25 season and episode number and the release date. This carousel is primarily for displaying tv shows.
26 */
27Column {
28 id: _detailCarousel
29
30 // Header Title
31 property alias header: _header.text
32
33 // Carousel Data Model
34 property alias dataModel: _carouselList.model
35
36 // Carousel Thumbnail size (On the phone, show 2 + 2/3 cover art always by dynamically adjusting the size)
37 property int size: parent.width < units.gu(50) ? (3 * (parent.width - 2*_carouselList.spacing))/8 : units.gu(17)
38
39 // Property to show/hide date
40 property bool showDate: true
41
42 // Signal triggered when a thumb
43 signal thumbClicked(var model)
44
45 width: parent.width
46 spacing: units.gu(1)
47 /*
48 WORKAROUND: Due to bug https://bugs.launchpad.net/ubuntu-ui-toolkit/+bug/1300668, the opacity and height are used
49 to show/hide the carousel. Previously the declaration was,
50
51 visible: _carouselList.model.count > 0
52 height: _header.height + _carouselList.height
53 */
54 opacity: _carouselList.model.count > 0 ? 1 : 0
55 height: opacity === 1 ? _header.height + _carouselList.height : 0
56
57 Header {
58 id: _header
59 text: i18n.tr("Default Header Title")
60 }
61
62 ListView {
63 id: _carouselList
64
65 width: parent.width
66 height: 1.5*_detailCarousel.size + units.gu(5)
67 orientation: Qt.Horizontal
68 spacing: units.gu(2)
69
70 // Element consists of a Picture and a text label below it.
71 delegate: Item {
72 id: _carouselItem
73 width: _detailCarousel.size
74 height: _thumbColumn.height
75
76 Column {
77 id: _thumbColumn
78 spacing: units.gu(0.5)
79
80 // Widget to curve edges and encase the thumbnail
81 Thumbnail {
82 id: _carouselThumb
83 radius: "medium"
84 width: _detailCarousel.size
85 height: 1.5*_detailCarousel.size
86 thumbSource: thumb_url
87
88 Item {
89 id: bottomContainer
90 clip: true
91 height: parent.height/5
92 anchors {
93 left: parent.left
94 right: parent.right
95 bottom: parent.bottom
96 }
97
98 UbuntuShape {
99 id: detailsContainer
100 height: _carouselThumb.height
101 anchors {
102 bottom: parent.bottom
103 left: parent.left
104 right: parent.right
105 }
106 radius: "medium"
107 color: Qt.rgba(0,0,0,0.8)
108 }
109
110 Column {
111 id: detailsColumn
112 anchors {
113 left: parent.left
114 right: parent.right
115 verticalCenter: parent.verticalCenter
116 margins: units.gu(1)
117 }
118
119 // Label showing the tv episode name
120 Label {
121 id: _episodeTitle
122 text: episode_name
123 elide: Text.ElideRight
124 font.bold: true
125 anchors {
126 left: parent.left
127 right: parent.right
128 }
129 }
130
131 // Container to hold the tv show season number and release date
132 Item {
133 height: childrenRect.height
134 anchors {
135 left: parent.left
136 right: parent.right
137 }
138
139 Label {
140 id: _seasonDetail
141 text: "S" + season + "E" + episode
142 width: parent.width * (2/5)
143 elide: Text.ElideRight
144 fontSize: "small"
145 anchors.left: parent.left
146 }
147
148 Label {
149 id: _seasonDate
150
151 font.bold: true
152 fontSize: "small"
153 color: "LightGreen"
154 visible: showDate
155 text: get_date(episode_air_date)
156 elide: Text.ElideRight
157 width: parent.width * (3/5)
158 anchors.right: parent.right
159 horizontalAlignment: Text.AlignRight
160
161 function get_date(iso) {
162 var date, month
163 date = iso.split('T')[0].split('-')
164 month = Qt.locale().standaloneMonthName(date[1] - 1, Locale.ShortFormat)
165 return date[2] + " " + month
166 }
167 }
168 }
169 }
170 }
171 }
172
173 // Label showing the tv show name
174 Label {
175 id: _carouselThumbDescription
176 text: name
177 maximumLineCount: 2
178 elide: Text.ElideRight
179 wrapMode: Text.WordWrap
180 width: _carouselThumb.width
181 horizontalAlignment: Text.AlignHCenter
182 }
183 }
184
185 MouseArea {
186 anchors.fill: parent
187 onClicked: _detailCarousel.thumbClicked(model)
188 }
189 }
190 }
191}
192
0193
=== added file 'components/Development.qml'
--- components/Development.qml 1970-01-01 00:00:00 +0000
+++ components/Development.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,25 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import Ubuntu.Components 0.1
21
22Label{
23 text: i18n.tr("Still in development")
24 color: Theme.palette.normal.baseText
25}
026
=== added file 'components/Grid.qml'
--- components/Grid.qml 1970-01-01 00:00:00 +0000
+++ components/Grid.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,278 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import Ubuntu.Components 0.1
21import Ubuntu.Components.ListItems 0.1
22
23Item {
24 id: grid
25
26 // Property to choose the grid type
27 property string gridType: "gridCarousel"
28
29 // Property to show/hide date
30 property bool showDate: true
31
32 // Header Title
33 property alias header: header.text
34
35 // Grid Data Model
36 property alias dataModel: gridView.model
37
38 // Grid Thumbnail size
39 property int size: {
40 if (width >= units.gu(170))
41 return (width - 9*container.spacing)/8
42 if (width >= units.gu(150))
43 return (width - 8*container.spacing)/7
44 else if (width >= units.gu(130))
45 return (width - 7*container.spacing)/6
46 else if (tabletLandscapeForm || width > units.gu(100))
47 return (width - 6*container.spacing)/5
48 else if (width > units.gu(80))
49 return (width - 5*container.spacing)/4
50 else if (width >= units.gu(60))
51 return (width - 4*container.spacing)/3
52 else
53 return (width - 3*container.spacing)/2
54 }
55
56 // Grid Thumbnail height
57 property int gridHeight: 1.5*size
58
59 // Signal triggered when a thumb
60 signal thumbClicked(var model)
61
62 width: parent.width
63 visible: gridView.model.count > 0
64
65 Column {
66 id: container
67
68 spacing: units.gu(3)
69 anchors {
70 fill: parent
71 leftMargin: units.gu(3)
72 topMargin: units.gu(2)
73 }
74
75 Header {
76 id: header
77 text: "Default Header Title"
78 visible: text !== "Default Header Title"
79 anchors {
80 left: parent.left
81 right: parent.right
82 margins: -units.gu(3)
83 }
84 }
85
86 Component {
87 id: gridCarouselDelegate
88 Item {
89 id: thumbContainer
90
91 width: grid.size
92 height: grid.gridHeight + units.gu(5)
93
94 Column {
95 id: thumbColumn
96 spacing: units.gu(0.5)
97 anchors.fill: parent
98
99 // Widget to curve edges and encase the thumbnail
100 Thumbnail {
101 id: gridThumb
102 radius: "small"
103 width: grid.size
104 height: grid.gridHeight
105 thumbSource: thumb_url
106
107 MouseArea {
108 anchors.fill: parent
109 onClicked: grid.thumbClicked(model)
110 }
111 }
112
113 // Label showing the movie/tv show name
114 Label {
115 id: gridThumbDescription
116
117 text: name
118 maximumLineCount: 2
119 visible: !tabletPortraitForm && !tabletLandscapeForm
120 elide: Text.ElideRight
121 wrapMode: Text.WordWrap
122 width: gridThumb.width
123 horizontalAlignment: Text.AlignHCenter
124
125 MouseArea {
126 anchors.fill: parent
127 onClicked: grid.thumbClicked(model)
128 }
129 }
130 }
131 }
132 }
133
134 Component {
135 id: gridDetailedCarouselDelegate
136 Item {
137 id: thumbContainer
138
139 width: grid.size
140 height: grid.gridHeight + units.gu(5)
141
142 Column {
143 id: thumbColumn
144 spacing: units.gu(0.5)
145 anchors.fill: parent
146
147 // Widget to curve edges and encase the thumbnail
148 Thumbnail {
149 id: gridThumb
150 radius: "small"
151 width: grid.size
152 height: grid.gridHeight
153 thumbSource: thumb_url
154
155 MouseArea {
156 anchors.fill: parent
157 onClicked: grid.thumbClicked(model)
158 }
159
160 Item {
161 id: bottomContainer
162 clip: true
163 height: parent.height/5
164 anchors {
165 left: parent.left
166 right: parent.right
167 bottom: parent.bottom
168 }
169
170 UbuntuShape {
171 id: detailsContainer
172 height: gridThumb.height
173 anchors {
174 bottom: parent.bottom
175 left: parent.left
176 right: parent.right
177 }
178 radius: "medium"
179 color: Qt.rgba(0,0,0,0.8)
180 }
181
182 Column {
183 id: detailsColumn
184 anchors {
185 left: parent.left
186 right: parent.right
187 verticalCenter: parent.verticalCenter
188 margins: units.gu(1)
189 }
190
191 // Label showing the tv episode name
192 Label {
193 id: _episodeTitle
194 text: episode_name
195 elide: Text.ElideRight
196 font.bold: true
197 anchors {
198 left: parent.left
199 right: parent.right
200 }
201 }
202
203 // Container to hold the tv show season number and release date
204 Item {
205 height: childrenRect.height
206 anchors {
207 left: parent.left
208 right: parent.right
209 }
210
211 Label {
212 id: _seasonDetail
213 text: "S" + season + "E" + episode
214 width: parent.width * (2/5)
215 elide: Text.ElideRight
216 fontSize: "small"
217 anchors.left: parent.left
218 }
219
220 Label {
221 id: _seasonDate
222
223 font.bold: true
224 fontSize: "small"
225 color: "LightGreen"
226 visible: showDate
227 text: get_date(episode_air_date)
228 elide: Text.ElideRight
229 width: parent.width * (3/5)
230 anchors.right: parent.right
231 horizontalAlignment: Text.AlignRight
232
233 function get_date(iso) {
234 var date, month
235 date = iso.split('T')[0].split('-')
236 month = Qt.locale().standaloneMonthName(date[1] - 1, Locale.ShortFormat)
237 return date[2] + " " + month
238 }
239 }
240 }
241 }
242 }
243 }
244
245 // Label showing the tv show name
246 Label {
247 id: gridThumbDescription
248 text: name
249 maximumLineCount: 2
250 elide: Text.ElideRight
251 wrapMode: Text.WordWrap
252 width: gridThumb.width
253 horizontalAlignment: Text.AlignHCenter
254 visible: !tabletPortraitForm && !tabletLandscapeForm
255
256 MouseArea {
257 anchors.fill: parent
258 onClicked: grid.thumbClicked(model)
259 }
260 }
261 }
262 }
263 }
264
265 GridView {
266 id: gridView
267 clip: true
268 width: parent.width
269 height: header.visible ? parent.height - header.height - parent.spacing : parent.height
270 snapMode: GridView.SnapToRow
271
272 cellHeight: !tabletPortraitForm && !tabletLandscapeForm ? grid.gridHeight + units.gu(8) : grid.gridHeight + units.gu(4)
273 cellWidth: grid.size + container.spacing
274
275 delegate: gridType == "gridCarousel" ? gridCarouselDelegate : gridDetailedCarouselDelegate
276 }
277 }
278}
0279
=== added file 'components/ImageLabel.qml'
--- components/ImageLabel.qml 1970-01-01 00:00:00 +0000
+++ components/ImageLabel.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,53 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import Ubuntu.Components 0.1
21
22/*
23 Generic component to display an icon and text side by side
24 */
25Item {
26 id: imageLabel
27
28 // Public Properties
29
30 property alias image: icon.source
31 property alias label: iconText.text
32 property alias size: icon.width
33
34 height: childrenRect.height
35 width: childrenRect.width
36
37 Row {
38 spacing: units.gu(0.5)
39 Image {
40 id: icon
41 smooth: true
42 height: width
43 width: units.gu(4)
44 antialiasing: true
45 fillMode: Image.PreserveAspectFit
46 }
47
48 Label {
49 id: iconText
50 anchors.verticalCenter: icon.verticalCenter
51 }
52 }
53}
054
=== added file 'components/ListViewExpandable.qml'
--- components/ListViewExpandable.qml 1970-01-01 00:00:00 +0000
+++ components/ListViewExpandable.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,80 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import Ubuntu.Components 0.1
21import Ubuntu.Components.ListItems 0.1
22
23// Expandable List Element
24Expandable {
25 id: listviewExpandable
26
27 // Property to set the model of the search results listview
28 property alias model: _resultsList.model
29
30 // Property to set the label of the search category header
31 property alias header: _header.text
32
33 // Property to store the number of the search results
34 property int count
35
36 // Property to set the listitem delegate
37 property alias delegateItem: _resultsList.delegate
38
39 collapseOnClick: true
40 enabled: count !== 0
41 visible: count !== 0
42 onClicked: expanded = true
43 expandedHeight: _contentColumn.height + units.gu(1)
44
45 Column {
46 id: _contentColumn
47 anchors {
48 left: parent.left
49 right: parent.right
50 }
51
52 Item {
53 anchors {
54 left: parent.left
55 right: parent.right
56 }
57
58 height: listviewExpandable.collapsedHeight
59
60 Label {
61 id: _header
62 anchors {
63 left: parent.left
64 right: parent.right
65 verticalCenter: parent.verticalCenter
66 }
67 }
68 }
69
70 ListView {
71 id: _resultsList
72 clip: true
73 height: count > 5 ? 5 * units.gu(6) : count * units.gu(6)
74 anchors {
75 left: parent.left
76 right: parent.right
77 }
78 }
79 }
80}
081
=== added file 'components/LoadingIndicator.qml'
--- components/LoadingIndicator.qml 1970-01-01 00:00:00 +0000
+++ components/LoadingIndicator.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,60 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import Ubuntu.Components 0.1
21
22/*
23 Generic loading indicator component to provide user feedback
24 */
25Rectangle {
26 id: loadingContainer
27
28 property alias loadingText: _loadingLabel.text
29
30 width: units.gu(30)
31 height: units.gu(10)
32 radius: units.gu(0.5)
33
34 /*
35 WORKAROUND: Due to bug https://bugs.launchpad.net/ubuntu-ui-toolkit/+bug/1300668, the opacity property
36 is used for hiding and showing the loading indicator and hence cannot be used for the appearance of the
37 widget.
38 */
39 //opacity: 0.7
40 color: "Black"
41
42 anchors.centerIn: parent
43 z: parent.z + 1
44
45 Row {
46 anchors.centerIn: parent
47 spacing: units.gu(2)
48
49 ActivityIndicator {
50 id: _indicator
51 running: true
52 }
53
54 Label {
55 id: _loadingLabel
56 text: i18n.tr("Loading...")
57 anchors.verticalCenter: _indicator.verticalCenter
58 }
59 }
60}
061
=== added file 'components/Notification.qml'
--- components/Notification.qml 1970-01-01 00:00:00 +0000
+++ components/Notification.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,190 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import Ubuntu.Components 0.1
21
22/*
23 Component to show user notification about an activity
24 Behavior: Hidden after 10 seconds automatically or when the user clicks the close button
25 */
26Rectangle {
27 id: _notificationContainer
28
29 // Property to set the notification title
30 property alias messageTitle: _notificationTitle.text
31
32 // Property to set the notification message
33 property alias message: _notificationMessage.text
34
35 // Property to set the notification icon (By default shows the error icon since it is the common case)
36 property alias messageIcon: _notificationIcon.source
37
38 // Property to set the notification timeout (in seconds). By default set to 10 seconds
39 property int timeout: 10
40
41 //
42
43 height: _mainColumn.height + units.gu(5)
44 anchors.centerIn: parent
45 width: parent.width/1.2
46 radius: units.gu(0.5)
47 z: parent.z + 1
48 visible: false
49 opacity: 0.8
50 color: "Black"
51
52 // When notification is visible, start the internal timer
53 onVisibleChanged: visible == true ? _countDownTimer.restart() : undefined
54
55 Behavior on width {
56 UbuntuNumberAnimation { duration: UbuntuAnimation.BriskDuration }
57 }
58
59 Behavior on height {
60 UbuntuNumberAnimation { duration: UbuntuAnimation.BriskDuration }
61 }
62
63 // Timer to show the time countdown to the user (updated every second)
64 Timer {
65 id: _countDownTimer
66
67 property int _countDown: timeout
68
69 repeat: true
70 interval: 1000
71
72 onTriggered: {
73 _visualCountDownAnimation.start()
74 _countDown = _countDown - 1
75 if(_countDown == 0) {
76 _countDownTimer.stop()
77 _visualCountDownAnimation.complete()
78 _notificationContainer.visible = false
79 _countDown = timeout
80 }
81 }
82 }
83
84 // Notification Icon
85 Image {
86 id: _notificationIcon
87
88 width: units.gu(5)
89 height: width
90 anchors {
91 verticalCenter: _mainColumn.verticalCenter
92 left: parent.left
93 margins: units.gu(2)
94 }
95
96 source: Qt.resolvedUrl("../graphics/error.png")
97 fillMode: Image.PreserveAspectFit
98 smooth: true
99 }
100
101 // GUI consisting of the notification message. The string shows a custom message
102 Column {
103 id: _mainColumn
104 anchors {
105 left: _notificationIcon.right
106 right: parent.right
107 top: parent.top
108 margins: units.gu(2)
109 }
110
111 spacing: units.gu(1)
112
113 Label {
114 id: _notificationTitle
115
116 text: i18n.tr("Default")
117 font.bold: true
118 elide: Text.ElideRight
119 wrapMode: Text.WordWrap
120 anchors {
121 left: parent.left
122 right: parent.right
123 }
124
125 }
126
127 Label {
128 id: _notificationMessage
129
130 text: i18n.tr("Default")
131 elide: Text.ElideRight
132 wrapMode: Text.WordWrap
133 anchors {
134 left: parent.left
135 right: parent.right
136 }
137
138 }
139 }
140
141 // Visual count down animation (shown at the top)
142 Rectangle {
143 id: _visualCountDown
144
145 color: UbuntuColors.orange
146 height: units.gu(0.4)
147 anchors {
148 top: parent.top
149 left: _closeIcon.right
150 }
151
152 SequentialAnimation on width {
153 id: _visualCountDownAnimation
154 running: false
155 NumberAnimation {
156 from: _notificationContainer.width - units.gu(2)
157 to: 0
158 duration: (timeout*1000) - 1000
159 }
160 PauseAnimation {duration: 1000}
161 }
162 }
163
164 // Icon to close the notification bubble (shown at the top left corner)
165 Image {
166 id: _closeIcon
167
168 width: units.gu(3)
169 height: width
170 anchors {
171 bottom: parent.top
172 right: parent.left
173 margins: units.gu(-2)
174 }
175
176 source: Qt.resolvedUrl("../graphics/close.png")
177 fillMode: Image.PreserveAspectFit
178 smooth: true
179
180 MouseArea {
181 anchors.fill: parent
182 onClicked: {
183 _countDownTimer.stop()
184 _visualCountDownAnimation.complete()
185 _notificationContainer.visible = false
186 _countDownTimer._countDown = timeout
187 }
188 }
189 }
190}
0191
=== added file 'components/NowWatching.qml'
--- components/NowWatching.qml 1970-01-01 00:00:00 +0000
+++ components/NowWatching.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,147 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import Ubuntu.Components 0.1
21import Ubuntu.Components.ListItems 0.1
22
23Column {
24 id: nowWatching
25
26 spacing: units.gu(1)
27
28 // Public properties to set the currently watched movie/tv
29 property alias backgroundFanArt: _backgroundFanArt.thumbSource
30 property alias posterArt: _poster.thumbSource
31 property alias title: _title.text
32 property alias subtitle: _subtitle.text
33 property alias extra: _extra.text
34 property bool showTrailer: false
35
36 // Signal triggered when a thumb is clicked
37 signal thumbClicked()
38
39 // Signal triggered when trailer is clicked
40 signal trailerClicked()
41
42 // Default width and height
43 property int backgroundWidth: units.gu(35)
44 property int backgroundHeight: units.gu(20)
45
46 Header { text: i18n.tr("Now Watching") }
47
48 DesaturatedThumbnail {
49 id: _backgroundFanArt
50
51 width: backgroundWidth
52 height: backgroundHeight
53
54 Thumbnail {
55 id: _poster
56 width: parent.width/3.3
57 z: parent.z + 1
58 visible: !_backgroundFanArt.ready
59 anchors {
60 left: parent.left
61 top: parent.top
62 bottom: _detailsContainer.top
63 margins: units.gu(0.5)
64 }
65 }
66
67 // Container to show more details like episode title or movie runtime etc
68 Rectangle {
69 id: _detailsContainer
70
71 color: "Black"
72 opacity: 0.7
73 z: parent.z + 1
74 radius: units.gu(1)
75 height: parent.height/5
76 visible: !_backgroundFanArt.ready
77 anchors {
78 left: parent.left
79 right: parent.right
80 bottom: parent.bottom
81 }
82
83 Label {
84 id: _subtitle
85 elide: Text.ElideRight
86 width: parent.width * (4/5)
87 anchors {
88 leftMargin: units.gu(1)
89 left: parent.left
90 verticalCenter: parent.verticalCenter
91 }
92 }
93
94 Label {
95 id: _extra
96 width: parent.width/5
97 elide: Text.ElideRight
98 visible: !nowWatching.showTrailer
99 horizontalAlignment: Text.AlignRight
100 anchors {
101 rightMargin: units.gu(1)
102 right: parent.right
103 verticalCenter: parent.verticalCenter
104 }
105 }
106
107 Image {
108 id: _trailer
109
110 width: units.gu(3)
111 height: width
112 visible: nowWatching.showTrailer
113 source: Qt.resolvedUrl("../graphics/trailer.png")
114 anchors {
115 rightMargin: units.gu(1)
116 right: parent.right
117 verticalCenter: parent.verticalCenter
118 }
119
120 MouseArea {
121 anchors.fill: parent
122 preventStealing: true
123 enabled: _trailer.visible
124 onClicked: nowWatching.trailerClicked()
125 }
126 }
127 }
128
129 MouseArea {
130 id: thumbArea
131 anchors.fill: parent
132 onClicked: nowWatching.thumbClicked()
133 }
134 }
135
136 Label {
137 id: _title
138 maximumLineCount: 2
139 elide: Text.ElideRight
140 wrapMode: Text.WordWrap
141 horizontalAlignment: Text.AlignHCenter
142 anchors {
143 left: _backgroundFanArt.left
144 right: _backgroundFanArt.right
145 }
146 }
147}
0148
=== added file 'components/RatingChooser.qml'
--- components/RatingChooser.qml 1970-01-01 00:00:00 +0000
+++ components/RatingChooser.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,106 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import Ubuntu.Components 0.1
21import Ubuntu.Components.ListItems 0.1
22import "../backend/backend.js" as Backend
23import "../models"
24
25Rectangle {
26 id: ratingsChoice
27
28 // Public properties required for submitting a user rating to Trakt
29 property string type
30 property string type_id
31 property string name
32 property string year
33 property int season
34 property int episode
35
36 // Property to hold the user rating.
37 property int ratings: 0
38
39 // Signal triggered when ratings is successfully submitted
40 signal ratingClicked()
41
42 TraktUserRating {
43 id: traktUserRating
44 function updateJSONModel() {
45 if(reply.status === "success") {
46 console.log("[LOG]: " + type + " ratings success")
47 ratingsChoice.ratings = ratingListModel.get(ratingList.currentIndex).rating
48 ratingsChoice.ratingClicked()
49 }
50 }
51 }
52
53 color: "Black"
54 visible: false
55 radius: units.gu(2)
56 width: parent.width/1.6
57 height: parent.height/1.2
58
59 TraktRatingModel { id: ratingListModel }
60
61 ListView {
62 id: ratingList
63
64 clip: true
65 currentIndex: -1
66 model: ratingListModel
67 spacing: units.gu(1)
68 anchors {
69 top: parent.top
70 left: parent.left
71 right: parent.right
72 bottom: cancelButton.top
73 margins: units.gu(2)
74 }
75
76 delegate: Standard {
77 text: ratingDescription
78 iconFrame: false
79 iconSource: Qt.resolvedUrl(thumb_url)
80 onClicked: {
81 ratingList.currentIndex = index
82 ratingsChoice.visible = false
83 traktUserRating.source = Backend.traktAddRatingUrl(type)
84 if(type === "movie")
85 traktUserRating.createMovieMessage(traktLogin.contents.username, traktLogin.contents.password, type_id, name, year, rating)
86 else if(type === "episode")
87 traktUserRating.createEpisodeMessage(traktLogin.contents.username, traktLogin.contents.password, type_id, name, year, season, episode, rating)
88 else if(type === "show")
89 traktUserRating.createShowMessage(traktLogin.contents.username, traktLogin.contents.password, type_id, name, year, rating)
90 traktUserRating.sendMessage()
91 }
92 }
93 }
94
95 Button {
96 id: cancelButton
97 width: parent.width/2
98 text: i18n.tr("Cancel")
99 onClicked: ratingsChoice.visible = false
100 anchors {
101 horizontalCenter: parent.horizontalCenter
102 bottom: parent.bottom
103 bottomMargin: units.gu(2)
104 }
105 }
106}
0107
=== added file 'components/Rotater.qml'
--- components/Rotater.qml 1970-01-01 00:00:00 +0000
+++ components/Rotater.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,66 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import Ubuntu.Components 0.1
21
22/*
23 Generic component to provide the capability to truncate text or data when space is limited and yet provide
24 allow viewing of lengthy text or data when required without using a page.
25 */
26Flipable {
27 id: _rotater
28
29 // Property to flip the component to view the full extensive text or data
30 property bool flipped: false
31
32 // Property to hold the height of the flipped component
33 property real flipHeight
34
35 z: parent.z + 1
36
37 transform: Rotation {
38 id: _rotation
39 origin { x: _rotater.width/2; y: _rotater.height/2 }
40 axis { x: 0; y: 1; z: 0 }
41 angle: 0
42 }
43
44 states: State {
45 name: "back"
46 PropertyChanges { target: _rotation; angle: 180 }
47 PropertyChanges { target: _rotater; height: flipHeight }
48 PropertyChanges { target: _rotater; anchors.topMargin: units.gu(0) }
49
50 AnchorChanges {
51 target: _rotater
52 anchors.top: parent.top
53 anchors.left: parent.left
54 anchors.right: parent.right
55 }
56
57 when: _rotater.flipped
58 }
59
60 transitions: Transition {
61 ParallelAnimation {
62 UbuntuNumberAnimation { target: _rotation; property: "angle"; duration: UbuntuAnimation.SlowDuration }
63 AnchorAnimation {}
64 }
65 }
66}
067
=== added file 'components/SearchBox.qml'
--- components/SearchBox.qml 1970-01-01 00:00:00 +0000
+++ components/SearchBox.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,57 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import Ubuntu.Components 0.1
21
22Item {
23 id: searchBox
24
25 property alias defaultText: searchField.placeholderText
26 property alias search_term: searchField.text
27 signal searchTriggered()
28
29 Component.onCompleted: search_timer.triggered.connect(searchTriggered)
30
31 TextField {
32 id: searchField
33 anchors {
34 left: parent.left
35 right: parent.right
36 top: parent.top
37 }
38
39 primaryItem: Image {
40 height: parent.height/1.5;
41 fillMode: Image.PreserveAspectFit
42 source: Qt.resolvedUrl("../graphics/search_icon.svg")
43 }
44
45 Timer {
46 id: search_timer
47 interval: 1100
48 repeat: false
49 }
50
51 placeholderText: i18n.tr("Search")
52 hasClearButton: true
53 inputMethodHints: Qt.ImhNoPredictiveText
54 onTextChanged: search_timer.restart()
55 }
56}
57
058
=== added file 'components/SearchPage.qml'
--- components/SearchPage.qml 1970-01-01 00:00:00 +0000
+++ components/SearchPage.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,74 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import Ubuntu.Components 0.1
21import Ubuntu.Components.ListItems 0.1
22import "../backend/backend.js" as Backend
23
24Item {
25 id: _searchTemplate
26
27 // Public Properties
28 property alias searchBoxText: _searchBox.defaultText
29 property string type
30 property variant search_model
31 signal resultClicked(var model)
32
33 // Search Box to enter search query along with the search button
34 SearchBox {
35 id: _searchBox
36 anchors {
37 top: parent.top
38 left: parent.left
39 right: parent.right
40 margins: units.gu(2)
41 }
42 onSearchTriggered: {
43 search_model.model.clear();
44 search_model.source = Backend.searchUrl(type, _searchBox.search_term);
45 if (type == "tv") {
46 search_model.createMessage(traktLogin.contents.username, traktLogin.contents.password)
47 search_model.sendMessage()
48 }
49 }
50 }
51
52 ListView {
53 id: _searchResultsList
54 clip: true
55 anchors {
56 left: parent.left
57 right: parent.right
58 bottom: parent.bottom
59 top: _searchBox.bottom
60 leftMargin: units.gu(2)
61 rightMargin: units.gu(2)
62 bottomMargin: units.gu(2)
63 topMargin: units.gu(5)
64 }
65
66 model: search_model.model
67
68 delegate: Standard {
69 text: name
70 iconSource: thumb_url
71 onClicked: _searchTemplate.resultClicked(model)
72 }
73 }
74}
075
=== added file 'components/SidebarMenuItem.qml'
--- components/SidebarMenuItem.qml 1970-01-01 00:00:00 +0000
+++ components/SidebarMenuItem.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,155 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import Ubuntu.Layouts 0.1
21import Ubuntu.Components 0.1
22import Ubuntu.Components.ListItems 0.1 as ListItem
23
24/*
25 Menu item component for the Sidebar
26 */
27ListItem.Empty {
28 id: _sidebarMenuItem
29
30 // Property to set the label of the menu item in tablet portrait form
31 property string shortenedMenuLabel
32
33 // Property to set the label of the menu item in tablet landscape form
34 property string menuLabel
35
36 // Property to set the icon of the menu item
37 property alias menuIcon: _menuIcon.source
38
39 // Property to store the menu status (selected or not selected)
40 property bool isSelected: false
41
42 // Property to show menu item count
43 property string menuCount: "0"
44
45 width: parent.width
46 height: tabletPortraitForm ? units.gu(10) : units.gu(8)
47
48 Rectangle {
49 id: _indicator
50
51 width: units.gu(0)
52 height: parent.height
53 color: UbuntuColors.orange
54 anchors {
55 left: parent.left
56 top: parent.top
57 bottom: parent.bottom
58 }
59
60 states: State {
61 name: "selected"
62 when: isSelected
63 PropertyChanges { target: _indicator; width: units.gu(1) }
64 }
65
66 transitions: Transition {
67 PropertyAnimation { target: _indicator; property: "width"; duration: UbuntuAnimation.FastDuration }
68 }
69 }
70
71 Layouts {
72 anchors.fill: parent
73 anchors.leftMargin: tabletPortraitForm ? units.gu(0) : units.gu(3)
74
75 layouts: [
76 ConditionalLayout {
77 name: "IconForm"
78 when: tabletPortraitForm
79
80 Column {
81 anchors.fill: parent
82 anchors.margins: units.gu(1.5)
83 spacing: units.gu(1)
84
85 ItemLayout {
86 item: "_menuIconItem"
87 width: units.gu(4)
88 height: units.gu(4)
89 anchors.horizontalCenter: parent.horizontalCenter
90
91 ItemLayout {
92 item: "menuCountItem"
93 width: units.gu(2.5)
94 height: units.gu(2.5)
95 anchors.top: parent.top
96 anchors.topMargin: -units.gu(0.5)
97 anchors.left: parent.right
98 anchors.leftMargin: units.gu(1)
99 }
100 }
101
102 ItemLayout {
103 item: "_menuLabelItem"
104 width: _menuLabel.width
105 height: _menuLabel.height
106 anchors.horizontalCenter: parent.horizontalCenter
107 }
108 }
109 }
110 ]
111
112 Row {
113 anchors.fill: parent
114 spacing: units.gu(2)
115
116 Image {
117 id: _menuIcon
118 Layouts.item: "_menuIconItem"
119 antialiasing: true
120 height: parent.height/2.5
121 fillMode: Image.PreserveAspectFit
122 anchors.verticalCenter: parent.verticalCenter
123 }
124
125 Label {
126 id: _menuLabel
127 Layouts.item: "_menuLabelItem"
128 width: units.gu(18)
129 anchors.verticalCenter: parent.verticalCenter
130 color: isSelected ? UbuntuColors.orange : "White"
131 text: tabletPortraitForm ? shortenedMenuLabel : menuLabel
132 horizontalAlignment: tabletPortraitForm ? Text.AlignHCenter : 0
133
134 }
135
136 Rectangle {
137 id: _menuCount
138 Layouts.item: "menuCountItem"
139 opacity: menuCount !== "0" ? 1 : 0
140 color: UbuntuColors.orange
141 width: units.gu(5)
142 height: units.gu(3)
143 radius: height
144 anchors.verticalCenter: parent.verticalCenter
145
146 Label {
147 anchors.centerIn: parent
148 text: menuCount
149 }
150 }
151 }
152
153
154 }
155}
0156
=== added file 'components/StatusIcons.qml'
--- components/StatusIcons.qml 1970-01-01 00:00:00 +0000
+++ components/StatusIcons.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,68 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import Ubuntu.Components 0.1
21
22/*
23 Component to show movie/show status icons such as watched status, watchlist, etc.
24 */
25Rectangle {
26 id: _statusIconsContainer
27
28 property real iconWidth: units.gu(2)
29 property bool showWatchedIcon: false
30 property bool showWatchListIcon: false
31
32 color: "black"
33 opacity: 0.7
34 smooth: true
35 z: parent.z + 1
36 radius: units.gu(0.5)
37 width: _iconColumn.width + units.gu(0.5)
38 height: showWatchedIcon || showWatchListIcon ? _iconColumn.height + units.gu(0.5) : 0
39
40 Column {
41 id: _iconColumn
42 anchors {
43 top: parent.top
44 left: parent.left
45 margins: units.gu(0.2)
46 }
47
48 spacing: units.gu(0.2)
49
50 Image {
51 id: _watchPic
52 source: Qt.resolvedUrl("../graphics/watched.png")
53 fillMode: Image.PreserveAspectFit
54 visible: showWatchedIcon
55 width: iconWidth
56 smooth: true
57 }
58
59 Image {
60 id: _watchListPic
61 source: Qt.resolvedUrl("../graphics/watchlist.png")
62 fillMode: Image.PreserveAspectFit
63 visible: showWatchListIcon
64 width: iconWidth
65 smooth: true
66 }
67 }
68}
069
=== added file 'components/TabletSidebar.qml'
--- components/TabletSidebar.qml 1970-01-01 00:00:00 +0000
+++ components/TabletSidebar.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,58 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import QtQuick.Layouts 1.1
21import Ubuntu.Components 0.1
22
23// Sidebar Component shown on the left side and can be used to house various options
24Rectangle {
25 id: sidebar
26
27 width: units.gu(0)
28 Layout.minimumWidth: units.gu(0)
29 Layout.maximumWidth: units.gu(0)
30
31 color: Qt.rgba(0,0,0,0.4)
32 anchors.top: parent.top
33 anchors.bottom: parent.bottom
34
35 states: [
36 State {
37 name: "IconForm"
38 when: tabletPortraitForm
39 PropertyChanges { target: sidebar; width: units.gu(15) }
40 PropertyChanges { target: sidebar; Layout.minimumWidth: units.gu(15) }
41 PropertyChanges { target: sidebar; Layout.maximumWidth: units.gu(15) }
42 },
43
44 State {
45 name: "FullForm"
46 when: tabletLandscapeForm
47 PropertyChanges { target: sidebar; width: units.gu(35) }
48 PropertyChanges { target: sidebar; Layout.minimumWidth: units.gu(35) }
49 PropertyChanges { target: sidebar; Layout.maximumWidth: units.gu(35) }
50 }
51 ]
52
53 transitions: Transition {
54 PropertyAnimation { target: sidebar; property: "width"; duration: UbuntuAnimation.FastDuration }
55 PropertyAnimation { target: sidebar; property: "Layout.minimumWidth"; duration: UbuntuAnimation.FastDuration }
56 PropertyAnimation { target: sidebar; property: "Layout.maximumWidth"; duration: UbuntuAnimation.FastDuration }
57 }
58}
059
=== added file 'components/Thumbnail.qml'
--- components/Thumbnail.qml 1970-01-01 00:00:00 +0000
+++ components/Thumbnail.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,41 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import Ubuntu.Components 0.1
21
22/*
23 Thumbnail wraps up an image in a ubuntu shape container.
24 */
25UbuntuShape {
26 id: carouselThumb
27
28 property alias thumbSource: thumbPic.source
29 radius: "medium"
30
31 image: Image {
32 id: thumbPic
33 fillMode: Image.PreserveAspectCrop
34 smooth: true
35 }
36
37 ActivityIndicator {
38 running: thumbPic.status != Image.Ready
39 anchors.centerIn: parent
40 }
41}
042
=== added file 'components/TraktAction.qml'
--- components/TraktAction.qml 1970-01-01 00:00:00 +0000
+++ components/TraktAction.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,28 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import Ubuntu.Components 0.1
21
22Action {
23 id: shareEpisodeAction
24 text: i18n.tr("Trakt")
25 keywords: i18n.tr("Trakt;Account;Watched;Seen;Share;Checkin;Social")
26 description: i18n.tr("Show Trakt Actions")
27 iconSource: Qt.resolvedUrl("../graphics/trakt.png")
28}
029
=== added file 'components/TraktPopup.qml'
--- components/TraktPopup.qml 1970-01-01 00:00:00 +0000
+++ components/TraktPopup.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,123 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import Ubuntu.Components 0.1
21import Ubuntu.Components.Popups 0.1
22import Ubuntu.Components.ListItems 0.1
23
24/*
25 Popup component to expose Trakt actions such as check-in, seen and configuring account.
26 */
27Popover {
28 id: popover
29
30 // Property to set the check-in message
31 property alias checkInMessage: _checkInAction.text
32
33 // Property to set the seen message
34 property alias seenMessage: _seenAction.text
35
36 // Property to set the watchlist message
37 property alias watchlistMessage: _watchlistAction.text
38
39 // Properties to set the visibility of the individual actions
40 property bool showConfigureAction: traktLogin.contents.status === "disabled"
41 property bool showCheckInAction: traktLogin.contents.status !== "disabled"
42 property bool showSeenAction: traktLogin.contents.status !== "disabled"
43 property bool showWatchlistAction: traktLogin.contents.status !== "disabled"
44 property bool showCommentAction: true
45
46 // Signal triggered when the checked-in action is triggered
47 signal checkedIn()
48
49 // Signal triggered when the watched action is triggered
50 signal watched()
51
52 // Signal triggered when the comments action is triggered
53 signal commented()
54
55 // Signal triggered when the watchlist action is triggered
56 signal watchlisted()
57
58 Column {
59 id: containerLayout
60 anchors {
61 left: parent.left
62 top: parent.top
63 right: parent.right
64 }
65
66 Standard {
67 id: _configureTraktAction
68 text: i18n.tr("Authenticate Trakt to perform \ncheck-ins, comment and rating.")
69 visible: showConfigureAction
70 iconSource: Qt.resolvedUrl("../graphics/trakt_logo.png")
71 onClicked: {
72 pagestack.push(Qt.resolvedUrl("../ui/Trakt.qml"))
73 PopupUtils.close(popover)
74 }
75 }
76
77 Standard {
78 id: _checkInAction
79 visible: showCheckInAction
80 iconSource: Qt.resolvedUrl("../graphics/checkmark_black.png")
81 iconFrame: false
82 onClicked: {
83 popover.checkedIn()
84 PopupUtils.close(popover)
85 }
86 }
87
88 Standard {
89 id: _watchlistAction
90 visible: showWatchlistAction
91 iconSource: Qt.resolvedUrl("../graphics/watchlist_black.png")
92 iconFrame: false
93 onClicked: {
94 popover.watchlisted()
95 PopupUtils.close(popover)
96 }
97 }
98
99 Standard {
100 id: _seenAction
101 visible: showSeenAction
102 iconSource: Qt.resolvedUrl("../graphics/watched_black.png")
103 iconFrame: false
104 onClicked: {
105 popover.watched()
106 PopupUtils.close(popover)
107 }
108 }
109
110 Standard {
111 id: _commentAction
112 visible: showCommentAction
113 iconSource: Qt.resolvedUrl("../graphics/comment.png")
114 text: traktLogin.contents.status !== "disabled" ? i18n.tr("View/Add comments") : i18n.tr("View comments")
115 iconFrame: false
116 onClicked: {
117 popover.commented()
118 PopupUtils.close(popover)
119 }
120 }
121 }
122}
123
0124
=== added file 'components/TraktRating.qml'
--- components/TraktRating.qml 1970-01-01 00:00:00 +0000
+++ components/TraktRating.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,56 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import Ubuntu.Components 0.1
21import "../components"
22
23Item {
24 id: ratings
25
26 property alias rating: _rating.label
27 property alias personal: _personalRating.label
28 property alias personalIcon: _personalRating.image
29
30 height: _overallRating.height
31
32 signal clicked()
33
34 Row {
35 id: _overallRating
36
37 spacing: units.gu(2)
38 anchors {
39 horizontalCenter: parent.horizontalCenter
40 verticalCenter: parent.verticalCenter
41 }
42
43 ImageLabel {
44 id: _rating
45 image: Qt.resolvedUrl("../graphics/star.png")
46 }
47
48 ImageLabel {
49 id: _personalRating
50 MouseArea {
51 anchors.fill: parent
52 onClicked: ratings.clicked()
53 }
54 }
55 }
56}
057
=== added directory 'debian'
=== renamed directory 'debian' => 'debian.moved'
=== added file 'debian/changelog'
--- debian/changelog 1970-01-01 00:00:00 +0000
+++ debian/changelog 2014-05-14 17:33:57 +0000
@@ -0,0 +1,27 @@
1flashback (0.4~alpha1) trusty; urgency=medium
2
3 [Nekhelesh Ramananthan]
4 * Fixed blurry actor placeholder image (LP: #1293787)
5 * Added placeholder text to the actors page biography if none are found (LP: #1292891)
6 * Made the ratings chooser opaque (LP: #1292884)
7 * Replace acting and production listview in actors page wth expandables (LP: #1292882)
8 * In the phone form factor, carousel now only shows 2 and 2/3rd cover art (LP: #1292878)
9
10 -- Nekhelesh Ramananthan <krnekhelesh@gmail.com> Sat, 22 Mar 2014 15:04:33 +0100
11
12flashback (0.3.2ubuntu1) trusty; urgency=medium
13
14 [Nekhelesh Ramananthan]
15 * Fixed debian packaing failnig due to missing flashback executable file
16
17 -- Nekhelesh Ramananthan <krnekhelesh@gmail.com> Mon, 17 Mar 2014 13:51:18 +0100
18
19flashback (0.3.2) trusty; urgency=medium
20
21 [Nekhelesh Ramananthan]
22 * Added walkthrough feature
23 * Added new home page search function
24 * Improved the visual of detail carousel corner radius
25 * Improved TV Show experience
26
27 -- Nekhelesh Ramananthan <krnekhelesh@gmail.com> Mon, 17 Mar 2014 09:43:01 +0100
028
=== added file 'debian/compat'
--- debian/compat 1970-01-01 00:00:00 +0000
+++ debian/compat 2014-05-14 17:33:57 +0000
@@ -0,0 +1,1 @@
19
02
=== added file 'debian/control'
--- debian/control 1970-01-01 00:00:00 +0000
+++ debian/control 2014-05-14 17:33:57 +0000
@@ -0,0 +1,23 @@
1Source: flashback
2Section: utils
3Priority: extra
4Maintainer: Nekhelesh Ramananthan <nik90@ubuntu.com>
5Build-Depends: debhelper (>= 9.0.0)
6Standards-Version: 3.9.5
7Homepage: http://launchpad.net/cliffhanger
8Vcs-Bzr: https://code.launchpad.net/~cliffhanger-dev/cliffhanger/trunk
9
10Package: flashback
11Architecture: all
12Depends: ${misc:Depends},
13 qtdeclarative5-hud1.0,
14 qtdeclarative5-qtquick2-plugin,
15 qtdeclarative5-ubuntu-ui-toolkit-plugin,
16 qtdeclarative5-u1db1.0,
17 qmlscene
18Description: Flashback application
19 Flashback is an entertainment application that helps you manage your movie
20 and TV show cravings. It integrates with Trakt and TMDB online services to
21 provide a variety of features such as discovering new movie, keeping track
22 of tv shows, adding movies and tv shows to your watchlist to watch later.
23
024
=== added file 'debian/copyright'
--- debian/copyright 1970-01-01 00:00:00 +0000
+++ debian/copyright 2014-05-14 17:33:57 +0000
@@ -0,0 +1,28 @@
1Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
2Upstream-Name: flashback
3Source: https://launchpad.net/cliffhanger
4
5Files: *
6Copyright: 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
7License: GPL-3.0
8
9Files: debian/*
10Copyright: 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
11License: GPL-3.0
12
13License: GPL-3.0
14 This program is free software: you can redistribute it and/or modify
15 it under the terms of the GNU General Public License as published by
16 the Free Software Foundation, either version 3 of the License, or
17 (at your option) any later version.
18 .
19 This package is distributed in the hope that it will be useful,
20 but WITHOUT ANY WARRANTY; without even the implied warranty of
21 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
22 GNU General Public License for more details.
23 .
24 You should have received a copy of the GNU General Public License
25 along with this program. If not, see <http://www.gnu.org/licenses/>.
26 .
27 On Debian systems, the complete text of the GNU General
28 Public License version 3 can be found in "/usr/share/common-licenses/GPL-3".
029
=== added file 'debian/install'
--- debian/install 1970-01-01 00:00:00 +0000
+++ debian/install 2014-05-14 17:33:57 +0000
@@ -0,0 +1,9 @@
1Flashback.desktop usr/share/applications/
2Flashback.qml usr/share/flashback/
3flashback.png usr/share/icons/hicolor/256x256/apps/
4backend usr/share/flashback/
5components usr/share/flashback/
6graphics usr/share/flashback/
7models usr/share/flashback/
8ui usr/share/flashback/
9walkthrough usr/share/flashback/
010
=== added file 'debian/rules'
--- debian/rules 1970-01-01 00:00:00 +0000
+++ debian/rules 2014-05-14 17:33:57 +0000
@@ -0,0 +1,7 @@
1#!/usr/bin/make -f
2# -*- makefile -*-
3# Uncomment this to turn on verbose mode.
4#export DH_VERBOSE=1
5
6%:
7 dh $@
08
=== added directory 'debian/source'
=== added file 'debian/source/format'
--- debian/source/format 1970-01-01 00:00:00 +0000
+++ debian/source/format 2014-05-14 17:33:57 +0000
@@ -0,0 +1,1 @@
13.0 (native)
02
=== added file 'design.jpg'
1Binary files design.jpg 1970-01-01 00:00:00 +0000 and design.jpg 2014-05-14 17:33:57 +0000 differ3Binary files design.jpg 1970-01-01 00:00:00 +0000 and design.jpg 2014-05-14 17:33:57 +0000 differ
=== renamed file 'design.jpg' => 'design.jpg.moved'
=== added file 'flashback.png'
2Binary files flashback.png 1970-01-01 00:00:00 +0000 and flashback.png 2014-05-14 17:33:57 +0000 differ4Binary files flashback.png 1970-01-01 00:00:00 +0000 and flashback.png 2014-05-14 17:33:57 +0000 differ
=== renamed file 'flashback.png' => 'flashback.png.moved'
=== added directory 'graphics'
=== renamed directory 'graphics' => 'graphics.moved'
=== added file 'graphics/add@8.png'
3Binary files graphics/add@8.png 1970-01-01 00:00:00 +0000 and graphics/add@8.png 2014-05-14 17:33:57 +0000 differ5Binary files graphics/add@8.png 1970-01-01 00:00:00 +0000 and graphics/add@8.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/arrow.png'
4Binary files graphics/arrow.png 1970-01-01 00:00:00 +0000 and graphics/arrow.png 2014-05-14 17:33:57 +0000 differ6Binary files graphics/arrow.png 1970-01-01 00:00:00 +0000 and graphics/arrow.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/author.jpg'
5Binary files graphics/author.jpg 1970-01-01 00:00:00 +0000 and graphics/author.jpg 2014-05-14 17:33:57 +0000 differ7Binary files graphics/author.jpg 1970-01-01 00:00:00 +0000 and graphics/author.jpg 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/bookmark.png'
6Binary files graphics/bookmark.png 1970-01-01 00:00:00 +0000 and graphics/bookmark.png 2014-05-14 17:33:57 +0000 differ8Binary files graphics/bookmark.png 1970-01-01 00:00:00 +0000 and graphics/bookmark.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/calendar.png'
7Binary files graphics/calendar.png 1970-01-01 00:00:00 +0000 and graphics/calendar.png 2014-05-14 17:33:57 +0000 differ9Binary files graphics/calendar.png 1970-01-01 00:00:00 +0000 and graphics/calendar.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/centerImage.png'
8Binary files graphics/centerImage.png 1970-01-01 00:00:00 +0000 and graphics/centerImage.png 2014-05-14 17:33:57 +0000 differ10Binary files graphics/centerImage.png 1970-01-01 00:00:00 +0000 and graphics/centerImage.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/checkmark.png'
9Binary files graphics/checkmark.png 1970-01-01 00:00:00 +0000 and graphics/checkmark.png 2014-05-14 17:33:57 +0000 differ11Binary files graphics/checkmark.png 1970-01-01 00:00:00 +0000 and graphics/checkmark.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/checkmark_black.png'
10Binary files graphics/checkmark_black.png 1970-01-01 00:00:00 +0000 and graphics/checkmark_black.png 2014-05-14 17:33:57 +0000 differ12Binary files graphics/checkmark_black.png 1970-01-01 00:00:00 +0000 and graphics/checkmark_black.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/close.png'
11Binary files graphics/close.png 1970-01-01 00:00:00 +0000 and graphics/close.png 2014-05-14 17:33:57 +0000 differ13Binary files graphics/close.png 1970-01-01 00:00:00 +0000 and graphics/close.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/comment.png'
12Binary files graphics/comment.png 1970-01-01 00:00:00 +0000 and graphics/comment.png 2014-05-14 17:33:57 +0000 differ14Binary files graphics/comment.png 1970-01-01 00:00:00 +0000 and graphics/comment.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/credits.png'
13Binary files graphics/credits.png 1970-01-01 00:00:00 +0000 and graphics/credits.png 2014-05-14 17:33:57 +0000 differ15Binary files graphics/credits.png 1970-01-01 00:00:00 +0000 and graphics/credits.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/designer.jpg'
14Binary files graphics/designer.jpg 1970-01-01 00:00:00 +0000 and graphics/designer.jpg 2014-05-14 17:33:57 +0000 differ16Binary files graphics/designer.jpg 1970-01-01 00:00:00 +0000 and graphics/designer.jpg 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/duration.png'
15Binary files graphics/duration.png 1970-01-01 00:00:00 +0000 and graphics/duration.png 2014-05-14 17:33:57 +0000 differ17Binary files graphics/duration.png 1970-01-01 00:00:00 +0000 and graphics/duration.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/email.png'
16Binary files graphics/email.png 1970-01-01 00:00:00 +0000 and graphics/email.png 2014-05-14 17:33:57 +0000 differ18Binary files graphics/email.png 1970-01-01 00:00:00 +0000 and graphics/email.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/error.png'
17Binary files graphics/error.png 1970-01-01 00:00:00 +0000 and graphics/error.png 2014-05-14 17:33:57 +0000 differ19Binary files graphics/error.png 1970-01-01 00:00:00 +0000 and graphics/error.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/facebook_logo.png'
18Binary files graphics/facebook_logo.png 1970-01-01 00:00:00 +0000 and graphics/facebook_logo.png 2014-05-14 17:33:57 +0000 differ20Binary files graphics/facebook_logo.png 1970-01-01 00:00:00 +0000 and graphics/facebook_logo.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/find@32.svg'
--- graphics/find@32.svg 1970-01-01 00:00:00 +0000
+++ graphics/find@32.svg 2014-05-14 17:33:57 +0000
@@ -0,0 +1,140 @@
1<?xml version="1.0" encoding="UTF-8" standalone="no"?>
2<!-- Created with Inkscape (http://www.inkscape.org/) -->
3
4<svg
5 xmlns:dc="http://purl.org/dc/elements/1.1/"
6 xmlns:cc="http://creativecommons.org/ns#"
7 xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
8 xmlns:svg="http://www.w3.org/2000/svg"
9 xmlns="http://www.w3.org/2000/svg"
10 xmlns:xlink="http://www.w3.org/1999/xlink"
11 xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
12 xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
13 width="90"
14 height="90.000015"
15 id="svg3133"
16 version="1.1"
17 inkscape:version="0.48.3.1 r9886"
18 sodipodi:docname="search@30.svg">
19 <defs
20 id="defs3135">
21 <linearGradient
22 inkscape:collect="always"
23 id="linearGradient3803">
24 <stop
25 style="stop-color:#e7e5e5;stop-opacity:1;"
26 offset="0"
27 id="stop3805" />
28 <stop
29 style="stop-color:#e2dfdf;stop-opacity:1"
30 offset="1"
31 id="stop3807" />
32 </linearGradient>
33 <linearGradient
34 inkscape:collect="always"
35 xlink:href="#linearGradient3803"
36 id="linearGradient3809"
37 x1="53.012165"
38 y1="-102.79017"
39 x2="53.012165"
40 y2="-66.661224"
41 gradientUnits="userSpaceOnUse" />
42 <linearGradient
43 inkscape:collect="always"
44 xlink:href="#linearGradient3803"
45 id="linearGradient3813"
46 gradientUnits="userSpaceOnUse"
47 x1="53.012165"
48 y1="-102.79017"
49 x2="53.012165"
50 y2="-66.661224"
51 gradientTransform="translate(-625,0)" />
52 </defs>
53 <sodipodi:namedview
54 id="base"
55 pagecolor="#ffffff"
56 bordercolor="#666666"
57 borderopacity="1.0"
58 inkscape:pageopacity="0.0"
59 inkscape:pageshadow="2"
60 inkscape:zoom="4.074536"
61 inkscape:cx="65.661925"
62 inkscape:cy="-9.5470961"
63 inkscape:document-units="px"
64 inkscape:current-layer="g3842"
65 showgrid="true"
66 inkscape:window-width="1920"
67 inkscape:window-height="1029"
68 inkscape:window-x="0"
69 inkscape:window-y="24"
70 inkscape:window-maximized="1"
71 inkscape:snap-grids="true"
72 inkscape:snap-global="true"
73 fit-margin-top="0"
74 fit-margin-left="0"
75 fit-margin-right="0"
76 fit-margin-bottom="0">
77 <inkscape:grid
78 type="xygrid"
79 id="grid3016"
80 empspacing="6"
81 visible="true"
82 enabled="true"
83 snapvisiblegridlinesonly="true"
84 originx="-2.98e-06px"
85 originy="2.6171874e-06px" />
86 </sodipodi:namedview>
87 <metadata
88 id="metadata3138">
89 <rdf:RDF>
90 <cc:Work
91 rdf:about="">
92 <dc:format>image/svg+xml</dc:format>
93 <dc:type
94 rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
95 <dc:title />
96 </cc:Work>
97 </rdf:RDF>
98 </metadata>
99 <g
100 inkscape:label="Layer 1"
101 inkscape:groupmode="layer"
102 id="layer1"
103 transform="translate(-2.98e-6,-962.36219)"
104 style="display:inline">
105 <g
106 transform="matrix(0.99934414,0,0,1,-106.92982,549.00002)"
107 id="g3842"
108 style="display:inline">
109 <rect
110 style="opacity:0.05;color:#000000;fill:none;stroke:none;stroke-width:2;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
111 id="rect3844"
112 width="90.059067"
113 height="90.000015"
114 x="107"
115 y="-503.36218"
116 transform="scale(1,-1)" />
117 <path
118 sodipodi:type="arc"
119 style="color:#000000;fill:none;stroke:#808080;stroke-width:9.49973201999999972;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
120 id="path2995"
121 sodipodi:cx="35.999996"
122 sodipodi:cy="36.500011"
123 sodipodi:rx="33"
124 sodipodi:ry="33.5"
125 d="m 68.999996,36.500011 a 33,33.5 0 1 1 -65.9999998,0 33,33.5 0 1 1 65.9999998,0 z"
126 transform="matrix(0.9551718,0,0,0.94029844,108.63744,415.04128)" />
127 <path
128 style="font-size:medium;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-indent:0;text-align:start;text-decoration:none;line-height:normal;letter-spacing:normal;word-spacing:normal;text-transform:none;direction:ltr;block-progression:tb;writing-mode:lr-tb;text-anchor:start;baseline-shift:baseline;color:#000000;fill:#808080;fill-opacity:1;stroke:none;stroke-width:6;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate;font-family:Sans;-inkscape-font-specification:Sans"
129 d="m 168.16512,470.23717 -4.25279,4.25 21.01378,21 4.25279,-4.25 -21.01378,-21 z"
130 id="path3765"
131 inkscape:connector-curvature="0" />
132 <path
133 style="font-size:medium;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-indent:0;text-align:start;text-decoration:none;line-height:normal;letter-spacing:normal;word-spacing:normal;text-transform:none;direction:ltr;block-progression:tb;writing-mode:lr-tb;text-anchor:start;baseline-shift:baseline;color:#000000;fill:#808080;fill-opacity:1;stroke:none;stroke-width:11.80387211;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate;font-family:Sans;-inkscape-font-specification:Sans"
134 d="m 175.96875,476.40625 c -2.32437,0.012 -4.57033,1.53501 -5.44162,3.68994 -0.87128,2.15492 -0.31496,4.81092 1.34787,6.43506 l 13.7996,13.79991 c 4.02735,4.27401 4.89575,3.69726 8.46955,0.1258 3.57381,-3.57146 4.15747,-4.18909 -0.1258,-8.46955 l -13.7996,-13.79991 c -1.10179,-1.12969 -2.672,-1.78779 -4.25,-1.78125 z"
135 id="path3767"
136 inkscape:connector-curvature="0"
137 sodipodi:nodetypes="cscczccc" />
138 </g>
139 </g>
140</svg>
0141
=== added file 'graphics/fusion.png'
1Binary files graphics/fusion.png 1970-01-01 00:00:00 +0000 and graphics/fusion.png 2014-05-14 17:33:57 +0000 differ142Binary files graphics/fusion.png 1970-01-01 00:00:00 +0000 and graphics/fusion.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/guide.png'
2Binary files graphics/guide.png 1970-01-01 00:00:00 +0000 and graphics/guide.png 2014-05-14 17:33:57 +0000 differ143Binary files graphics/guide.png 1970-01-01 00:00:00 +0000 and graphics/guide.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/heart-0.png'
3Binary files graphics/heart-0.png 1970-01-01 00:00:00 +0000 and graphics/heart-0.png 2014-05-14 17:33:57 +0000 differ144Binary files graphics/heart-0.png 1970-01-01 00:00:00 +0000 and graphics/heart-0.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/heart-1.png'
4Binary files graphics/heart-1.png 1970-01-01 00:00:00 +0000 and graphics/heart-1.png 2014-05-14 17:33:57 +0000 differ145Binary files graphics/heart-1.png 1970-01-01 00:00:00 +0000 and graphics/heart-1.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/heart-10.png'
5Binary files graphics/heart-10.png 1970-01-01 00:00:00 +0000 and graphics/heart-10.png 2014-05-14 17:33:57 +0000 differ146Binary files graphics/heart-10.png 1970-01-01 00:00:00 +0000 and graphics/heart-10.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/heart-2.png'
6Binary files graphics/heart-2.png 1970-01-01 00:00:00 +0000 and graphics/heart-2.png 2014-05-14 17:33:57 +0000 differ147Binary files graphics/heart-2.png 1970-01-01 00:00:00 +0000 and graphics/heart-2.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/heart-3.png'
7Binary files graphics/heart-3.png 1970-01-01 00:00:00 +0000 and graphics/heart-3.png 2014-05-14 17:33:57 +0000 differ148Binary files graphics/heart-3.png 1970-01-01 00:00:00 +0000 and graphics/heart-3.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/heart-4.png'
8Binary files graphics/heart-4.png 1970-01-01 00:00:00 +0000 and graphics/heart-4.png 2014-05-14 17:33:57 +0000 differ149Binary files graphics/heart-4.png 1970-01-01 00:00:00 +0000 and graphics/heart-4.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/heart-5.png'
9Binary files graphics/heart-5.png 1970-01-01 00:00:00 +0000 and graphics/heart-5.png 2014-05-14 17:33:57 +0000 differ150Binary files graphics/heart-5.png 1970-01-01 00:00:00 +0000 and graphics/heart-5.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/heart-6.png'
10Binary files graphics/heart-6.png 1970-01-01 00:00:00 +0000 and graphics/heart-6.png 2014-05-14 17:33:57 +0000 differ151Binary files graphics/heart-6.png 1970-01-01 00:00:00 +0000 and graphics/heart-6.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/heart-7.png'
11Binary files graphics/heart-7.png 1970-01-01 00:00:00 +0000 and graphics/heart-7.png 2014-05-14 17:33:57 +0000 differ152Binary files graphics/heart-7.png 1970-01-01 00:00:00 +0000 and graphics/heart-7.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/heart-8.png'
12Binary files graphics/heart-8.png 1970-01-01 00:00:00 +0000 and graphics/heart-8.png 2014-05-14 17:33:57 +0000 differ153Binary files graphics/heart-8.png 1970-01-01 00:00:00 +0000 and graphics/heart-8.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/heart-9.png'
13Binary files graphics/heart-9.png 1970-01-01 00:00:00 +0000 and graphics/heart-9.png 2014-05-14 17:33:57 +0000 differ154Binary files graphics/heart-9.png 1970-01-01 00:00:00 +0000 and graphics/heart-9.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/help.png'
14Binary files graphics/help.png 1970-01-01 00:00:00 +0000 and graphics/help.png 2014-05-14 17:33:57 +0000 differ155Binary files graphics/help.png 1970-01-01 00:00:00 +0000 and graphics/help.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/home.png'
15Binary files graphics/home.png 1970-01-01 00:00:00 +0000 and graphics/home.png 2014-05-14 17:33:57 +0000 differ156Binary files graphics/home.png 1970-01-01 00:00:00 +0000 and graphics/home.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/icon_designer.jpg'
16Binary files graphics/icon_designer.jpg 1970-01-01 00:00:00 +0000 and graphics/icon_designer.jpg 2014-05-14 17:33:57 +0000 differ157Binary files graphics/icon_designer.jpg 1970-01-01 00:00:00 +0000 and graphics/icon_designer.jpg 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/list.png'
17Binary files graphics/list.png 1970-01-01 00:00:00 +0000 and graphics/list.png 2014-05-14 17:33:57 +0000 differ158Binary files graphics/list.png 1970-01-01 00:00:00 +0000 and graphics/list.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/network.png'
18Binary files graphics/network.png 1970-01-01 00:00:00 +0000 and graphics/network.png 2014-05-14 17:33:57 +0000 differ159Binary files graphics/network.png 1970-01-01 00:00:00 +0000 and graphics/network.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/no-passport@8.png'
19Binary files graphics/no-passport@8.png 1970-01-01 00:00:00 +0000 and graphics/no-passport@8.png 2014-05-14 17:33:57 +0000 differ160Binary files graphics/no-passport@8.png 1970-01-01 00:00:00 +0000 and graphics/no-passport@8.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/no-poster.jpg'
20Binary files graphics/no-poster.jpg 1970-01-01 00:00:00 +0000 and graphics/no-poster.jpg 2014-05-14 17:33:57 +0000 differ161Binary files graphics/no-poster.jpg 1970-01-01 00:00:00 +0000 and graphics/no-poster.jpg 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/now_playing@48.png'
21Binary files graphics/now_playing@48.png 1970-01-01 00:00:00 +0000 and graphics/now_playing@48.png 2014-05-14 17:33:57 +0000 differ162Binary files graphics/now_playing@48.png 1970-01-01 00:00:00 +0000 and graphics/now_playing@48.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/password.png'
22Binary files graphics/password.png 1970-01-01 00:00:00 +0000 and graphics/password.png 2014-05-14 17:33:57 +0000 differ163Binary files graphics/password.png 1970-01-01 00:00:00 +0000 and graphics/password.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/play@32.svg'
--- graphics/play@32.svg 1970-01-01 00:00:00 +0000
+++ graphics/play@32.svg 2014-05-14 17:33:57 +0000
@@ -0,0 +1,98 @@
1<?xml version="1.0" encoding="UTF-8" standalone="no"?>
2<!-- Created with Inkscape (http://www.inkscape.org/) -->
3
4<svg
5 xmlns:dc="http://purl.org/dc/elements/1.1/"
6 xmlns:cc="http://creativecommons.org/ns#"
7 xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
8 xmlns:svg="http://www.w3.org/2000/svg"
9 xmlns="http://www.w3.org/2000/svg"
10 xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
11 xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
12 width="90"
13 height="90"
14 id="svg3747"
15 version="1.1"
16 inkscape:version="0.48.3.1 r9886"
17 sodipodi:docname="media-play@30.svg">
18 <defs
19 id="defs3749" />
20 <sodipodi:namedview
21 id="base"
22 pagecolor="#ffffff"
23 bordercolor="#666666"
24 borderopacity="1.0"
25 inkscape:pageopacity="0.0"
26 inkscape:pageshadow="2"
27 inkscape:zoom="3.259629"
28 inkscape:cx="64.301793"
29 inkscape:cy="-13.007581"
30 inkscape:document-units="px"
31 inkscape:current-layer="g4171"
32 showgrid="true"
33 fit-margin-top="0"
34 fit-margin-left="0"
35 fit-margin-right="0"
36 fit-margin-bottom="0"
37 inkscape:window-width="1920"
38 inkscape:window-height="1029"
39 inkscape:window-x="0"
40 inkscape:window-y="24"
41 inkscape:window-maximized="1">
42 <inkscape:grid
43 type="xygrid"
44 id="grid3012"
45 empspacing="6"
46 visible="true"
47 enabled="true"
48 snapvisiblegridlinesonly="true"
49 originx="0px"
50 originy="1.3134766e-05px" />
51 </sodipodi:namedview>
52 <metadata
53 id="metadata3752">
54 <rdf:RDF>
55 <cc:Work
56 rdf:about="">
57 <dc:format>image/svg+xml</dc:format>
58 <dc:type
59 rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
60 <dc:title />
61 </cc:Work>
62 </rdf:RDF>
63 </metadata>
64 <g
65 inkscape:label="Layer 1"
66 inkscape:groupmode="layer"
67 id="layer1"
68 transform="translate(-144,-962.36221)">
69 <g
70 transform="translate(-198,611)"
71 id="g4171">
72 <path
73 sodipodi:type="star"
74 style="color:#000000;fill:#808080;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:3;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
75 id="path4984"
76 sodipodi:sides="3"
77 sodipodi:cx="111"
78 sodipodi:cy="174.09448"
79 sodipodi:r1="5.8309517"
80 sodipodi:r2="2.9154758"
81 sodipodi:arg1="1.0471976"
82 sodipodi:arg2="2.0943951"
83 inkscape:flatsided="true"
84 inkscape:rounded="0.06"
85 inkscape:randomized="0"
86 d="m 113.91548,179.14423 c -0.52479,0.30299 -8.74643,-4.44378 -8.74643,-5.04975 0,-0.60597 8.22164,-5.35273 8.74643,-5.04975 0.52478,0.30299 0.52478,9.79652 0,10.0995 z"
87 transform="matrix(-5.9080854,0,0,5.9245853,1038.3477,-635.0754)"
88 inkscape:transform-center-x="-5.7056976" />
89 <rect
90 style="color:#000000;fill:none;stroke:none;stroke-width:4;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
91 id="rect2986"
92 width="90"
93 height="90"
94 x="342"
95 y="351.36221" />
96 </g>
97 </g>
98</svg>
099
=== added file 'graphics/rating@8.png'
1Binary files graphics/rating@8.png 1970-01-01 00:00:00 +0000 and graphics/rating@8.png 2014-05-14 17:33:57 +0000 differ100Binary files graphics/rating@8.png 1970-01-01 00:00:00 +0000 and graphics/rating@8.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/recommended@48.png'
2Binary files graphics/recommended@48.png 1970-01-01 00:00:00 +0000 and graphics/recommended@48.png 2014-05-14 17:33:57 +0000 differ101Binary files graphics/recommended@48.png 1970-01-01 00:00:00 +0000 and graphics/recommended@48.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/search_icon@8.svg'
--- graphics/search_icon@8.svg 1970-01-01 00:00:00 +0000
+++ graphics/search_icon@8.svg 2014-05-14 17:33:57 +0000
@@ -0,0 +1,153 @@
1<?xml version="1.0" encoding="UTF-8" standalone="no"?>
2<!-- Created with Inkscape (http://www.inkscape.org/) -->
3
4<svg
5 xmlns:dc="http://purl.org/dc/elements/1.1/"
6 xmlns:cc="http://creativecommons.org/ns#"
7 xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
8 xmlns:svg="http://www.w3.org/2000/svg"
9 xmlns="http://www.w3.org/2000/svg"
10 xmlns:xlink="http://www.w3.org/1999/xlink"
11 xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
12 xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
13 width="32"
14 height="32"
15 id="svg3133"
16 version="1.1"
17 inkscape:version="0.48.4 r9939"
18 sodipodi:docname="search.svg">
19 <defs
20 id="defs3135">
21 <linearGradient
22 inkscape:collect="always"
23 id="linearGradient3803">
24 <stop
25 style="stop-color:#e7e5e5;stop-opacity:1;"
26 offset="0"
27 id="stop3805" />
28 <stop
29 style="stop-color:#e2dfdf;stop-opacity:1"
30 offset="1"
31 id="stop3807" />
32 </linearGradient>
33 <linearGradient
34 inkscape:collect="always"
35 xlink:href="#linearGradient3803"
36 id="linearGradient3809"
37 x1="53.012165"
38 y1="-102.79017"
39 x2="53.012165"
40 y2="-66.661224"
41 gradientUnits="userSpaceOnUse" />
42 <linearGradient
43 inkscape:collect="always"
44 xlink:href="#linearGradient3803"
45 id="linearGradient3813"
46 gradientUnits="userSpaceOnUse"
47 x1="53.012165"
48 y1="-102.79017"
49 x2="53.012165"
50 y2="-66.661224"
51 gradientTransform="translate(-625,0)" />
52 </defs>
53 <sodipodi:namedview
54 id="base"
55 pagecolor="#ffffff"
56 bordercolor="#666666"
57 borderopacity="1.0"
58 inkscape:pageopacity="0.0"
59 inkscape:pageshadow="2"
60 inkscape:zoom="11.313708"
61 inkscape:cx="27.957393"
62 inkscape:cy="7.2819708"
63 inkscape:document-units="px"
64 inkscape:current-layer="g3842"
65 showgrid="true"
66 inkscape:window-width="1855"
67 inkscape:window-height="1056"
68 inkscape:window-x="65"
69 inkscape:window-y="24"
70 inkscape:window-maximized="1"
71 inkscape:snap-grids="true"
72 inkscape:snap-global="true"
73 fit-margin-top="0"
74 fit-margin-left="0"
75 fit-margin-right="0"
76 fit-margin-bottom="0"
77 inkscape:snap-bbox="true"
78 inkscape:bbox-paths="true"
79 inkscape:bbox-nodes="true"
80 inkscape:snap-bbox-edge-midpoints="true"
81 inkscape:snap-bbox-midpoints="true"
82 inkscape:object-paths="true"
83 inkscape:snap-intersection-paths="true"
84 inkscape:snap-midpoints="true"
85 inkscape:snap-smooth-nodes="true"
86 inkscape:object-nodes="true"
87 inkscape:snap-object-midpoints="true"
88 inkscape:snap-center="true">
89 <inkscape:grid
90 type="xygrid"
91 id="grid3016"
92 empspacing="6"
93 visible="true"
94 enabled="true"
95 snapvisiblegridlinesonly="true"
96 originx="-2.98e-06px"
97 originy="2.6171874e-06px" />
98 </sodipodi:namedview>
99 <metadata
100 id="metadata3138">
101 <rdf:RDF>
102 <cc:Work
103 rdf:about="">
104 <dc:format>image/svg+xml</dc:format>
105 <dc:type
106 rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
107 <dc:title></dc:title>
108 </cc:Work>
109 </rdf:RDF>
110 </metadata>
111 <g
112 inkscape:label="Layer 1"
113 inkscape:groupmode="layer"
114 id="layer1"
115 transform="translate(-2.98e-6,-1020.3622)"
116 style="display:inline">
117 <g
118 transform="matrix(0.99934414,0,0,1,-106.92982,549.00002)"
119 id="g3842"
120 style="display:inline">
121 <rect
122 style="opacity:0.05;color:#000000;fill:none;stroke:none;stroke-width:2;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
123 id="rect3844"
124 width="32.021008"
125 height="32.000011"
126 x="107"
127 y="-503.36218"
128 transform="scale(1,-1)" />
129 <path
130 sodipodi:type="arc"
131 style="color:#000000;fill:none;stroke:#808080;stroke-width:10.49972248;stroke-miterlimit:4;stroke-dasharray:none;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
132 id="path2995"
133 sodipodi:cx="35.999996"
134 sodipodi:cy="36.500011"
135 sodipodi:rx="33"
136 sodipodi:ry="33.5"
137 d="m 68.999996,36.500011 a 33,33.5 0 1 1 -65.9999998,0 33,33.5 0 1 1 65.9999998,0 z"
138 transform="matrix(0.30695569,0,0,0.30279797,111.9601,476.31005)" />
139 <path
140 style="font-size:xx-small;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-indent:0;text-align:start;text-decoration:none;line-height:normal;letter-spacing:normal;word-spacing:normal;text-transform:none;direction:ltr;block-progression:tb;writing-mode:lr-tb;text-anchor:start;baseline-shift:baseline;color:#000000;fill:#808080;fill-opacity:1;stroke:none;stroke-width:6;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate;font-family:Sans;-inkscape-font-specification:Sans"
141 d="m 131.23812,494.07329 -1.51211,1.51111 4.26947,4.26666 1.5121,-1.5111 z"
142 id="path3765"
143 inkscape:connector-curvature="0"
144 sodipodi:nodetypes="ccccc" />
145 <path
146 style="font-size:xx-small;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-indent:0;text-align:start;text-decoration:none;line-height:normal;letter-spacing:normal;word-spacing:normal;text-transform:none;direction:ltr;block-progression:tb;writing-mode:lr-tb;text-anchor:start;baseline-shift:baseline;color:#000000;fill:#808080;fill-opacity:1;stroke:none;stroke-width:11.80387211;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate;font-family:Sans;-inkscape-font-specification:Sans"
147 d="m 133.30117,495.55563 c -0.82645,0.004 -1.62501,0.54578 -1.9348,1.31198 -0.30979,0.7662 -0.11199,1.71055 0.47924,2.28802 l 3.12758,3.12885 c 1.43195,1.51965 1.74071,1.31459 3.0114,0.0447 1.27069,-1.26986 1.47821,-1.48946 -0.0447,-3.01141 l -3.12758,-3.12885 c -0.39175,-0.40166 -0.95004,-0.63566 -1.51111,-0.63333 z"
148 id="path3767"
149 inkscape:connector-curvature="0"
150 sodipodi:nodetypes="cscczccc" />
151 </g>
152 </g>
153</svg>
0154
=== added file 'graphics/settings@32.svg'
--- graphics/settings@32.svg 1970-01-01 00:00:00 +0000
+++ graphics/settings@32.svg 2014-05-14 17:33:57 +0000
@@ -0,0 +1,138 @@
1<?xml version="1.0" encoding="UTF-8" standalone="no"?>
2<!-- Created with Inkscape (http://www.inkscape.org/) -->
3
4<svg
5 xmlns:dc="http://purl.org/dc/elements/1.1/"
6 xmlns:cc="http://creativecommons.org/ns#"
7 xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
8 xmlns:svg="http://www.w3.org/2000/svg"
9 xmlns="http://www.w3.org/2000/svg"
10 xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
11 xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
12 width="90"
13 height="90"
14 id="svg3133"
15 version="1.1"
16 inkscape:version="0.48.3.1 r9886"
17 sodipodi:docname="settings@30.svg">
18 <defs
19 id="defs3135" />
20 <sodipodi:namedview
21 id="base"
22 pagecolor="#ffffff"
23 bordercolor="#666666"
24 borderopacity="1.0"
25 inkscape:pageopacity="0.0"
26 inkscape:pageshadow="2"
27 inkscape:zoom="6.3664628"
28 inkscape:cx="93.340685"
29 inkscape:cy="27.377839"
30 inkscape:document-units="px"
31 inkscape:current-layer="g4674"
32 showgrid="true"
33 inkscape:window-width="1920"
34 inkscape:window-height="1029"
35 inkscape:window-x="0"
36 inkscape:window-y="24"
37 inkscape:window-maximized="1"
38 fit-margin-top="0"
39 fit-margin-left="0"
40 fit-margin-right="0"
41 fit-margin-bottom="0"
42 showguides="true"
43 inkscape:guide-bbox="true">
44 <inkscape:grid
45 type="xygrid"
46 id="grid2992"
47 empspacing="6"
48 visible="true"
49 enabled="true"
50 snapvisiblegridlinesonly="true"
51 originx="4.2039363e-07px"
52 originy="0px" />
53 <sodipodi:guide
54 orientation="1,0"
55 position="45,11"
56 id="guide3763" />
57 <sodipodi:guide
58 orientation="0,1"
59 position="48,45"
60 id="guide3765" />
61 </sodipodi:namedview>
62 <metadata
63 id="metadata3138">
64 <rdf:RDF>
65 <cc:Work
66 rdf:about="">
67 <dc:format>image/svg+xml</dc:format>
68 <dc:type
69 rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
70 <dc:title />
71 </cc:Work>
72 </rdf:RDF>
73 </metadata>
74 <g
75 inkscape:label="Layer 1"
76 inkscape:groupmode="layer"
77 id="layer1"
78 transform="translate(4.2039363e-7,-962.3622)">
79 <g
80 id="g4978"
81 transform="matrix(0.99934414,0,0,1,-106.92982,549.00002)">
82 <g
83 id="g4674"
84 transform="matrix(1.0006563,0,0,1,-155.17195,-2.6171874e-6)">
85 <rect
86 y="431.36218"
87 x="262"
88 height="72"
89 width="72"
90 id="rect4869"
91 style="opacity:0.01000001;color:#000000;fill:none;stroke:none;stroke-width:2;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate" />
92 <path
93 style="color:#000000;fill:#808080;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:3;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
94 d="m 320.5,419.36218 c 6.5,0 7.49965,0 7.49979,7 l 2.1e-4,10 c 1.5e-4,7 -1,7 -7.5,7 -6.5,0 -7.50015,0 -7.5,-7 l 2.1e-4,-9.99997 c 1.4e-4,-7.00003 0.99979,-7.00003 7.49979,-7.00003 z"
95 id="rect4871"
96 inkscape:connector-curvature="0"
97 sodipodi:nodetypes="zsszssz" />
98 <path
99 style="color:#000000;fill:#808080;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:3;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
100 d="m 262,428.36218 0,6 45,0 0,-6 z m 72,0 0,6 18,0 0,-6 z"
101 id="rect4882"
102 inkscape:connector-curvature="0"
103 sodipodi:nodetypes="cccccccccc" />
104 <path
105 id="path4887"
106 d="m 262,455.36218 0,6 18,0 0,-6 z m 45,0 0,6 45,0 0,-6 z"
107 style="color:#000000;fill:#808080;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:3;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
108 inkscape:connector-curvature="0"
109 sodipodi:nodetypes="cccccccccc" />
110 <path
111 sodipodi:nodetypes="cccccccccc"
112 inkscape:connector-curvature="0"
113 style="color:#000000;fill:#808080;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:3;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
114 d="m 262,482.36218 0,6 45,0 0,-6 z m 72,0 0,6 18,0 0,-6 z"
115 id="path4889" />
116 <rect
117 y="413.36218"
118 x="262"
119 height="90"
120 width="90"
121 id="rect2993"
122 style="color:#000000;fill:none;stroke:none;stroke-width:11.80000019;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate" />
123 <path
124 sodipodi:nodetypes="zsszssz"
125 inkscape:connector-curvature="0"
126 id="path3775"
127 d="m 293.5,446.36218 c 6.5,0 7.49965,0 7.49979,7 l 2.1e-4,10 c 1.5e-4,7 -1,7 -7.5,7 -6.5,0 -7.50015,0 -7.5,-7 l 2.1e-4,-9.99997 c 1.4e-4,-7.00003 0.99979,-7.00003 7.49979,-7.00003 z"
128 style="color:#000000;fill:#808080;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:3;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate" />
129 <path
130 style="color:#000000;fill:#808080;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:3;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
131 d="m 320.5,473.36218 c 6.5,0 7.49965,0 7.49979,7 l 2.1e-4,10 c 1.5e-4,7 -1,7 -7.5,7 -6.5,0 -7.50015,0 -7.5,-7 l 2.1e-4,-9.99997 c 1.4e-4,-7.00003 0.99979,-7.00003 7.49979,-7.00003 z"
132 id="path3777"
133 inkscape:connector-curvature="0"
134 sodipodi:nodetypes="zsszssz" />
135 </g>
136 </g>
137 </g>
138</svg>
0139
=== added file 'graphics/share.png'
1Binary files graphics/share.png 1970-01-01 00:00:00 +0000 and graphics/share.png 2014-05-14 17:33:57 +0000 differ140Binary files graphics/share.png 1970-01-01 00:00:00 +0000 and graphics/share.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/share@32.svg'
--- graphics/share@32.svg 1970-01-01 00:00:00 +0000
+++ graphics/share@32.svg 2014-05-14 17:33:57 +0000
@@ -0,0 +1,96 @@
1<?xml version="1.0" encoding="UTF-8" standalone="no"?>
2<!-- Created with Inkscape (http://www.inkscape.org/) -->
3
4<svg
5 xmlns:dc="http://purl.org/dc/elements/1.1/"
6 xmlns:cc="http://creativecommons.org/ns#"
7 xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
8 xmlns:svg="http://www.w3.org/2000/svg"
9 xmlns="http://www.w3.org/2000/svg"
10 xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
11 xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
12 width="90"
13 height="90"
14 id="svg3140"
15 version="1.1"
16 inkscape:version="0.48.3.1 r9886"
17 sodipodi:docname="share@30.svg">
18 <defs
19 id="defs3142" />
20 <sodipodi:namedview
21 id="base"
22 pagecolor="#ffffff"
23 bordercolor="#666666"
24 borderopacity="1.0"
25 inkscape:pageopacity="0.0"
26 inkscape:pageshadow="2"
27 inkscape:zoom="6.3664629"
28 inkscape:cx="42.15056"
29 inkscape:cy="44.663717"
30 inkscape:document-units="px"
31 inkscape:current-layer="g3441-4"
32 showgrid="true"
33 inkscape:window-width="1920"
34 inkscape:window-height="1029"
35 inkscape:window-x="0"
36 inkscape:window-y="24"
37 inkscape:window-maximized="1"
38 inkscape:snap-global="true"
39 fit-margin-top="0"
40 fit-margin-left="0"
41 fit-margin-right="0"
42 fit-margin-bottom="0">
43 <inkscape:grid
44 type="xygrid"
45 id="grid3178"
46 empspacing="6"
47 visible="true"
48 enabled="true"
49 snapvisiblegridlinesonly="true"
50 originx="0px"
51 originy="-1.7382813e-05px" />
52 </sodipodi:namedview>
53 <metadata
54 id="metadata3145">
55 <rdf:RDF>
56 <cc:Work
57 rdf:about="">
58 <dc:format>image/svg+xml</dc:format>
59 <dc:type
60 rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
61 <dc:title />
62 </cc:Work>
63 </rdf:RDF>
64 </metadata>
65 <g
66 inkscape:label="Layer 1"
67 inkscape:groupmode="layer"
68 id="layer1"
69 transform="translate(0,-962.36218)">
70 <g
71 id="g4978"
72 transform="translate(-60,548.00002)">
73 <g
74 style="display:inline"
75 inkscape:label="Layer 1"
76 id="g3441-4"
77 transform="matrix(0.99999833,0,0,1,60,-548.00002)">
78 <path
79 sodipodi:type="inkscape:offset"
80 inkscape:radius="-0.31838349"
81 inkscape:original="M 24.5 1017.375 C 21.683495 1017.386 19.129252 1019.8328 19.15625 1022.6875 C 19.10523 1024.7025 18.477924 1026.8931 16.6875 1028.0312 C 14.928548 1029.3646 12.623753 1028.7898 10.59375 1028.875 C 8.0503952 1029.1104 6.0137365 1031.4714 5.875 1033.9375 C 5.5443658 1036.9979 8.260099 1040.0778 11.40625 1039.875 C 13.365705 1039.7298 15.622444 1039.6396 17.15625 1041.0938 C 18.814084 1042.3961 19.09263 1044.5982 19.21875 1046.5625 C 19.461671 1049.9937 23.46779 1052.2857 26.59375 1051 C 29.575663 1049.9779 31.072138 1046.1852 29.59375 1043.4062 C 28.600866 1041.3589 26.30781 1040.0344 24.03125 1040.3438 C 22.04021 1040.5857 19.786406 1040.2924 18.40625 1038.6875 C 16.702625 1036.8125 16.61443 1033.9255 17.40625 1031.625 C 18.25454 1029.3292 20.800946 1027.9984 23.1875 1028.3125 C 24.95755 1028.5278 26.909137 1028.3777 28.25 1027.0625 C 30.728542 1025.0571 30.788794 1020.8982 28.375 1018.8125 C 27.334787 1017.8485 25.916691 1017.3405 24.5 1017.375 z "
82 style="color:#000000;fill:#808080;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
83 id="path2991"
84 d="m 24.5,1017.6875 c -2.632867,0.01 -5.056436,2.3369 -5.03125,5 -0.05219,2.0614 -0.70521,4.3682 -2.59375,5.5937 -0.01213,0.01 -0.01908,0.022 -0.03125,0.031 -0.941881,0.6982 -2.026015,0.9033 -3.09375,0.9375 -1.07083,0.034 -2.152687,-0.1001 -3.125,-0.062 -0.0097,4e-4 -0.02155,-4e-4 -0.03125,0 -2.3505987,0.2351 -4.2772414,2.4881 -4.40625,4.7813 -0.3081864,2.8526 2.2595836,5.7824 5.1875,5.5937 1.954564,-0.1448 4.318532,-0.252 5.96875,1.2813 0.01112,0.01 0.0202,0.021 0.03125,0.031 1.748744,1.4022 2.030053,3.6908 2.15625,5.6562 0.226212,3.1952 4.023145,5.3862 6.9375,4.1876 a 0.31841532,0.31841532 0 0 1 0.03125,-0.031 c 2.784288,-0.9544 4.192635,-4.5307 2.8125,-7.125 a 0.31841532,0.31841532 0 0 1 0,-0.031 c -0.932425,-1.9226 -3.121855,-3.1642 -5.25,-2.875 -2.050184,0.2491 -4.426871,-0.03 -5.90625,-1.75 -1.809332,-1.9913 -1.883366,-4.9901 -1.0625,-7.375 a 0.31841532,0.31841532 0 0 1 0,-0.031 c 0.906221,-2.4526 3.594049,-3.8331 6.125,-3.5 1.724598,0.2098 3.573245,0.059 4.8125,-1.1562 a 0.31841532,0.31841532 0 0 1 0.03125,-0.031 c 2.31317,-1.8716 2.347131,-5.8029 0.09375,-7.75 a 0.31841532,0.31841532 0 0 1 0,-0.031 c -0.975302,-0.9038 -2.320772,-1.3762 -3.65625,-1.3437 z"
85 transform="matrix(2.5495252,0,0,2.5175823,-0.90522399,-1596.7459)" />
86 <rect
87 style="opacity:0.1;color:#000000;fill:none;stroke:none;stroke-width:4;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
88 id="rect2988"
89 width="90.000153"
90 height="90"
91 x="0"
92 y="962.36218" />
93 </g>
94 </g>
95 </g>
96</svg>
097
=== added file 'graphics/smile.png'
1Binary files graphics/smile.png 1970-01-01 00:00:00 +0000 and graphics/smile.png 2014-05-14 17:33:57 +0000 differ98Binary files graphics/smile.png 1970-01-01 00:00:00 +0000 and graphics/smile.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/spoiler.png'
2Binary files graphics/spoiler.png 1970-01-01 00:00:00 +0000 and graphics/spoiler.png 2014-05-14 17:33:57 +0000 differ99Binary files graphics/spoiler.png 1970-01-01 00:00:00 +0000 and graphics/spoiler.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/star.png'
3Binary files graphics/star.png 1970-01-01 00:00:00 +0000 and graphics/star.png 2014-05-14 17:33:57 +0000 differ100Binary files graphics/star.png 1970-01-01 00:00:00 +0000 and graphics/star.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/time@64.png'
4Binary files graphics/time@64.png 1970-01-01 00:00:00 +0000 and graphics/time@64.png 2014-05-14 17:33:57 +0000 differ101Binary files graphics/time@64.png 1970-01-01 00:00:00 +0000 and graphics/time@64.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/tmdb.png'
5Binary files graphics/tmdb.png 1970-01-01 00:00:00 +0000 and graphics/tmdb.png 2014-05-14 17:33:57 +0000 differ102Binary files graphics/tmdb.png 1970-01-01 00:00:00 +0000 and graphics/tmdb.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/today_sidebar@48.png'
6Binary files graphics/today_sidebar@48.png 1970-01-01 00:00:00 +0000 and graphics/today_sidebar@48.png 2014-05-14 17:33:57 +0000 differ103Binary files graphics/today_sidebar@48.png 1970-01-01 00:00:00 +0000 and graphics/today_sidebar@48.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/top_rated@48.png'
7Binary files graphics/top_rated@48.png 1970-01-01 00:00:00 +0000 and graphics/top_rated@48.png 2014-05-14 17:33:57 +0000 differ104Binary files graphics/top_rated@48.png 1970-01-01 00:00:00 +0000 and graphics/top_rated@48.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/trailer.png'
8Binary files graphics/trailer.png 1970-01-01 00:00:00 +0000 and graphics/trailer.png 2014-05-14 17:33:57 +0000 differ105Binary files graphics/trailer.png 1970-01-01 00:00:00 +0000 and graphics/trailer.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/trailer2.png'
9Binary files graphics/trailer2.png 1970-01-01 00:00:00 +0000 and graphics/trailer2.png 2014-05-14 17:33:57 +0000 differ106Binary files graphics/trailer2.png 1970-01-01 00:00:00 +0000 and graphics/trailer2.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/trakt@16.png'
10Binary files graphics/trakt@16.png 1970-01-01 00:00:00 +0000 and graphics/trakt@16.png 2014-05-14 17:33:57 +0000 differ107Binary files graphics/trakt@16.png 1970-01-01 00:00:00 +0000 and graphics/trakt@16.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/trakt_logo.png'
11Binary files graphics/trakt_logo.png 1970-01-01 00:00:00 +0000 and graphics/trakt_logo.png 2014-05-14 17:33:57 +0000 differ108Binary files graphics/trakt_logo.png 1970-01-01 00:00:00 +0000 and graphics/trakt_logo.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/trending_icon@48.png'
12Binary files graphics/trending_icon@48.png 1970-01-01 00:00:00 +0000 and graphics/trending_icon@48.png 2014-05-14 17:33:57 +0000 differ109Binary files graphics/trending_icon@48.png 1970-01-01 00:00:00 +0000 and graphics/trending_icon@48.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/twitter_logo.png'
13Binary files graphics/twitter_logo.png 1970-01-01 00:00:00 +0000 and graphics/twitter_logo.png 2014-05-14 17:33:57 +0000 differ110Binary files graphics/twitter_logo.png 1970-01-01 00:00:00 +0000 and graphics/twitter_logo.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/unwatched_gray.png'
14Binary files graphics/unwatched_gray.png 1970-01-01 00:00:00 +0000 and graphics/unwatched_gray.png 2014-05-14 17:33:57 +0000 differ111Binary files graphics/unwatched_gray.png 1970-01-01 00:00:00 +0000 and graphics/unwatched_gray.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/unwatched_sidebar@48.png'
15Binary files graphics/unwatched_sidebar@48.png 1970-01-01 00:00:00 +0000 and graphics/unwatched_sidebar@48.png 2014-05-14 17:33:57 +0000 differ112Binary files graphics/unwatched_sidebar@48.png 1970-01-01 00:00:00 +0000 and graphics/unwatched_sidebar@48.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/upcoming@48.png'
16Binary files graphics/upcoming@48.png 1970-01-01 00:00:00 +0000 and graphics/upcoming@48.png 2014-05-14 17:33:57 +0000 differ113Binary files graphics/upcoming@48.png 1970-01-01 00:00:00 +0000 and graphics/upcoming@48.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/user.png'
17Binary files graphics/user.png 1970-01-01 00:00:00 +0000 and graphics/user.png 2014-05-14 17:33:57 +0000 differ114Binary files graphics/user.png 1970-01-01 00:00:00 +0000 and graphics/user.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/votedown.png'
18Binary files graphics/votedown.png 1970-01-01 00:00:00 +0000 and graphics/votedown.png 2014-05-14 17:33:57 +0000 differ115Binary files graphics/votedown.png 1970-01-01 00:00:00 +0000 and graphics/votedown.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/voteup.png'
19Binary files graphics/voteup.png 1970-01-01 00:00:00 +0000 and graphics/voteup.png 2014-05-14 17:33:57 +0000 differ116Binary files graphics/voteup.png 1970-01-01 00:00:00 +0000 and graphics/voteup.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/watched.png'
20Binary files graphics/watched.png 1970-01-01 00:00:00 +0000 and graphics/watched.png 2014-05-14 17:33:57 +0000 differ117Binary files graphics/watched.png 1970-01-01 00:00:00 +0000 and graphics/watched.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/watched_black.png'
21Binary files graphics/watched_black.png 1970-01-01 00:00:00 +0000 and graphics/watched_black.png 2014-05-14 17:33:57 +0000 differ118Binary files graphics/watched_black.png 1970-01-01 00:00:00 +0000 and graphics/watched_black.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/watched_gray.png'
22Binary files graphics/watched_gray.png 1970-01-01 00:00:00 +0000 and graphics/watched_gray.png 2014-05-14 17:33:57 +0000 differ119Binary files graphics/watched_gray.png 1970-01-01 00:00:00 +0000 and graphics/watched_gray.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/watchlist.png'
23Binary files graphics/watchlist.png 1970-01-01 00:00:00 +0000 and graphics/watchlist.png 2014-05-14 17:33:57 +0000 differ120Binary files graphics/watchlist.png 1970-01-01 00:00:00 +0000 and graphics/watchlist.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/watchlist_black.png'
24Binary files graphics/watchlist_black.png 1970-01-01 00:00:00 +0000 and graphics/watchlist_black.png 2014-05-14 17:33:57 +0000 differ121Binary files graphics/watchlist_black.png 1970-01-01 00:00:00 +0000 and graphics/watchlist_black.png 2014-05-14 17:33:57 +0000 differ
=== added file 'graphics/watchlist_sidebar@48.png'
25Binary files graphics/watchlist_sidebar@48.png 1970-01-01 00:00:00 +0000 and graphics/watchlist_sidebar@48.png 2014-05-14 17:33:57 +0000 differ122Binary files graphics/watchlist_sidebar@48.png 1970-01-01 00:00:00 +0000 and graphics/watchlist_sidebar@48.png 2014-05-14 17:33:57 +0000 differ
=== added file 'manifest.json'
--- manifest.json 1970-01-01 00:00:00 +0000
+++ manifest.json 2014-05-14 17:33:57 +0000
@@ -0,0 +1,15 @@
1{
2 "architecture": "all",
3 "description": "description of Flashback",
4 "framework": "ubuntu-sdk-14.04-qml-dev1",
5 "hooks": {
6 "Cliffhanger": {
7 "apparmor": "Flashback.json",
8 "desktop": "Flashback.desktop"
9 }
10 },
11 "maintainer": "Nekhelesh Ramananthan <krnekhelesh@gmail.com>",
12 "name": "com.ubuntu.developer.nik90.flashback",
13 "title": "Flashback",
14 "version": "0.3.3"
15}
0\ No newline at end of file16\ No newline at end of file
117
=== renamed file 'manifest.json' => 'manifest.json.moved'
=== added directory 'models'
=== renamed directory 'models' => 'models.moved'
=== added file 'models/Activity.qml'
--- models/Activity.qml 1970-01-01 00:00:00 +0000
+++ models/Activity.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,97 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import Ubuntu.Components 0.1
21import "../backend/backend.js" as Backend
22
23/*
24 Component to keep track of user activity (movies and tv show) and update the document automatically
25 */
26BasePostModel {
27 id: userActivity
28
29 property string username
30 property string password
31 property var activityDocument
32
33 Component.onCompleted: getUserActivityOnline()
34 Component.onDestruction: setDefaultDatabase()
35
36 // Function to get user's movie activity online. It automatically updates the local database if there is user activity
37 function getUserActivityOnline() {
38 console.log("[LOG]: Checking for user activity")
39 source = Backend.userActivity(username)
40 createMessage(username, password)
41 sendMessage()
42 }
43
44 // Function here to set the user movie activity database to defaults.
45 function setDefaultDatabase() {
46 console.log("[LOG]: Resetting user activity documents")
47 activityDocument = {
48 type: "default",
49 name: "default",
50 id: "default",
51 imdb: "default",
52 runtime: "default",
53 trailer: "default",
54 year: "default",
55 episode_title: "default",
56 season: "default",
57 number: "default",
58 poster: "default",
59 fanart: "default"
60 }
61 }
62
63 function updateJSONModel() {
64 if(reply.type === "movie") {
65 console.log("[LOG]: User is watching a movie -> " + reply.movie.title)
66 activityDocument = {
67 type: "movie",
68 name: reply.movie.title,
69 id: reply.movie.tmdb_id,
70 imdb: reply.movie.imdb_id,
71 runtime: reply.movie.runtime,
72 trailer: reply.movie.trailer,
73 year: reply.movie.year,
74 poster: get_thumb(reply.movie.images.poster, '-138'),
75 fanart: get_thumb(reply.movie.images.fanart, '-940')
76 }
77 }
78 else if(reply.type === "episode") {
79 console.log("[LOG]: User is watching a tv show -> " + reply.show.title)
80 activityDocument = {
81 type: "episode",
82 name: reply.show.title,
83 id: reply.show.tvdb_id,
84 imdb: reply.show.imdb_id,
85 episode_title: reply.episode.title,
86 season: reply.episode.season,
87 number: reply.episode.number,
88 poster: get_thumb(reply.show.images.poster, '-138'),
89 fanart: get_thumb(reply.show.images.fanart, '-940')
90 }
91 }
92 else {
93 console.log("[LOG]: User is not watching anything")
94 setDefaultDatabase()
95 }
96 }
97}
098
=== added file 'models/AiringShows.qml'
--- models/AiringShows.qml 1970-01-01 00:00:00 +0000
+++ models/AiringShows.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,66 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import "../backend/backend.js" as Backend
21
22BasePostModel {
23 id: airingShowsModel
24
25 // Property to store the time when the model was updated
26 property string lastUpdated: "default"
27
28 // Property to store the last action performed
29 property string lastAction: "default"
30
31 // Property to control if watched episodes should be hidden or not
32 property bool hideWatched: false
33
34 function fetchData(username, password, date, days) {
35 source = Backend.userShows(username, date, days)
36 createMessage(username, password)
37 sendMessage()
38 }
39
40 function updateJSONModel() {
41 model.clear()
42 for ( var key in reply ) {
43 var jo = reply[key];
44 for( var innerkey in jo.episodes ) {
45 var mo = jo.episodes[innerkey]
46 if (hideWatched && mo.episode.watched == true)
47 continue
48 // Only show episodes airing of tv shows that are watchlisted by the user
49 if (mo.show.in_watchlist == true) {
50 model.append({
51 'name': mo.show.title,
52 'year': mo.show.year,
53 'id': mo.show.tvdb_id,
54 'imdb_id': mo.show.imdb_id,
55 'season': mo.episode.season,
56 'episode': mo.episode.number,
57 'episode_name': mo.episode.title,
58 'episode_air_date': mo.episode.first_aired_iso,
59 'watched': mo.episode.watched ? mo.episode.watched.toString() : "",
60 'thumb_url': get_thumb(mo.show.images.poster, '-300')
61 });
62 }
63 }
64 }
65 }
66}
067
=== added file 'models/BaseModel.qml'
--- models/BaseModel.qml 1970-01-01 00:00:00 +0000
+++ models/BaseModel.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,58 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20
21Item {
22 id: baseModel
23 property string source: ""
24 property string json: ""
25 property int status: XMLHttpRequest.UNSENT
26
27 property ListModel model: ListModel { id: model }
28 property alias count: model.count
29
30 signal updated()
31
32 onSourceChanged: {
33 var xhr = new XMLHttpRequest;
34 xhr.open("GET", source);
35 xhr.onreadystatechange = function() {
36 status = xhr.readyState;
37 if (xhr.readyState == XMLHttpRequest.DONE && xhr.status == 200)
38 json = xhr.responseText;
39 }
40 xhr.send();
41 }
42
43 onJsonChanged: {
44 if ( json != "" ) {
45 updateJSONModel();
46 updated();
47 }
48 }
49
50 function thumbnail_url(thumb_path, type) {
51 if (thumb_path)
52 return "http://d3gtl9l2a4fn1j.cloudfront.net/t/p/" + "w185/" + thumb_path;
53 else if (type !== "person")
54 return Qt.resolvedUrl("../graphics/no-poster.jpg");
55 else if (type === "person")
56 return Qt.resolvedUrl("../graphics/no-passport.png");
57 }
58}
059
=== added file 'models/BasePostModel.qml'
--- models/BasePostModel.qml 1970-01-01 00:00:00 +0000
+++ models/BasePostModel.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,64 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20
21Item {
22 id: basePostModel
23 property string source: ""
24 property string json: ""
25 property int status: XMLHttpRequest.UNSENT
26
27 property var reply
28 property var message
29
30 property string username
31 property string password
32
33 property ListModel model: ListModel { id: model }
34 property alias count: model.count
35
36 signal updated()
37
38 function createMessage(username, password) {
39 message = JSON.stringify({username: username, password: password})
40 }
41
42 function get_thumb(thumb_url, size) {
43 return thumb_url.split('.jpg')[0] + size + '.jpg'
44 }
45
46 function sendMessage() {
47 var xhr = new XMLHttpRequest();
48 xhr.open("POST", source);
49
50 xhr.onreadystatechange = function() {
51 status = xhr.readyState;
52 if (xhr.readyState == XMLHttpRequest.DONE)
53 getReply(json = xhr.responseText);
54 }
55 xhr.send(message);
56 }
57
58 function getReply(json) {
59 if ( json != "" ) {
60 reply = JSON.parse(json)
61 updateJSONModel();
62 }
63 }
64}
065
=== added file 'models/Cast.qml'
--- models/Cast.qml 1970-01-01 00:00:00 +0000
+++ models/Cast.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,38 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20
21BaseModel {
22 id: cast
23
24 function updateJSONModel() {
25 model.clear();
26
27 var objectArray = JSON.parse(json).cast;
28 for ( var key in objectArray ) {
29 var jo = objectArray[key];
30 model.append({
31 'name': jo.name,
32 'character': jo.character,
33 'id': jo.id,
34 'thumb_url': thumbnail_url(jo.profile_path, "person")
35 });
36 }
37 }
38}
039
=== added file 'models/Crew.qml'
--- models/Crew.qml 1970-01-01 00:00:00 +0000
+++ models/Crew.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,37 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20
21BaseModel {
22 id: crew
23 function updateJSONModel() {
24 model.clear();
25
26 var objectArray = JSON.parse(json).crew;
27 for ( var key in objectArray ) {
28 var jo = objectArray[key];
29 model.append({
30 'name': jo.name,
31 'department': jo.department,
32 'id': jo.id,
33 'thumb_url': thumbnail_url(jo.profile_path, "person")
34 });
35 }
36 }
37}
038
=== added file 'models/Episode.qml'
--- models/Episode.qml 1970-01-01 00:00:00 +0000
+++ models/Episode.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,55 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20
21BasePostModel {
22 id: episodeDetails
23
24 property variant attributes: {
25 'name': '',
26 'year': 0,
27 'episode_name': '',
28 'overview': '',
29 'episode_air_date': '',
30 'voteAverage': 0.0,
31 'voteCount': 0,
32 'userVote': 0,
33 'thumb_url': ''
34 }
35
36 function updateJSONModel() {
37 attributes = {
38 'name': reply.show.title,
39 'year': parseInt(reply.show.year),
40 'id': reply.show.tvdb_id,
41 'imdb_id': reply.show.imdb_id,
42 'season': parseInt(reply.episode.season),
43 'episode': parseInt(reply.episode.number),
44 'episode_name': reply.episode.title,
45 'overview': reply.episode.overview,
46 'episode_air_date': reply.episode.first_aired_utc,
47 'voteAverage': parseFloat(reply.episode.ratings.percentage),
48 'voteCount': parseInt(reply.episode.ratings.votes),
49 'userVote': parseInt(reply.episode.rating_advanced),
50 'watched': reply.episode.watched ? reply.episode.watched.toString() : "",
51 'thumb_url': reply.episode.images.screen
52 };
53 updated()
54 }
55}
056
=== added file 'models/Genres.qml'
--- models/Genres.qml 1970-01-01 00:00:00 +0000
+++ models/Genres.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,35 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20
21BaseModel {
22 id: genres
23 function updateJSONModel() {
24 model.clear();
25
26 var objectArray = JSON.parse(json).genres;
27 for ( var key in objectArray ) {
28 var jo = objectArray[key];
29 model.append({
30 'name': jo.name,
31 'id': jo.id
32 });
33 }
34 }
35}
036
=== added file 'models/Movie.qml'
--- models/Movie.qml 1970-01-01 00:00:00 +0000
+++ models/Movie.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,57 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20
21BaseModel {
22 id: movie
23
24 property variant attributes: {
25 'title': '',
26 'homepage': '',
27 'tagline': '',
28 'overview': '',
29 'releaseDate': '',
30 'runtime': 0,
31 'voteAverage': 0.0,
32 'voteCount': 0,
33 'genres': [],
34 'thumb_url': ''
35 }
36
37 function updateJSONModel() {
38 var ob = JSON.parse(json);
39 attributes = {
40 'id': ob.id,
41 'imdb_id': ob.imdb_id,
42 'title': ob.title,
43 'homepage': (ob.homepage || "") ,
44 'tagline': (ob.tagline || ""),
45 'overview': (ob.overview || ""),
46 'releaseDate': (ob.release_date || ""),
47 'runtime': parseInt(ob.runtime),
48 'voteAverage': parseFloat(ob.vote_average),
49 'voteCount': parseInt(ob.vote_count),
50 'genres': ob.genres,
51 'thumb_url': thumbnail_url(ob.poster_path, "movie"),
52 'creditsJson': JSON.stringify(ob.credits || {}),
53 'trailersJson': JSON.stringify(ob.trailers || {}),
54 'similarMoviesJson': JSON.stringify(ob.similar_movies || {})
55 };
56 }
57}
058
=== added file 'models/Movies.qml'
--- models/Movies.qml 1970-01-01 00:00:00 +0000
+++ models/Movies.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,37 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20
21BaseModel {
22 id: movies
23
24 function updateJSONModel() {
25 model.clear();
26
27 var objectArray = JSON.parse(json).results;
28 for ( var key in objectArray ) {
29 var jo = objectArray[key];
30 model.append({
31 'name': jo.title,
32 'id': jo.id,
33 'thumb_url': thumbnail_url(jo.poster_path, "movie")
34 });
35 }
36 }
37}
038
=== added file 'models/People.qml'
--- models/People.qml 1970-01-01 00:00:00 +0000
+++ models/People.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,36 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20
21BaseModel {
22 id: people
23 function updateJSONModel() {
24 model.clear();
25
26 var objectArray = JSON.parse(json).results;
27 for ( var key in objectArray ) {
28 var jo = objectArray[key];
29 model.append({
30 'name': jo.name,
31 'id': jo.id,
32 'thumb_url': thumbnail_url(jo.profile_path, "person")
33 });
34 }
35 }
36}
037
=== added file 'models/Person.qml'
--- models/Person.qml 1970-01-01 00:00:00 +0000
+++ models/Person.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,48 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20
21BaseModel {
22 id: person
23
24 property variant attributes: {
25 'name': '',
26 'biography': '',
27 'birthday': '',
28 'deathday': '',
29 'homepage': '',
30 'placeOfBirth': '',
31 'thumb_url': ''
32 }
33
34 function updateJSONModel() {
35 var ob = JSON.parse(json);
36 attributes = {
37 'id': ob.id,
38 'name': ob.name,
39 'biography': ob.biography || "",
40 'birthday': ob.birthday || "",
41 'deathday': ob.deathday || "",
42 'homepage': ob.homepage || "",
43 'placeOfBirth': ob.place_of_birth || "",
44 'thumb_url': thumbnail_url(ob.profile_path, "person"),
45 'combinedCreditsJson': JSON.stringify(ob.combined_credits || {})
46 };
47 }
48}
049
=== added file 'models/PersonCast.qml'
--- models/PersonCast.qml 1970-01-01 00:00:00 +0000
+++ models/PersonCast.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,40 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20
21BaseModel {
22 id: personCast
23
24 function updateJSONModel() {
25 model.clear();
26
27 var objectArray = JSON.parse(json).cast;
28 for ( var key in objectArray ) {
29 var jo = objectArray[key];
30 model.append({
31 'id': jo.id,
32 'title': jo.title || jo.name || "",
33 'character': jo.character || "",
34 'releaseDate': jo.release_date || "",
35 'mediaType': jo.media_type,
36 'thumb_url': thumbnail_url(jo.poster_path, "person")
37 });
38 }
39 }
40}
041
=== added file 'models/PersonCrew.qml'
--- models/PersonCrew.qml 1970-01-01 00:00:00 +0000
+++ models/PersonCrew.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,40 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20
21BaseModel {
22 id: personCrew
23 function updateJSONModel() {
24 model.clear();
25
26 var objectArray = JSON.parse(json).crew;
27 for ( var key in objectArray ) {
28 var jo = objectArray[key];
29 model.append({
30 'id': jo.id,
31 'title': jo.title || jo.name || "",
32 'department': jo.department || "",
33 'job': jo.job || "",
34 'releaseDate': jo.release_date || "",
35 'mediaType': jo.media_type,
36 'thumb_url': thumbnail_url(jo.poster_path, "person")
37 });
38 }
39 }
40}
041
=== added file 'models/SeasonEpisodes.qml'
--- models/SeasonEpisodes.qml 1970-01-01 00:00:00 +0000
+++ models/SeasonEpisodes.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,38 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20
21BasePostModel {
22 id: episodeList
23
24 function updateJSONModel() {
25 model.clear()
26 for ( var key in reply ) {
27 var jo = reply[key];
28 model.append({
29 'episode_name': jo.title || "",
30 'season': parseInt(jo.season),
31 'episode': parseInt(jo.episode),
32 'watched': jo.watched ? jo.watched.toString() : "",
33 'thumb_url': jo.images.screen
34 });
35 }
36 updated()
37 }
38}
039
=== added file 'models/Show.qml'
--- models/Show.qml 1970-01-01 00:00:00 +0000
+++ models/Show.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,65 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20
21BasePostModel {
22 id: show
23
24 property variant attributes: {
25 'name': '',
26 'year': 0,
27 'overview': '',
28 'first_air_date': '',
29 'air_day_utc': '',
30 'air_time_utc': '',
31 'episode_run_time': 0,
32 'voteAverage': 0.0,
33 'voteCount': 0,
34 'userVote': 0,
35 'in_watchlist': '',
36 'number_of_seasons': 0,
37 'networks': '',
38 'genres': [],
39 'thumb_url': ''
40 }
41
42 function updateJSONModel() {
43 attributes = {
44 'name': reply.title,
45 'year': reply.year,
46 'id': reply.tvdb_id,
47 'imdb_id': reply.imdb_id,
48 'overview': reply.overview,
49 'first_air_date': reply.first_aired_utc,
50 'air_day_utc': reply.air_day_utc,
51 'air_time_utc': reply.air_time_utc,
52 'episode_run_time': parseInt(reply.runtime),
53 'voteAverage': parseFloat(reply.ratings.percentage),
54 'voteCount': parseInt(reply.ratings.votes),
55 'userVote': parseInt(reply.rating_advanced),
56 'in_watchlist': reply.in_watchlist ? reply.in_watchlist.toString() : "",
57 'in_production': reply.status,
58 'networks': reply.network,
59 'genres': reply.genres,
60 'thumb_url': get_thumb(reply.images.poster, '-138'),
61 'creditsJson': JSON.stringify(reply.people.actors || {})
62 };
63 updated();
64 }
65}
066
=== added file 'models/ShowSeasons.qml'
--- models/ShowSeasons.qml 1970-01-01 00:00:00 +0000
+++ models/ShowSeasons.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,37 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20
21BaseModel {
22 id: seasons
23
24 function updateJSONModel() {
25 model.clear();
26
27 var objectArray = JSON.parse(json);
28 for ( var key in objectArray ) {
29 var jo = objectArray[key];
30 model.append({
31 'season': parseInt(jo.season),
32 'no_of_episodes': parseInt(jo.episodes),
33 'thumb_url': jo.images.poster
34 });
35 }
36 }
37}
038
=== added file 'models/Shows.qml'
--- models/Shows.qml 1970-01-01 00:00:00 +0000
+++ models/Shows.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,42 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20import "../backend/backend.js" as Backend
21
22BasePostModel {
23 id: shows
24
25 source: Backend.trendingShowsUrl()
26
27 function updateJSONModel() {
28 model.clear()
29 for ( var key in reply ) {
30 var jo = reply[key];
31 model.append({
32 'name': jo.title,
33 'year': jo.year,
34 'id': jo.tvdb_id,
35 'imdb_id': jo.imdb_id,
36 'watched': jo.watched ? jo.watched.toString() : "",
37 'watchlist': jo.in_watchlist ? jo.in_watchlist.toString() : "",
38 'thumb_url': jo.images.poster !== "http://slurm.trakt.us/images/poster-dark.jpg" ? get_thumb(jo.images.poster, '-138') : jo.images.poster
39 });
40 }
41 }
42}
043
=== added file 'models/Trailer.qml'
--- models/Trailer.qml 1970-01-01 00:00:00 +0000
+++ models/Trailer.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,37 @@
1/*
2 * Flashback - Entertainment app for Ubuntu
3 * Copyright (C) 2013, 2014 Nekhelesh Ramananthan <nik90@ubuntu.com>
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 *
17 */
18
19import QtQuick 2.0
20
21BaseModel {
22 id: trailer
23
24 function updateJSONModel() {
25 model.clear();
26
27 var objectArray = JSON.parse(json).youtube;
28 for ( var key in objectArray ) {
29 var jo = objectArray[key];
30 model.append({
31 'name': jo.name,
32 'type': jo.type,
33 'url': jo.source
34 });
35 }
36 }
37}
038
=== added file 'models/TraktAccount.qml'
--- models/TraktAccount.qml 1970-01-01 00:00:00 +0000
+++ models/TraktAccount.qml 2014-05-14 17:33:57 +0000
@@ -0,0 +1,28 @@
1/*
The diff has been truncated for viewing.

Subscribers

People subscribed via source and target branches

to all changes: