def finishBuyList(self):
#ask to confirm
content = BoxLayout(orientation = 'vertical')
content.add_widget(Label(text = 'Do you really want to finish?'))
button_confirm = Button(text='Finish')
button_confirm.bind(on_press=self.registerBuy)
button_cancel = Button(text='Cancel')
button_cancel.bind(on_press=self.popup.dismiss)
options = BoxLayout()
options.add_widget(button_confirm)
options.add_widget(button_cancel)
content.add_widget(options)
#
self.popup = Popup(
title = 'Finish Buy List',
content = content,
size_hint = (None, None),
size = (400, 100)
)
# open the popup
self.popup.open()
###
评论列表
文章目录