diff options
| author | Mark Wagner <mxw@google.com> | 2011-10-07 15:21:00 -0700 |
|---|---|---|
| committer | Mark Wagner <mxw@google.com> | 2011-10-10 10:16:58 -0700 |
| commit | a44cfbaf741b5410465cbfe6a4907eb38e0db001 (patch) | |
| tree | 7b32ec1c134a12765cc6b10f0a78901b0324d6e5 | |
| parent | c9b561c39318deb9c80f15f6f1169e7d92bdeb19 (diff) | |
| download | LegacyCamera-a44cfbaf741b5410465cbfe6a4907eb38e0db001.zip LegacyCamera-a44cfbaf741b5410465cbfe6a4907eb38e0db001.tar.gz LegacyCamera-a44cfbaf741b5410465cbfe6a4907eb38e0db001.tar.bz2 | |
bugfix 5290450 Share UI should match redlines
Add the "go to gallery" button at the top of the list of share
choices. Made it a separate button rather than part of the list
since it gets it's own separator.
Change-Id: I62f866f7aedd3e84916eccf037f3fa37a8528196
| -rw-r--r-- | res/drawable-hdpi/ic_gallery.png | bin | 0 -> 803 bytes | |||
| -rw-r--r-- | res/drawable-mdpi/ic_gallery.png | bin | 0 -> 658 bytes | |||
| -rw-r--r-- | res/drawable-w1024dp-hdpi/ic_gallery.png | bin | 0 -> 998 bytes | |||
| -rw-r--r-- | res/drawable-w1024dp-mdpi/ic_gallery.png | bin | 0 -> 802 bytes | |||
| -rw-r--r-- | res/drawable-w1024dp-xhdpi/ic_gallery.png | bin | 0 -> 1219 bytes | |||
| -rw-r--r-- | res/drawable-xhdpi/ic_gallery.png | bin | 0 -> 942 bytes | |||
| -rw-r--r-- | res/layout/share_popup.xml | 25 | ||||
| -rw-r--r-- | src/com/android/camera/ui/SharePopup.java | 7 |
8 files changed, 30 insertions, 2 deletions
diff --git a/res/drawable-hdpi/ic_gallery.png b/res/drawable-hdpi/ic_gallery.png Binary files differnew file mode 100644 index 0000000..bfccaa6 --- /dev/null +++ b/res/drawable-hdpi/ic_gallery.png diff --git a/res/drawable-mdpi/ic_gallery.png b/res/drawable-mdpi/ic_gallery.png Binary files differnew file mode 100644 index 0000000..b164c59 --- /dev/null +++ b/res/drawable-mdpi/ic_gallery.png diff --git a/res/drawable-w1024dp-hdpi/ic_gallery.png b/res/drawable-w1024dp-hdpi/ic_gallery.png Binary files differnew file mode 100644 index 0000000..18da118 --- /dev/null +++ b/res/drawable-w1024dp-hdpi/ic_gallery.png diff --git a/res/drawable-w1024dp-mdpi/ic_gallery.png b/res/drawable-w1024dp-mdpi/ic_gallery.png Binary files differnew file mode 100644 index 0000000..c977213 --- /dev/null +++ b/res/drawable-w1024dp-mdpi/ic_gallery.png diff --git a/res/drawable-w1024dp-xhdpi/ic_gallery.png b/res/drawable-w1024dp-xhdpi/ic_gallery.png Binary files differnew file mode 100644 index 0000000..0d6b27f --- /dev/null +++ b/res/drawable-w1024dp-xhdpi/ic_gallery.png diff --git a/res/drawable-xhdpi/ic_gallery.png b/res/drawable-xhdpi/ic_gallery.png Binary files differnew file mode 100644 index 0000000..eb189f8 --- /dev/null +++ b/res/drawable-xhdpi/ic_gallery.png diff --git a/res/layout/share_popup.xml b/res/layout/share_popup.xml index 416f46e..c9beb3a 100644 --- a/res/layout/share_popup.xml +++ b/res/layout/share_popup.xml @@ -46,17 +46,38 @@ <ImageView android:id="@+id/play" style="@style/ReviewPlayIcon"/> </RelativeLayout> - <FrameLayout + <LinearLayout android:layout_width="@dimen/share_item_width" android:layout_height="match_parent" + android:orientation="vertical" android:layout_gravity="right" android:background="@color/share_icon_background"> + <com.android.camera.ui.RotateLayout + android:layout_marginTop="8dip" + android:id="@+id/goto_gallery_button_rotate" + android:layout_gravity="center" + android:layout_width="match_parent" + android:layout_height="wrap_content" > + <ImageButton + android:id="@+id/goto_gallery_button" + android:background="?android:attr/selectableItemBackground" + android:layout_gravity="center" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:src="@drawable/ic_gallery" /> + </com.android.camera.ui.RotateLayout> + <View + android:layout_width="match_parent" + android:layout_margin="8dip" + android:layout_height="1dp" + android:background="#5affffff" /> + <ListView android:id="@+id/share_list" android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="vertical" android:choiceMode="singleChoice" style="@android:style/Widget.Holo.ListView" /> - </FrameLayout> + </LinearLayout> </FrameLayout> </FrameLayout> diff --git a/src/com/android/camera/ui/SharePopup.java b/src/com/android/camera/ui/SharePopup.java index 42b27d1..84bada4 100644 --- a/src/com/android/camera/ui/SharePopup.java +++ b/src/com/android/camera/ui/SharePopup.java @@ -68,6 +68,7 @@ public class SharePopup extends PopupWindow implements View.OnClickListener, private ListView mShareList; // A rotated view that contains the thumbnail. private RotateLayout mThumbnailRotateLayout; + private RotateLayout mGotoGalleryRotate; private View mPreviewFrame; private ArrayList<ComponentName> mComponent = new ArrayList<ComponentName>(); @@ -120,6 +121,9 @@ public class SharePopup extends PopupWindow implements View.OnClickListener, mShareView = (ViewGroup) sharePopup.findViewById(R.id.share_view); mShareView.setOnClickListener(this); + mGotoGalleryRotate =(RotateLayout) sharePopup.findViewById(R.id.goto_gallery_button_rotate); + sharePopup.findViewById(R.id.goto_gallery_button).setOnClickListener(this); + mBitmapWidth = bitmap.getWidth(); mBitmapHeight = bitmap.getHeight(); @@ -258,6 +262,8 @@ public class SharePopup extends PopupWindow implements View.OnClickListener, r.setOrientation(orientation); } + mGotoGalleryRotate.setOrientation(orientation); + adjustThumbnailPosition(); } @@ -271,6 +277,7 @@ public class SharePopup extends PopupWindow implements View.OnClickListener, @Override public void onClick(View v) { switch (v.getId()) { + case R.id.goto_gallery_button: case R.id.share_view: Util.viewUri(mUri, mContext); break; |
