60 lines
1.1 KiB
Python
60 lines
1.1 KiB
Python
# This is a simple test plugin, to make sure everything is working
|
|
|
|
__author__="bjschuma"
|
|
__date__ ="$Jan 16, 2010 12:18:10 PM$"
|
|
|
|
|
|
global name, app, type, path, opt
|
|
name = "test"
|
|
app = "scion"
|
|
type = "extra"
|
|
path = ""
|
|
opt = []
|
|
|
|
from bt.message import write
|
|
from manager import manager
|
|
import settings
|
|
from guiGTK import *
|
|
from guiOGTK import *
|
|
|
|
|
|
global window
|
|
global vbox
|
|
global bar
|
|
global tabs
|
|
|
|
|
|
# Called when the plugin needs to perform some action
|
|
def run(args):
|
|
if args == None:
|
|
manager.run("sgtk")
|
|
else:
|
|
global window, vbox, bar, tabs
|
|
window = args[0]
|
|
vbox = args[1]
|
|
bar = args[2]
|
|
window.resize(settings.get("winsize"))
|
|
tabs = tabs.Tabs()
|
|
vbox.pack(tabs,True,True)
|
|
library = listPage.ListPage("Library")
|
|
tabs.append(library,library.label)
|
|
tabs.tabpos("left")
|
|
|
|
|
|
|
|
# Called every time the plugin is enabled
|
|
def open():
|
|
# Enable scion GTK when we are enabled
|
|
manager.run("enable", ["sgtk"])
|
|
settings.set("gtkfuncs",run)
|
|
settings.set("winsize",(800,600))
|
|
|
|
|
|
# Called every time the plugin is stopped
|
|
def close():
|
|
pass
|
|
|
|
|
|
def help():
|
|
return "Ocarina GTK functions"
|