Footer remove page

I added a remove page function to the footer for plugins that make use
of it.
This commit is contained in:
Bryan Schumaker 2010-11-27 15:39:33 -05:00
parent 6a5176d5d7
commit 8af11586ac
1 changed files with 8 additions and 0 deletions

View File

@ -34,6 +34,14 @@ def add_page(title, widget):
pages[title] = widget
tabs.append_page(widget, label)
def remove_page(title):
page = pages.get(title, None)
if page == None:
return
n = tabs.page_num(page)
tabs.remove_page(n)
del pages[title]
def up_button():
tabs.show()
bar.hide()