diff options
| author | Andrew Dolgov <fox@fakecake.org> | 2025-05-16 08:05:26 +0300 |
|---|---|---|
| committer | Andrew Dolgov <fox@fakecake.org> | 2025-05-16 08:05:26 +0300 |
| commit | 191ba10cf398212e25e80114a43100dfdcfa55ab (patch) | |
| tree | 14fb034e3ea0dc132e3c6bcfeb358d423e63ac64 /org.fox.ttrss/src/main/res/layout | |
| parent | ef4705f2387ef6158f3d66e8c94ebb9fcc28732a (diff) | |
switch feeds to recycler view while removing most of legacy code
Diffstat (limited to 'org.fox.ttrss/src/main/res/layout')
3 files changed, 77 insertions, 107 deletions
diff --git a/org.fox.ttrss/src/main/res/layout/feeds_row_header.xml b/org.fox.ttrss/src/main/res/layout/feeds_row_header.xml deleted file mode 100755 index f4954259..00000000 --- a/org.fox.ttrss/src/main/res/layout/feeds_row_header.xml +++ /dev/null @@ -1,70 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android" - android:layout_width="match_parent" - android:layout_height="72dp" - xmlns:tools="http://schemas.android.com/tools" - xmlns:app="http://schemas.android.com/apk/res-auto" - android:orientation="vertical" - android:weightSum="1" - android:clickable="false"> - - <FrameLayout - android:layout_width="match_parent" - android:layout_height="match_parent"> - - <com.google.android.material.button.MaterialButton - style="?attr/materialIconButtonStyle" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:scaleX="1.5" - android:scaleY="1.5" - app:icon="@drawable/baseline_settings_24" - android:id="@+id/drawer_settings_btn" - android:layout_gravity="center_vertical|end" - android:layout_marginEnd="8dp" - android:transitionName="SETTINGS_REVEAL" - /> - - <LinearLayout - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:orientation="vertical" - android:layout_alignParentBottom="true" - android:layout_alignParentLeft="true" - android:layout_alignParentStart="true" - android:id="@+id/linearLayout" - android:layout_gravity="center_horizontal|bottom"> - - <TextView - android:id="@+id/drawer_header_login" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:layout_marginStart="16dp" - tools:text="user" - android:textAppearance="?attr/textAppearanceHeadlineSmall" - android:textColor="?attr/colorOnSurface"/> - - <TextView - android:id="@+id/drawer_header_server" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:layout_marginStart="16dp" - android:layout_marginTop="8dp" - android:layout_marginBottom="8dp" - tools:text="example.org" - android:textAppearance="?attr/textAppearanceTitleSmall" - android:textColor="?attr/colorOnSurfaceVariant"/> - </LinearLayout> - </FrameLayout> - - <ProgressBar - style="?android:attr/progressBarStyleHorizontal" - android:visibility="invisible" - android:indeterminate="true" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:id="@+id/feeds_loading_bar" - android:layout_alignParentLeft="true" - android:layout_alignParentBottom="true" - android:layout_gravity="bottom" /> -</FrameLayout>
\ No newline at end of file diff --git a/org.fox.ttrss/src/main/res/layout/fragment_feeds.xml b/org.fox.ttrss/src/main/res/layout/fragment_feeds.xml index bf26e3fc..9f57dda2 100755 --- a/org.fox.ttrss/src/main/res/layout/fragment_feeds.xml +++ b/org.fox.ttrss/src/main/res/layout/fragment_feeds.xml @@ -1,24 +1,82 @@ <?xml version="1.0" encoding="utf-8"?> -<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" +<androidx.coordinatorlayout.widget.CoordinatorLayout + 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:id="@+id/feeds_fragment" - android:layout_width="fill_parent" - android:layout_height="fill_parent" > + android:layout_width="match_parent" + android:layout_height="wrap_content"> - <androidx.swiperefreshlayout.widget.SwipeRefreshLayout - android:id="@+id/feeds_swipe_container" - android:layout_width="match_parent" - android:layout_height="match_parent"> - - <ListView - android:id="@+id/feeds" - android:dividerHeight="4dp" - android:divider="@null" - android:paddingStart="4dp" - android:paddingEnd="4dp" + <com.google.android.material.appbar.AppBarLayout + android:background="@null" + android:layout_width="match_parent" + android:layout_height="wrap_content"> + + <FrameLayout + app:layout_scrollFlags="scroll|enterAlways" android:layout_width="match_parent" - android:layout_height="match_parent" - android:layout_alignParentLeft="true" - android:layout_alignParentStart="true"> - </ListView> + android:layout_height="wrap_content"> + + <com.google.android.material.button.MaterialButton + style="?attr/materialIconButtonStyle" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:scaleX="1.5" + android:scaleY="1.5" + app:icon="@drawable/baseline_settings_24" + android:id="@+id/drawer_settings_btn" + android:layout_gravity="center_vertical|end" + android:layout_marginEnd="8dp" + android:transitionName="SETTINGS_REVEAL" + /> + + <LinearLayout + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:orientation="vertical" + android:layout_alignParentBottom="true" + android:layout_alignParentLeft="true" + android:layout_alignParentStart="true" + android:id="@+id/linearLayout" + android:layout_gravity="center_horizontal|bottom"> + + <TextView + android:id="@+id/drawer_header_login" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_marginStart="16dp" + tools:text="user" + android:textAppearance="?attr/textAppearanceHeadlineSmall" + android:textColor="?attr/colorOnSurface"/> + + <TextView + android:id="@+id/drawer_header_server" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_marginStart="16dp" + android:layout_marginTop="8dp" + android:layout_marginBottom="8dp" + tools:text="example.org" + android:textAppearance="?attr/textAppearanceTitleSmall" + android:textColor="?attr/colorOnSurfaceVariant"/> + </LinearLayout> + </FrameLayout> + + </com.google.android.material.appbar.AppBarLayout> + + <androidx.swiperefreshlayout.widget.SwipeRefreshLayout + android:id="@+id/feeds_swipe_container" + app:layout_behavior="@string/appbar_scrolling_view_behavior" + android:layout_width="match_parent" + android:layout_height="wrap_content"> + + <org.fox.ttrss.util.ContextMenuRecyclerView + android:id="@+id/feeds" + android:scrollbars="vertical" + + android:layout_width="match_parent" + android:layout_height="wrap_content" /> + </androidx.swiperefreshlayout.widget.SwipeRefreshLayout> -</RelativeLayout>
\ No newline at end of file + +</androidx.coordinatorlayout.widget.CoordinatorLayout> diff --git a/org.fox.ttrss/src/main/res/layout/fragment_feeds_recycler.xml b/org.fox.ttrss/src/main/res/layout/fragment_feeds_recycler.xml deleted file mode 100755 index 1ed85a5b..00000000 --- a/org.fox.ttrss/src/main/res/layout/fragment_feeds_recycler.xml +++ /dev/null @@ -1,18 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" - android:id="@+id/feeds_fragment" - android:layout_width="fill_parent" - android:layout_height="fill_parent" > - - <androidx.swiperefreshlayout.widget.SwipeRefreshLayout - android:id="@+id/feeds_swipe_container" - android:layout_width="match_parent" - android:layout_height="match_parent"> - - <org.fox.ttrss.util.ContextMenuRecyclerView - android:id="@+id/feeds" - android:scrollbars="vertical" - android:layout_width="match_parent" - android:layout_height="match_parent" /> - </androidx.swiperefreshlayout.widget.SwipeRefreshLayout> -</RelativeLayout>
\ No newline at end of file |