Java Code Examples for android.support.design.widget.CheckableImageButton#setOnClickListener()
The following examples show how to use
android.support.design.widget.CheckableImageButton#setOnClickListener() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: MapImageViewFragment.java From dhis2-android-dashboard with BSD 3-Clause "New" or "Revised" License | 6 votes |
@Override public void onViewCreated(View view, @Nullable Bundle savedInstanceState) { viewBaseMapButton = (CheckableImageButton) view.findViewById(R.id.view_base_map_button); viewBaseMapButton.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { modeWithBaseMap = !modeWithBaseMap; showMapImage(modeWithBaseMap); } }); showMapImage(modeWithBaseMap); }
Example 2
Source File: InterpretationAdapter.java From dhis2-android-dashboard with BSD 3-Clause "New" or "Revised" License | 6 votes |
public ImageItemViewHolder(View rootView, CheckableImageButton modeButton, ImageView view, OnItemClickListener outerListener) { this.rootView = rootView; this.imageView = view; this.modeButton = modeButton; mImageLoader = PicassoProvider.getInstance(rootView.getContext(), false); listener = new OnInterpretationInternalClickListener(outerListener); imageView.setOnClickListener(listener); modeButton.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { modeWithBaseMap = !modeWithBaseMap; showMapImage(modeWithBaseMap); } }); }
Example 3
Source File: DashboardItemAdapter.java From dhis2-android-dashboard with BSD 3-Clause "New" or "Revised" License | 6 votes |
public ImageItemViewHolder(View rootView, CheckableImageButton modeButton, ImageView view, OnItemClickListener outerListener) { this.rootView = rootView; this.imageView = view; this.modeButton = modeButton; mImageLoader = PicassoProvider.getInstance(rootView.getContext(), false); listener = new OnElementInternalClickListener(outerListener); imageView.setOnClickListener(listener); modeButton.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { modeWithBaseMap = !modeWithBaseMap; showMapImage(modeWithBaseMap); } }); }