18 |
19 |
--------------------------------------------------------------------------------
/app/.gitignore:
--------------------------------------------------------------------------------
1 | /build
--------------------------------------------------------------------------------
/app/build.gradle:
--------------------------------------------------------------------------------
1 | plugins {
2 | id 'com.android.application'
3 | id 'org.jetbrains.kotlin.android'
4 | }
5 |
6 | android {
7 | compileSdk 32
8 |
9 | defaultConfig {
10 | applicationId "com.tutorial.tvapp"
11 | minSdk 21
12 | targetSdk 32
13 | versionCode 1
14 | versionName "1.0"
15 |
16 | }
17 |
18 | buildTypes {
19 | release {
20 | minifyEnabled false
21 | proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
22 | }
23 | }
24 | }
25 |
26 | dependencies {
27 |
28 | implementation 'androidx.core:core-ktx:1.7.0'
29 | implementation 'androidx.leanback:leanback:1.0.0'
30 | implementation 'androidx.appcompat:appcompat:1.5.1'
31 | implementation 'com.google.android.material:material:1.7.0'
32 | implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
33 | implementation 'androidx.legacy:legacy-support-v4:1.0.0'
34 |
35 |
36 | implementation 'com.github.bumptech.glide:glide:4.12.0'
37 | implementation 'com.google.code.gson:gson:2.8.9'
38 | }
--------------------------------------------------------------------------------
/app/proguard-rules.pro:
--------------------------------------------------------------------------------
1 | # Add project specific ProGuard rules here.
2 | # You can control the set of applied configuration files using the
3 | # proguardFiles setting in build.gradle.
4 | #
5 | # For more details, see
6 | # http://developer.android.com/guide/developing/tools/proguard.html
7 |
8 | # If your project uses WebView with JS, uncomment the following
9 | # and specify the fully qualified class name to the JavaScript interface
10 | # class:
11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview {
12 | # public *;
13 | #}
14 |
15 | # Uncomment this to preserve the line number information for
16 | # debugging stack traces.
17 | #-keepattributes SourceFile,LineNumberTable
18 |
19 | # If you keep the line number information, uncomment this to
20 | # hide the original source file name.
21 | #-renamesourcefileattribute SourceFile
--------------------------------------------------------------------------------
/app/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
6 |
7 |
8 |
10 |
11 |
13 |
14 |
15 |
22 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
--------------------------------------------------------------------------------
/app/src/main/assets/movies.json:
--------------------------------------------------------------------------------
1 | {
2 | "result": [
3 | {
4 | "id": 0,
5 | "title": "Upcoming Movies",
6 | "details": [
7 | {
8 | "adult": false,
9 | "backdrop_path": "/c1bz69r0v065TGFA5nqBiKzPDys.jpg",
10 | "genre_ids": [
11 | 35,
12 | 10751,
13 | 10402
14 | ],
15 | "id": 830784,
16 | "original_language": "en",
17 | "original_title": "Lyle, Lyle, Crocodile",
18 | "overview": "When the Primm family moves to New York City, their young son Josh struggles to adapt to his new school and new friends. All of that changes when he discovers Lyle — a singing crocodile who loves baths, caviar and great music — living in the attic of his new home. But when Lyle’s existence is threatened by evil neighbor Mr. Grumps, the Primms must band together to show the world that family can come from the most unexpected places.",
19 | "popularity": 1710.176,
20 | "poster_path": "/irIS5Tn3TXjNi1R9BpWvGAN4CZ1.jpg",
21 | "release_date": "2022-10-07",
22 | "title": "Lyle, Lyle, Crocodile",
23 | "video": false,
24 | "vote_average": 7.8,
25 | "vote_count": 122
26 | },
27 | {
28 | "adult": false,
29 | "backdrop_path": "/tUBN1paMQ1tmVA5Sjy1ZjPWVsiF.jpg",
30 | "genre_ids": [
31 | 12,
32 | 16,
33 | 35,
34 | 10751,
35 | 14
36 | ],
37 | "id": 676701,
38 | "original_language": "es",
39 | "original_title": "Tadeo Jones 3: La Tabla Esmeralda",
40 | "overview": "Tad would love for his archeologist colleagues to accept him as one of their own, but he always messes everything up. Tad accidentally destroys a sarcophagus and unleashes an ancient spell endangering the lives of his friends: Mummy, Jeff and Belzoni. With everyone against him and only helped by Sara, he sets off on an adventure that will take him from Mexico to Chicago and from Paris to Egypt, in order to put an end to the curse of the Mummy.",
41 | "popularity": 862.707,
42 | "poster_path": "/jvIVl8zdNSOAJImw1elQEzxStMN.jpg",
43 | "release_date": "2022-08-24",
44 | "title": "Tad the Lost Explorer and the Curse of the Mummy",
45 | "video": false,
46 | "vote_average": 7.8,
47 | "vote_count": 128
48 | },
49 | {
50 | "adult": false,
51 | "backdrop_path": "/tlin6STxxVoln0f818sEQYH7PyC.jpg",
52 | "genre_ids": [
53 | 27,
54 | 53
55 | ],
56 | "id": 663712,
57 | "original_language": "en",
58 | "original_title": "Terrifier 2",
59 | "overview": "After being resurrected by a sinister entity, Art the Clown returns to Miles County where he must hunt down and destroy a teenage girl and her younger brother on Halloween night. As the body count rises, the siblings fight to stay alive while uncovering the true nature of Art's evil intent.",
60 | "popularity": 962.461,
61 | "poster_path": "/8gLhu8UFPZfH2Hv11JhTZkb9CVl.jpg",
62 | "release_date": "2022-10-06",
63 | "title": "Terrifier 2",
64 | "video": false,
65 | "vote_average": 7,
66 | "vote_count": 709
67 | },
68 | {
69 | "adult": false,
70 | "backdrop_path": "/198vrF8k7mfQ4FjDJsBmdQcaiyq.jpg",
71 | "genre_ids": [
72 | 878,
73 | 28,
74 | 12
75 | ],
76 | "id": 76600,
77 | "original_language": "en",
78 | "original_title": "Avatar: The Way of Water",
79 | "overview": "Set more than a decade after the events of the first film, learn the story of the Sully family (Jake, Neytiri, and their kids), the trouble that follows them, the lengths they go to keep each other safe, the battles they fight to stay alive, and the tragedies they endure.",
80 | "popularity": 898.098,
81 | "poster_path": "/t6HIqrRAclMCA60NsSmeqe9RmNV.jpg",
82 | "release_date": "2022-12-14",
83 | "title": "Avatar: The Way of Water",
84 | "video": false,
85 | "vote_average": 0,
86 | "vote_count": 0
87 | },
88 | {
89 | "adult": false,
90 | "backdrop_path": "/AaV1YIdWKnjAIAOe8UUKBFm327v.jpg",
91 | "genre_ids": [
92 | 28,
93 | 18
94 | ],
95 | "id": 361743,
96 | "original_language": "en",
97 | "original_title": "Top Gun: Maverick",
98 | "overview": "After more than thirty years of service as one of the Navy’s top aviators, and dodging the advancement in rank that would ground him, Pete “Maverick” Mitchell finds himself training a detachment of TOP GUN graduates for a specialized mission the likes of which no living pilot has ever seen.",
99 | "popularity": 538.764,
100 | "poster_path": "/62HCnUTziyWcpDaBO2i1DX17ljH.jpg",
101 | "release_date": "2022-05-24",
102 | "title": "Top Gun: Maverick",
103 | "video": false,
104 | "vote_average": 8.3,
105 | "vote_count": 4909
106 | },
107 | {
108 | "adult": false,
109 | "backdrop_path": "/jBIMZ0AlUYuFNsKbd4L6FojWMoy.jpg",
110 | "genre_ids": [
111 | 16,
112 | 35,
113 | 10749
114 | ],
115 | "id": 820067,
116 | "original_language": "ja",
117 | "original_title": "映画 五等分の花嫁",
118 | "overview": "When five lovely young girls who hate studying hire part-time tutor Futaro, he guides not only their education but also their hearts. Time spent has brought them all closer, with feelings growing within the girls and Futaro. As they finish their third year of high school and their last school festival approaches, they set their sights on what’s next. Is there a future with one of them and Futaro?",
119 | "popularity": 365.38,
120 | "poster_path": "/sg7klpt1xwK1IJirBI9EHaqQwJ5.jpg",
121 | "release_date": "2022-05-20",
122 | "title": "The Quintessential Quintuplets Movie",
123 | "video": false,
124 | "vote_average": 9,
125 | "vote_count": 116
126 | },
127 | {
128 | "adult": false,
129 | "backdrop_path": "/GFq9kYUnpRCnlbIbjPzNA96e0j.jpg",
130 | "genre_ids": [
131 | 35,
132 | 27,
133 | 53
134 | ],
135 | "id": 593643,
136 | "original_language": "en",
137 | "original_title": "The Menu",
138 | "overview": "A couple travels to a coastal island to eat at an exclusive restaurant where the chef has prepared a lavish menu, with some shocking surprises.",
139 | "popularity": 459.386,
140 | "poster_path": "/v31MsWhF9WFh7Qooq6xSBbmJxoG.jpg",
141 | "release_date": "2022-11-17",
142 | "title": "The Menu",
143 | "video": false,
144 | "vote_average": 7.3,
145 | "vote_count": 347
146 | },
147 | {
148 | "adult": false,
149 | "backdrop_path": "/6mEYUYdkKoVCMeYf3rTFj0L1uyv.jpg",
150 | "genre_ids": [
151 | 28,
152 | 35,
153 | 80,
154 | 53
155 | ],
156 | "id": 899112,
157 | "original_language": "en",
158 | "original_title": "Violent Night",
159 | "overview": "When a team of mercenaries breaks into a wealthy family compound on Christmas Eve, taking everyone inside hostage, the team isn’t prepared for a surprise combatant: Santa Claus is on the grounds, and he’s about to show why this Nick is no saint.",
160 | "popularity": 300.568,
161 | "poster_path": "/1CHp8QQjGwqWaPZWjzcRidlt5Xs.jpg",
162 | "release_date": "2022-11-30",
163 | "title": "Violent Night",
164 | "video": false,
165 | "vote_average": 7.6,
166 | "vote_count": 54
167 | },
168 | {
169 | "adult": false,
170 | "backdrop_path": "/aIkG2V4UXrfkxMdJZmq30xO0QQr.jpg",
171 | "genre_ids": [
172 | 878,
173 | 10751,
174 | 28,
175 | 12
176 | ],
177 | "id": 791155,
178 | "original_language": "en",
179 | "original_title": "Secret Headquarters",
180 | "overview": "While hanging out after school, Charlie and his friends discover the headquarters of the world’s most powerful superhero hidden beneath his home. When villains attack, they must team up to defend the headquarters and save the world.",
181 | "popularity": 350.064,
182 | "poster_path": "/8PsHogUfvjWPGdWAI5uslDhHDx7.jpg",
183 | "release_date": "2022-12-20",
184 | "title": "Secret Headquarters",
185 | "video": false,
186 | "vote_average": 0,
187 | "vote_count": 0
188 | },
189 | {
190 | "adult": false,
191 | "backdrop_path": "/2iGUavwv86Hubv3V5Iq4qEQXDfE.jpg",
192 | "genre_ids": [
193 | 53,
194 | 18,
195 | 27
196 | ],
197 | "id": 848058,
198 | "original_language": "vi",
199 | "original_title": "Cerdita",
200 | "overview": "A bullied overweight teenager sees a glimpse of hope when her tormentors are brutally abducted by a mesmerizing stranger.",
201 | "popularity": 397.907,
202 | "poster_path": "/8EIQAvJjXdbNDMmBtHtgGqbc09V.jpg",
203 | "release_date": "2022-10-07",
204 | "title": "Piggy",
205 | "video": false,
206 | "vote_average": 6.7,
207 | "vote_count": 225
208 | },
209 | {
210 | "adult": false,
211 | "backdrop_path": "/qjGrUmKW78MCFG8PTLDBp67S27p.jpg",
212 | "genre_ids": [
213 | 16,
214 | 28,
215 | 12,
216 | 14
217 | ],
218 | "id": 635302,
219 | "original_language": "ja",
220 | "original_title": "劇場版「鬼滅の刃」無限列車編",
221 | "overview": "Tanjirō Kamado, joined with Inosuke Hashibira, a boy raised by boars who wears a boar's head, and Zenitsu Agatsuma, a scared boy who reveals his true power when he sleeps, boards the Infinity Train on a new mission with the Fire Hashira, Kyōjurō Rengoku, to defeat a demon who has been tormenting the people and killing the demon slayers who oppose it!",
222 | "popularity": 330.895,
223 | "poster_path": "/h8Rb9gBr48ODIwYUttZNYeMWeUU.jpg",
224 | "release_date": "2020-10-16",
225 | "title": "Demon Slayer -Kimetsu no Yaiba- The Movie: Mugen Train",
226 | "video": false,
227 | "vote_average": 8.3,
228 | "vote_count": 2804
229 | },
230 | {
231 | "adult": false,
232 | "backdrop_path": "/cP8YNG3XUeBmO8Jk7Skzq3vwHy1.jpg",
233 | "genre_ids": [
234 | 16,
235 | 12,
236 | 35,
237 | 10751,
238 | 14
239 | ],
240 | "id": 315162,
241 | "original_language": "en",
242 | "original_title": "Puss in Boots: The Last Wish",
243 | "overview": "Puss in Boots discovers that his passion for adventure has taken its toll: He has burned through eight of his nine lives, leaving him with only one life left. Puss sets out on an epic journey to find the mythical Last Wish and restore his nine lives.",
244 | "popularity": 181.542,
245 | "poster_path": "/1NqwE6LP9IEdOZ57NCT51ftHtWT.jpg",
246 | "release_date": "2022-12-07",
247 | "title": "Puss in Boots: The Last Wish",
248 | "video": false,
249 | "vote_average": 7.7,
250 | "vote_count": 7
251 | },
252 | {
253 | "adult": false,
254 | "backdrop_path": "/txIt41UgDBJsZ7W33bhXjdqUIv8.jpg",
255 | "genre_ids": [
256 | 10751,
257 | 35,
258 | 18
259 | ],
260 | "id": 929340,
261 | "original_language": "en",
262 | "original_title": "A Christmas Story Christmas",
263 | "overview": "Ralphie is now all grown up and must deal with Christmas and all that comes with it…as a dad.",
264 | "popularity": 117.274,
265 | "poster_path": "/5QeoDiiIFY9VF87Rm79WpCFZbwf.jpg",
266 | "release_date": "2022-11-17",
267 | "title": "A Christmas Story Christmas",
268 | "video": false,
269 | "vote_average": 6.7,
270 | "vote_count": 43
271 | },
272 | {
273 | "adult": false,
274 | "backdrop_path": "/1AsP4UAv6hCGXUcH8GqMwd5KmCN.jpg",
275 | "genre_ids": [
276 | 35,
277 | 18
278 | ],
279 | "id": 497828,
280 | "original_language": "en",
281 | "original_title": "Triangle of Sadness",
282 | "overview": "A celebrity model couple are invited on a luxury cruise for the uber-rich, helmed by an unhinged captain. What first appeared Instagrammable ends catastrophically, leaving the survivors stranded on a desert island and fighting for survival.",
283 | "popularity": 88.771,
284 | "poster_path": "/fgy78BLl0gk8OzTWHZyGrSlIEON.jpg",
285 | "release_date": "2022-09-23",
286 | "title": "Triangle of Sadness",
287 | "video": false,
288 | "vote_average": 7.6,
289 | "vote_count": 356
290 | },
291 | {
292 | "adult": false,
293 | "backdrop_path": "/A1bWhTFQKkhF1yhSKWosSyzn2Hp.jpg",
294 | "genre_ids": [
295 | 9648,
296 | 53,
297 | 80,
298 | 18,
299 | 10749
300 | ],
301 | "id": 705996,
302 | "original_language": "ko",
303 | "original_title": "헤어질 결심",
304 | "overview": "From a mountain peak in South Korea, a man plummets to his death. Did he jump, or was he pushed? When detective Hae-joon arrives on the scene, he begins to suspect the dead man’s wife Seo-rae. But as he digs deeper into the investigation, he finds himself trapped in a web of deception and desire.",
305 | "popularity": 83.685,
306 | "poster_path": "/N0rskx91Eh6aWjvBybeY6epNic.jpg",
307 | "release_date": "2022-06-29",
308 | "title": "Decision to Leave",
309 | "video": false,
310 | "vote_average": 7.3,
311 | "vote_count": 315
312 | },
313 | {
314 | "adult": false,
315 | "backdrop_path": "/giveZjQGE4Pn3kJvsTn7uHqLjZS.jpg",
316 | "genre_ids": [
317 | 18
318 | ],
319 | "id": 615952,
320 | "original_language": "en",
321 | "original_title": "Armageddon Time",
322 | "overview": "In 1980, Queens, New York, a young Jewish boy befriends a rebellious African-American classmate to the disapproval of his privileged family and begins to reckon with growing up in a world of inequality and prejudice.",
323 | "popularity": 109.624,
324 | "poster_path": "/1ResCMsWd0w4o8SJEJIZrQxbRof.jpg",
325 | "release_date": "2022-10-28",
326 | "title": "Armageddon Time",
327 | "video": false,
328 | "vote_average": 7,
329 | "vote_count": 102
330 | },
331 | {
332 | "adult": false,
333 | "backdrop_path": "/bnXGwFBomUseQIc9Xqiymy9p8qP.jpg",
334 | "genre_ids": [
335 | 27,
336 | 14
337 | ],
338 | "id": 517302,
339 | "original_language": "fi",
340 | "original_title": "Pahanhautoja",
341 | "overview": "12 year old Tinja is desperate to please her mother, a woman obsessed with presenting the image of a perfect family. One night, Tinja finds a strange egg. What hatches is beyond belief.",
342 | "popularity": 54.353,
343 | "poster_path": "/jgJACjJIpcbFfEEmEglinfQWQPO.jpg",
344 | "release_date": "2022-03-04",
345 | "title": "Hatching",
346 | "video": false,
347 | "vote_average": 6.4,
348 | "vote_count": 194
349 | },
350 | {
351 | "adult": false,
352 | "backdrop_path": "/r1l5Z6cQzqhXuY8j3cdvBdwtunc.jpg",
353 | "genre_ids": [
354 | 18,
355 | 9648
356 | ],
357 | "id": 790867,
358 | "original_language": "en",
359 | "original_title": "The Eternal Daughter",
360 | "overview": "An artist and her elderly mother confront long-buried secrets when they return to a former family home, now a hotel haunted by its mysterious past.",
361 | "popularity": 67.215,
362 | "poster_path": "/kyv8tPXx3mKchYzVmA3VckKoJDi.jpg",
363 | "release_date": "2022-12-02",
364 | "title": "The Eternal Daughter",
365 | "video": false,
366 | "vote_average": 6.3,
367 | "vote_count": 3
368 | },
369 | {
370 | "adult": false,
371 | "backdrop_path": "/7IwLNl9MJbj47pObu8xMDUbIesv.jpg",
372 | "genre_ids": [
373 | 27,
374 | 53
375 | ],
376 | "id": 676547,
377 | "original_language": "en",
378 | "original_title": "Prey for the Devil",
379 | "overview": "In response to a global rise in demonic possessions, the Catholic Church reopens exorcism schools to train priests in the Rite of Exorcism. On this spiritual battlefield, an unlikely warrior rises: a young nun, Sister Ann. Thrust onto the spiritual frontline with fellow student Father Dante, Sister Ann finds herself in a battle for the soul of a young girl and soon realizes the Devil has her right where he wants her.",
380 | "popularity": 78.071,
381 | "poster_path": "/w3s6XEDNVGq5LUlghqs6VlvsvL6.jpg",
382 | "release_date": "2022-10-23",
383 | "title": "Prey for the Devil",
384 | "video": false,
385 | "vote_average": 5.7,
386 | "vote_count": 72
387 | },
388 | {
389 | "adult": false,
390 | "backdrop_path": "/dom8lzl2iU46nDu6s4lBolBNjQs.jpg",
391 | "genre_ids": [
392 | 18
393 | ],
394 | "id": 736732,
395 | "original_language": "ko",
396 | "original_title": "브로커",
397 | "overview": "Boxes are left out for people to anonymously drop off their unwanted babies.",
398 | "popularity": 55.038,
399 | "poster_path": "/hhoINfy92ufsdsrSeovpQyVrOUD.jpg",
400 | "release_date": "2022-06-08",
401 | "title": "Broker",
402 | "video": false,
403 | "vote_average": 7.3,
404 | "vote_count": 103
405 | }
406 | ]
407 | },
408 | {
409 | "id": 1,
410 | "title": "Popular Movies",
411 | "details": [
412 | {
413 | "adult": false,
414 | "backdrop_path": "/bOGkgRGdhrBYJSLpXaxhXVstddV.jpg",
415 | "genre_ids": [
416 | 28,
417 | 12,
418 | 14,
419 | 878
420 | ],
421 | "id": 299536,
422 | "original_language": "en",
423 | "original_title": "Avengers: Infinity War",
424 | "overview": "As the Avengers and their allies have continued to protect the world from threats too large for any one hero to handle, a new danger has emerged from the cosmic shadows: Thanos. A despot of intergalactic infamy, his goal is to collect all six Infinity Stones, artifacts of unimaginable power, and use them to inflict his twisted will on all of reality. Everything the Avengers have fought for has led up to this moment - the fate of Earth and existence itself has never been more uncertain.",
425 | "poster_path": "/7WsyChQLEftFiDOVTGkv3hFpyyt.jpg",
426 | "release_date": "2018-04-25",
427 | "title": "Avengers: Infinity War",
428 | "video": false,
429 | "vote_average": 8.3,
430 | "vote_count": 6937,
431 | "popularity": 358.799
432 | },
433 | {
434 | "adult": false,
435 | "backdrop_path": "/3P52oz9HPQWxcwHOwxtyrVV1LKi.jpg",
436 | "genre_ids": [
437 | 28,
438 | 35,
439 | 878
440 | ],
441 | "id": 383498,
442 | "original_language": "en",
443 | "original_title": "Deadpool 2",
444 | "overview": "Wisecracking mercenary Deadpool battles the evil and powerful Cable and other bad guys to save a boy's life.",
445 | "poster_path": "/to0spRl1CMDvyUbOnbb4fTk3VAd.jpg",
446 | "release_date": "2018-05-15",
447 | "title": "Deadpool 2",
448 | "video": false,
449 | "vote_average": 7.6,
450 | "vote_count": 3938,
451 | "popularity": 223.011
452 | },
453 | {
454 | "adult": false,
455 | "backdrop_path": "/22cUd4Yg5euCxIwWzXrL4m4otkU.jpg",
456 | "genre_ids": [
457 | 28,
458 | 878,
459 | 53
460 | ],
461 | "id": 500664,
462 | "original_language": "en",
463 | "original_title": "Upgrade",
464 | "overview": "A brutal mugging leaves Grey Trace paralyzed in the hospital and his beloved wife dead. A billionaire inventor soon offers Trace a cure — an artificial intelligence implant called STEM that will enhance his body. Now able to walk, Grey finds that he also has superhuman strength and agility — skills he uses to seek revenge against the thugs who destroyed his life.",
465 | "poster_path": "/adOzdWS35KAo21r9R4BuFCkLer6.jpg",
466 | "release_date": "2018-06-01",
467 | "title": "Upgrade",
468 | "video": false,
469 | "vote_average": 7.6,
470 | "vote_count": 138,
471 | "popularity": 32.969
472 | },
473 | {
474 | "adult": false,
475 | "backdrop_path": "/uZTtVdOEIwPA6vwVRI3217DoPM.jpg",
476 | "genre_ids": [
477 | 35,
478 | 10749
479 | ],
480 | "id": 466282,
481 | "original_language": "en",
482 | "original_title": "To All the Boys I've Loved Before",
483 | "overview": "Lara Jean's love life goes from imaginary to out of control when her secret letters to every boy she's ever fallen for are mysteriously mailed out.",
484 | "poster_path": "/hKHZhUbIyUAjcSrqJThFGYIR6kI.jpg",
485 | "release_date": "2018-08-17",
486 | "title": "To All the Boys I've Loved Before",
487 | "video": false,
488 | "vote_average": 8.4,
489 | "vote_count": 349,
490 | "popularity": 31.76
491 | },
492 | {
493 | "adult": false,
494 | "backdrop_path": "/yRXzrwLfB5tDTIA3lSU9S3N9RUK.jpg",
495 | "genre_ids": [
496 | 35,
497 | 18
498 | ],
499 | "id": 455980,
500 | "original_language": "en",
501 | "original_title": "Tag",
502 | "overview": "For one month every year, five highly competitive friends hit the ground running in a no-holds-barred game of tag they’ve been playing since the first grade. This year, the game coincides with the wedding of their only undefeated player, which should finally make him an easy target. But he knows they’re coming...and he’s ready.",
503 | "poster_path": "/eXXpuW2xaq5Aen9N5prFlARVIvr.jpg",
504 | "release_date": "2018-06-14",
505 | "title": "Tag",
506 | "video": false,
507 | "vote_average": 7,
508 | "vote_count": 285,
509 | "popularity": 87.194
510 | },
511 | {
512 | "backdrop_path": "/hHEqDPbO6z4Xje5tOf3Wm1mdMtI.jpg",
513 | "first_air_date": "2018-08-17",
514 | "genre_ids": [
515 | 16,
516 | 35,
517 | 10765
518 | ],
519 | "id": 73021,
520 | "name": "Disenchantment",
521 | "origin_country": [
522 | "US"
523 | ],
524 | "original_language": "en",
525 | "original_name": "Disenchantment",
526 | "overview": "Set in a ruined medieval city called Dreamland, Disenchantment follows the grubby adventures of a hard-drinking princess, her feisty elf companion and her personal demon.",
527 | "poster_path": "/c3cUb0b3qHlWaawbLRC9DSsJwEr.jpg",
528 | "vote_average": 7.8,
529 | "vote_count": 8,
530 | "popularity": 19.929
531 | },
532 | {
533 | "adult": false,
534 | "backdrop_path": "/3ccBOsbVpgwN9K5whd2UB9ACebG.jpg",
535 | "genre_ids": [
536 | 80,
537 | 18
538 | ],
539 | "id": 489931,
540 | "original_language": "en",
541 | "original_title": "American Animals",
542 | "overview": "Four young men mistake their lives for a movie and attempt one of the most audacious heists in U.S. history.",
543 | "poster_path": "/aLbdKxgxuOPvs6CTlmzoOQ4Yg3j.jpg",
544 | "release_date": "2018-06-01",
545 | "title": "American Animals",
546 | "video": false,
547 | "vote_average": 7,
548 | "vote_count": 38,
549 | "popularity": 16.876
550 | },
551 | {
552 | "adult": false,
553 | "backdrop_path": "/tmpY6f0Lf7Dnx6inByjvHby4AYf.jpg",
554 | "genre_ids": [
555 | 35
556 | ],
557 | "id": 454283,
558 | "original_language": "en",
559 | "original_title": "Action Point",
560 | "overview": "A daredevil designs and operates his own theme park with his friends.",
561 | "poster_path": "/5lqJx0uNKrD1cEKgaqF1LBsLAoi.jpg",
562 | "release_date": "2018-06-01",
563 | "title": "Action Point",
564 | "video": false,
565 | "vote_average": 5.3,
566 | "vote_count": 31,
567 | "popularity": 33.909
568 | },
569 | {
570 | "adult": false,
571 | "backdrop_path": "/cS6S6OcvcAjx0aBzvHPy1Sm4Snj.jpg",
572 | "genre_ids": [
573 | 18,
574 | 14,
575 | 27,
576 | 53
577 | ],
578 | "id": 421792,
579 | "original_language": "en",
580 | "original_title": "Down a Dark Hall",
581 | "overview": "Kitt Gordy, a new student at the exclusive Blackwood Boarding School, confronts the institution's supernatural occurrences and dark powers of its headmistress.",
582 | "poster_path": "/wErHaJrD1QZ2FEVneH6w0GZUz2L.jpg",
583 | "release_date": "2018-08-01",
584 | "title": "Down a Dark Hall",
585 | "video": false,
586 | "vote_average": 5.5,
587 | "vote_count": 30,
588 | "popularity": 11.162
589 | },
590 | {
591 | "adult": false,
592 | "backdrop_path": "/64jAqTJvrzEwncD3ARZdqYLcqbc.jpg",
593 | "genre_ids": [
594 | 12,
595 | 53,
596 | 10749
597 | ],
598 | "id": 429300,
599 | "original_language": "en",
600 | "original_title": "Adrift",
601 | "overview": "A true story of survival, as a young couple's chance encounter leads them first to love, and then on the adventure of a lifetime as they face one of the most catastrophic hurricanes in recorded history.",
602 | "poster_path": "/5gLDeADaETvwQlQow5szlyuhLbj.jpg",
603 | "release_date": "2018-05-31",
604 | "title": "Adrift",
605 | "video": false,
606 | "vote_average": 6.4,
607 | "vote_count": 170,
608 | "popularity": 49.661
609 | },
610 | {
611 | "adult": false,
612 | "backdrop_path": "/gRtLcCQOpYUI9ThdVzi4VUP8QO3.jpg",
613 | "genre_ids": [
614 | 18,
615 | 36,
616 | 10752
617 | ],
618 | "id": 857,
619 | "original_language": "en",
620 | "original_title": "Saving Private Ryan",
621 | "overview": "As U.S. troops storm the beaches of Normandy, three brothers lie dead on the battlefield, with a fourth trapped behind enemy lines. Ranger captain John Miller and seven men are tasked with penetrating German-held territory and bringing the boy home.",
622 | "poster_path": "/miDoEMlYDJhOCvxlzI0wZqBs9Yt.jpg",
623 | "release_date": "1998-07-24",
624 | "title": "Saving Private Ryan",
625 | "video": false,
626 | "vote_average": 8,
627 | "vote_count": 6840,
628 | "popularity": 15.153
629 | },
630 | {
631 | "adult": false,
632 | "backdrop_path": "/aOQjLmHGuFy3hsY26QDIctxjMol.jpg",
633 | "genre_ids": [
634 | 18,
635 | 53
636 | ],
637 | "id": 470918,
638 | "original_language": "en",
639 | "original_title": "Beast",
640 | "overview": "A troubled woman living in an isolated community finds herself pulled between the control of her oppressive family and the allure of a secretive outsider suspected of a series of brutal murders.",
641 | "poster_path": "/kZdncyp1IKhEqwv5zdmUpK5Dc7S.jpg",
642 | "release_date": "2018-04-18",
643 | "title": "Beast",
644 | "video": false,
645 | "vote_average": 6.9,
646 | "vote_count": 19,
647 | "popularity": 2.492
648 | },
649 | {
650 | "id": 353081,
651 | "video": false,
652 | "vote_count": 952,
653 | "vote_average": 7.5,
654 | "title": "Mission: Impossible - Fallout",
655 | "release_date": "2018-07-25",
656 | "original_language": "en",
657 | "original_title": "Mission: Impossible - Fallout",
658 | "genre_ids": [
659 | 28,
660 | 12,
661 | 53
662 | ],
663 | "backdrop_path": "/5qxePyMYDisLe8rJiBYX8HKEyv2.jpg",
664 | "adult": false,
665 | "overview": "When an IMF mission ends badly, the world is faced with dire consequences. As Ethan Hunt takes it upon himself to fulfil his original briefing, the CIA begin to question his loyalty and his motives. The IMF team find themselves in a race against time, hunted by assassins while trying to prevent a global catastrophe.",
666 | "poster_path": "/AkJQpZp9WoNdj7pLYSj1L0RcMMN.jpg",
667 | "popularity": 139.023
668 | },
669 | {
670 | "adult": false,
671 | "backdrop_path": "/kNAzo7icHdFkF43JQa18mPEUtvf.jpg",
672 | "genre_ids": [
673 | 12,
674 | 16,
675 | 14
676 | ],
677 | "id": 271706,
678 | "original_language": "zh",
679 | "original_title": "大魚海棠",
680 | "overview": "Beyond the human realm, there is a magical race of beings who control the tides and the changing of the seasons. One of these beings, a young girl named Chun, seeks something more—she wants to experience the human world! At sixteen, she finally gets her chance and transforms into a dolphin in order to explore the world that has her fascinated. But she soon discovers that it’s a dangerous place and nearly gets killed in a vortex. Luckily, her life is spared when a young boy sacrifices himself to save her. Moved by his kindness and courage, she uses magic to bring him back to life only to learn that this power comes at a serious price. On a new adventure, she’ll have to make her own sacrifices in order to protect his soul until it is ready to return to the human world.",
681 | "poster_path": "/fRCdXh9MZutj1JJPZlUXMex6AuB.jpg",
682 | "release_date": "2016-07-08",
683 | "title": "Big Fish & Begonia",
684 | "video": false,
685 | "vote_average": 6.9,
686 | "vote_count": 30,
687 | "popularity": 7.424
688 | },
689 | {
690 | "original_name": "Game of Thrones",
691 | "id": 1399,
692 | "name": "Game of Thrones",
693 | "vote_count": 4772,
694 | "vote_average": 8.2,
695 | "first_air_date": "2011-04-17",
696 | "poster_path": "/gwPSoYUHAKmdyVywgLpKKA4BjRr.jpg",
697 | "genre_ids": [
698 | 18,
699 | 10759,
700 | 10765
701 | ],
702 | "original_language": "en",
703 | "backdrop_path": "/gX8SYlnL9ZznfZwEH4KJUePBFUM.jpg",
704 | "overview": "Seven noble families fight for control of the mythical land of Westeros. Friction between the houses leads to full-scale war. All while a very ancient evil awakens in the farthest north. Amidst the war, a neglected military order of misfits, the Night's Watch, is all that stands between the realms of men and icy horrors beyond.",
705 | "origin_country": [
706 | "US"
707 | ],
708 | "popularity": 61.91
709 | },
710 | {
711 | "adult": false,
712 | "backdrop_path": "/5a7lMDn3nAj2ByO0X1fg6BhUphR.jpg",
713 | "genre_ids": [
714 | 12,
715 | 14,
716 | 878
717 | ],
718 | "id": 333339,
719 | "original_language": "en",
720 | "original_title": "Ready Player One",
721 | "overview": "When the creator of a popular video game system dies, a virtual contest is created to compete for his fortune.",
722 | "poster_path": "/pU1ULUq8D3iRxl1fdX2lZIzdHuI.jpg",
723 | "release_date": "2018-03-28",
724 | "title": "Ready Player One",
725 | "video": false,
726 | "vote_average": 7.7,
727 | "vote_count": 3673,
728 | "popularity": 68.153
729 | },
730 | {
731 | "adult": false,
732 | "backdrop_path": "/wWoCid7YUxiLhq3ZZT6CtFEDPXw.jpg",
733 | "genre_ids": [
734 | 28
735 | ],
736 | "id": 347375,
737 | "original_language": "en",
738 | "original_title": "Mile 22",
739 | "overview": "A CIA field officer and an Indonesian police officer are forced to work together in confronting political corruption. An informant must be moved twenty-two miles to safety.",
740 | "poster_path": "/2L8ehd95eSW9x7KINYtZmRkAlrZ.jpg",
741 | "release_date": "2018-08-10",
742 | "title": "Mile 22",
743 | "video": false,
744 | "vote_average": 6,
745 | "vote_count": 8,
746 | "popularity": 30.064
747 | },
748 | {
749 | "backdrop_path": "/okhLwP26UXHJ4KYGVsERQqp3129.jpg",
750 | "first_air_date": "2015-08-23",
751 | "genre_ids": [
752 | 18,
753 | 27
754 | ],
755 | "id": 62286,
756 | "name": "Fear the Walking Dead",
757 | "origin_country": [
758 | "US"
759 | ],
760 | "original_language": "en",
761 | "original_name": "Fear the Walking Dead",
762 | "overview": "What did the world look like as it was transforming into the horrifying apocalypse depicted in \"The Walking Dead\"? This spin-off set in Los Angeles, following new characters as they face the beginning of the end of the world, will answer that question.",
763 | "poster_path": "/gAEZitvNudXr9kphSd4XOlOkjPX.jpg",
764 | "vote_average": 6.4,
765 | "vote_count": 791,
766 | "popularity": 44.477
767 | },
768 | {
769 | "adult": false,
770 | "backdrop_path": "/bLJTjfbZ1c5zSNiAvGYs1Uc82ir.jpg",
771 | "genre_ids": [
772 | 28,
773 | 12,
774 | 14
775 | ],
776 | "id": 338970,
777 | "original_language": "en",
778 | "original_title": "Tomb Raider",
779 | "overview": "Lara Croft, the fiercely independent daughter of a missing adventurer, must push herself beyond her limits when she finds herself on the island where her father disappeared.",
780 | "poster_path": "/3zrC5tUiR35rTz9stuIxnU1nUS5.jpg",
781 | "release_date": "2018-03-05",
782 | "title": "Tomb Raider",
783 | "video": false,
784 | "vote_average": 6.3,
785 | "vote_count": 2530,
786 | "popularity": 44.164
787 | },
788 | {
789 | "id": 345940,
790 | "video": false,
791 | "vote_count": 310,
792 | "vote_average": 6.3,
793 | "title": "The Meg",
794 | "release_date": "2018-08-09",
795 | "original_language": "en",
796 | "original_title": "The Meg",
797 | "genre_ids": [
798 | 28,
799 | 27,
800 | 878,
801 | 53
802 | ],
803 | "backdrop_path": "/ibKeXahq4JD63z6uWQphqoJLvNw.jpg",
804 | "adult": false,
805 | "overview": "A deep sea submersible pilot revisits his past fears in the Mariana Trench, and accidentally unleashes the seventy foot ancestor of the Great White Shark believed to be extinct.",
806 | "poster_path": "/xqECHNvzbDL5I3iiOVUkVPJMSbc.jpg",
807 | "popularity": 198.941
808 | }
809 | ]
810 | },
811 | {
812 | "id": 2,
813 | "title": "New Movies",
814 | "details": [
815 | {
816 | "adult": false,
817 | "backdrop_path": "/bQXAqRx2Fgc46uCVWgoPz5L5Dtr.jpg",
818 | "genre_ids": [
819 | 28,
820 | 14,
821 | 878
822 | ],
823 | "id": 436270,
824 | "original_language": "en",
825 | "original_title": "Black Adam",
826 | "overview": "Nearly 5,000 years after he was bestowed with the almighty powers of the Egyptian gods—and imprisoned just as quickly—Black Adam is freed from his earthly tomb, ready to unleash his unique form of justice on the modern world.",
827 | "popularity": 9137.939,
828 | "poster_path": "/pFlaoHTZeyNkG83vxsAJiGzfSsa.jpg",
829 | "release_date": "2022-10-19",
830 | "title": "Black Adam",
831 | "video": false,
832 | "vote_average": 7.3,
833 | "vote_count": 2296
834 | },
835 | {
836 | "adult": false,
837 | "backdrop_path": "/7zQJYV02yehWrQN6NjKsBorqUUS.jpg",
838 | "genre_ids": [
839 | 28,
840 | 18,
841 | 36
842 | ],
843 | "id": 724495,
844 | "original_language": "en",
845 | "original_title": "The Woman King",
846 | "overview": "The story of the Agojie, the all-female unit of warriors who protected the African Kingdom of Dahomey in the 1800s with skills and a fierceness unlike anything the world has ever seen, and General Nanisca as she trains the next generation of recruits and readies them for battle against an enemy determined to destroy their way of life.",
847 | "popularity": 4835.899,
848 | "poster_path": "/438QXt1E3WJWb3PqNniK0tAE5c1.jpg",
849 | "release_date": "2022-09-15",
850 | "title": "The Woman King",
851 | "video": false,
852 | "vote_average": 7.9,
853 | "vote_count": 552
854 | },
855 | {
856 | "adult": false,
857 | "backdrop_path": "/90ZZIoWQLLEXSVm0ik3eEQBinul.jpg",
858 | "genre_ids": [
859 | 28,
860 | 27,
861 | 53
862 | ],
863 | "id": 988233,
864 | "original_language": "en",
865 | "original_title": "Hex",
866 | "overview": "Following a mysterious disappearance on a jump, a group of skydivers experience paranormal occurrences that leave them fighting for their lives.",
867 | "popularity": 2444.032,
868 | "poster_path": "/xFJHb43ZAnnuiDztxZYsmyopweb.jpg",
869 | "release_date": "2022-11-01",
870 | "title": "Hex",
871 | "video": false,
872 | "vote_average": 3.8,
873 | "vote_count": 8
874 | },
875 | {
876 | "adult": false,
877 | "backdrop_path": "/kmzppWh7ljL6K9fXW72bPN3gKwu.jpg",
878 | "genre_ids": [
879 | 14,
880 | 28,
881 | 35,
882 | 80
883 | ],
884 | "id": 1013860,
885 | "original_language": "en",
886 | "original_title": "R.I.P.D. 2: Rise of the Damned",
887 | "overview": "When Sheriff Roy Pulsipher finds himself in the afterlife, he joins a special police force and returns to Earth to save humanity from the undead.",
888 | "popularity": 3173.029,
889 | "poster_path": "/g4yJTzMtOBUTAR2Qnmj8TYIcFVq.jpg",
890 | "release_date": "2022-11-15",
891 | "title": "R.I.P.D. 2: Rise of the Damned",
892 | "video": false,
893 | "vote_average": 6.8,
894 | "vote_count": 191
895 | },
896 | {
897 | "adult": false,
898 | "backdrop_path": "/707thQazLJiYLBhCrZlRoV05NNL.jpg",
899 | "genre_ids": [
900 | 28,
901 | 18,
902 | 53
903 | ],
904 | "id": 948276,
905 | "original_language": "fr",
906 | "original_title": "Balle perdue 2",
907 | "overview": "Having cleared his name, genius mechanic Lino has only one goal in mind: getting revenge on the corrupt cops who killed his brother and his mentor.",
908 | "popularity": 2504.871,
909 | "poster_path": "/uAeZI1JJbLPq7Bu5dziH7emHeu7.jpg",
910 | "release_date": "2022-11-10",
911 | "title": "Lost Bullet 2",
912 | "video": false,
913 | "vote_average": 6.7,
914 | "vote_count": 134
915 | },
916 | {
917 | "adult": false,
918 | "backdrop_path": "/au4HUSWDRadIcl9CqySlw1kJMfo.jpg",
919 | "genre_ids": [
920 | 80,
921 | 28,
922 | 53
923 | ],
924 | "id": 829799,
925 | "original_language": "en",
926 | "original_title": "Paradise City",
927 | "overview": "Renegade bounty hunter Ryan Swan must carve his way through the Hawaiian crime world to wreak vengeance on the kingpin who murdered his father.",
928 | "popularity": 2126.399,
929 | "poster_path": "/uGuHHS9SWv7MrFhCH6zoGGd7DA8.jpg",
930 | "release_date": "2022-11-11",
931 | "title": "Paradise City",
932 | "video": false,
933 | "vote_average": 6.1,
934 | "vote_count": 33
935 | },
936 | {
937 | "adult": false,
938 | "backdrop_path": "/8Tr79lfoCkOYRg8SYwWit4OoQLi.jpg",
939 | "genre_ids": [
940 | 878,
941 | 28
942 | ],
943 | "id": 872177,
944 | "original_language": "en",
945 | "original_title": "Corrective Measures",
946 | "overview": "Set in San Tiburon, the world's most dangerous maximum-security penitentiary and home to the world's most treacherous superpowered criminals, where tensions among the inmates and staff heighten, leading to anarchy that engulfs the prison and order is turned upside down.",
947 | "popularity": 1528.562,
948 | "poster_path": "/aHFq9NMhavOL0jtQvmHQ1c5e0ya.jpg",
949 | "release_date": "2022-04-29",
950 | "title": "Corrective Measures",
951 | "video": false,
952 | "vote_average": 5.1,
953 | "vote_count": 35
954 | },
955 | {
956 | "adult": false,
957 | "backdrop_path": "/sP1ShE4BGLkHSRqG9ZeGHg6C76t.jpg",
958 | "genre_ids": [
959 | 53,
960 | 80
961 | ],
962 | "id": 934641,
963 | "original_language": "en",
964 | "original_title": "The Minute You Wake Up Dead",
965 | "overview": "A stockbroker in a small southern town gets embroiled in an insurance scam with a next-door neighbor that leads to multiple murders when a host of other people want in on the plot. Sheriff Thurmond Fowler, the by-the-book town sheriff for over four decades, works earnestly to try and unravel the town’s mystery and winds up getting more than he bargained for.",
966 | "popularity": 1503.761,
967 | "poster_path": "/pUPwTbnAqfm95BZjNBnMMf39ChT.jpg",
968 | "release_date": "2022-11-04",
969 | "title": "The Minute You Wake Up Dead",
970 | "video": false,
971 | "vote_average": 4.9,
972 | "vote_count": 19
973 | },
974 | {
975 | "adult": false,
976 | "backdrop_path": null,
977 | "genre_ids": [
978 | 10749
979 | ],
980 | "id": 485470,
981 | "original_language": "ko",
982 | "original_title": "착한 형수2",
983 | "overview": "If you give it once, a good brother-in-law who gives everything generously will come! At the house of her girlfriend Jin-kyung, who lives with pumice stone, her brother and his wife suddenly visit and the four of them live together. At first, Kyung-seok, who was burdened by his girlfriend's brother, began to keep his eyes on his wife, Yeon-su. A bold brother-in-law who walks around in no-bra and panties without hesitation even at his sister-in-law's house. Besides, from a certain moment, he starts to send a hand of temptation to Pyeong-seok first...",
984 | "popularity": 1953.437,
985 | "poster_path": "/3pEs4hmeHvTAsmx09whEaPDOQpq.jpg",
986 | "release_date": "2017-10-08",
987 | "title": "Nice Sister-In-Law 2",
988 | "video": false,
989 | "vote_average": 6,
990 | "vote_count": 2
991 | },
992 | {
993 | "adult": false,
994 | "backdrop_path": "/xDMIl84Qo5Tsu62c9DGWhmPI67A.jpg",
995 | "genre_ids": [
996 | 28,
997 | 12,
998 | 878
999 | ],
1000 | "id": 505642,
1001 | "original_language": "en",
1002 | "original_title": "Black Panther: Wakanda Forever",
1003 | "overview": "Queen Ramonda, Shuri, M’Baku, Okoye and the Dora Milaje fight to protect their nation from intervening world powers in the wake of King T’Challa’s death. As the Wakandans strive to embrace their next chapter, the heroes must band together with the help of War Dog Nakia and Everett Ross and forge a new path for the kingdom of Wakanda.",
1004 | "popularity": 1687.653,
1005 | "poster_path": "/ps2oKfhY6DL3alynlSqY97gHSsg.jpg",
1006 | "release_date": "2022-11-09",
1007 | "title": "Black Panther: Wakanda Forever",
1008 | "video": false,
1009 | "vote_average": 7.6,
1010 | "vote_count": 1129
1011 | },
1012 | {
1013 | "adult": false,
1014 | "backdrop_path": "/gVecEIEZLZg3pV5CACXAB48I6au.jpg",
1015 | "genre_ids": [
1016 | 80,
1017 | 18,
1018 | 9648,
1019 | 53
1020 | ],
1021 | "id": 862965,
1022 | "original_language": "en",
1023 | "original_title": "Emily the Criminal",
1024 | "overview": "Emily, who is saddled with student debt and locked out of the job market due to a minor criminal record, gets involved in a credit card scam that pulls her into the criminal underworld of Los Angeles, ultimately leading to deadly consequences.",
1025 | "popularity": 1023.229,
1026 | "poster_path": "/iZvzMpREGiqDQ5eYbx8z70qPgst.jpg",
1027 | "release_date": "2022-08-12",
1028 | "title": "Emily the Criminal",
1029 | "video": false,
1030 | "vote_average": 6.9,
1031 | "vote_count": 215
1032 | },
1033 | {
1034 | "adult": false,
1035 | "backdrop_path": "/kpUre8wWSXn3D5RhrMttBZa6w1v.jpg",
1036 | "genre_ids": [
1037 | 35,
1038 | 10751,
1039 | 14
1040 | ],
1041 | "id": 338958,
1042 | "original_language": "en",
1043 | "original_title": "Disenchanted",
1044 | "overview": "Disillusioned with life in the city, feeling out of place in suburbia, and frustrated that her happily ever after hasn’t been so easy to find, Giselle turns to the magic of Andalasia for help. Accidentally transforming the entire town into a real-life fairy tale and placing her family’s future happiness in jeopardy, she must race against time to reverse the spell and determine what happily ever after truly means to her and her family.",
1045 | "popularity": 1468.421,
1046 | "poster_path": "/4x3pt6hoLblBeHebUa4OyiVXFiM.jpg",
1047 | "release_date": "2022-11-16",
1048 | "title": "Disenchanted",
1049 | "video": false,
1050 | "vote_average": 7.3,
1051 | "vote_count": 445
1052 | },
1053 | {
1054 | "adult": false,
1055 | "backdrop_path": "/eyiSLRh44SKKWIJ6bxWq8z1sscB.jpg",
1056 | "genre_ids": [
1057 | 53,
1058 | 27,
1059 | 80
1060 | ],
1061 | "id": 899294,
1062 | "original_language": "en",
1063 | "original_title": "Frank and Penelope",
1064 | "overview": "A tale of love and violence when a man on his emotional last legs finds a savior seductively dancing in a run-down strip club. And a life most certainly headed off a cliff suddenly becomes redirected - as everything is now worth dying for.",
1065 | "popularity": 1406.877,
1066 | "poster_path": "/5NpXoAi3nEQkEgLO09nmotPfyNa.jpg",
1067 | "release_date": "2022-06-03",
1068 | "title": "Frank and Penelope",
1069 | "video": false,
1070 | "vote_average": 7.6,
1071 | "vote_count": 40
1072 | },
1073 | {
1074 | "adult": false,
1075 | "backdrop_path": "/c1bz69r0v065TGFA5nqBiKzPDys.jpg",
1076 | "genre_ids": [
1077 | 35,
1078 | 10751,
1079 | 10402
1080 | ],
1081 | "id": 830784,
1082 | "original_language": "en",
1083 | "original_title": "Lyle, Lyle, Crocodile",
1084 | "overview": "When the Primm family moves to New York City, their young son Josh struggles to adapt to his new school and new friends. All of that changes when he discovers Lyle — a singing crocodile who loves baths, caviar and great music — living in the attic of his new home. But when Lyle’s existence is threatened by evil neighbor Mr. Grumps, the Primms must band together to show the world that family can come from the most unexpected places.",
1085 | "popularity": 1548.885,
1086 | "poster_path": "/CpaU433AomkCvwAhR3KROUIFJO.jpg",
1087 | "release_date": "2022-10-07",
1088 | "title": "Lyle, Lyle, Crocodile",
1089 | "video": false,
1090 | "vote_average": 7.7,
1091 | "vote_count": 104
1092 | },
1093 | {
1094 | "adult": false,
1095 | "backdrop_path": "/AokFVAl1JVooW1uz2V2vxNUxfit.jpg",
1096 | "genre_ids": [
1097 | 36,
1098 | 28,
1099 | 18
1100 | ],
1101 | "id": 551271,
1102 | "original_language": "en",
1103 | "original_title": "Medieval",
1104 | "overview": "The story of 14th century Czech icon and warlord Jan Zizka who defeated armies of the Teutonic Order and the Holy Roman Empire.",
1105 | "popularity": 1043.02,
1106 | "poster_path": "/4njdAkiBdC5LnFApeXSkFQ78GdT.jpg",
1107 | "release_date": "2022-09-08",
1108 | "title": "Medieval",
1109 | "video": false,
1110 | "vote_average": 7.2,
1111 | "vote_count": 201
1112 | },
1113 | {
1114 | "adult": false,
1115 | "backdrop_path": "/olPXihyFeeNvnaD6IOBltgIV1FU.jpg",
1116 | "genre_ids": [
1117 | 27,
1118 | 9648,
1119 | 53
1120 | ],
1121 | "id": 882598,
1122 | "original_language": "en",
1123 | "original_title": "Smile",
1124 | "overview": "After witnessing a bizarre, traumatic incident involving a patient, Dr. Rose Cotter starts experiencing frightening occurrences that she can't explain. As an overwhelming terror begins taking over her life, Rose must confront her troubling past in order to survive and escape her horrifying new reality.",
1125 | "popularity": 1105.399,
1126 | "poster_path": "/aPqcQwu4VGEewPhagWNncDbJ9Xp.jpg",
1127 | "release_date": "2022-09-23",
1128 | "title": "Smile",
1129 | "video": false,
1130 | "vote_average": 6.8,
1131 | "vote_count": 997
1132 | },
1133 | {
1134 | "adult": false,
1135 | "backdrop_path": "/sUuzl04qNIYsnwCLQpZ2RSvXA1V.jpg",
1136 | "genre_ids": [
1137 | 35,
1138 | 28,
1139 | 53
1140 | ],
1141 | "id": 792775,
1142 | "original_language": "is",
1143 | "original_title": "Leynilögga",
1144 | "overview": "When Bússi, Iceland's toughest cop, is forced to work with a new partner to solve a series of bank robberies, the pressure to close the case as soon as possible proves too much for him.",
1145 | "popularity": 1800.201,
1146 | "poster_path": "/jnWyZsaCl3Ke6u6ReSmBRO8S1rX.jpg",
1147 | "release_date": "2022-05-23",
1148 | "title": "Cop Secret",
1149 | "video": false,
1150 | "vote_average": 6.2,
1151 | "vote_count": 26
1152 | },
1153 | {
1154 | "adult": false,
1155 | "backdrop_path": "/sCOHkah9RbFeZfFnfBrcykKCMNa.jpg",
1156 | "genre_ids": [
1157 | 27,
1158 | 878
1159 | ],
1160 | "id": 846778,
1161 | "original_language": "en",
1162 | "original_title": "Margaux",
1163 | "overview": "As a group of seniors celebrate their final college days at a smart house, the house's highly advanced AI system, Margaux, begins to take on a deadly presence of her own. A carefree weekend of partying turns into a dystopian nightmare as they realize Margaux's plans to eliminate her tenants one way or another. Time begins to run out as the group desperately tries to survive and outsmart the smart home.",
1164 | "popularity": 975.133,
1165 | "poster_path": "/uNzgeMetu9l4q9NDw7gtiUFwPOJ.jpg",
1166 | "release_date": "2022-09-09",
1167 | "title": "Margaux",
1168 | "video": false,
1169 | "vote_average": 7,
1170 | "vote_count": 46
1171 | },
1172 | {
1173 | "adult": false,
1174 | "backdrop_path": "/yNib9QAiyaopUJbaayKQ2xK7mYf.jpg",
1175 | "genre_ids": [
1176 | 18,
1177 | 28,
1178 | 10752
1179 | ],
1180 | "id": 966220,
1181 | "original_language": "uk",
1182 | "original_title": "Снайпер. Білий ворон",
1183 | "overview": "Mykola is an eccentric pacifist who wants to be useful to humanity. When the war begins at Donbass, Mykola’s naive world is collapsing as the militants kill his pregnant wife and burn his home to the ground. Recovered, he makes a cardinal decision and gets enlisted in a sniper company. Having met his wife’s killers, he emotionally breaks down and arranges “sniper terror” for the enemy. He’s saved from a senseless death by his instructor who himself gets mortally wounded. The death of a friend leaves a “scar” and Mykola is ready to sacrifice his life.",
1184 | "popularity": 894.927,
1185 | "poster_path": "/lZOODJzwuQo0etJJyBBZJOSdZcW.jpg",
1186 | "release_date": "2022-05-03",
1187 | "title": "Sniper: The White Raven",
1188 | "video": false,
1189 | "vote_average": 7.6,
1190 | "vote_count": 141
1191 | },
1192 | {
1193 | "adult": false,
1194 | "backdrop_path": "/83Vt9Io9xSFKfKDdgxqKZgdqjuZ.jpg",
1195 | "genre_ids": [
1196 | 28,
1197 | 53,
1198 | 80
1199 | ],
1200 | "id": 972313,
1201 | "original_language": "en",
1202 | "original_title": "Blowback",
1203 | "overview": "When a master thief is sabotaged during a bank heist and left for dead, he seeks revenge on his former crew one target at a time. Now, with the cops and the mob closing in, he's in the race of his life to reclaim an untold fortune in cryptocurrency from those who double-crossed him.",
1204 | "popularity": 1358.078,
1205 | "poster_path": "/fHQHC32dhom8u0OxC2hs2gYQh0M.jpg",
1206 | "release_date": "2022-06-17",
1207 | "title": "Blowback",
1208 | "video": false,
1209 | "vote_average": 5.6,
1210 | "vote_count": 19
1211 | }
1212 | ]
1213 | }
1214 | ]
1215 | }
--------------------------------------------------------------------------------
/app/src/main/java/com/tutorial/tvapp/DataModel.kt:
--------------------------------------------------------------------------------
1 | package com.tutorial.tvapp
2 |
3 | data class DataModel(
4 | val result: List = listOf()
5 | ) {
6 | data class Result(
7 | val details: List = listOf(),
8 | val id: Int = 0,
9 | val title: String = ""
10 | ) {
11 | data class Detail(
12 | val adult: Boolean = false,
13 | val backdrop_path: String = "",
14 | val first_air_date: String = "",
15 | val genre_ids: List = listOf(),
16 | val id: Int = 0,
17 | val name: String = "",
18 | val origin_country: List = listOf(),
19 | val original_language: String = "",
20 | val original_name: String = "",
21 | val original_title: String = "",
22 | val overview: String = "",
23 | val popularity: Double = 0.0,
24 | val poster_path: String = "",
25 | val release_date: String = "",
26 | val title: String = "",
27 | val video: Boolean = false,
28 | val vote_average: Double = 0.0,
29 | val vote_count: Int = 0
30 | )
31 | }
32 | }
--------------------------------------------------------------------------------
/app/src/main/java/com/tutorial/tvapp/ItemPresenter.kt:
--------------------------------------------------------------------------------
1 | package com.tutorial.tvapp
2 |
3 | import android.content.Context
4 | import android.view.LayoutInflater
5 | import android.view.ViewGroup
6 | import android.widget.ImageView
7 | import androidx.leanback.widget.Presenter
8 | import com.bumptech.glide.Glide
9 |
10 | class ItemPresenter : Presenter() {
11 | override fun onCreateViewHolder(parent: ViewGroup?): ViewHolder {
12 |
13 | val view =
14 | LayoutInflater.from(parent?.context).inflate(R.layout.item_view, parent, false)
15 |
16 | val params = view.layoutParams
17 | params.width = getWidthInPercent(parent!!.context, 12)
18 | params.height = getHeightInPercent(parent!!.context, 32)
19 |
20 | return ViewHolder(view)
21 |
22 | }
23 |
24 | fun getWidthInPercent(context: Context, percent: Int): Int {
25 | val width = context.resources.displayMetrics.widthPixels ?: 0
26 | return (width * percent) / 100
27 | }
28 |
29 | fun getHeightInPercent(context: Context, percent: Int): Int {
30 | val width = context.resources.displayMetrics.heightPixels ?: 0
31 | return (width * percent) / 100
32 | }
33 |
34 |
35 | override fun onBindViewHolder(viewHolder: ViewHolder?, item: Any?) {
36 |
37 | val content = item as? DataModel.Result.Detail
38 |
39 | val imageview = viewHolder?.view?.findViewById(R.id.poster_image)
40 |
41 | val url = "https://www.themoviedb.org/t/p/w500" + content?.poster_path
42 | Glide.with(viewHolder?.view?.context!!)
43 | .load(url)
44 | .into(imageview!!)
45 |
46 | }
47 |
48 | override fun onUnbindViewHolder(viewHolder: ViewHolder?) {
49 | }
50 | }
--------------------------------------------------------------------------------
/app/src/main/java/com/tutorial/tvapp/ListFragment.kt:
--------------------------------------------------------------------------------
1 | package com.tutorial.tvapp
2 |
3 | import android.os.Bundle
4 | import androidx.fragment.app.Fragment
5 | import android.view.LayoutInflater
6 | import android.view.View
7 | import android.view.ViewGroup
8 | import androidx.leanback.app.RowsSupportFragment
9 | import androidx.leanback.widget.*
10 |
11 |
12 | class ListFragment : RowsSupportFragment() {
13 |
14 | private var itemSelectedListener: ((DataModel.Result.Detail) -> Unit)? = null
15 | private var rootAdapter: ArrayObjectAdapter =
16 | ArrayObjectAdapter(ListRowPresenter(FocusHighlight.ZOOM_FACTOR_MEDIUM))
17 |
18 | override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
19 | super.onViewCreated(view, savedInstanceState)
20 |
21 | adapter = rootAdapter
22 |
23 | onItemViewSelectedListener = ItemViewSelectedListener()
24 | }
25 |
26 | fun bindData(dataList: DataModel) {
27 |
28 | dataList.result.forEachIndexed { index, result ->
29 | val arrayObjectAdapter = ArrayObjectAdapter(ItemPresenter())
30 |
31 | result.details.forEach {
32 | arrayObjectAdapter.add(it)
33 | }
34 |
35 | val headerItem = HeaderItem(result.title)
36 | val listRow = ListRow(headerItem, arrayObjectAdapter)
37 | rootAdapter.add(listRow)
38 |
39 | }
40 |
41 | }
42 |
43 | fun setOnContentSelectedListener(listener : (DataModel.Result.Detail) -> Unit){
44 | this.itemSelectedListener = listener
45 | }
46 |
47 | inner class ItemViewSelectedListener : OnItemViewSelectedListener{
48 | override fun onItemSelected(
49 | itemViewHolder: Presenter.ViewHolder?,
50 | item: Any?,
51 | rowViewHolder: RowPresenter.ViewHolder?,
52 | row: Row?
53 | ) {
54 | if (item is DataModel.Result.Detail){
55 | itemSelectedListener?.invoke(item)
56 | }
57 |
58 | }
59 |
60 | }
61 |
62 | }
--------------------------------------------------------------------------------
/app/src/main/java/com/tutorial/tvapp/MainActivity.kt:
--------------------------------------------------------------------------------
1 | package com.tutorial.tvapp
2 |
3 | import android.os.Bundle
4 | import android.widget.ImageView
5 | import android.widget.TextView
6 | import androidx.fragment.app.FragmentActivity
7 | import com.bumptech.glide.Glide
8 | import com.google.gson.Gson
9 | import java.io.BufferedReader
10 | import java.io.InputStream
11 | import java.io.InputStreamReader
12 |
13 | class MainActivity : FragmentActivity() {
14 |
15 | lateinit var txtTitle: TextView
16 | lateinit var txtSubTitle: TextView
17 | lateinit var txtDescription: TextView
18 |
19 | lateinit var imgBanner: ImageView
20 | lateinit var listFragment: ListFragment
21 |
22 | override fun onCreate(savedInstanceState: Bundle?) {
23 | super.onCreate(savedInstanceState)
24 | setContentView(R.layout.activity_main)
25 |
26 | imgBanner = findViewById(R.id.img_banner)
27 | txtTitle = findViewById(R.id.title)
28 | txtSubTitle = findViewById(R.id.subtitle)
29 | txtDescription = findViewById(R.id.description)
30 |
31 |
32 | listFragment = ListFragment()
33 | val transaction = supportFragmentManager.beginTransaction()
34 | transaction.add(R.id.list_fragment, listFragment)
35 | transaction.commit()
36 |
37 |
38 | val gson = Gson()
39 | val i: InputStream = this.assets.open("movies.json")
40 | val br = BufferedReader(InputStreamReader(i))
41 | val dataList: DataModel = gson.fromJson(br, DataModel::class.java)
42 |
43 | listFragment.bindData(dataList)
44 |
45 | listFragment.setOnContentSelectedListener {
46 | updateBanner(it)
47 | }
48 |
49 | }
50 |
51 | fun updateBanner(dataList: DataModel.Result.Detail) {
52 | txtTitle.text = dataList.title
53 | txtDescription.text = dataList.overview
54 |
55 |
56 | val url = "https://www.themoviedb.org/t/p/w780" + dataList.backdrop_path
57 | Glide.with(this).load(url).into(imgBanner)
58 | }
59 |
60 | }
--------------------------------------------------------------------------------
/app/src/main/res/drawable/banner_gradient.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
8 |
9 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/activity_main.xml:
--------------------------------------------------------------------------------
1 |
2 |
9 |
10 |
16 |
17 |
23 |
24 |
30 |
31 |
41 |
42 |
53 |
54 |
65 |
66 |
76 |
77 |
91 |
92 |
101 |
102 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/fragment_list.xml:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 |
9 |
13 |
14 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/item_view.xml:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 |
12 |
13 |
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-hdpi/ic_launcher.webp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tvdevelopmenttutorial/tv_tutorial/283931adcc3732dc322784e27ad0e57185d4d12f/app/src/main/res/mipmap-hdpi/ic_launcher.webp
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-mdpi/ic_launcher.webp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tvdevelopmenttutorial/tv_tutorial/283931adcc3732dc322784e27ad0e57185d4d12f/app/src/main/res/mipmap-mdpi/ic_launcher.webp
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xhdpi/ic_launcher.webp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tvdevelopmenttutorial/tv_tutorial/283931adcc3732dc322784e27ad0e57185d4d12f/app/src/main/res/mipmap-xhdpi/ic_launcher.webp
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxhdpi/ic_launcher.webp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tvdevelopmenttutorial/tv_tutorial/283931adcc3732dc322784e27ad0e57185d4d12f/app/src/main/res/mipmap-xxhdpi/ic_launcher.webp
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxxhdpi/ic_launcher.webp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tvdevelopmenttutorial/tv_tutorial/283931adcc3732dc322784e27ad0e57185d4d12f/app/src/main/res/mipmap-xxxhdpi/ic_launcher.webp
--------------------------------------------------------------------------------
/app/src/main/res/values/strings.xml:
--------------------------------------------------------------------------------
1 |
2 | TvApp
3 |
4 | Hello blank fragment
5 |
--------------------------------------------------------------------------------
/app/src/main/res/values/themes.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/build.gradle:
--------------------------------------------------------------------------------
1 | // Top-level build file where you can add configuration options common to all sub-projects/modules.
2 | plugins {
3 | id 'com.android.application' version '7.1.3' apply false
4 | id 'com.android.library' version '7.1.3' apply false
5 | id 'org.jetbrains.kotlin.android' version '1.6.21' apply false
6 | }
7 |
8 | task clean(type: Delete) {
9 | delete rootProject.buildDir
10 | }
--------------------------------------------------------------------------------
/gradle.properties:
--------------------------------------------------------------------------------
1 | # Project-wide Gradle settings.
2 | # IDE (e.g. Android Studio) users:
3 | # Gradle settings configured through the IDE *will override*
4 | # any settings specified in this file.
5 | # For more details on how to configure your build environment visit
6 | # http://www.gradle.org/docs/current/userguide/build_environment.html
7 | # Specifies the JVM arguments used for the daemon process.
8 | # The setting is particularly useful for tweaking memory settings.
9 | org.gradle.jvmargs=-Xmx2048m -Dfile.encoding=UTF-8
10 | # When configured, Gradle will run in incubating parallel mode.
11 | # This option should only be used with decoupled projects. More details, visit
12 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
13 | # org.gradle.parallel=true
14 | # AndroidX package structure to make it clearer which packages are bundled with the
15 | # Android operating system, and which are packaged with your app"s APK
16 | # https://developer.android.com/topic/libraries/support-library/androidx-rn
17 | android.useAndroidX=true
18 | # Kotlin code style for this project: "official" or "obsolete":
19 | kotlin.code.style=official
20 | # Enables namespacing of each library's R class so that its R class includes only the
21 | # resources declared in the library itself and none from the library's dependencies,
22 | # thereby reducing the size of the R class for that library
23 | android.nonTransitiveRClass=true
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tvdevelopmenttutorial/tv_tutorial/283931adcc3732dc322784e27ad0e57185d4d12f/gradle/wrapper/gradle-wrapper.jar
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.properties:
--------------------------------------------------------------------------------
1 | #Wed Dec 07 16:34:10 IST 2022
2 | distributionBase=GRADLE_USER_HOME
3 | distributionUrl=https\://services.gradle.org/distributions/gradle-7.2-bin.zip
4 | distributionPath=wrapper/dists
5 | zipStorePath=wrapper/dists
6 | zipStoreBase=GRADLE_USER_HOME
7 |
--------------------------------------------------------------------------------
/gradlew:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env sh
2 |
3 | #
4 | # Copyright 2015 the original author or authors.
5 | #
6 | # Licensed under the Apache License, Version 2.0 (the "License");
7 | # you may not use this file except in compliance with the License.
8 | # You may obtain a copy of the License at
9 | #
10 | # https://www.apache.org/licenses/LICENSE-2.0
11 | #
12 | # Unless required by applicable law or agreed to in writing, software
13 | # distributed under the License is distributed on an "AS IS" BASIS,
14 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 | # See the License for the specific language governing permissions and
16 | # limitations under the License.
17 | #
18 |
19 | ##############################################################################
20 | ##
21 | ## Gradle start up script for UN*X
22 | ##
23 | ##############################################################################
24 |
25 | # Attempt to set APP_HOME
26 | # Resolve links: $0 may be a link
27 | PRG="$0"
28 | # Need this for relative symlinks.
29 | while [ -h "$PRG" ] ; do
30 | ls=`ls -ld "$PRG"`
31 | link=`expr "$ls" : '.*-> \(.*\)$'`
32 | if expr "$link" : '/.*' > /dev/null; then
33 | PRG="$link"
34 | else
35 | PRG=`dirname "$PRG"`"/$link"
36 | fi
37 | done
38 | SAVED="`pwd`"
39 | cd "`dirname \"$PRG\"`/" >/dev/null
40 | APP_HOME="`pwd -P`"
41 | cd "$SAVED" >/dev/null
42 |
43 | APP_NAME="Gradle"
44 | APP_BASE_NAME=`basename "$0"`
45 |
46 | # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
47 | DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
48 |
49 | # Use the maximum available, or set MAX_FD != -1 to use that value.
50 | MAX_FD="maximum"
51 |
52 | warn () {
53 | echo "$*"
54 | }
55 |
56 | die () {
57 | echo
58 | echo "$*"
59 | echo
60 | exit 1
61 | }
62 |
63 | # OS specific support (must be 'true' or 'false').
64 | cygwin=false
65 | msys=false
66 | darwin=false
67 | nonstop=false
68 | case "`uname`" in
69 | CYGWIN* )
70 | cygwin=true
71 | ;;
72 | Darwin* )
73 | darwin=true
74 | ;;
75 | MINGW* )
76 | msys=true
77 | ;;
78 | NONSTOP* )
79 | nonstop=true
80 | ;;
81 | esac
82 |
83 | CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
84 |
85 |
86 | # Determine the Java command to use to start the JVM.
87 | if [ -n "$JAVA_HOME" ] ; then
88 | if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
89 | # IBM's JDK on AIX uses strange locations for the executables
90 | JAVACMD="$JAVA_HOME/jre/sh/java"
91 | else
92 | JAVACMD="$JAVA_HOME/bin/java"
93 | fi
94 | if [ ! -x "$JAVACMD" ] ; then
95 | die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
96 |
97 | Please set the JAVA_HOME variable in your environment to match the
98 | location of your Java installation."
99 | fi
100 | else
101 | JAVACMD="java"
102 | which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
103 |
104 | Please set the JAVA_HOME variable in your environment to match the
105 | location of your Java installation."
106 | fi
107 |
108 | # Increase the maximum file descriptors if we can.
109 | if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then
110 | MAX_FD_LIMIT=`ulimit -H -n`
111 | if [ $? -eq 0 ] ; then
112 | if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
113 | MAX_FD="$MAX_FD_LIMIT"
114 | fi
115 | ulimit -n $MAX_FD
116 | if [ $? -ne 0 ] ; then
117 | warn "Could not set maximum file descriptor limit: $MAX_FD"
118 | fi
119 | else
120 | warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
121 | fi
122 | fi
123 |
124 | # For Darwin, add options to specify how the application appears in the dock
125 | if $darwin; then
126 | GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
127 | fi
128 |
129 | # For Cygwin or MSYS, switch paths to Windows format before running java
130 | if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then
131 | APP_HOME=`cygpath --path --mixed "$APP_HOME"`
132 | CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
133 |
134 | JAVACMD=`cygpath --unix "$JAVACMD"`
135 |
136 | # We build the pattern for arguments to be converted via cygpath
137 | ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
138 | SEP=""
139 | for dir in $ROOTDIRSRAW ; do
140 | ROOTDIRS="$ROOTDIRS$SEP$dir"
141 | SEP="|"
142 | done
143 | OURCYGPATTERN="(^($ROOTDIRS))"
144 | # Add a user-defined pattern to the cygpath arguments
145 | if [ "$GRADLE_CYGPATTERN" != "" ] ; then
146 | OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
147 | fi
148 | # Now convert the arguments - kludge to limit ourselves to /bin/sh
149 | i=0
150 | for arg in "$@" ; do
151 | CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
152 | CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
153 |
154 | if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
155 | eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
156 | else
157 | eval `echo args$i`="\"$arg\""
158 | fi
159 | i=`expr $i + 1`
160 | done
161 | case $i in
162 | 0) set -- ;;
163 | 1) set -- "$args0" ;;
164 | 2) set -- "$args0" "$args1" ;;
165 | 3) set -- "$args0" "$args1" "$args2" ;;
166 | 4) set -- "$args0" "$args1" "$args2" "$args3" ;;
167 | 5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
168 | 6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
169 | 7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
170 | 8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
171 | 9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
172 | esac
173 | fi
174 |
175 | # Escape application args
176 | save () {
177 | for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done
178 | echo " "
179 | }
180 | APP_ARGS=`save "$@"`
181 |
182 | # Collect all arguments for the java command, following the shell quoting and substitution rules
183 | eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS"
184 |
185 | exec "$JAVACMD" "$@"
186 |
--------------------------------------------------------------------------------
/gradlew.bat:
--------------------------------------------------------------------------------
1 | @rem
2 | @rem Copyright 2015 the original author or authors.
3 | @rem
4 | @rem Licensed under the Apache License, Version 2.0 (the "License");
5 | @rem you may not use this file except in compliance with the License.
6 | @rem You may obtain a copy of the License at
7 | @rem
8 | @rem https://www.apache.org/licenses/LICENSE-2.0
9 | @rem
10 | @rem Unless required by applicable law or agreed to in writing, software
11 | @rem distributed under the License is distributed on an "AS IS" BASIS,
12 | @rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | @rem See the License for the specific language governing permissions and
14 | @rem limitations under the License.
15 | @rem
16 |
17 | @if "%DEBUG%" == "" @echo off
18 | @rem ##########################################################################
19 | @rem
20 | @rem Gradle startup script for Windows
21 | @rem
22 | @rem ##########################################################################
23 |
24 | @rem Set local scope for the variables with windows NT shell
25 | if "%OS%"=="Windows_NT" setlocal
26 |
27 | set DIRNAME=%~dp0
28 | if "%DIRNAME%" == "" set DIRNAME=.
29 | set APP_BASE_NAME=%~n0
30 | set APP_HOME=%DIRNAME%
31 |
32 | @rem Resolve any "." and ".." in APP_HOME to make it shorter.
33 | for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi
34 |
35 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
36 | set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m"
37 |
38 | @rem Find java.exe
39 | if defined JAVA_HOME goto findJavaFromJavaHome
40 |
41 | set JAVA_EXE=java.exe
42 | %JAVA_EXE% -version >NUL 2>&1
43 | if "%ERRORLEVEL%" == "0" goto execute
44 |
45 | echo.
46 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
47 | echo.
48 | echo Please set the JAVA_HOME variable in your environment to match the
49 | echo location of your Java installation.
50 |
51 | goto fail
52 |
53 | :findJavaFromJavaHome
54 | set JAVA_HOME=%JAVA_HOME:"=%
55 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe
56 |
57 | if exist "%JAVA_EXE%" goto execute
58 |
59 | echo.
60 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
61 | echo.
62 | echo Please set the JAVA_HOME variable in your environment to match the
63 | echo location of your Java installation.
64 |
65 | goto fail
66 |
67 | :execute
68 | @rem Setup the command line
69 |
70 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
71 |
72 |
73 | @rem Execute Gradle
74 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %*
75 |
76 | :end
77 | @rem End local scope for the variables with windows NT shell
78 | if "%ERRORLEVEL%"=="0" goto mainEnd
79 |
80 | :fail
81 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
82 | rem the _cmd.exe /c_ return code!
83 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
84 | exit /b 1
85 |
86 | :mainEnd
87 | if "%OS%"=="Windows_NT" endlocal
88 |
89 | :omega
90 |
--------------------------------------------------------------------------------
/settings.gradle:
--------------------------------------------------------------------------------
1 | pluginManagement {
2 | repositories {
3 | gradlePluginPortal()
4 | google()
5 | mavenCentral()
6 | }
7 | }
8 | dependencyResolutionManagement {
9 | repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
10 | repositories {
11 | google()
12 | mavenCentral()
13 | }
14 | }
15 | rootProject.name = "TvApp"
16 | include ':app'
17 |
--------------------------------------------------------------------------------