From 00ac626b27076397b79bcd4bdd934ab861ff05a5 Mon Sep 17 00:00:00 2001 From: Clyhtsuriva Date: Fri, 19 Feb 2021 19:46:42 +0100 Subject: Implementing TopAnime Copied the topmanga folder and transformed everything in it into top anime. --- .../xyz/adjutor/aniki/topanime/TopAnimePage.kt | 93 ++++++++++++++++++++++ 1 file changed, 93 insertions(+) create mode 100644 app/src/main/java/xyz/adjutor/aniki/topanime/TopAnimePage.kt (limited to 'app/src/main/java/xyz/adjutor/aniki/topanime/TopAnimePage.kt') diff --git a/app/src/main/java/xyz/adjutor/aniki/topanime/TopAnimePage.kt b/app/src/main/java/xyz/adjutor/aniki/topanime/TopAnimePage.kt new file mode 100644 index 0000000..9e86191 --- /dev/null +++ b/app/src/main/java/xyz/adjutor/aniki/topanime/TopAnimePage.kt @@ -0,0 +1,93 @@ +package xyz.adjutor.aniki.topanime + +import android.os.Bundle +import android.view.LayoutInflater +import android.view.View +import android.view.ViewGroup +import android.widget.Button +import androidx.fragment.app.Fragment +import androidx.navigation.fragment.findNavController +import androidx.recyclerview.widget.LinearLayoutManager +import androidx.recyclerview.widget.RecyclerView +import com.google.android.material.snackbar.Snackbar +import com.google.gson.GsonBuilder +import retrofit2.Call +import retrofit2.Callback +import retrofit2.Response +import retrofit2.Retrofit +import retrofit2.converter.gson.GsonConverterFactory +import xyz.adjutor.aniki.R + +class TopAnimePage : Fragment() { + + override fun onCreateView( + inflater: LayoutInflater, container: ViewGroup?, + savedInstanceState: Bundle? + ): View? { + // Inflate the layout for this fragment + val view = inflater.inflate(R.layout.top_anime_page, container, false) + + makeApiCall(view, base_url) + + return view + } + + override fun onViewCreated(view: View, savedInstanceState: Bundle?) { + super.onViewCreated(view, savedInstanceState) + + //button to return to the home page + view.findViewById