diff --git a/src/base/bt/needle.py b/src/base/bt/needle.py new file mode 100644 index 00000000..58e6338d --- /dev/null +++ b/src/base/bt/needle.py @@ -0,0 +1,20 @@ +#! /usr/bin/python + +# To change this template, choose Tools | Templates +# and open the template in the editor. + +__author__="bjschuma" +__date__ ="$Dec 19, 2009 9:30:59 PM$" + + +from threading import Thread + + +class Needle(Thread): + def __init__(self, func, args): + self.func = func + self.args = args + + + def run(self): + func(args) \ No newline at end of file diff --git a/src/base/settings.py b/src/base/settings.py index 9179945f..af47e044 100644 --- a/src/base/settings.py +++ b/src/base/settings.py @@ -63,6 +63,7 @@ def parseInput(): # Set verbose first so we can use write() set("VERBOSE", ('-v' in sys.argv) or ("--verbose" in sys.argv) ) write("Setting default values...", True) + # Find who is running the program user = os.path.expanduser("~") user = os.path.join(user,".ocarina2") diff --git a/src/core/cli.py b/src/core/cli.py index 86506978..7860c636 100644 --- a/src/core/cli.py +++ b/src/core/cli.py @@ -13,6 +13,7 @@ opt = [] import curses from bt.message import write +from bt.needle import Needle global maxxy, input, stdscr diff --git a/src/core/cline/__init__.py b/src/core/cline/__init__.py new file mode 100644 index 00000000..43d04fb6 --- /dev/null +++ b/src/core/cline/__init__.py @@ -0,0 +1,2 @@ +__author__="bjschuma" +__date__ ="$Dec 19, 2009 9:13:05 PM$" \ No newline at end of file