basic offline manga fragment
This commit is contained in:
parent
c75df942f2
commit
91d869005c
14 changed files with 502 additions and 32 deletions
|
@ -20,6 +20,7 @@
|
|||
android:gravity="center"
|
||||
android:orientation="vertical">
|
||||
|
||||
|
||||
<TextView
|
||||
android:id="@+id/noInternetSad"
|
||||
android:layout_width="wrap_content"
|
||||
|
@ -49,7 +50,7 @@
|
|||
android:layout_width="150dp"
|
||||
android:layout_height="64dp"
|
||||
android:layout_gravity="bottom|center_horizontal"
|
||||
android:layout_margin="32dp"
|
||||
android:layout_margin="128dp"
|
||||
android:fontFamily="@font/poppins_bold"
|
||||
android:text="@string/refresh"
|
||||
app:cornerRadius="16dp"
|
||||
|
|
78
app/src/main/res/layout/fragment_manga_offline.xml
Normal file
78
app/src/main/res/layout/fragment_manga_offline.xml
Normal file
|
@ -0,0 +1,78 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".home.MangaFragment">
|
||||
|
||||
<androidx.swiperefreshlayout.widget.SwipeRefreshLayout
|
||||
android:id="@+id/mangaRefresh"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:clipChildren="false"
|
||||
android:clipToPadding="false">
|
||||
|
||||
<!-- Add a LinearLayout or other ViewGroup as a direct child of SwipeRefreshLayout -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/mangaOfflineTitle"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingTop="16dp"
|
||||
android:text="Offline Manga"
|
||||
android:textColor="?attr/colorOnSurface"
|
||||
android:textSize="24sp"
|
||||
android:textStyle="bold"
|
||||
android:fontFamily="@font/poppins"
|
||||
android:gravity="center_horizontal" />
|
||||
|
||||
<!-- This TextView might overlap with GridView if GridView has items -->
|
||||
<TextView
|
||||
android:id="@+id/noMangaOffline"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:text="No offline manga found"
|
||||
android:textColor="?attr/colorOnSurface"
|
||||
android:textSize="18sp"
|
||||
android:visibility="gone" />
|
||||
|
||||
<GridView
|
||||
android:id="@+id/gridView"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:numColumns="auto_fit"
|
||||
android:columnWidth="108dp"
|
||||
android:verticalSpacing="10dp"
|
||||
android:horizontalSpacing="10dp"
|
||||
android:padding="10dp"
|
||||
android:gravity="center" />
|
||||
</LinearLayout>
|
||||
</androidx.swiperefreshlayout.widget.SwipeRefreshLayout>
|
||||
|
||||
<androidx.cardview.widget.CardView
|
||||
android:id="@+id/mangaPageScrollTop"
|
||||
android:layout_width="48dp"
|
||||
android:layout_height="48dp"
|
||||
android:layout_gravity="bottom|center_horizontal"
|
||||
android:layout_marginBottom="16dp"
|
||||
app:cardBackgroundColor="?android:colorBackground"
|
||||
app:cardCornerRadius="24dp"
|
||||
app:contentPadding="12dp">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:rotation="90"
|
||||
app:srcCompat="@drawable/ic_round_arrow_back_ios_new_24"
|
||||
app:tint="?attr/colorOnSurface"
|
||||
tools:ignore="ContentDescription" />
|
||||
</androidx.cardview.widget.CardView>
|
||||
|
||||
</FrameLayout>
|
Loading…
Add table
Add a link
Reference in a new issue