mirror of
https://github.com/python-telegram-bot/python-telegram-bot.git
synced 2024-12-22 06:25:12 +01:00
hide inline keyboard in conversationbot example (#439)
This commit is contained in:
parent
e76ee6bb57
commit
a7bfb0c3a1
1 changed files with 5 additions and 3 deletions
|
@ -17,7 +17,7 @@ Press Ctrl-C on the command line or send a signal to the process to stop the
|
|||
bot.
|
||||
"""
|
||||
|
||||
from telegram import (ReplyKeyboardMarkup)
|
||||
from telegram import (ReplyKeyboardMarkup, ReplyKeyboardHide)
|
||||
from telegram.ext import (Updater, CommandHandler, MessageHandler, Filters, RegexHandler,
|
||||
ConversationHandler)
|
||||
|
||||
|
@ -48,7 +48,8 @@ def gender(bot, update):
|
|||
user = update.message.from_user
|
||||
logger.info("Gender of %s: %s" % (user.first_name, update.message.text))
|
||||
update.message.reply_text('I see! Please send me a photo of yourself, '
|
||||
'so I know what you look like, or send /skip if you don\'t want to.')
|
||||
'so I know what you look like, or send /skip if you don\'t want to.',
|
||||
reply_markup=ReplyKeyboardHide())
|
||||
|
||||
return PHOTO
|
||||
|
||||
|
@ -104,7 +105,8 @@ def bio(bot, update):
|
|||
def cancel(bot, update):
|
||||
user = update.message.from_user
|
||||
logger.info("User %s canceled the conversation." % user.first_name)
|
||||
update.message.reply_text('Bye! I hope we can talk again some day.')
|
||||
update.message.reply_text('Bye! I hope we can talk again some day.',
|
||||
reply_markup=ReplyKeyboardHide())
|
||||
|
||||
return ConversationHandler.END
|
||||
|
||||
|
|
Loading…
Reference in a new issue