Android中的手勢 (Gestures in Android)


問題描述

Android中的手勢 (Gestures in Android)

There are more than 30 pictures in my android app.. I'm planning to show one image at a time when the user swipes left or right.

What is the best way to do this? Can you please point some working examples?

‑‑‑‑‑

參考解法

方法 1:

Try using Gallery . Here is the link ‑ http://developer.android.com/reference/android/widget/Gallery.html

And 

http://www.mobisoftinfotech.com/blog/android/android‑gallery‑widget‑example‑and‑tutorial/

方法 2:

    see this ...
    http://developer.android.com/reference/android/view/GestureDetector.html
You can use Gesture Detector class so detect left,rigth,up down swipes

(by NaveenAnukoolakash yadav)

參考文件

  1. Gestures in Android (CC BY‑SA 3.0/4.0)

#imageview #gestures #Android






相關問題

Android imageview 未在 TableRow 中顯示 (Android imageview not displaying in TableRow)

Android中的手勢 (Gestures in Android)

GridView kéo dài ImageView không đồng nhất (GridView Stretching ImageView Non-Uniformly)

ios在表格視圖單元格中視覺調整圖像大小 (ios visually resize image in a table view cell)

IndoorAtlas SDK 2.0:使用 Picasso 和自定義 ImageView (IndoorAtlas SDK 2.0: Using Picasso with custom ImageView)

當圖像的寬度小於顯示器的寬度時,如何在視圖尋呼機內對齊圖像視圖的中心? (How to align center an image view inside a view pager when the image's width is less than the display's?)

正確旋轉 ImageView 和 FrameLayout (Rotate ImageView and FrameLayout correctly)

setOnClickListener 沒有在圖像視圖上被調用 (setOnClickListener is not getting called on image view)

Android:擴展 onTouchEvent 以進行拖動的 ImageView (Android: ImageView that extends onTouchEvent for Drag)

將旋轉的文本放在圖像視圖上 (Put rotated text on an imageview)

如何在底部設置圖像視圖 (how to set imageview in bottom)

我如何使用數組來顯示匹配的 Imageview? (How Could I use array to show match Imageview?)







留言討論