Search in sources :

Example 1 with SwipeGestureDetector

use of de.danoeh.antennapod.view.SwipeGestureDetector in project AntennaPod by AntennaPod.

the class ItemFragment method onCreate.

@Override
public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setRetainInstance(true);
    setHasOptionsMenu(true);
    feedItems = getArguments().getLongArray(ARG_FEEDITEMS);
    feedItemPos = getArguments().getInt(ARG_FEEDITEM_POS);
    headerGestureDetector = new GestureDetectorCompat(getActivity(), new SwipeGestureDetector(this));
    webviewGestureDetector = new GestureDetectorCompat(getActivity(), new SwipeGestureDetector(this) {

        // necessary for the longclick context menu to work properly
        @Override
        public boolean onDown(MotionEvent e) {
            return false;
        }
    });
}
Also used : SwipeGestureDetector(de.danoeh.antennapod.view.SwipeGestureDetector) GestureDetectorCompat(android.support.v4.view.GestureDetectorCompat) MotionEvent(android.view.MotionEvent)

Aggregations

GestureDetectorCompat (android.support.v4.view.GestureDetectorCompat)1 MotionEvent (android.view.MotionEvent)1 SwipeGestureDetector (de.danoeh.antennapod.view.SwipeGestureDetector)1