Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 73: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 74: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 75: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 76: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 77: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 78: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
package org.anddev.andnav.apk.ui.common.views; import android.view.MotionEvent; import android.view.View; import android.view.View.OnTouchListener; public abstract class OnTouchAndLongPressListener implements OnTouchListener{ // =========================================================== // Constants // =========================================================== /** Time in milliseconds until a TouchEvent should be registered as an actual LongPress. */ public static final long LONGPRESS_DOWNTIME = 1200; public static final int LONGPRESS_MAXDIST_POW2 = 5*5; // =========================================================== // Fields // =========================================================== protected boolean mLongPressTriggeredThisMotion = false; protected final boolean mNoTouchEvents; protected int mDownX, mDownY; // =========================================================== // Constructors // =========================================================== public OnTouchAndLongPressListener(boolean noTouchEvents){ this.mNoTouchEvents = noTouchEvents; } // =========================================================== // Getter & Setter // =========================================================== // =========================================================== // Methods from SuperClass/Interfaces // =========================================================== @Override public final boolean onTouch(final View v, final MotionEvent moEv) { final int action = moEv.getAction(); final int x = (int)moEv.getX(); final int y = (int)moEv.getY(); switch(action){ case MotionEvent.ACTION_CANCEL: mLongPressTriggeredThisMotion = false; break; case MotionEvent.ACTION_MOVE: case MotionEvent.ACTION_UP: final int dx = mDownX - x; final int dy = mDownY - y; final boolean movedFar = dx*dx + dy*dy > LONGPRESS_MAXDIST_POW2; if(!movedFar && !mLongPressTriggeredThisMotion && (moEv.getEventTime() - moEv.getDownTime() > LONGPRESS_DOWNTIME)){ mLongPressTriggeredThisMotion = true; onLongPress(v, x, y); } break; case MotionEvent.ACTION_DOWN: mDownX = (int)x; mDownY = (int)y; mLongPressTriggeredThisMotion = false; break; } return onTouchEvent(v, moEv); } // =========================================================== // Methods // =========================================================== public abstract boolean onTouchEvent(View v, MotionEvent moEv); public abstract void onLongPress(final View v, final float x, final float y); // =========================================================== // Inner and Anonymous Classes // =========================================================== }