Esempio n. 1
0
 @Override
 public void onBindViewHolder(SpotlightViewHolder holder, int position) {
   Message info = data.get(position);
   holder.spotlightText.setText(info.getMESSAGE());
   if (info.hasValidUrl()) {
     holder.spotlightText.setTextColor(getActivity().getResources().getColor(R.color.fade_blue));
   }
 }
Esempio n. 2
0
 @Override
 public void onClick(View v) {
   Message mes = data.get(getAdapterPosition());
   if (mes.hasValidUrl()) {
     mes.formatURL();
     Intent browserIntent = new Intent(Intent.ACTION_VIEW, Uri.parse(mes.getURL()));
     startActivity(browserIntent);
   }
 }