Search in sources :

Example 1 with CircularImageView

use of com.mikhaellopez.circularimageview.CircularImageView in project MTweaks-KernelAdiutorMOD by morogoku.

the class ContributorView method onCreateView.

@Override
public void onCreateView(View view) {
    super.onCreateView(view);
    CircularImageView image = (CircularImageView) view.findViewById(R.id.image);
    TextView name = (TextView) view.findViewById(R.id.name);
    TextView contributions = (TextView) view.findViewById(R.id.contributions);
    ViewUtils.loadImagefromUrl(mContributor.getAvatarUrl(), image, 200, 200);
    name.setText(mContributor.getLogin());
    contributions.setText(view.getResources().getString(R.string.commits, mContributor.getContributions()));
    view.setOnClickListener(new View.OnClickListener() {

        @Override
        public void onClick(View v) {
            Utils.launchUrl(mContributor.getHtmlUrl(), v.getContext());
        }
    });
}
Also used : TextView(android.widget.TextView) CircularImageView(com.mikhaellopez.circularimageview.CircularImageView) TextView(android.widget.TextView) View(android.view.View) CircularImageView(com.mikhaellopez.circularimageview.CircularImageView)

Aggregations

View (android.view.View)1 TextView (android.widget.TextView)1 CircularImageView (com.mikhaellopez.circularimageview.CircularImageView)1