Exemplo n.º 1
0
 @Override
 protected void onDraw(Canvas canvas) {
   if (mCanvasAdapter.beginPaint(canvas)) {
     canvas.drawColor(Color.TRANSPARENT, Mode.CLEAR);
     mCoreView.dynDraw(mViewAdapter, mCanvasAdapter);
     mCanvasAdapter.endPaint();
   }
 }
Exemplo n.º 2
0
 @Override
 protected void onDetachedFromWindow() {
   if (mCanvasAdapter != null) {
     mCanvasAdapter.delete();
     mCanvasAdapter = null;
   }
   mCoreView = null;
   mViewAdapter = null;
   super.onDetachedFromWindow();
 }
Exemplo n.º 3
0
 public void doDraw() {
   if (!mCanvasAdapter.isDrawing()) {
     mBeginTime = android.os.SystemClock.uptimeMillis();
     new Thread(new DrawThread()).start();
   }
 }
Exemplo n.º 4
0
 public boolean isDrawing() {
   return mCanvasAdapter != null && mCanvasAdapter.isDrawing();
 }