summaryrefslogtreecommitdiffstats
path: root/res/layout
diff options
context:
space:
mode:
authorwqi <wqi@codeaurora.org>2016-04-14 11:25:23 +0800
committerGerrit - the friendly Code Review server <code-review@localhost>2016-04-22 02:51:33 -0700
commit6c5a2dd884a861e8d279fb7cd50c11b4c7d68004 (patch)
tree8fcb5cfbfc6f6fdc8f1845767add280e59422ee9 /res/layout
parent317616930e7273b40e8b7a367fee225b1c9e6bea (diff)
downloadandroid_packages_apps_Gallery2-6c5a2dd884a861e8d279fb7cd50c11b4c7d68004.tar.gz
android_packages_apps_Gallery2-6c5a2dd884a861e8d279fb7cd50c11b4c7d68004.tar.bz2
android_packages_apps_Gallery2-6c5a2dd884a861e8d279fb7cd50c11b4c7d68004.zip
Gallery2: Modified layout of crop and exposure model in photo editor.
1. Modified layout in crop model. 2. Remove mirror and draw only keep crop, straighten, rotate in crop model. 3. Adjust style of seekbar in exposure model. 4. Modified layout in exposure model. 5. Remove '4:3', '3:4', '5:7' and '7:5' functions from crop. According to UX specification document. Change-Id: Ib536b3f57a83053bac8fc6ec778675a82b6327e6 CRs-Fixed: 988082 988090
Diffstat (limited to 'res/layout')
-rw-r--r--res/layout/filtershow_actionbar.xml3
-rw-r--r--res/layout/filtershow_category_geometry_panel.xml163
-rw-r--r--res/layout/filtershow_editor_panel.xml9
-rw-r--r--res/layout/filtershow_seekbar.xml56
4 files changed, 193 insertions, 38 deletions
diff --git a/res/layout/filtershow_actionbar.xml b/res/layout/filtershow_actionbar.xml
index 7e6d62504..a23ca80b7 100644
--- a/res/layout/filtershow_actionbar.xml
+++ b/res/layout/filtershow_actionbar.xml
@@ -27,7 +27,7 @@
android:scaleType="fitCenter"
android:src="@drawable/cancel"
android:layout_gravity="left|center_vertical"
- android:paddingStart="16dp" />
+ android:paddingStart="6dp" />
<TextView
android:id="@+id/filtershow_done"
@@ -36,6 +36,7 @@
android:paddingRight="13dp"
android:textSize="17sp"
android:text="@string/save"
+ android:textAllCaps="true"
android:layout_gravity="center_vertical|right"
android:textColor="#ffffff" />
diff --git a/res/layout/filtershow_category_geometry_panel.xml b/res/layout/filtershow_category_geometry_panel.xml
new file mode 100644
index 000000000..92dc359d6
--- /dev/null
+++ b/res/layout/filtershow_category_geometry_panel.xml
@@ -0,0 +1,163 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright (c) 2016, The Linux Foundation. All rights reserved.
+
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are
+ met:
+ * Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above
+ copyright notice, this list of conditions and the following
+ disclaimer in the documentation and/or other materials provided
+ with the distribution.
+ * Neither the name of The Linux Foundation nor the names of its
+ contributors may be used to endorse or promote products derived
+ from this software without specific prior written permission.
+
+ THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED
+ WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT
+ ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS
+ BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
+ BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+ WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
+ OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
+ IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+-->
+
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:background="@android:color/transparent"
+ android:orientation="vertical">
+
+ <LinearLayout
+ android:layout_width="match_parent"
+ android:layout_height="@dimen/category_panel_height"
+ android:background="@android:color/transparent"
+ android:clickable="true"
+ android:orientation="horizontal">
+
+ <LinearLayout
+ android:id="@+id/leftPanel"
+ android:layout_width="0dp"
+ android:layout_height="match_parent"
+ android:layout_weight="1"
+ android:background="@android:color/transparent"
+ android:orientation="vertical" >
+
+ <ImageButton
+ android:id="@+id/leftButton"
+ android:layout_width="match_parent"
+ android:layout_height="@dimen/crop_icon_size"
+ android:scaleType="centerInside"
+ android:background="@android:color/transparent"
+ android:layout_marginTop="@dimen/crop_icon_margin_padding" />
+
+ <TextView
+ android:id="@+id/leftText"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:gravity="center"
+ android:clickable="true"
+ android:background="@android:color/transparent"
+ android:layout_marginTop="@dimen/crop_text_margin_padding"
+ android:textColor="#ffffff"
+ android:textSize="12sp" />
+ </LinearLayout>
+
+ <LinearLayout
+ android:id="@+id/centerPanel"
+ android:layout_width="0dp"
+ android:layout_height="match_parent"
+ android:layout_weight="1"
+ android:clickable="true"
+ android:background="@android:color/transparent"
+ android:orientation="vertical">
+
+ <ImageButton
+ android:id="@+id/centerButton"
+ android:layout_width="match_parent"
+ android:layout_height="@dimen/crop_icon_size"
+ android:scaleType="centerInside"
+ android:background="@android:color/transparent"
+ android:layout_marginTop="@dimen/crop_icon_margin_padding" />
+
+ <TextView
+ android:id="@+id/centerText"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:gravity="center"
+ android:clickable="true"
+ android:background="@android:color/transparent"
+ android:layout_marginTop="@dimen/crop_text_margin_padding"
+ android:textColor="#ffffff"
+ android:textSize="12sp" />
+ </LinearLayout>
+
+ <LinearLayout
+ android:id="@+id/rightPanel"
+ android:layout_width="0dp"
+ android:layout_height="match_parent"
+ android:layout_weight="1"
+ android:clickable="true"
+ android:background="@android:color/transparent"
+ android:orientation="vertical">
+
+ <ImageButton
+ android:id="@+id/rightButton"
+ android:layout_width="match_parent"
+ android:layout_height="@dimen/crop_icon_size"
+ android:scaleType="centerInside"
+ android:layout_marginTop="@dimen/crop_icon_margin_padding"
+ android:background="@android:color/transparent" />
+
+ <TextView
+ android:id="@+id/rightText"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:gravity="center"
+ android:clickable="true"
+ android:background="@android:color/transparent"
+ android:layout_marginTop="@dimen/crop_text_margin_padding"
+ android:textColor="#ffffff"
+ android:textSize="12sp" />
+ </LinearLayout>
+
+ </LinearLayout>
+
+ <FrameLayout
+ android:id="@+id/bottom_panel"
+ android:layout_width="match_parent"
+ android:layout_height="@dimen/category_actionbar_panel_height"
+ android:background="@color/edit_actionbar_background"
+ android:visibility="gone">
+
+ <ImageButton
+ android:id="@+id/cancel"
+ android:layout_width="@dimen/category_actionbar_panel_height"
+ android:layout_height="@dimen/category_actionbar_panel_height"
+ android:background="@color/edit_actionbar_background"
+ android:src="@drawable/cancel" />
+
+ <TextView
+ android:id="@+id/editor_name"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:textSize="16sp"
+ android:textColor="#fff"
+ android:layout_gravity="center"/>
+
+ <ImageButton
+ android:id="@+id/done"
+ android:layout_width="@dimen/category_actionbar_panel_height"
+ android:layout_height="@dimen/category_actionbar_panel_height"
+ android:background="@color/edit_actionbar_background"
+ android:layout_gravity="right"
+ android:src="@drawable/done" />
+ </FrameLayout>
+
+</LinearLayout>
diff --git a/res/layout/filtershow_editor_panel.xml b/res/layout/filtershow_editor_panel.xml
index 8fc01ecae..b7ec266f2 100644
--- a/res/layout/filtershow_editor_panel.xml
+++ b/res/layout/filtershow_editor_panel.xml
@@ -22,6 +22,15 @@
android:orientation="vertical"
android:visibility="visible" >
+ <Button
+ android:id="@+id/toggle_state"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_alignParentTop="true"
+ android:background="@color/background_main_toolbar"
+ android:text="@string/imageState"
+ android:visibility="gone"/>
+
<!-- <View -->
<!-- android:layout_width="match_parent" -->
<!-- android:layout_height="1dip" -->
diff --git a/res/layout/filtershow_seekbar.xml b/res/layout/filtershow_seekbar.xml
index f4d5577d2..5b884ae49 100644
--- a/res/layout/filtershow_seekbar.xml
+++ b/res/layout/filtershow_seekbar.xml
@@ -22,49 +22,31 @@
android:orientation="horizontal"
android:visibility="visible" >
- <LinearLayout
- android:id="@+id/basicFilterContainer"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:orientation="vertical" >
-
- <TextView
- android:id="@+id/tvFilterValue"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:layout_alignParentLeft="true"
- android:layout_gravity="left|center_vertical"
- android:paddingLeft="23dp"
- android:paddingTop="20dp"
- android:textColor="#ffffff"
- android:textSize="20sp"
- android:visibility="gone" />
-
- <TextView
- android:id="@+id/tvFilterName"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:layout_alignParentLeft="true"
- android:layout_below="@+id/tvFilterValue"
- android:layout_gravity="center_vertical"
- android:paddingLeft="12dp"
- android:paddingTop="14dp"
- android:text="@string/apply_effect"
- android:textColor="#ffffff"
- android:textSize="14sp"
- android:visibility="gone" />
- </LinearLayout>
+ <ImageButton
+ android:id="@+id/slider_cancel"
+ android:layout_width="60dp"
+ android:layout_height="60dp"
+ android:src="@drawable/cancel"
+ android:layout_gravity="center_vertical"
+ android:background="#000000" />
<SeekBar
android:id="@+id/primarySeekBar"
style="@style/FilterShowSlider"
android:layout_width="match_parent"
- android:layout_height="wrap_content"
+ android:layout_height="match_parent"
android:layout_gravity="center_vertical|center_horizontal"
- android:layout_marginRight="34dp"
android:layout_toRightOf="@+id/tvFilterName"
- android:layout_weight="1"
- android:paddingTop="20dp"
- android:visibility="gone" />
+ android:layout_marginStart="10dp"
+ android:layout_marginEnd="10dp"
+ android:layout_weight="1" />
+
+ <ImageButton
+ android:id="@+id/slider_save"
+ android:layout_width="60dp"
+ android:layout_height="60dp"
+ android:src="@drawable/done"
+ android:layout_gravity="center_vertical"
+ android:background="#000000" />
</LinearLayout>