Skip to content

Instantly share code, notes, and snippets.

@ParisaRashidi
Created June 29, 2016 13:36
Show Gist options
  • Save ParisaRashidi/1e6df71bae4aee9aa6e694821b36df79 to your computer and use it in GitHub Desktop.
Save ParisaRashidi/1e6df71bae4aee9aa6e694821b36df79 to your computer and use it in GitHub Desktop.
@Override
public void onViewCreated(final View view, @Nullable Bundle savedInstanceState) {
super.onViewCreated(view, savedInstanceState);
barcodeScanRecyclerView = (RecyclerView) view.findViewById(R.id.recycler);
pinterestView = (PinterestView) view.findViewById(R.id.pin_view);
pinterestView.addMenuItem(createChildView(R.mipmap.spinner_frame_8_96px, "loading")
, createChildView(R.mipmap.delete, "delete"), createChildView(R.drawable.delete_this_barcode, "link")
, createChildView(R.mipmap.share_96px, "share"));
pinterestView.setPinClickListener(new PinterestView.PinMenuClickListener() {
@Override
public void onMenuItemClick(View view) {
switch (view.getTag().toString())
{
case "delete": deleteBtnClicked = true ;
break;
case "share" : shareBtnClicked = true;
break;
case "link": linkBtnClicked = true;
break;
default:
break;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment