Interface ChannelClickListener
-
- All Implemented Interfaces:
public interface ChannelClickListenerListener for user interaction events within a conversation (channel) screen.
Register an implementation via setChannelClickListener.
Each method returns
trueif the app handles the event, orfalseto fall back to the default SDK behavior.
-
-
Method Summary
Modifier and Type Method Description abstract booleanonUserPortraitClick(Context context, ChannelType conversationType, UserInfo user, String targetId)Called when a user's avatar is tapped. abstract booleanonUserPortraitLongClick(Context context, ChannelType conversationType, UserInfo user, String targetId)Called when a user's avatar is long-pressed. abstract booleanonMessageClick(Context context, View view, Message message)Called when a message bubble is tapped. abstract booleanonMessageLongClick(Context context, View view, Message message)Called when a message bubble is long-pressed. abstract booleanonMessageLinkClick(Context context, String link, Message message)Called when a hyperlink inside a message is tapped. abstract booleanonReadReceiptStateClick(Context context, Message message)Called when the read-receipt status indicator of a message is tapped. booleanonQuickReplyClick(Context context)Called when the quick-reply button is tapped. -
-
Method Detail
-
onUserPortraitClick
abstract boolean onUserPortraitClick(Context context, ChannelType conversationType, UserInfo user, String targetId)
Called when a user's avatar is tapped.
- Parameters:
context- contextconversationType- channel typeuser- the tapped user's infotargetId- channel ID- Returns:
trueif the app handles this click;falseto use the default behavior
-
onUserPortraitLongClick
abstract boolean onUserPortraitLongClick(Context context, ChannelType conversationType, UserInfo user, String targetId)
Called when a user's avatar is long-pressed.
- Parameters:
context- contextconversationType- channel typeuser- the long-pressed user's infotargetId- channel ID- Returns:
trueif the app handles this event;falseto use the default behavior
-
onMessageClick
abstract boolean onMessageClick(Context context, View view, Message message)
Called when a message bubble is tapped.
- Parameters:
context- contextview- the View that received the tapmessage- the tapped message- Returns:
trueif the app handles this click;falseto use the default behavior
-
onMessageLongClick
abstract boolean onMessageLongClick(Context context, View view, Message message)
Called when a message bubble is long-pressed.
- Parameters:
context- contextview- the View that received the long-pressmessage- the long-pressed message- Returns:
trueif the app handles this event;falseto use the default behavior
-
onMessageLinkClick
abstract boolean onMessageLinkClick(Context context, String link, Message message)
Called when a hyperlink inside a message is tapped.
- Parameters:
context- contextlink- the tapped link URLmessage- the message that contains the link- Returns:
trueif the app handles this click;falseto use the default behavior
-
onReadReceiptStateClick
abstract boolean onReadReceiptStateClick(Context context, Message message)
Called when the read-receipt status indicator of a message is tapped.
- Parameters:
context- contextmessage- the message whose receipt status was tapped- Returns:
trueif the app handles this click;falseto use the default behavior
-
onQuickReplyClick
boolean onQuickReplyClick(Context context)
Called when the quick-reply button is tapped.
- Parameters:
context- context- Returns:
trueif the app handles this click;falseto use the default behavior
-
-
-
-