コード例 #1
0
 public Callback(Context context, CameraControlView view, View.IOnTouchListener listener)
     : base(context)
 {
     _context          = context;
     mOpenCvCameraView = view;
     _listener         = listener;
 }
コード例 #2
0
 public virtual Com.Zhy.Adapter.Abslistview.ViewHolder SetOnTouchListener(int viewId
                                                                          , View.IOnTouchListener listener)
 {
     Android.Views.View view = GetView <View>(viewId);
     view.SetOnTouchListener(listener);
     return(this);
 }
コード例 #3
0
        private Actor(View view, List <Motion> motions, View.IOnTouchListener onTouchListener, bool motionListenerEnabled, bool attachTouchListener, bool requestDisallowTouchEvent)
        {
            mView            = view;
            mMotions         = motions;
            mOnTouchListener = onTouchListener;

            try
            {
                mMotionListener = new MotionListener();
                mMotionListener.mMotionListenerEnabled = mMotionListenerEnabled;
                mMotionListener.mMotions                   = mMotions;
                mMotionListener.mOnTouchListener           = onTouchListener;
                mMotionListener.mRequestDisallowTouchEvent = mRequestDisallowTouchEvent;
                mMotionListener.MAX_CLICK_DISTANCE         = MAX_CLICK_DISTANCE;
            }
            catch (Java.Lang.Exception ex)
            {
                throw ex;
            }

            mMotionListenerEnabled = motionListenerEnabled;

            mRequestDisallowTouchEvent = requestDisallowTouchEvent;

            if (attachTouchListener)
            {
                view.SetOnTouchListener(mMotionListener);
            }
        }
コード例 #4
0
        public SwipeHelper(Context context, RecyclerView recyclerView, int buttonWidth) : base(0, ItemTouchHelper.Left)
        {
            this.recyclerView  = recyclerView;
            this.buttonHelpers = new List <ButtonHelper>();
            this.buttonBuffer  = new Dictionary <int, List <ButtonHelper> >();
            this.buttonWidth   = buttonWidth;

            simpleOnGestureListener = new GestureListenerHelper(this);
            onTouchListener         = new TouchListenerHelper(this);
            this.gestureDetector    = new GestureDetector(context, simpleOnGestureListener);
            this.recyclerView.SetOnTouchListener(onTouchListener);
            AttachSwipe();
        }
コード例 #5
0
        public PolyLibView ResizeView(int boundsWidth, int boundsHeight, View.IOnTouchListener listener = null)
        {
            //SKCanvasView cannot change size. Instead, generate a new one in this views place

            var parent = ((ViewGroup)Parent);
            var index  = parent.IndexOfChild(this);

            parent.RemoveView(this);
            var newCanvasView = new PolyLibView(Context);

            //setup listeners
            newCanvasView.SetOnTouchListener(listener);
            SetOnTouchListener(null);

            parent.AddView(newCanvasView, index, new FrameLayout.LayoutParams(boundsWidth, boundsHeight));
            return(newCanvasView);
        }
 public Callback(Context context, View.IOnTouchListener listener, CameraCalibrationActivity activity)
     : base(context)
 {
     _listener = listener;
     _activity = activity;
 }
コード例 #7
0
 public void RemoveListener(View.IOnTouchListener listener)
 {
     Listeners.Remove(listener);
 }
コード例 #8
0
 public void AddListener(View.IOnTouchListener listener)
 {
     Listeners.Add(listener);
 }
コード例 #9
0
 public ListAdapterClass(Activity context, string[] strMnu, View.IOnTouchListener gesture)
 {
     _context = context;
     _mnuText = strMnu;
     iGesture = gesture;
 }
コード例 #10
0
 public override void SetOnTouchListener(View.IOnTouchListener l)
 {
     touchListener = l;
 }
コード例 #11
0
            /**
             * @param onTouchListener
             *      a touch listener to pass touch events to
             * @return this builder for chaining
             */

            public Builder OnTouchListener(View.IOnTouchListener onTouchListener)
            {
                mOnTouchListener = onTouchListener;
                return(this);
            }