Cleveroad / Cleveroad/AdaptiveTableLayout

Not able to click on view

Open
#49 3 comments 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
1.9k
Forks
238
PR merge metrics
No merged PRs in 30d

Description

Kindly check my code below:

I am not able to find click listener

+++++++++++++++++++

private static class TestHeaderColumnViewHolder extends ViewHolderImpl {

TextView tvTitle, tvAddToCartCompare;
ImageView ivProduct, ivRemove;

private TestHeaderColumnViewHolder(@NonNull View itemView) {
super(itemView);
tvTitle = itemView.findViewById(R.id.tvTitle);
tvAddToCartCompare = itemView.findViewById(R.id.tvAddToCartCompare);
ivProduct = itemView.findViewById(R.id.ivProduct);
ivRemove = itemView.findViewById(R.id.ivRemove);

}

public void bind(TestHeaderColumnViewHolder vh, int column) {
tvTitle.setText(arrayListOfItem.get(column - 1).getProduct_name());
Glide.with(getItemView().getContext()).load(arrayListOfItem.get(column - 1).getProduct_image()).into(ivProduct);
**tvAddToCartCompare.setOnClickListener(view -> {

assert addtocartClickListner != null;
addtocartClickListner.addToCart(view, arrayListOfItem.get(column - 1), arrayListOfItem.get(column - 1).get_id());

});**
**ivRemove.setOnClickListener(view -> {

assert removeCompareClickLisner != null;
removeCompareClickLisner.removeFromCart(view, arrayListOfItem.get(column - 1), arrayListOfItem.get(column - 1).get_id());

});**
}
}

+++++++++++++++++++

Kindly help me with solution

Thanks

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with the supplied TestHeaderColumnViewHolder.bind method and trace how the holder is created and bound in the repository. Reproduce the click failure and inspect listener setup and view state; the issue names no project file, test, or concrete completion condition.

Written by the indexing model from the issue text.

Assessment

Tech stack
android, java
Domain
mobile
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
12/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.