From cd108fbe554b81dc4fb1279ef5e0660ca9836d8e Mon Sep 17 00:00:00 2001 From: Alex Ning Date: Mon, 13 Jul 2020 22:57:30 +0800 Subject: Probably fix app crashes when loading large images in PostRecyclerViewAdapter. --- .../main/res/layout/activity_view_image_or_gif.xml | 1 - app/src/main/res/layout/item_post_detail_image.xml | 2 - app/src/main/res/layout/item_post_gif_autoplay.xml | 325 -------------------- app/src/main/res/layout/item_post_image.xml | 329 --------------------- .../layout/item_post_image_and_gif_autoplay.xml | 326 ++++++++++++++++++++ 5 files changed, 326 insertions(+), 657 deletions(-) delete mode 100644 app/src/main/res/layout/item_post_gif_autoplay.xml delete mode 100644 app/src/main/res/layout/item_post_image.xml create mode 100644 app/src/main/res/layout/item_post_image_and_gif_autoplay.xml (limited to 'app/src/main/res') diff --git a/app/src/main/res/layout/activity_view_image_or_gif.xml b/app/src/main/res/layout/activity_view_image_or_gif.xml index 0156de76..35cdb0b6 100644 --- a/app/src/main/res/layout/activity_view_image_or_gif.xml +++ b/app/src/main/res/layout/activity_view_image_or_gif.xml @@ -27,7 +27,6 @@ android:id="@+id/image_view_view_image_or_gif_activity" android:layout_width="match_parent" android:layout_height="match_parent" - app:initScaleType="fitCenter" app:optimizeDisplay="true" app:tapToRetry="false" /> diff --git a/app/src/main/res/layout/item_post_detail_image.xml b/app/src/main/res/layout/item_post_detail_image.xml index 0c0ed5f5..be6dabfa 100644 --- a/app/src/main/res/layout/item_post_detail_image.xml +++ b/app/src/main/res/layout/item_post_detail_image.xml @@ -204,8 +204,6 @@ android:id="@+id/image_view_item_post_detail_image" android:layout_width="match_parent" android:layout_height="wrap_content" - android:adjustViewBounds="true" - android:scaleType="fitStart" app:quickScaleEnabled="false" app:zoomEnabled="false" app:panEnabled="false" /> diff --git a/app/src/main/res/layout/item_post_gif_autoplay.xml b/app/src/main/res/layout/item_post_gif_autoplay.xml deleted file mode 100644 index 504cb903..00000000 --- a/app/src/main/res/layout/item_post_gif_autoplay.xml +++ /dev/null @@ -1,325 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/app/src/main/res/layout/item_post_image.xml b/app/src/main/res/layout/item_post_image.xml deleted file mode 100644 index 2a1f8513..00000000 --- a/app/src/main/res/layout/item_post_image.xml +++ /dev/null @@ -1,329 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/app/src/main/res/layout/item_post_image_and_gif_autoplay.xml b/app/src/main/res/layout/item_post_image_and_gif_autoplay.xml new file mode 100644 index 00000000..561200b1 --- /dev/null +++ b/app/src/main/res/layout/item_post_image_and_gif_autoplay.xml @@ -0,0 +1,326 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file -- cgit v1.2.3