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)
/** * Demonstrates the handling of touch screen events to implement a simple * painting app. */ package com.e2esp.android.drawing; import android.app.Activity; import android.content.Context; import android.graphics.Bitmap; import android.graphics.Canvas; import android.graphics.Color; import android.graphics.Paint; import android.graphics.PorterDuff; import android.graphics.Rect; import android.os.Bundle; import android.view.MotionEvent; import android.view.View; //Need the following import to get access to the app resources, since this //class is in a sub-package. /** * Demonstrates the handling of touch screen events to implement a simple * painting app. */ public class TouchPaint extends Activity { @Override protected void onCreate(Bundle icicle) { super.onCreate(icicle); setContentView(new MyView(this)); } public class MyView extends View { Bitmap mBitmap; Canvas mCanvas; private final Rect mRect = new Rect(); private final Paint mPaint; private boolean mCurDown; private int mCurX; private int mCurY; private float mCurPressure; private float mCurSize; private int mCurWidth; boolean isActionMove = false; private int[] xCoord; private int[] yCoord; private int count = 0; public MyView(Context c) { super(c); mPaint = new Paint(); mPaint.setAntiAlias(true); //mPaint.setARGB(0, 0, 0, 0); mPaint.setColor(Color.BLACK); xCoord = new int[100]; yCoord = new int[100]; } @Override protected void onSizeChanged(int w, int h, int oldw, int oldh) { int curW = mBitmap != null ? mBitmap.width() : 0; int curH = mBitmap != null ? mBitmap.height() : 0; if (curW >= w && curH >= h) { return; } if (curW < w) curW = w; if (curH < h) curH = h; Bitmap newBitmap = Bitmap.createBitmap(curW, curH, false); Canvas newCanvas = new Canvas(); newCanvas.setDevice(newBitmap); if (mBitmap != null) { newCanvas.drawBitmap(mBitmap, 0, 0, null); } mBitmap = newBitmap; mCanvas = newCanvas; mCanvas.drawColor(Color.WHITE); } @Override protected void onDraw(Canvas canvas) { if (mBitmap != null) { canvas.drawBitmap(mBitmap, 0, 0, null); } } @Override public boolean onMotionEvent(MotionEvent event) { int action = event.getAction(); int X = (int)event.getX(); int Y = (int)event.getY(); mCurPressure = event.getPressure(); mCurSize = event.getSize(); mCurWidth = (int)(mCurSize*(getWidth()/3)); switch (action ) { case MotionEvent.ACTION_DOWN: mCurX = (int)event.getX(); mCurY = (int)event.getY(); break; case MotionEvent.ACTION_MOVE: // saving the coordinates xCoord[count] = X; yCoord[count] = Y; count++; mCanvas.drawLine(mCurX, mCurY, X, Y, mPaint); // Paint paint = new Paint(); // int pressureLevel = (int)(mCurPressure*255); // paint.setARGB(pressureLevel, 255, 255, 255); // paint.setColor(Color.WHITE); // mCanvas.drawLine(mCurX, mCurY, X, Y, paint); //isActionMove = true; break; case MotionEvent.ACTION_UP: // if (isActionMove) // rub the previous lines /* for (int i=0; i