aboutsummaryrefslogtreecommitdiff
path: root/app/src/main/res
diff options
context:
space:
mode:
authorAllan Wang <me@allanwang.ca>2021-11-19 20:30:19 -0800
committerAllan Wang <me@allanwang.ca>2021-11-19 20:30:19 -0800
commit8c343fd09cdf80cfbcdf49fd5cc72bec759478cf (patch)
tree1c3a34641b44ca6f435c7a9979de77abc1669234 /app/src/main/res
parent888af190ed4fc0ebf492088e54d81cf45fa50549 (diff)
downloadfrost-8c343fd09cdf80cfbcdf49fd5cc72bec759478cf.tar.gz
frost-8c343fd09cdf80cfbcdf49fd5cc72bec759478cf.tar.bz2
frost-8c343fd09cdf80cfbcdf49fd5cc72bec759478cf.zip
Test image activity
Diffstat (limited to 'app/src/main/res')
-rw-r--r--app/src/main/res/layout/activity_image.xml2
-rw-r--r--app/src/main/res/layout/activity_image_2.xml72
2 files changed, 74 insertions, 0 deletions
diff --git a/app/src/main/res/layout/activity_image.xml b/app/src/main/res/layout/activity_image.xml
index 6530dc4a..7e19dabf 100644
--- a/app/src/main/res/layout/activity_image.xml
+++ b/app/src/main/res/layout/activity_image.xml
@@ -17,6 +17,8 @@
android:layout_width="match_parent"
android:layout_height="match_parent">
+ <!-- Alpha and scaling will be reset on load -->
+
<com.davemorrissey.labs.subscaleview.SubsamplingScaleImageView
android:id="@+id/image_photo"
android:layout_width="match_parent"
diff --git a/app/src/main/res/layout/activity_image_2.xml b/app/src/main/res/layout/activity_image_2.xml
new file mode 100644
index 00000000..689c4f4d
--- /dev/null
+++ b/app/src/main/res/layout/activity_image_2.xml
@@ -0,0 +1,72 @@
+<?xml version="1.0" encoding="utf-8"?>
+<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:app="http://schemas.android.com/apk/res-auto"
+ android:id="@+id/image_container"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent">
+
+ <ProgressBar
+ android:id="@+id/image_progress"
+ style="?android:attr/progressBarStyleLarge"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_gravity="center" />
+
+ <com.pitchedapps.frost.views.DragFrame
+ android:id="@+id/image_drag"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent">
+
+ <!-- Alpha and scaling will be reset on load -->
+
+ <com.github.piasy.biv.view.BigImageView
+ android:id="@+id/image_photo"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:alpha="0"
+ android:scaleX="0.9"
+ android:scaleY="0.9" />
+
+ </com.pitchedapps.frost.views.DragFrame>
+
+ <LinearLayout
+ android:id="@+id/toolbar"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_gravity="top"
+ android:gravity="end"
+ android:orientation="horizontal"
+ android:paddingStart="8dp"
+ android:paddingTop="10dp"
+ android:paddingEnd="8dp"
+ android:paddingBottom="10dp">
+
+ <ImageView
+ android:id="@+id/error"
+ style="@style/Image.Icon" />
+
+ <Space
+ android:layout_width="0dp"
+ android:layout_height="wrap_content"
+ android:layout_weight="1" />
+
+ <ImageView
+ android:id="@+id/download"
+ style="@style/Image.Icon" />
+
+ <ImageView
+ android:id="@+id/share"
+ style="@style/Image.Icon" />
+
+ </LinearLayout>
+
+ <TextView
+ android:id="@+id/image_text"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:alpha="0.5"
+ android:padding="@dimen/kau_padding_normal"
+ app:behavior_peekHeight="44dp"
+ app:layout_behavior="@string/bottom_sheet_behavior" />
+
+</androidx.coordinatorlayout.widget.CoordinatorLayout>