aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorClyhtsuriva <aimeric@adjutor.xyz>2021-05-19 10:12:39 +0200
committerClyhtsuriva <aimeric@adjutor.xyz>2021-05-19 10:12:39 +0200
commitcccf03dbafbb5605f530e14912dfa15418d22db0 (patch)
tree366dcab01a2a6ab40fed72cc25cf1bb4368c9589
parent67be76376ab6263ec1d97ea68d561bf90844df9d (diff)
parent8ede9457fd21ac5e272e73f5ece1d4bc9c23faab (diff)
Merge branch 'release/3.2'v3.2.0
-rw-r--r--README.md12
-rw-r--r--app/build.gradle4
-rw-r--r--app/src/main/AndroidManifest.xml10
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/data/AnimeApi.kt (renamed from app/src/main/java/xyz/adjutor/aniki/data/anime/AnimeApi.kt)4
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/data/MangaApi.kt (renamed from app/src/main/java/xyz/adjutor/aniki/data/manga/MangaApi.kt)4
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/data/SearchAnimeApi.kt (renamed from app/src/main/java/xyz/adjutor/aniki/data/anime/SearchAnimeApi.kt)4
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/data/SearchMangaApi.kt (renamed from app/src/main/java/xyz/adjutor/aniki/data/manga/SearchMangaApi.kt)4
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/data/TopAnimeApi.kt (renamed from app/src/main/java/xyz/adjutor/aniki/data/anime/TopAnimeApi.kt)4
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/data/TopMangaApi.kt (renamed from app/src/main/java/xyz/adjutor/aniki/data/manga/TopMangaApi.kt)4
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/Constants.kt8
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/Singletons.kt25
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/controller/DetailSearchAnimeController.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/controller/anime/DetailSearchAnimeController.kt)18
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/controller/DetailSearchMangaController.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/controller/manga/DetailSearchMangaController.kt)18
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/controller/DetailTopAnimeController.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/controller/anime/DetailTopAnimeController.kt)19
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/controller/DetailTopMangaController.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/controller/manga/DetailTopMangaController.kt)19
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/controller/SearchAnimeController.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/controller/anime/SearchAnimeController.kt)26
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/controller/SearchMangaController.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/controller/manga/SearchMangaController.kt)26
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/controller/TopAnimeController.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/controller/anime/TopAnimeController.kt)37
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/controller/TopMangaController.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/controller/manga/TopMangaController.kt)35
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/model/SearchAnime.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/model/anime/SearchAnime.kt)2
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/model/SearchManga.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/model/manga/SearchManga.kt)2
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/model/TopAnime.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/model/anime/TopAnime.kt)2
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/model/TopManga.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/model/manga/TopManga.kt)2
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/model/response/AnimeResponse.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/model/anime/AnimeResponse.kt)2
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/model/response/MangaResponse.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/model/manga/MangaResponse.kt)2
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/model/response/SearchAnimeResponse.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/model/anime/SearchAnimeResponse.kt)3
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/model/response/SearchMangaResponse.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/model/manga/SearchMangaResponse.kt)3
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/model/response/TopAnimeResponse.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/model/anime/TopAnimeResponse.kt)3
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/model/response/TopMangaResponse.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/model/manga/TopMangaResponse.kt)3
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/view/activity/DetailSearchAnimeActivity.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/view/anime/DetailSearchAnimeActivity.kt)6
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/view/activity/DetailSearchMangaActivity.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/view/manga/DetailSearchMangaActivity.kt)6
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/view/activity/DetailTopAnimeActivity.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/view/anime/DetailTopAnimeActivity.kt)6
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/view/activity/DetailTopMangaActivity.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/view/manga/DetailTopMangaActivity.kt)6
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/view/activity/MainActivity.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/view/MainActivity.kt)2
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/view/adapter/SearchAnimeAdapter.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/view/anime/SearchAnimeAdapter.kt)5
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/view/adapter/SearchMangaAdapter.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/view/manga/SearchMangaAdapter.kt)5
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/view/adapter/TopAnimeAdapter.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/view/anime/TopAnimeAdapter.kt)5
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/view/adapter/TopMangaAdapter.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/view/manga/TopMangaAdapter.kt)5
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/view/fragment/HomePage.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/view/HomePage.kt)2
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/view/fragment/SearchAnimeFragment.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/view/anime/SearchAnimePage.kt)12
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/view/fragment/SearchMangaFragment.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/view/manga/SearchMangaPage.kt)11
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/view/fragment/TopAnimeFragment.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/view/anime/TopAnimePage.kt)9
-rw-r--r--app/src/main/java/xyz/adjutor/aniki/presentation/view/fragment/TopMangaFragment.kt (renamed from app/src/main/java/xyz/adjutor/aniki/presentation/view/manga/TopMangaPage.kt)9
-rw-r--r--app/src/main/res/layout/activity_detail_search_anime.xml2
-rw-r--r--app/src/main/res/layout/activity_detail_search_manga.xml2
-rw-r--r--app/src/main/res/layout/activity_detail_top_anime.xml2
-rw-r--r--app/src/main/res/layout/activity_detail_top_manga.xml2
-rw-r--r--app/src/main/res/layout/activity_main.xml2
-rw-r--r--app/src/main/res/layout/home_page.xml2
-rw-r--r--app/src/main/res/layout/search_anime_page.xml2
-rw-r--r--app/src/main/res/layout/search_manga_page.xml2
-rw-r--r--app/src/main/res/layout/top_anime_page.xml2
-rw-r--r--app/src/main/res/layout/top_manga_page.xml2
-rw-r--r--app/src/main/res/navigation/nav_graph.xml10
-rw-r--r--build.gradle4
55 files changed, 193 insertions, 235 deletions
diff --git a/README.md b/README.md
index 4cca4a2..07cff78 100644
--- a/README.md
+++ b/README.md
@@ -2,23 +2,20 @@
## Features
-List of elements used in top manga and top anime with a recycler view
++ List of elements used in top manga and top anime with a recycler view
SwipeRefresh used to refresh the list of data of the first page.
Use the button (prev and next) to navigate with ease through the pages.
-
-Details of a chosen element from the recycler view with an intent object
++ Details of a chosen element from the recycler view with an intent object
Title, synopsys and background clickable.
-
URL link openable.
-
-Search pages for animes and mangas.
++ Search pages for animes and mangas.
They display the data in a recycler view similar to the tops.
@@ -83,3 +80,6 @@ Displaying a snack when hitting the previously button on the first page :
<img src="https://adjutor.xyz/gif/prev-button-message.gif" alt="Previous_button_on_first_page" width="400"/>
This is a reminder since there's a bug (or a feature ;) ) that reset the page number inside the app/code but not the actual list displayed.
+
+## You Should Know
+YSK : Searching for an item using 2 or less characters will result in an API error. This error is normal, it comes from the REST API I'm using.
diff --git a/app/build.gradle b/app/build.gradle
index e8f6245..3785aca 100644
--- a/app/build.gradle
+++ b/app/build.gradle
@@ -36,8 +36,8 @@ dependencies {
//noinspection GradleDependency
implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
- implementation 'androidx.core:core-ktx:1.3.2'
- implementation 'androidx.appcompat:appcompat:1.2.0'
+ implementation 'androidx.core:core-ktx:1.5.0'
+ implementation 'androidx.appcompat:appcompat:1.3.0'
implementation 'com.google.android.material:material:1.3.0'
implementation 'androidx.constraintlayout:constraintlayout:2.0.4'
implementation 'androidx.navigation:navigation-fragment-ktx:2.3.5'
diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml
index 356c924..87a2fd8 100644
--- a/app/src/main/AndroidManifest.xml
+++ b/app/src/main/AndroidManifest.xml
@@ -14,23 +14,23 @@
android:theme="@style/Theme.Aniki"
tools:ignore="AllowBackup">
<activity
- android:name="xyz.adjutor.aniki.presentation.view.manga.DetailTopMangaActivity"
+ android:name="xyz.adjutor.aniki.presentation.view.activity.DetailTopMangaActivity"
android:label="Details"
android:theme="@style/Theme.Aniki" />
<activity
- android:name="xyz.adjutor.aniki.presentation.view.anime.DetailTopAnimeActivity"
+ android:name="xyz.adjutor.aniki.presentation.view.activity.DetailTopAnimeActivity"
android:label="Details"
android:theme="@style/Theme.Aniki" />
<activity
- android:name="xyz.adjutor.aniki.presentation.view.manga.DetailSearchMangaActivity"
+ android:name="xyz.adjutor.aniki.presentation.view.activity.DetailSearchMangaActivity"
android:label="Details"
android:theme="@style/Theme.Aniki" />
<activity
- android:name="xyz.adjutor.aniki.presentation.view.anime.DetailSearchAnimeActivity"
+ android:name="xyz.adjutor.aniki.presentation.view.activity.DetailSearchAnimeActivity"
android:label="Details"
android:theme="@style/Theme.Aniki" />
<activity
- android:name=".presentation.view.MainActivity"
+ android:name=".presentation.view.activity.MainActivity"
android:label="@string/app_name"
android:theme="@style/Theme.Aniki.NoActionBar">
<intent-filter>
diff --git a/app/src/main/java/xyz/adjutor/aniki/data/anime/AnimeApi.kt b/app/src/main/java/xyz/adjutor/aniki/data/AnimeApi.kt
index 24e5cd7..0f0cb17 100644
--- a/app/src/main/java/xyz/adjutor/aniki/data/anime/AnimeApi.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/data/AnimeApi.kt
@@ -1,9 +1,9 @@
-package xyz.adjutor.aniki.data.anime
+package xyz.adjutor.aniki.data
import retrofit2.Call
import retrofit2.http.GET
import retrofit2.http.Path
-import xyz.adjutor.aniki.presentation.model.anime.AnimeResponse
+import xyz.adjutor.aniki.presentation.model.response.AnimeResponse
interface AnimeApi {
diff --git a/app/src/main/java/xyz/adjutor/aniki/data/manga/MangaApi.kt b/app/src/main/java/xyz/adjutor/aniki/data/MangaApi.kt
index a0f8df1..c6236b4 100644
--- a/app/src/main/java/xyz/adjutor/aniki/data/manga/MangaApi.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/data/MangaApi.kt
@@ -1,9 +1,9 @@
-package xyz.adjutor.aniki.data.manga
+package xyz.adjutor.aniki.data
import retrofit2.Call
import retrofit2.http.GET
import retrofit2.http.Path
-import xyz.adjutor.aniki.presentation.model.manga.MangaResponse
+import xyz.adjutor.aniki.presentation.model.response.MangaResponse
interface MangaApi {
diff --git a/app/src/main/java/xyz/adjutor/aniki/data/anime/SearchAnimeApi.kt b/app/src/main/java/xyz/adjutor/aniki/data/SearchAnimeApi.kt
index 9bd6b2d..6ff1439 100644
--- a/app/src/main/java/xyz/adjutor/aniki/data/anime/SearchAnimeApi.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/data/SearchAnimeApi.kt
@@ -1,9 +1,9 @@
-package xyz.adjutor.aniki.data.anime
+package xyz.adjutor.aniki.data
import retrofit2.Call
import retrofit2.http.GET
import retrofit2.http.Query
-import xyz.adjutor.aniki.presentation.model.anime.SearchAnimeResponse
+import xyz.adjutor.aniki.presentation.model.response.SearchAnimeResponse
interface SearchAnimeApi {
diff --git a/app/src/main/java/xyz/adjutor/aniki/data/manga/SearchMangaApi.kt b/app/src/main/java/xyz/adjutor/aniki/data/SearchMangaApi.kt
index 6cc2d77..6b679b7 100644
--- a/app/src/main/java/xyz/adjutor/aniki/data/manga/SearchMangaApi.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/data/SearchMangaApi.kt
@@ -1,9 +1,9 @@
-package xyz.adjutor.aniki.data.manga
+package xyz.adjutor.aniki.data
import retrofit2.Call
import retrofit2.http.GET
import retrofit2.http.Query
-import xyz.adjutor.aniki.presentation.model.manga.SearchMangaResponse
+import xyz.adjutor.aniki.presentation.model.response.SearchMangaResponse
interface SearchMangaApi {
diff --git a/app/src/main/java/xyz/adjutor/aniki/data/anime/TopAnimeApi.kt b/app/src/main/java/xyz/adjutor/aniki/data/TopAnimeApi.kt
index 76fd25f..d850c2a 100644
--- a/app/src/main/java/xyz/adjutor/aniki/data/anime/TopAnimeApi.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/data/TopAnimeApi.kt
@@ -1,9 +1,9 @@
-package xyz.adjutor.aniki.data.anime
+package xyz.adjutor.aniki.data
import retrofit2.Call
import retrofit2.http.GET
import retrofit2.http.Path
-import xyz.adjutor.aniki.presentation.model.anime.TopAnimeResponse
+import xyz.adjutor.aniki.presentation.model.response.TopAnimeResponse
interface TopAnimeApi {
diff --git a/app/src/main/java/xyz/adjutor/aniki/data/manga/TopMangaApi.kt b/app/src/main/java/xyz/adjutor/aniki/data/TopMangaApi.kt
index 222dce3..c9bb53b 100644
--- a/app/src/main/java/xyz/adjutor/aniki/data/manga/TopMangaApi.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/data/TopMangaApi.kt
@@ -1,9 +1,9 @@
-package xyz.adjutor.aniki.data.manga
+package xyz.adjutor.aniki.data
import retrofit2.Call
import retrofit2.http.GET
import retrofit2.http.Path
-import xyz.adjutor.aniki.presentation.model.manga.TopMangaResponse
+import xyz.adjutor.aniki.presentation.model.response.TopMangaResponse
interface TopMangaApi {
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/Constants.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/Constants.kt
new file mode 100644
index 0000000..23e5c3f
--- /dev/null
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/Constants.kt
@@ -0,0 +1,8 @@
+package xyz.adjutor.aniki.presentation
+
+class Constants {
+ companion object {
+ const val baseUrl = "https://api.jikan.moe/"
+ }
+
+} \ No newline at end of file
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/Singletons.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/Singletons.kt
index 827c7e3..896757c 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/Singletons.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/Singletons.kt
@@ -4,55 +4,52 @@ import com.google.gson.Gson
import com.google.gson.GsonBuilder
import retrofit2.Retrofit
import retrofit2.converter.gson.GsonConverterFactory
-import xyz.adjutor.aniki.data.anime.AnimeApi
-import xyz.adjutor.aniki.data.anime.SearchAnimeApi
-import xyz.adjutor.aniki.data.anime.TopAnimeApi
-import xyz.adjutor.aniki.data.manga.MangaApi
-import xyz.adjutor.aniki.data.manga.SearchMangaApi
-import xyz.adjutor.aniki.data.manga.TopMangaApi
+import xyz.adjutor.aniki.data.*
+import xyz.adjutor.aniki.presentation.Constants.Companion.baseUrl
class Singletons {
companion object {
+
val gson: Gson = GsonBuilder()
.setLenient()
- .create()!!
- private const val BASE_URL = "https://api.jikan.moe/"
+ .create()
val topMangaApi: TopMangaApi = Retrofit.Builder()
- .baseUrl(BASE_URL)
+ .baseUrl(baseUrl)
.addConverterFactory(GsonConverterFactory.create(gson))
.build()
.create(TopMangaApi::class.java)
val searchMangaApi: SearchMangaApi = Retrofit.Builder()
- .baseUrl(BASE_URL)
+ .baseUrl(baseUrl)
.addConverterFactory(GsonConverterFactory.create(gson))
.build()
.create(SearchMangaApi::class.java)
val mangaApi: MangaApi = Retrofit.Builder()
- .baseUrl(BASE_URL)
+ .baseUrl(baseUrl)
.addConverterFactory(GsonConverterFactory.create(gson))
.build()
.create(MangaApi::class.java)
val topAnimeApi: TopAnimeApi = Retrofit.Builder()
- .baseUrl(BASE_URL)
+ .baseUrl(baseUrl)
.addConverterFactory(GsonConverterFactory.create(gson))
.build()
.create(TopAnimeApi::class.java)
val searchAnimeApi: SearchAnimeApi = Retrofit.Builder()
- .baseUrl(BASE_URL)
+ .baseUrl(baseUrl)
.addConverterFactory(GsonConverterFactory.create(gson))
.build()
.create(SearchAnimeApi::class.java)
val animeApi: AnimeApi = Retrofit.Builder()
- .baseUrl(BASE_URL)
+ .baseUrl(baseUrl)
.addConverterFactory(GsonConverterFactory.create(gson))
.build()
.create(AnimeApi::class.java)
}
+
}
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/controller/anime/DetailSearchAnimeController.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/controller/DetailSearchAnimeController.kt
index e12de3a..95aabec 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/controller/anime/DetailSearchAnimeController.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/controller/DetailSearchAnimeController.kt
@@ -1,32 +1,24 @@
-package xyz.adjutor.aniki.presentation.controller.anime
+package xyz.adjutor.aniki.presentation.controller
-import com.google.gson.Gson
-import com.google.gson.GsonBuilder
import retrofit2.Call
import retrofit2.Callback
import retrofit2.Response
import xyz.adjutor.aniki.presentation.Singletons
-import xyz.adjutor.aniki.presentation.model.anime.AnimeResponse
-import xyz.adjutor.aniki.presentation.view.anime.DetailSearchAnimeActivity
+import xyz.adjutor.aniki.presentation.model.response.AnimeResponse
+import xyz.adjutor.aniki.presentation.view.activity.DetailSearchAnimeActivity
class DetailSearchAnimeController {
- lateinit var gson: Gson
- private lateinit var baseUrl: String //the api's base url
lateinit var view: DetailSearchAnimeActivity
fun onStart(DetailSearchAnimeActivity: DetailSearchAnimeActivity, animeId: String) {
view = DetailSearchAnimeActivity
- baseUrl = "https://api.jikan.moe/" //the api's base url
- gson = GsonBuilder()
- .setLenient()
- .create()
- makeApiCall(baseUrl, animeId)
+ makeApiCall(animeId)
}
- private fun makeApiCall(BASE_URL: String, animeId: String) {
+ private fun makeApiCall(animeId: String) {
Singletons
.animeApi
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/controller/manga/DetailSearchMangaController.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/controller/DetailSearchMangaController.kt
index 080e4ed..d2f718a 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/controller/manga/DetailSearchMangaController.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/controller/DetailSearchMangaController.kt
@@ -1,32 +1,24 @@
-package xyz.adjutor.aniki.presentation.controller.manga
+package xyz.adjutor.aniki.presentation.controller
-import com.google.gson.Gson
-import com.google.gson.GsonBuilder
import retrofit2.Call
import retrofit2.Callback
import retrofit2.Response
import xyz.adjutor.aniki.presentation.Singletons
-import xyz.adjutor.aniki.presentation.model.manga.MangaResponse
-import xyz.adjutor.aniki.presentation.view.manga.DetailSearchMangaActivity
+import xyz.adjutor.aniki.presentation.model.response.MangaResponse
+import xyz.adjutor.aniki.presentation.view.activity.DetailSearchMangaActivity
class DetailSearchMangaController {
- lateinit var gson: Gson
- private lateinit var baseUrl: String //the api's base url
lateinit var view: DetailSearchMangaActivity
fun onStart(DetailSearchMangaActivity: DetailSearchMangaActivity, mangaId: String) {
view = DetailSearchMangaActivity
- baseUrl = "https://api.jikan.moe/" //the api's base url
- gson = GsonBuilder()
- .setLenient()
- .create()
- makeApiCall(baseUrl, mangaId)
+ makeApiCall(mangaId)
}
- private fun makeApiCall(BASE_URL: String, mangaId: String) {
+ private fun makeApiCall(mangaId: String) {
Singletons
.mangaApi
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/controller/anime/DetailTopAnimeController.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/controller/DetailTopAnimeController.kt
index 3fb13b4..46e7edd 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/controller/anime/DetailTopAnimeController.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/controller/DetailTopAnimeController.kt
@@ -1,32 +1,25 @@
-package xyz.adjutor.aniki.presentation.controller.anime
+package xyz.adjutor.aniki.presentation.controller
import android.content.Context
import android.content.SharedPreferences
-import com.google.gson.Gson
-import com.google.gson.GsonBuilder
import com.google.gson.reflect.TypeToken
import retrofit2.Call
import retrofit2.Callback
import retrofit2.Response
import xyz.adjutor.aniki.presentation.Singletons
-import xyz.adjutor.aniki.presentation.model.anime.AnimeResponse
-import xyz.adjutor.aniki.presentation.view.anime.DetailTopAnimeActivity
+import xyz.adjutor.aniki.presentation.Singletons.Companion.gson
+import xyz.adjutor.aniki.presentation.model.response.AnimeResponse
+import xyz.adjutor.aniki.presentation.view.activity.DetailTopAnimeActivity
import java.lang.reflect.Type
class DetailTopAnimeController {
private lateinit var sharedPreferences: SharedPreferences
- lateinit var gson: Gson
- private lateinit var baseUrl: String //the api's base url
lateinit var view: DetailTopAnimeActivity
fun onStart(DetailTopAnimeActivity: DetailTopAnimeActivity, animeId: String) {
view = DetailTopAnimeActivity
- baseUrl = "https://api.jikan.moe/" //the api's base url
- gson = GsonBuilder()
- .setLenient()
- .create()
sharedPreferences =
view.applicationContext.getSharedPreferences("sp_anime", Context.MODE_PRIVATE)
@@ -35,7 +28,7 @@ class DetailTopAnimeController {
view.showDetail(anime)
} else {
//taking the API's fields I want and displaying them
- makeApiCall(baseUrl, animeId)
+ makeApiCall(animeId)
}
}
@@ -50,7 +43,7 @@ class DetailTopAnimeController {
}
}
- private fun makeApiCall(BASE_URL: String, animeId: String) {
+ private fun makeApiCall(animeId: String) {
Singletons
.animeApi
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/controller/manga/DetailTopMangaController.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/controller/DetailTopMangaController.kt
index 9789d0c..f9aaa07 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/controller/manga/DetailTopMangaController.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/controller/DetailTopMangaController.kt
@@ -1,32 +1,25 @@
-package xyz.adjutor.aniki.presentation.controller.manga
+package xyz.adjutor.aniki.presentation.controller
import android.content.Context
import android.content.SharedPreferences
-import com.google.gson.Gson
-import com.google.gson.GsonBuilder
import com.google.gson.reflect.TypeToken
import retrofit2.Call
import retrofit2.Callback
import retrofit2.Response
import xyz.adjutor.aniki.presentation.Singletons
-import xyz.adjutor.aniki.presentation.model.manga.MangaResponse
-import xyz.adjutor.aniki.presentation.view.manga.DetailTopMangaActivity
+import xyz.adjutor.aniki.presentation.Singletons.Companion.gson
+import xyz.adjutor.aniki.presentation.model.response.MangaResponse
+import xyz.adjutor.aniki.presentation.view.activity.DetailTopMangaActivity
import java.lang.reflect.Type
class DetailTopMangaController {
private lateinit var sharedPreferences: SharedPreferences
- lateinit var gson: Gson
- private lateinit var baseUrl: String //the api's base url
lateinit var view: DetailTopMangaActivity
fun onStart(DetailTopMangaActivity: DetailTopMangaActivity, mangaId: String) {
view = DetailTopMangaActivity
- baseUrl = "https://api.jikan.moe/" //the api's base url
- gson = GsonBuilder()
- .setLenient()
- .create()
sharedPreferences =
view.applicationContext.getSharedPreferences("sp_manga", Context.MODE_PRIVATE)
@@ -35,7 +28,7 @@ class DetailTopMangaController {
view.showDetail(manga)
} else {
//taking the API's fields I want and displaying them
- makeApiCall(baseUrl, mangaId)
+ makeApiCall(mangaId)
}
}
@@ -50,7 +43,7 @@ class DetailTopMangaController {
}
}
- private fun makeApiCall(BASE_URL: String, mangaId: String) {
+ private fun makeApiCall(mangaId: String) {
Singletons
.mangaApi
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/controller/anime/SearchAnimeController.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/controller/SearchAnimeController.kt
index 5951f1b..3ee6047 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/controller/anime/SearchAnimeController.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/controller/SearchAnimeController.kt
@@ -1,32 +1,24 @@
-package xyz.adjutor.aniki.presentation.controller.anime
+package xyz.adjutor.aniki.presentation.controller
-import com.google.gson.Gson
-import com.google.gson.GsonBuilder
import retrofit2.Call
import retrofit2.Callback
import retrofit2.Response
import xyz.adjutor.aniki.presentation.Singletons
-import xyz.adjutor.aniki.presentation.model.anime.SearchAnime
-import xyz.adjutor.aniki.presentation.model.anime.SearchAnimeResponse
-import xyz.adjutor.aniki.presentation.view.anime.SearchAnimePage
+import xyz.adjutor.aniki.presentation.model.SearchAnime
+import xyz.adjutor.aniki.presentation.model.response.SearchAnimeResponse
+import xyz.adjutor.aniki.presentation.view.fragment.SearchAnimeFragment
class SearchAnimeController {
- lateinit var gson: Gson
- lateinit var baseUrl: String //the api's base url
- lateinit var view: SearchAnimePage
+ lateinit var view: SearchAnimeFragment
- fun onStart(searchAnimePage: SearchAnimePage) {
+ fun onStart(searchAnimeFragment: SearchAnimeFragment) {
- view = searchAnimePage
- baseUrl = "https://api.jikan.moe/" //the api's base url
- gson = GsonBuilder()
- .setLenient()
- .create()
+ view = searchAnimeFragment
}
//call the API and show the list
- private fun makeApiCall(view: SearchAnimePage, BASE_URL: String, query: String) {
+ private fun makeApiCall(view: SearchAnimeFragment, query: String) {
Singletons
.searchAnimeApi
@@ -59,7 +51,7 @@ class SearchAnimeController {
}
fun updateList(userInput: String) {
- makeApiCall(view, baseUrl, userInput)
+ makeApiCall(view, userInput)
}
} \ No newline at end of file
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/controller/manga/SearchMangaController.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/controller/SearchMangaController.kt
index de1edad..7d5f92b 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/controller/manga/SearchMangaController.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/controller/SearchMangaController.kt
@@ -1,32 +1,24 @@
-package xyz.adjutor.aniki.presentation.controller.manga
+package xyz.adjutor.aniki.presentation.controller
-import com.google.gson.Gson
-import com.google.gson.GsonBuilder
import retrofit2.Call
import retrofit2.Callback
import retrofit2.Response
import xyz.adjutor.aniki.presentation.Singletons
-import xyz.adjutor.aniki.presentation.model.manga.SearchManga
-import xyz.adjutor.aniki.presentation.model.manga.SearchMangaResponse
-import xyz.adjutor.aniki.presentation.view.manga.SearchMangaPage
+import xyz.adjutor.aniki.presentation.model.SearchManga
+import xyz.adjutor.aniki.presentation.model.response.SearchMangaResponse
+import xyz.adjutor.aniki.presentation.view.fragment.SearchMangaFragment
class SearchMangaController {
- lateinit var gson: Gson
- lateinit var baseUrl: String //the api's base url
- lateinit var view: SearchMangaPage
+ lateinit var view: SearchMangaFragment
- fun onStart(searchMangaPage: SearchMangaPage) {
+ fun onStart(searchMangaFragment: SearchMangaFragment) {
- view = searchMangaPage
- baseUrl = "https://api.jikan.moe/" //the api's base url
- gson = GsonBuilder()
- .setLenient()
- .create()
+ view = searchMangaFragment
}
//call the API and show the list
- private fun makeApiCall(view: SearchMangaPage, BASE_URL: String, query: String) {
+ private fun makeApiCall(view: SearchMangaFragment, query: String) {
Singletons
.searchMangaApi
@@ -59,7 +51,7 @@ class SearchMangaController {
}
fun updateList(userInput: String) {
- makeApiCall(view, baseUrl, userInput)
+ makeApiCall(view, userInput)
}
} \ No newline at end of file
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/controller/anime/TopAnimeController.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/controller/TopAnimeController.kt
index 57dc10b..446f4e6 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/controller/anime/TopAnimeController.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/controller/TopAnimeController.kt
@@ -1,37 +1,30 @@
-package xyz.adjutor.aniki.presentation.controller.anime
+package xyz.adjutor.aniki.presentation.controller
import android.content.Context
import android.content.SharedPreferences
import android.view.View
-import com.google.gson.Gson
-import com.google.gson.GsonBuilder
import com.google.gson.reflect.TypeToken
import retrofit2.Call
import retrofit2.Callback
import retrofit2.Response
import xyz.adjutor.aniki.presentation.Singletons
-import xyz.adjutor.aniki.presentation.model.anime.TopAnime
-import xyz.adjutor.aniki.presentation.model.anime.TopAnimeResponse
-import xyz.adjutor.aniki.presentation.view.anime.TopAnimePage
+import xyz.adjutor.aniki.presentation.Singletons.Companion.gson
+import xyz.adjutor.aniki.presentation.model.TopAnime
+import xyz.adjutor.aniki.presentation.model.response.TopAnimeResponse
+import xyz.adjutor.aniki.presentation.view.fragment.TopAnimeFragment
import java.lang.reflect.Type
import kotlin.properties.Delegates
class TopAnimeController {
- lateinit var sharedPreferences: SharedPreferences
- lateinit var gson: Gson
- lateinit var baseUrl: String //the api's base url
- var page by Delegates.notNull<Int>()
- lateinit var view: TopAnimePage
+ private lateinit var sharedPreferences: SharedPreferences
+ private var page by Delegates.notNull<Int>()
+ lateinit var view: TopAnimeFragment
- fun onStart(topAnimePage: TopAnimePage, viewTopAnimePage: View) {
+ fun onStart(topAnimeFragment: TopAnimeFragment, viewTopAnimePage: View) {
- view = topAnimePage
- baseUrl = "https://api.jikan.moe/" //the api's base url
+ view = topAnimeFragment
page = 1
- gson = GsonBuilder()
- .setLenient()
- .create()
sharedPreferences =
viewTopAnimePage.context.getSharedPreferences("sp_anime", Context.MODE_PRIVATE)
@@ -40,11 +33,11 @@ class TopAnimeController {
if (animeList != null) {
view.showList(viewTopAnimePage, animeList)
} else {
- makeApiCall(view, baseUrl, 1)
+ makeApiCall(view, 1)
}
}
- fun makeApiCall(view: TopAnimePage, BASE_URL: String, page: Int) {
+ private fun makeApiCall(view: TopAnimeFragment, page: Int) {
Singletons
.topAnimeApi
@@ -102,7 +95,7 @@ class TopAnimeController {
fun onButtonPrevClick() {
if (page > 1) { // if we're not on the first page, because we can't go back if we're on the first one.
page -= 1
- makeApiCall(view, baseUrl, page)
+ makeApiCall(view, page)
view.showText("Page $page has been loaded.")
} else {
view.showText("You're already on page 1. (If you're actually not, refresh the list.)")
@@ -111,12 +104,12 @@ class TopAnimeController {
fun onButtonNextClick() {
page += 1
- makeApiCall(view, baseUrl, page)
+ makeApiCall(view, page)
view.showText("Page $page has been loaded.")
}
fun updateList() {
- makeApiCall(view, baseUrl, 1)
+ makeApiCall(view, 1)
view.showText("Data refreshed")
page = 1
}
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/controller/manga/TopMangaController.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/controller/TopMangaController.kt
index ea631fd..afdbac7 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/controller/manga/TopMangaController.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/controller/TopMangaController.kt
@@ -1,37 +1,30 @@
-package xyz.adjutor.aniki.presentation.controller.manga
+package xyz.adjutor.aniki.presentation.controller
import android.content.Context
import android.content.SharedPreferences
import android.view.View
-import com.google.gson.Gson
-import com.google.gson.GsonBuilder
import com.google.gson.reflect.TypeToken
import retrofit2.Call
import retrofit2.Callback
import retrofit2.Response
import xyz.adjutor.aniki.presentation.Singletons
-import xyz.adjutor.aniki.presentation.model.manga.TopManga
-import xyz.adjutor.aniki.presentation.model.manga.TopMangaResponse
-import xyz.adjutor.aniki.presentation.view.manga.TopMangaPage
+import xyz.adjutor.aniki.presentation.Singletons.Companion.gson
+import xyz.adjutor.aniki.presentation.model.TopManga
+import xyz.adjutor.aniki.presentation.model.response.TopMangaResponse
+import xyz.adjutor.aniki.presentation.view.fragment.TopMangaFragment
import java.lang.reflect.Type
import kotlin.properties.Delegates
class TopMangaController {
- lateinit var sharedPreferences: SharedPreferences
- lateinit var gson: Gson
- lateinit var baseUrl: String //the api's base url
- var page by Delegates.notNull<Int>()
- lateinit var view: TopMangaPage
+ private lateinit var sharedPreferences: SharedPreferences
+ private var page by Delegates.notNull<Int>()
+ lateinit var view: TopMangaFragment
- fun onStart(topMangaPage: TopMangaPage, viewTopMangaPage: View) {
+ fun onStart(topMangaPage: TopMangaFragment, viewTopMangaPage: View) {
view = topMangaPage
- baseUrl = "https://api.jikan.moe/" //the api's base url
page = 1
- gson = GsonBuilder()
- .setLenient()
- .create()
sharedPreferences =
viewTopMangaPage.context.getSharedPreferences("sp_manga", Context.MODE_PRIVATE)
@@ -40,11 +33,11 @@ class TopMangaController {
if (mangaList != null) {
view.showList(viewTopMangaPage, mangaList)
} else {
- makeApiCall(view, baseUrl, 1)
+ makeApiCall(view, 1)
}
}
- private fun makeApiCall(view: TopMangaPage, BASE_URL: String, page: Int) {
+ private fun makeApiCall(view: TopMangaFragment, page: Int) {
Singletons
.topMangaApi
@@ -102,7 +95,7 @@ class TopMangaController {
fun onButtonPrevClick() {
if (page > 1) { // if we're not on the first page, because we can't go back if we're on the first one.
page -= 1
- makeApiCall(view, baseUrl, page)
+ makeApiCall(view, page)
view.showText("Page $page has been loaded.")
} else {
view.showText("You're already on page 1. (If you're actually not, refresh the list.)")
@@ -111,12 +104,12 @@ class TopMangaController {
fun onButtonNextClick() {
page += 1
- makeApiCall(view, baseUrl, page)
+ makeApiCall(view, page)
view.showText("Page $page has been loaded.")
}
fun updateList() {
- makeApiCall(view, baseUrl, 1)
+ makeApiCall(view, 1)
view.showText("Data refreshed")
page = 1
}
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/model/anime/SearchAnime.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/model/SearchAnime.kt
index 7e4340c..df5189d 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/model/anime/SearchAnime.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/model/SearchAnime.kt
@@ -1,4 +1,4 @@
-package xyz.adjutor.aniki.presentation.model.anime
+package xyz.adjutor.aniki.presentation.model
import com.google.gson.annotations.SerializedName
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/model/manga/SearchManga.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/model/SearchManga.kt
index d69227b..c24d93c 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/model/manga/SearchManga.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/model/SearchManga.kt
@@ -1,4 +1,4 @@
-package xyz.adjutor.aniki.presentation.model.manga
+package xyz.adjutor.aniki.presentation.model
import com.google.gson.annotations.SerializedName
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/model/anime/TopAnime.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/model/TopAnime.kt
index aefc1c5..3cf4390 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/model/anime/TopAnime.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/model/TopAnime.kt
@@ -1,4 +1,4 @@
-package xyz.adjutor.aniki.presentation.model.anime
+package xyz.adjutor.aniki.presentation.model
import com.google.gson.annotations.SerializedName
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/model/manga/TopManga.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/model/TopManga.kt
index 4fe3951..27f63f3 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/model/manga/TopManga.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/model/TopManga.kt
@@ -1,4 +1,4 @@
-package xyz.adjutor.aniki.presentation.model.manga
+package xyz.adjutor.aniki.presentation.model
import com.google.gson.annotations.SerializedName
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/model/anime/AnimeResponse.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/model/response/AnimeResponse.kt
index e4336ce..c2ef05b 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/model/anime/AnimeResponse.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/model/response/AnimeResponse.kt
@@ -1,4 +1,4 @@
-package xyz.adjutor.aniki.presentation.model.anime
+package xyz.adjutor.aniki.presentation.model.response
import com.google.gson.annotations.SerializedName
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/model/manga/MangaResponse.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/model/response/MangaResponse.kt
index 06aeed0..da88a79 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/model/manga/MangaResponse.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/model/response/MangaResponse.kt
@@ -1,4 +1,4 @@
-package xyz.adjutor.aniki.presentation.model.manga
+package xyz.adjutor.aniki.presentation.model.response
import com.google.gson.annotations.SerializedName
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/model/anime/SearchAnimeResponse.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/model/response/SearchAnimeResponse.kt
index d04aa67..1400704 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/model/anime/SearchAnimeResponse.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/model/response/SearchAnimeResponse.kt
@@ -1,6 +1,7 @@
-package xyz.adjutor.aniki.presentation.model.anime
+package xyz.adjutor.aniki.presentation.model.response
import com.google.gson.annotations.SerializedName
+import xyz.adjutor.aniki.presentation.model.SearchAnime
class SearchAnimeResponse { //only kept the infos I didn't have and that were interesting to me.
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/model/manga/SearchMangaResponse.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/model/response/SearchMangaResponse.kt
index 942c071..ed94b95 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/model/manga/SearchMangaResponse.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/model/response/SearchMangaResponse.kt
@@ -1,6 +1,7 @@
-package xyz.adjutor.aniki.presentation.model.manga
+package xyz.adjutor.aniki.presentation.model.response
import com.google.gson.annotations.SerializedName
+import xyz.adjutor.aniki.presentation.model.SearchManga
class SearchMangaResponse { //only kept the infos I didn't have and that were interesting to me.
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/model/anime/TopAnimeResponse.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/model/response/TopAnimeResponse.kt
index 48e2f8f..0c0adb4 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/model/anime/TopAnimeResponse.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/model/response/TopAnimeResponse.kt
@@ -1,6 +1,7 @@
-package xyz.adjutor.aniki.presentation.model.anime
+package xyz.adjutor.aniki.presentation.model.response
import com.google.gson.annotations.SerializedName
+import xyz.adjutor.aniki.presentation.model.TopAnime
class TopAnimeResponse {
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/model/manga/TopMangaResponse.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/model/response/TopMangaResponse.kt
index a0f6b8c..091984c 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/model/manga/TopMangaResponse.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/model/response/TopMangaResponse.kt
@@ -1,6 +1,7 @@
-package xyz.adjutor.aniki.presentation.model.manga
+package xyz.adjutor.aniki.presentation.model.response
import com.google.gson.annotations.SerializedName
+import xyz.adjutor.aniki.presentation.model.TopManga
class TopMangaResponse {
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/view/anime/DetailSearchAnimeActivity.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/view/activity/DetailSearchAnimeActivity.kt
index 5acf1c3..1b015b6 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/view/anime/DetailSearchAnimeActivity.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/view/activity/DetailSearchAnimeActivity.kt
@@ -1,4 +1,4 @@
-package xyz.adjutor.aniki.presentation.view.anime
+package xyz.adjutor.aniki.presentation.view.activity
import android.os.Bundle
import android.widget.ImageView
@@ -8,8 +8,8 @@ import androidx.appcompat.app.AppCompatActivity
import com.bumptech.glide.Glide
import com.bumptech.glide.request.RequestOptions
import xyz.adjutor.aniki.R
-import xyz.adjutor.aniki.presentation.controller.anime.DetailSearchAnimeController
-import xyz.adjutor.aniki.presentation.model.anime.AnimeResponse
+import xyz.adjutor.aniki.presentation.controller.DetailSearchAnimeController
+import xyz.adjutor.aniki.presentation.model.response.AnimeResponse
class DetailSearchAnimeActivity : AppCompatActivity() {
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/view/manga/DetailSearchMangaActivity.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/view/activity/DetailSearchMangaActivity.kt
index 83beb9b..5e57c5a 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/view/manga/DetailSearchMangaActivity.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/view/activity/DetailSearchMangaActivity.kt
@@ -1,4 +1,4 @@
-package xyz.adjutor.aniki.presentation.view.manga
+package xyz.adjutor.aniki.presentation.view.activity
import android.os.Bundle
import android.widget.ImageView
@@ -8,8 +8,8 @@ import androidx.appcompat.app.AppCompatActivity
import com.bumptech.glide.Glide
import com.bumptech.glide.request.RequestOptions
import xyz.adjutor.aniki.R
-import xyz.adjutor.aniki.presentation.controller.manga.DetailSearchMangaController
-import xyz.adjutor.aniki.presentation.model.manga.MangaResponse
+import xyz.adjutor.aniki.presentation.controller.DetailSearchMangaController
+import xyz.adjutor.aniki.presentation.model.response.MangaResponse
class DetailSearchMangaActivity : AppCompatActivity() {
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/view/anime/DetailTopAnimeActivity.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/view/activity/DetailTopAnimeActivity.kt
index b8cf505..5902e94 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/view/anime/DetailTopAnimeActivity.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/view/activity/DetailTopAnimeActivity.kt
@@ -1,4 +1,4 @@
-package xyz.adjutor.aniki.presentation.view.anime
+package xyz.adjutor.aniki.presentation.view.activity
import android.os.Bundle
import android.widget.ImageView
@@ -8,8 +8,8 @@ import androidx.appcompat.app.AppCompatActivity
import com.bumptech.glide.Glide
import com.bumptech.glide.request.RequestOptions
import xyz.adjutor.aniki.R
-import xyz.adjutor.aniki.presentation.controller.anime.DetailTopAnimeController
-import xyz.adjutor.aniki.presentation.model.anime.AnimeResponse
+import xyz.adjutor.aniki.presentation.controller.DetailTopAnimeController
+import xyz.adjutor.aniki.presentation.model.response.AnimeResponse
class DetailTopAnimeActivity : AppCompatActivity() {
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/view/manga/DetailTopMangaActivity.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/view/activity/DetailTopMangaActivity.kt
index 2a4b28b..3e70acc 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/view/manga/DetailTopMangaActivity.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/view/activity/DetailTopMangaActivity.kt
@@ -1,4 +1,4 @@
-package xyz.adjutor.aniki.presentation.view.manga
+package xyz.adjutor.aniki.presentation.view.activity
import android.os.Bundle
import android.widget.ImageView
@@ -8,8 +8,8 @@ import androidx.appcompat.app.AppCompatActivity
import com.bumptech.glide.Glide
import com.bumptech.glide.request.RequestOptions
import xyz.adjutor.aniki.R
-import xyz.adjutor.aniki.presentation.controller.manga.DetailTopMangaController
-import xyz.adjutor.aniki.presentation.model.manga.MangaResponse
+import xyz.adjutor.aniki.presentation.controller.DetailTopMangaController
+import xyz.adjutor.aniki.presentation.model.response.MangaResponse
class DetailTopMangaActivity : AppCompatActivity() {
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/view/MainActivity.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/view/activity/MainActivity.kt
index e58737a..3a50028 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/view/MainActivity.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/view/activity/MainActivity.kt
@@ -1,4 +1,4 @@
-package xyz.adjutor.aniki.presentation.view
+package xyz.adjutor.aniki.presentation.view.activity
import android.os.Bundle
import androidx.appcompat.app.AppCompatActivity
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/view/anime/SearchAnimeAdapter.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/view/adapter/SearchAnimeAdapter.kt
index 3bb875b..8d828d3 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/view/anime/SearchAnimeAdapter.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/view/adapter/SearchAnimeAdapter.kt
@@ -1,4 +1,4 @@
-package xyz.adjutor.aniki.presentation.view.anime
+package xyz.adjutor.aniki.presentation.view.adapter
import android.content.Intent
import android.view.LayoutInflater
@@ -11,7 +11,8 @@ import androidx.recyclerview.widget.RecyclerView
import com.bumptech.glide.Glide
import com.bumptech.glide.request.RequestOptions
import xyz.adjutor.aniki.R
-import xyz.adjutor.aniki.presentation.model.anime.SearchAnime
+import xyz.adjutor.aniki.presentation.model.SearchAnime
+import xyz.adjutor.aniki.presentation.view.activity.DetailSearchAnimeActivity
class SearchAnimeAdapter(private val animeList: List<SearchAnime>) :
RecyclerView.Adapter<SearchAnimeAdapter.AnimeViewHolder>() {
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/view/manga/SearchMangaAdapter.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/view/adapter/SearchMangaAdapter.kt
index c0813c8..ab99bce 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/view/manga/SearchMangaAdapter.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/view/adapter/SearchMangaAdapter.kt
@@ -1,4 +1,4 @@
-package xyz.adjutor.aniki.presentation.view.manga
+package xyz.adjutor.aniki.presentation.view.adapter
import android.content.Intent
import android.view.LayoutInflater
@@ -11,7 +11,8 @@ import androidx.recyclerview.widget.RecyclerView
import com.bumptech.glide.Glide
import com.bumptech.glide.request.RequestOptions
import xyz.adjutor.aniki.R
-import xyz.adjutor.aniki.presentation.model.manga.SearchManga
+import xyz.adjutor.aniki.presentation.model.SearchManga
+import xyz.adjutor.aniki.presentation.view.activity.DetailSearchMangaActivity
class SearchMangaAdapter(private val mangaList: List<SearchManga>) :
RecyclerView.Adapter<SearchMangaAdapter.MangaViewHolder>() {
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/view/anime/TopAnimeAdapter.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/view/adapter/TopAnimeAdapter.kt
index 0529c26..ee0df14 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/view/anime/TopAnimeAdapter.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/view/adapter/TopAnimeAdapter.kt
@@ -1,4 +1,4 @@
-package xyz.adjutor.aniki.presentation.view.anime
+package xyz.adjutor.aniki.presentation.view.adapter
import android.content.Intent
import android.view.LayoutInflater
@@ -11,7 +11,8 @@ import androidx.recyclerview.widget.RecyclerView
import com.bumptech.glide.Glide
import com.bumptech.glide.request.RequestOptions
import xyz.adjutor.aniki.R
-import xyz.adjutor.aniki.presentation.model.anime.TopAnime
+import xyz.adjutor.aniki.presentation.model.TopAnime
+import xyz.adjutor.aniki.presentation.view.activity.DetailTopAnimeActivity
class TopAnimeAdapter(private val animeList: List<TopAnime>) :
RecyclerView.Adapter<TopAnimeAdapter.AnimeViewHolder>() {
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/view/manga/TopMangaAdapter.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/view/adapter/TopMangaAdapter.kt
index 5ab1713..dc4380d 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/view/manga/TopMangaAdapter.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/view/adapter/TopMangaAdapter.kt
@@ -1,4 +1,4 @@
-package xyz.adjutor.aniki.presentation.view.manga
+package xyz.adjutor.aniki.presentation.view.adapter
import android.content.Intent
import android.view.LayoutInflater
@@ -11,7 +11,8 @@ import androidx.recyclerview.widget.RecyclerView
import com.bumptech.glide.Glide
import com.bumptech.glide.request.RequestOptions
import xyz.adjutor.aniki.R
-import xyz.adjutor.aniki.presentation.model.manga.TopManga
+import xyz.adjutor.aniki.presentation.model.TopManga
+import xyz.adjutor.aniki.presentation.view.activity.DetailTopMangaActivity
class TopMangaAdapter(private val mangaList: List<TopManga>) :
RecyclerView.Adapter<TopMangaAdapter.MangaViewHolder>() {
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/view/HomePage.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/view/fragment/HomePage.kt
index f2abca1..d8d271c 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/view/HomePage.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/view/fragment/HomePage.kt
@@ -1,4 +1,4 @@
-package xyz.adjutor.aniki.presentation.view
+package xyz.adjutor.aniki.presentation.view.fragment
import android.os.Bundle
import android.view.LayoutInflater
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/view/anime/SearchAnimePage.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/view/fragment/SearchAnimeFragment.kt
index 764601f..29b6c53 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/view/anime/SearchAnimePage.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/view/fragment/SearchAnimeFragment.kt
@@ -1,4 +1,4 @@
-package xyz.adjutor.aniki.presentation.view.anime
+package xyz.adjutor.aniki.presentation.view.fragment
import android.content.Context
import android.os.Bundle
@@ -16,11 +16,13 @@ import androidx.recyclerview.widget.RecyclerView
import com.google.android.material.snackbar.Snackbar
import com.google.android.material.textfield.TextInputEditText
import xyz.adjutor.aniki.R
-import xyz.adjutor.aniki.presentation.controller.anime.SearchAnimeController
-import xyz.adjutor.aniki.presentation.model.anime.SearchAnime
-import xyz.adjutor.aniki.presentation.view.MainActivity
+import xyz.adjutor.aniki.presentation.controller.SearchAnimeController
+import xyz.adjutor.aniki.presentation.model.SearchAnime
+import xyz.adjutor.aniki.presentation.view.activity.MainActivity
+import xyz.adjutor.aniki.presentation.view.adapter.SearchAnimeAdapter
-class SearchAnimePage : Fragment() {
+
+class SearchAnimeFragment : Fragment() {
lateinit var controller: SearchAnimeController
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/view/manga/SearchMangaPage.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/view/fragment/SearchMangaFragment.kt
index b6ae2bb..4ad6e89 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/view/manga/SearchMangaPage.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/view/fragment/SearchMangaFragment.kt
@@ -1,4 +1,4 @@
-package xyz.adjutor.aniki.presentation.view.manga
+package xyz.adjutor.aniki.presentation.view.fragment
import android.content.Context
import android.os.Bundle
@@ -16,12 +16,13 @@ import androidx.recyclerview.widget.RecyclerView
import com.google.android.material.snackbar.Snackbar
import com.google.android.material.textfield.TextInputEditText
import xyz.adjutor.aniki.R
-import xyz.adjutor.aniki.presentation.controller.manga.SearchMangaController
-import xyz.adjutor.aniki.presentation.model.manga.SearchManga
-import xyz.adjutor.aniki.presentation.view.MainActivity
+import xyz.adjutor.aniki.presentation.controller.SearchMangaController
+import xyz.adjutor.aniki.presentation.model.SearchManga
+import xyz.adjutor.aniki.presentation.view.activity.MainActivity
+import xyz.adjutor.aniki.presentation.view.adapter.SearchMangaAdapter
-class SearchMangaPage : Fragment() {
+class SearchMangaFragment : Fragment() {
lateinit var controller: SearchMangaController
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/view/anime/TopAnimePage.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/view/fragment/TopAnimeFragment.kt
index 5453154..56f7a49 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/view/anime/TopAnimePage.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/view/fragment/TopAnimeFragment.kt
@@ -1,4 +1,4 @@
-package xyz.adjutor.aniki.presentation.view.anime
+package xyz.adjutor.aniki.presentation.view.fragment
import android.os.Bundle
import android.view.LayoutInflater
@@ -12,11 +12,12 @@ import androidx.recyclerview.widget.RecyclerView
import androidx.swiperefreshlayout.widget.SwipeRefreshLayout
import com.google.android.material.snackbar.Snackbar
import xyz.adjutor.aniki.R
-import xyz.adjutor.aniki.presentation.controller.anime.TopAnimeController
-import xyz.adjutor.aniki.presentation.model.anime.TopAnime
+import xyz.adjutor.aniki.presentation.controller.TopAnimeController
+import xyz.adjutor.aniki.presentation.model.TopAnime
+import xyz.adjutor.aniki.presentation.view.adapter.TopAnimeAdapter
//view
-class TopAnimePage : Fragment() {
+class TopAnimeFragment : Fragment() {
lateinit var controller: TopAnimeController
diff --git a/app/src/main/java/xyz/adjutor/aniki/presentation/view/manga/TopMangaPage.kt b/app/src/main/java/xyz/adjutor/aniki/presentation/view/fragment/TopMangaFragment.kt
index 98eb0dd..7821e50 100644
--- a/app/src/main/java/xyz/adjutor/aniki/presentation/view/manga/TopMangaPage.kt
+++ b/app/src/main/java/xyz/adjutor/aniki/presentation/view/fragment/TopMangaFragment.kt
@@ -1,4 +1,4 @@
-package xyz.adjutor.aniki.presentation.view.manga
+package xyz.adjutor.aniki.presentation.view.fragment
import android.os.Bundle
import android.view.LayoutInflater
@@ -12,11 +12,12 @@ import androidx.recyclerview.widget.RecyclerView
import androidx.swiperefreshlayout.widget.SwipeRefreshLayout
import com.google.android.material.snackbar.Snackbar
import xyz.adjutor.aniki.R
-import xyz.adjutor.aniki.presentation.controller.manga.TopMangaController
-import xyz.adjutor.aniki.presentation.model.manga.TopManga
+import xyz.adjutor.aniki.presentation.controller.TopMangaController
+import xyz.adjutor.aniki.presentation.model.TopManga
+import xyz.adjutor.aniki.presentation.view.adapter.TopMangaAdapter
//view
-class TopMangaPage : Fragment() {
+class TopMangaFragment : Fragment() {
lateinit var controller: TopMangaController
diff --git a/app/src/main/res/layout/activity_detail_search_anime.xml b/app/src/main/res/layout/activity_detail_search_anime.xml
index 90f2459..43ced49 100644
--- a/app/src/main/res/layout/activity_detail_search_anime.xml
+++ b/app/src/main/res/layout/activity_detail_search_anime.xml
@@ -8,7 +8,7 @@
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- tools:context=".anime.searchanime.DetailSearchAnimeActivity">
+ tools:context=".presentation.view.activity.DetailSearchAnimeActivity">
<androidx.cardview.widget.CardView
android:id="@+id/cv_header"
diff --git a/app/src/main/res/layout/activity_detail_search_manga.xml b/app/src/main/res/layout/activity_detail_search_manga.xml
index 75cad74..b70319e 100644
--- a/app/src/main/res/layout/activity_detail_search_manga.xml
+++ b/app/src/main/res/layout/activity_detail_search_manga.xml
@@ -8,7 +8,7 @@
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- tools:context=".manga.searchmanga.DetailSearchMangaActivity">
+ tools:context=".presentation.view.activity.DetailSearchMangaActivity">
<androidx.cardview.widget.CardView
android:id="@+id/cv_header"
diff --git a/app/src/main/res/layout/activity_detail_top_anime.xml b/app/src/main/res/layout/activity_detail_top_anime.xml
index f352e61..411b3c6 100644
--- a/app/src/main/res/layout/activity_detail_top_anime.xml
+++ b/app/src/main/res/layout/activity_detail_top_anime.xml
@@ -8,7 +8,7 @@
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- tools:context=".presentation.view.anime.DetailTopAnimeActivity">
+ tools:context=".presentation.view.activity.DetailTopAnimeActivity">
<androidx.cardview.widget.CardView
android:id="@+id/cv_header"
diff --git a/app/src/main/res/layout/activity_detail_top_manga.xml b/app/src/main/res/layout/activity_detail_top_manga.xml
index cbfa296..55dd7d7 100644
--- a/app/src/main/res/layout/activity_detail_top_manga.xml
+++ b/app/src/main/res/layout/activity_detail_top_manga.xml
@@ -8,7 +8,7 @@
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- tools:context=".presentation.view.manga.DetailTopMangaActivity">
+ tools:context=".presentation.view.activity.DetailTopMangaActivity">
<androidx.cardview.widget.CardView
android:id="@+id/cv_header"
diff --git a/app/src/main/res/layout/activity_main.xml b/app/src/main/res/layout/activity_main.xml
index ff9ab1f..dc71220 100644
--- a/app/src/main/res/layout/activity_main.xml
+++ b/app/src/main/res/layout/activity_main.xml
@@ -4,7 +4,7 @@
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
- tools:context=".presentation.view.MainActivity">
+ tools:context=".presentation.view.activity.MainActivity">
<com.google.android.material.appbar.AppBarLayout
android:layout_width="match_parent"
diff --git a/app/src/main/res/layout/home_page.xml b/app/src/main/res/layout/home_page.xml
index d9677a9..05af56b 100644
--- a/app/src/main/res/layout/home_page.xml
+++ b/app/src/main/res/layout/home_page.xml
@@ -5,7 +5,7 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/very_dark_purple"
- tools:context=".presentation.view.HomePage">
+ tools:context=".presentation.view.fragment.HomePage">
<ImageView
android:id="@+id/logo"
diff --git a/app/src/main/res/layout/search_anime_page.xml b/app/src/main/res/layout/search_anime_page.xml
index abbd762..0682238 100644
--- a/app/src/main/res/layout/search_anime_page.xml
+++ b/app/src/main/res/layout/search_anime_page.xml
@@ -5,7 +5,7 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/very_dark_purple"
- tools:context=".presentation.view.anime.SearchAnimePage">
+ tools:context=".presentation.view.fragment.SearchAnimeFragment">
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/tiet_query"
diff --git a/app/src/main/res/layout/search_manga_page.xml b/app/src/main/res/layout/search_manga_page.xml
index db4bd6c..137e046 100644
--- a/app/src/main/res/layout/search_manga_page.xml
+++ b/app/src/main/res/layout/search_manga_page.xml
@@ -5,7 +5,7 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/very_dark_purple"
- tools:context=".presentation.view.manga.SearchMangaPage">
+ tools:context=".presentation.view.fragment.SearchMangaFragment">
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/tiet_query"
diff --git a/app/src/main/res/layout/top_anime_page.xml b/app/src/main/res/layout/top_anime_page.xml
index 633e5f4..0835c11 100644
--- a/app/src/main/res/layout/top_anime_page.xml
+++ b/app/src/main/res/layout/top_anime_page.xml
@@ -5,7 +5,7 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/very_dark_purple"
- tools:context=".presentation.view.anime.TopAnimePage">
+ tools:context=".presentation.view.fragment.TopAnimeFragment">
<androidx.swiperefreshlayout.widget.SwipeRefreshLayout
android:id="@+id/swiperefresh"
diff --git a/app/src/main/res/layout/top_manga_page.xml b/app/src/main/res/layout/top_manga_page.xml
index 6bb911b..b9b3182 100644
--- a/app/src/main/res/layout/top_manga_page.xml
+++ b/app/src/main/res/layout/top_manga_page.xml
@@ -5,7 +5,7 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/very_dark_purple"
- tools:context=".presentation.view.manga.TopMangaPage">
+ tools:context=".presentation.view.fragment.TopMangaFragment">
<androidx.swiperefreshlayout.widget.SwipeRefreshLayout
android:id="@+id/swiperefresh"
diff --git a/app/src/main/res/navigation/nav_graph.xml b/app/src/main/res/navigation/nav_graph.xml
index 63639d8..5e96635 100644
--- a/app/src/main/res/navigation/nav_graph.xml
+++ b/app/src/main/res/navigation/nav_graph.xml
@@ -7,7 +7,7 @@
<fragment
android:id="@+id/HomePage"
- android:name="xyz.adjutor.aniki.presentation.view.HomePage"
+ android:name="xyz.adjutor.aniki.presentation.view.fragment.HomePage"
android:label="@string/home_page_label"
tools:layout="@layout/home_page">
@@ -28,7 +28,7 @@
<fragment
android:id="@+id/TopMangaPage"
- android:name="xyz.adjutor.aniki.presentation.view.manga.TopMangaPage"
+ android:name="xyz.adjutor.aniki.presentation.view.fragment.TopMangaFragment"
android:label="@string/top_manga_page_label"
tools:layout="@layout/top_manga_page">
@@ -38,7 +38,7 @@
</fragment>
<fragment
android:id="@+id/TopAnimePage"
- android:name="xyz.adjutor.aniki.presentation.view.anime.TopAnimePage"
+ android:name="xyz.adjutor.aniki.presentation.view.fragment.TopAnimeFragment"
android:label="@string/top_anime_page_label"
tools:layout="@layout/top_anime_page">
@@ -48,7 +48,7 @@
</fragment>
<fragment
android:id="@+id/SearchMangaPage"
- android:name="xyz.adjutor.aniki.presentation.view.manga.SearchMangaPage"
+ android:name="xyz.adjutor.aniki.presentation.view.fragment.SearchMangaFragment"
android:label="@string/search_manga_page_label"
tools:layout="@layout/search_manga_page">
@@ -58,7 +58,7 @@
</fragment>
<fragment
android:id="@+id/SearchAnimePage"
- android:name="xyz.adjutor.aniki.presentation.view.anime.SearchAnimePage"
+ android:name="xyz.adjutor.aniki.presentation.view.fragment.SearchAnimeFragment"
android:label="@string/search_anime_page_label"
tools:layout="@layout/search_anime_page">
diff --git a/build.gradle b/build.gradle
index cd9f6d3..39c5db8 100644
--- a/build.gradle
+++ b/build.gradle
@@ -1,12 +1,12 @@
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
- ext.kotlin_version = "1.3.72"
+ ext.kotlin_version = '1.5.0'
repositories {
google()
mavenCentral()
}
dependencies {
- classpath 'com.android.tools.build:gradle:4.2.0'
+ classpath 'com.android.tools.build:gradle:4.2.1'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
// NOTE: Do not place your application dependencies here; they belong