14.06.2011

surfaceCreated()

posted by Karsten

public void surfaceCreated(SurfaceHolder holder) { if(thread!=null) { thread.setRunning(true); if(thread.getState() == Thread.State.NEW){ //Just start the new thread thread.start(); } else { if(thread.getState() == Thread.State.TERMINATED){ //Set up and start a new thread with the old thread as seed thread = new GameThread(this, thread); thread.setRunning(true); thread.start(); } } } }

Share

Place your comment

Please fill your data and comment below.
Name
Email
Website
Your comment