ocarina: Remove components directory
I've implemented everything that was here. Time to remove it
This commit is contained in:
parent
cf164deb44
commit
19f2597936
|
@ -1,46 +0,0 @@
|
|||
# Bryan Schumaker (8/26/2010)
|
||||
|
||||
import ocarina
|
||||
import image
|
||||
LS = ocarina.libsaria
|
||||
gtk = ocarina.gtk
|
||||
prefs = LS.prefs
|
||||
invite = LS.event.invite
|
||||
|
||||
class Button(gtk.Button):
|
||||
def __init__(self, stock, tooltip, func=None, show=True):
|
||||
gtk.Button.__init__(self)
|
||||
self.func = func
|
||||
img = gtk.image_new_from_stock(stock, gtk.ICON_SIZE_MENU)
|
||||
img.show()
|
||||
self.add(img)
|
||||
self.set_relief(gtk.RELIEF_NONE)
|
||||
self.click_id = self.connect("clicked", self.clicked)
|
||||
if show == True:
|
||||
Button.show(self)
|
||||
self.set_alignment(0,0)
|
||||
self.set_tooltip_text(tooltip)
|
||||
|
||||
def clicked(self, button):
|
||||
self.func()
|
||||
|
||||
def show(self, *args):
|
||||
gtk.Button.show(self)
|
||||
|
||||
def hide(self, *args):
|
||||
gtk.Button.hide(self)
|
||||
|
||||
class OpenButton(Button):
|
||||
def __init__(self):
|
||||
Button.__init__(self, gtk.STOCK_OPEN, "Open Anything")
|
||||
def clicked(self, button):
|
||||
from ocarina import fsselect
|
||||
fsselect.run_chooser2(LS.path.files.universal_open)
|
||||
ocarina.playlist.refresh()
|
||||
|
||||
class SettingsButton(Button):
|
||||
def __init__(self):
|
||||
Button.__init__(self, gtk.STOCK_PREFERENCES, "Configure Preferences")
|
||||
def clicked(self, button):
|
||||
from ocarina import settings
|
||||
settings.configure()
|
Loading…
Reference in New Issue