예제 #1
0
  public void surfaceDestroyed(SurfaceHolder holder) {
    thread.setMode(Mode.STOPPED);

    boolean retry = true;
    while (retry) {
      try {
        thread.join();
        retry = false;
      } catch (InterruptedException e) {
      }
    }
  }
 @Override
 public void surfaceDestroyed(SurfaceHolder holder) {
   boolean retry = true;
   drawThread.setRunning(false);
   while (retry) {
     try {
       drawThread.join();
       retry = false;
     } catch (InterruptedException e) {
     }
   }
 }
예제 #3
0
 public void surfaceDestroyed(SurfaceHolder holder) {
   boolean retry = true;
   thread.setRunning(false);
   while (retry) {
     try {
       thread.join();
       retry = false;
     } catch (InterruptedException e) {
       // we will try it again and again...
     }
   }
 }
예제 #4
0
    @Override
    public void surfaceDestroyed(SurfaceHolder arg0) {
      stop();
      _thread.setRunning(false);
      while (true) {
        try {
          _thread.join();
          break;
        } catch (InterruptedException e) {

        }
      }
    }
예제 #5
0
파일: WidgetView.java 프로젝트: fesch/CanZE
 @Override
 public void surfaceDestroyed(SurfaceHolder arg0) {
   // stop the drawThread properly
   boolean retry = true;
   while (retry) {
     try {
       // wait for it to finish
       if (drawThread != null && drawThread.isRunning()) drawThread.join();
       retry = false;
     } catch (InterruptedException e) {
       // ignore any error
       e.printStackTrace();
     }
   }
   // set it to null, so that a new one can be created in case of a resume
   drawThread = null;
 }