mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2025-01-23 07:27:22 +01:00
fix so board draws correctly when loaded in trade mode
This commit is contained in:
parent
82a82b5ae1
commit
7457ce9b80
3 changed files with 6 additions and 4 deletions
|
@ -767,7 +767,7 @@ public class BoardActivity extends XWActivity
|
||||||
item.setTitle( R.string.board_menu_game_final );
|
item.setTitle( R.string.board_menu_game_final );
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( DeviceRole.SERVER_STANDALONE == m_gi.serverRole ) {
|
if ( null != m_gi && DeviceRole.SERVER_STANDALONE == m_gi.serverRole ) {
|
||||||
Utils.setItemVisible( menu, R.id.board_menu_game_resend, false );
|
Utils.setItemVisible( menu, R.id.board_menu_game_resend, false );
|
||||||
Utils.setItemVisible( menu, R.id.gamel_menu_checkmoves, false );
|
Utils.setItemVisible( menu, R.id.gamel_menu_checkmoves, false );
|
||||||
}
|
}
|
||||||
|
@ -1803,8 +1803,8 @@ public class BoardActivity extends XWActivity
|
||||||
updateToolbar();
|
updateToolbar();
|
||||||
if ( m_inTrade != m_gsi.inTrade ) {
|
if ( m_inTrade != m_gsi.inTrade ) {
|
||||||
m_inTrade = m_gsi.inTrade;
|
m_inTrade = m_gsi.inTrade;
|
||||||
m_view.setInTrade( m_inTrade );
|
|
||||||
}
|
}
|
||||||
|
m_view.setInTrade( m_inTrade );
|
||||||
adjustTradeVisibility();
|
adjustTradeVisibility();
|
||||||
Activity self = BoardActivity.this;
|
Activity self = BoardActivity.this;
|
||||||
Utils.invalidateOptionsMenuIf( self );
|
Utils.invalidateOptionsMenuIf( self );
|
||||||
|
|
|
@ -178,7 +178,10 @@ public class BoardCanvas extends Canvas implements DrawCtx {
|
||||||
|
|
||||||
public void setInTrade( boolean inTrade )
|
public void setInTrade( boolean inTrade )
|
||||||
{
|
{
|
||||||
m_inTrade = inTrade;
|
if ( m_inTrade != inTrade ) {
|
||||||
|
m_inTrade = inTrade;
|
||||||
|
m_jniThread.handle( JNIThread.JNICmd.CMD_INVALALL );
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// DrawCtxt interface implementation
|
// DrawCtxt interface implementation
|
||||||
|
|
|
@ -321,7 +321,6 @@ public class BoardView extends View implements BoardHandler, SyncedDraw {
|
||||||
if ( null != m_canvas ) {
|
if ( null != m_canvas ) {
|
||||||
m_canvas.setInTrade( inTrade );
|
m_canvas.setInTrade( inTrade );
|
||||||
}
|
}
|
||||||
m_jniThread.handle( JNIThread.JNICmd.CMD_INVALALL );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public int getCurPlayer()
|
public int getCurPlayer()
|
||||||
|
|
Loading…
Add table
Reference in a new issue