Back to project page Briscola.
The source code is released under:
GNU General Public License
If you think the Android project Briscola listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package com.gmail.craptik.briscola; /*from w w w. j ava2 s.c om*/ import android.app.Activity; import android.os.Bundle; import android.view.View; public class CallCardSunsSelectActivity extends Activity { @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_call_card_suns_select); } public void onCardClicked(View view) { GameData gameData = NewGameActivity.getGameData(); switch(view.getId()) { case R.id.call_card_suns_ace: { gameData.getCalledCard().setNumber(ECardNumber.ACE); break; } case R.id.call_card_suns_three: { gameData.getCalledCard().setNumber(ECardNumber.THREE); break; } case R.id.call_card_suns_king: { gameData.getCalledCard().setNumber(ECardNumber.KING); break; } case R.id.call_card_suns_horse: { gameData.getCalledCard().setNumber(ECardNumber.HORSE); break; } case R.id.call_card_suns_queen: { gameData.getCalledCard().setNumber(ECardNumber.QUEEN); break; } case R.id.call_card_suns_seven: { gameData.getCalledCard().setNumber(ECardNumber.SEVEN); break; } case R.id.call_card_suns_six: { gameData.getCalledCard().setNumber(ECardNumber.SIX); break; } case R.id.call_card_suns_five: { gameData.getCalledCard().setNumber(ECardNumber.FIVE); break; } case R.id.call_card_suns_four: { gameData.getCalledCard().setNumber(ECardNumber.FOUR); break; } case R.id.call_card_suns_two: { gameData.getCalledCard().setNumber(ECardNumber.TWO); break; } default: { // Need to handle every case here... assert false; break; } } setResult(RESULT_OK); finish(); } }