switchInlineChosen method

InlineKeyboard switchInlineChosen(
  1. String text, {
  2. String query = "",
  3. bool? allowUserChats,
  4. bool? allowBotChats,
  5. bool? allowGroupChats,
  6. bool? allowChannelChats,
  7. String? iconCustomEmojiId,
  8. StyleType? style,
})

Adds an inline query button for chosen chat type to the current row.

Implementation

InlineKeyboard switchInlineChosen(
  String text, {
  String query = "",
  bool? allowUserChats,
  bool? allowBotChats,
  bool? allowGroupChats,
  bool? allowChannelChats,
  String? iconCustomEmojiId,
  StyleType? style,
}) {
  return add(
    InlineKeyboardButton(
      text: text,
      switchInlineQueryChosenChat: SwitchInlineQueryChosenChat(
        query: query,
        allowUserChats: allowUserChats,
        allowBotChats: allowBotChats,
        allowGroupChats: allowGroupChats,
        allowChannelChats: allowChannelChats,
      ),
      iconCustomEmojiId: iconCustomEmojiId,
      style: style,
    ),
  );
}