ocarina: Added library category to settings
I'll eventually use this for controlling the library. Right now it's just an empty page.
This commit is contained in:
parent
381b72aea4
commit
f09f80cd65
|
@ -9,10 +9,14 @@ settings_page = gtk.VBox()
|
||||||
settings_page.show()
|
settings_page.show()
|
||||||
SETTINGS_PAGE = body.add_page(settings_page, "Settings")
|
SETTINGS_PAGE = body.add_page(settings_page, "Settings")
|
||||||
|
|
||||||
close_button = gtk.Button("Close", gtk.STOCK_CLOSE)
|
categories = gtk.Notebook()
|
||||||
settings_page.pack_start(close_button, False, False)
|
settings_page.pack_start(categories, True, True)
|
||||||
settings_page.show_all()
|
settings_page.show_all()
|
||||||
|
|
||||||
|
close_button = gtk.Button("Close", gtk.STOCK_CLOSE)
|
||||||
|
categories.set_action_widget(close_button, gtk.PACK_END)
|
||||||
|
close_button.show()
|
||||||
|
|
||||||
def hide_settings(*args):
|
def hide_settings(*args):
|
||||||
body.hide_page(SETTINGS_PAGE)
|
body.hide_page(SETTINGS_PAGE)
|
||||||
body.switch_to_page_n(0)
|
body.switch_to_page_n(0)
|
||||||
|
@ -24,3 +28,12 @@ def show_settings():
|
||||||
def show_page():
|
def show_page():
|
||||||
show_settings()
|
show_settings()
|
||||||
body.switch_to_page(SETTINGS_PAGE)
|
body.switch_to_page(SETTINGS_PAGE)
|
||||||
|
|
||||||
|
def add_category(module):
|
||||||
|
label = gtk.Label(module.text)
|
||||||
|
label.show()
|
||||||
|
categories.append_page(module.page, label)
|
||||||
|
module.page.show()
|
||||||
|
|
||||||
|
import library
|
||||||
|
add_category(library)
|
||||||
|
|
|
@ -0,0 +1,6 @@
|
||||||
|
# Bryan Schumaker (6 / 18 / 2011)
|
||||||
|
|
||||||
|
import gtk
|
||||||
|
|
||||||
|
page = gtk.VBox()
|
||||||
|
text = "Library"
|
Loading…
Reference in New Issue