public class CupcakeListener implements OnClickListener{
?? ??? ?
?? ??? ?public CupcakeListener(){
?? ??? ??? ?// icons
?? ??? ??? ?findViewById(R.id.Home).setOnClickListener(this);
?? ??? ??? ?findViewById(R.id.Album).setOnClickListener(this);
?? ??? ??? ?findViewById(R.id.Artist).setOnClickListener(this);
?? ??? ??? ?findViewById(R.id.Playlist).setOnClickListener(this);
?? ??? ??? ?
?? ??? ??? ?// buttons
?? ??? ??? ?findViewById(R.id.SliderLyrics).setOnClickListener(this);
?? ??? ??? ?findViewById(R.id.SliderAddToPlaylist).setOnClickListener(this);
?? ??? ??? ?findViewById(R.id.SliderShare).setOnClickListener(this);
?? ??? ??? ?findViewById(R.id.SliderDownload).setOnClickListener(this);
?? ??? ??? ?
?? ??? ??? ?// license
?? ??? ??? ?if(mLicenseImageView != null){
?? ??? ??? ??? ?mLicenseImageView.setOnClickListener(this);
?? ??? ??? ?}
?? ??? ?}
?? ??? [email protected]
?? ??? ?public void onClick(View v) {
?? ??? ??? ?
?? ??? ??? ?switch(v.getId()){
?? ??? ??? ?// icons
?? ??? ??? ?case R.id.Home:
?? ??? ??? ??? ?homeClickHandler(v);
?? ??? ??? ??? ?break;
?? ??? ??? ?case R.id.Album:
?? ??? ??? ??? ?albumClickHandler(v);
?? ??? ??? ??? ?break;
?? ??? ??? ?case R.id.Artist:
?? ??? ??? ??? ?artistClickHandler(v);
?? ??? ??? ??? ?break;
?? ??? ??? ?case R.id.Playlist:
?? ??? ??? ??? ?playlistClickHandler(v);
?? ??? ??? ??? ?break;
?? ??? ??? ?// buttons
?? ??? ??? ?case R.id.Lyrics:
?? ??? ??? ??? ?lyricsOnClick(v);
?? ??? ??? ??? ?break;
?? ??? ??? ?case R.id.SliderAddToPlaylist:
?? ??? ??? ??? ?addOnClick(v);
?? ??? ??? ??? ?break;
?? ??? ??? ?case R.id.SliderShare:
?? ??? ??? ??? ?shareOnClick(v);
?? ??? ??? ??? ?break;
?? ??? ??? ?case R.id.Download:
?? ??? ??? ??? ?downloadOnClick(v);
?? ??? ??? ??? ?break;
?? ??? ??? ??? ?
?? ??? ??? ?// license
?? ??? ??? ?case R.id.LicenseImageView:
?? ??? ??? ??? ?licenseClickHandler(v);
?? ??? ??? ??? ?break;
?? ??? ??? ?}
?? ??? ??? ?
?? ??? ?}
?? ??? ?
?? ?}