mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2025-01-20 22:26:54 +01:00
go back to overriding onPause and onResume, but don't tear down the game unless isFinishing() returns true
This commit is contained in:
parent
5e3c26d453
commit
b56d990a04
1 changed files with 16 additions and 12 deletions
|
@ -593,26 +593,30 @@ public class BoardActivity extends XWActivity
|
||||||
} // onCreate
|
} // onCreate
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void onStop()
|
protected void onPause()
|
||||||
{
|
{
|
||||||
m_handler = null;
|
if ( isFinishing() ) {
|
||||||
ConnStatusHandler.setHandler( null );
|
m_handler = null;
|
||||||
waitCloseGame( true );
|
ConnStatusHandler.setHandler( null );
|
||||||
super.onStop();
|
waitCloseGame( true );
|
||||||
|
}
|
||||||
|
super.onPause();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void onStart()
|
protected void onResume()
|
||||||
{
|
{
|
||||||
super.onStart();
|
super.onResume();
|
||||||
m_handler = new Handler();
|
if ( null == m_handler ) {
|
||||||
m_blockingDlgID = BLOCKING_DLG_NONE;
|
m_handler = new Handler();
|
||||||
|
m_blockingDlgID = BLOCKING_DLG_NONE;
|
||||||
|
|
||||||
setKeepScreenOn();
|
setKeepScreenOn();
|
||||||
|
|
||||||
loadGame();
|
loadGame();
|
||||||
|
|
||||||
ConnStatusHandler.setHandler( this );
|
ConnStatusHandler.setHandler( this );
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
Loading…
Reference in a new issue