add click listener to image button in Recycle view row
<p>I using recycle view and i have in each row textview and image button.
In on bind i adding to the image button click listener but when i try to click on the image button it clicks on the row and react only when i long click on the image button.</p>

<p>Any suggestions?</p>

<pre><code>    @Override
public void onBindViewHolder(final FolderViewHolder holder, final int position) {

    if (isFolder(position)) {
        holder.folderName.setText(folders.get(position));

    }else{

        ImageButton edit = (ImageButton) holder.view.findViewById(R.id.browser_bookmark_row_edit);
        edit.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                System.out.println(" ######### EDIT CLICKED");
                mListener.switchToEditBookmarkFragmentFolderAdapter(bookmarks.get(position - folders.size()));
            }
        });

        holder.folderName.setText(bookmarks.get(position - folders.size() ).getTitle());
    }

}




public class FolderViewHolder extends RecyclerView.ViewHolder {

    MuseoSansTextView folderName;
    View view;

    public FolderViewHolder(View itemView, MuseoSansTextView museoSansTextView) {
        super(itemView);

        view = itemView;
        folderName = museoSansTextView; //(MuseoSansTextView) itemView.findViewById(R.id.browser_bookmark_folder_name);

    }

}



&lt;android.support.v7.widget.CardView
android:id="@+id/card_view_contact"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:descendantFocusability="blocksDescendants"
card_view:cardBackgroundColor="@color/transparent"
card_view:cardCornerRadius="@dimen/card_corner_radius"
card_view:cardUseCompatPadding="false"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:card_view="http://schemas.android.com/apk/res-auto"&gt;

    &lt;RelativeLayout
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:padding="@dimen/activity_horizontal_margin"&gt;


        &lt;com.osnewhorizon.pommmanager.ui.MuseoSansTextView
            android:id="@+id/browser_bookmark_row_title"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_alignParentStart="true"
            android:layout_toLeftOf="@+id/browser_bookmark_row_edit"
            android:layout_centerVertical="true"
            android:layout_marginLeft="10dp"
            android:layout_marginRight="10dp"
            android:singleLine="true"
            android:textColor="@color/white"
            android:text="test"
            android:textSize="@dimen/contact_row_title_height" /&gt;

        &lt;ImageButton
            android:id="@+id/browser_bookmark_row_edit"
            android:layout_width="30dp"
            android:layout_height="30dp"
            android:layout_centerVertical="true"
            android:layout_alignParentEnd="true"
            android:layout_marginRight="5dp"
            android:src="@drawable/edit"
            android:background="?android:attr/selectableItemBackground"
            android:clickable="true"/&gt;


    &lt;/RelativeLayout&gt;
&lt;/android.support.v7.widget.CardView&gt;
</code></pre>