Fix custom emoji keyboard

This commit is contained in:
Grishka 2024-10-30 09:20:35 +03:00
parent 01ae5b915d
commit 1b6c299251
1 changed files with 3 additions and 3 deletions

View File

@ -216,7 +216,7 @@ public class CustomEmojiPopupKeyboard extends PopupKeyboard{
} }
} }
private class EmojiViewHolder extends BindableViewHolder<Emoji> implements ImageLoaderViewHolder, UsableRecyclerView.Clickable{ private class EmojiViewHolder extends BindableViewHolder<Emoji> implements ImageLoaderViewHolder{
public int positionWithinCategory; public int positionWithinCategory;
public EmojiViewHolder(){ public EmojiViewHolder(){
super(new ImageView(activity)); super(new ImageView(activity));
@ -226,6 +226,7 @@ public class CustomEmojiPopupKeyboard extends PopupKeyboard{
int pad=V.dp(12); int pad=V.dp(12);
img.setPadding(pad, pad, pad, pad); img.setPadding(pad, pad, pad, pad);
img.setBackgroundResource(R.drawable.bg_custom_emoji); img.setBackgroundResource(R.drawable.bg_custom_emoji);
itemView.setOnClickListener(v->onClick());
} }
@Override @Override
@ -247,8 +248,7 @@ public class CustomEmojiPopupKeyboard extends PopupKeyboard{
((ImageView)itemView).setImageDrawable(null); ((ImageView)itemView).setImageDrawable(null);
} }
@Override private void onClick(){
public void onClick(){
listener.onEmojiSelected(item); listener.onEmojiSelected(item);
} }
} }