Skip to content

Commit

Permalink
Probably fix failure to resume? Think I was calling startGame twice.
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisboyle committed Oct 12, 2011
1 parent cab4317 commit 9e105fb
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/name/boyle/chris/sgtpuzzles/SGTPuzzles.java
Original file line number Diff line number Diff line change
Expand Up @@ -230,6 +230,10 @@ public void uncaughtException(Thread t, Throwable e) {
@Override
protected void onNewIntent(Intent intent)
{
if( progress != null ) {
// Sorry, cancelling is hard. :-p Require explicit user action.
return;
}
String s = intent.getStringExtra("game");
Uri u = intent.getData();
if (s != null && s.length() > 0) {
Expand Down Expand Up @@ -448,6 +452,10 @@ static String getVersion(Context c)
void startGame(final int which, final String savedGame)
{
Log.d(TAG, "startGame: "+which+", "+((savedGame==null)?"null":(savedGame.length()+" bytes")));
if (progress != null) {
Log.wtf(TAG, "startGame while already starting!");
return;
}
showProgress( (savedGame == null) ? R.string.starting : R.string.resuming );
if( gameRunning ) {
gameView.clear();
Expand Down

0 comments on commit 9e105fb

Please sign in to comment.