I am trying to create a simple 2D game using OpenGL 2. I am using GL Sufus Wiv. I am trying to find out the point of inclination on the scene but it does not recognize anything why is it? The code is following: -.
inside and glsurfaceview
@SuppressWarnings ( "resistance") Last GestureDetector gestureDetector = new GestureDetector tried to declare out (new gesture Detecter GestureDetectorkSimpleOnGestureListener () {public zero onLongPress (MotionEvent e) {Log.d ( "", "Longpress detected");} @Override public boolean onFling (MotionEvent E1, MotionEvent e2, boat velocityX, velocityY float) {Log.d ( "", " Onfling detected "); Return super. Nifling (E1, E2, Velcityx, Velocity V);}});
GLSurfaceView inside
@Override public boolean onTouchEvent (MotionEvent event) {return gestureDetector.onTouchEvent (event); }
When I wavy on the surface, it detects the press for a long time and instead prints the debug message for long press instead of throwing it. Whatever I do on the screen, it just looks longpress .. What's wrong?
After the override onDown
In your listener:
@ Override Public Boolean OnDown (Motion Event Event) {Return Truth; }
to:
That's because all gestures start with an ondown () message. If you return false from onDown (), as GestureDetector.SimpleOnGestureListener By default, the system assumes that you get to ignore the rest of the points, and other methods of GestureDetector.OnGestureListener never called. This is the capability due to unexpected problems in your app. "Does not
I appreciate the explanation why you're still manage to get to know a text and email. Is above resolve your problem, maybe This is the puzzle that does not need to be solved ...
Comments
Post a Comment