1 |
#!/usr/bin/env python |
2 |
#Boa:App:BoaApp |
3 |
|
4 |
# $Id: fraggleMain.py,v 1.7 2004/08/30 13:55:12 joko Exp $ |
5 |
# $Log: fraggleMain.py,v $ |
6 |
# Revision 1.7 2004/08/30 13:55:12 joko |
7 |
# + caching phpsessionid here |
8 |
# |
9 |
# Revision 1.6 2004/08/30 13:01:47 joko |
10 |
# U prepend "libs"-dir to path |
11 |
# |
12 |
# Revision 1.5 2004/08/27 03:22:30 joko |
13 |
# start singleton instance of FraggleEngine here |
14 |
# |
15 |
# Revision 1.4 2004/08/26 15:19:26 joko |
16 |
# get rid of urlOpener here |
17 |
# added key shortcuts to menu-items |
18 |
# |
19 |
|
20 |
import sys, os |
21 |
from wxPython.wx import * |
22 |
|
23 |
from fraggleConstants import * |
24 |
from fraggleEngine import * |
25 |
from fraggleViewport import * |
26 |
|
27 |
modules ={'fraggleDialogPrefs': [0, '', 'fraggleDialogPrefs.py'], |
28 |
'fraggleViewport': [1, '', 'fraggleViewport.py']} |
29 |
|
30 |
class BoaApp(wxApp): |
31 |
def OnInit(self): |
32 |
wxInitAllImageHandlers() |
33 |
self.main = fraggleMainWin(None) |
34 |
# needed when running from Boa under Windows 9X |
35 |
self.SetTopWindow(self.main) |
36 |
self.main.Show();self.main.Hide();self.main.Show() |
37 |
return True |
38 |
|
39 |
class fraggleMainWin(fraggleViewport): |
40 |
def _init_coll_menu1_Items(self, parent): |
41 |
|
42 |
|
43 |
fraggleViewport._init_coll_menu1_Items(self, parent) |
44 |
|
45 |
|
46 |
def _init_coll_menu2_Items(self, parent): |
47 |
|
48 |
|
49 |
fraggleViewport._init_coll_menu2_Items(self, parent) |
50 |
|
51 |
|
52 |
def main(): |
53 |
global engine, phpsessionid |
54 |
sys.path.insert(0, os.path.join(APPLOCATION, '..', 'libs')) |
55 |
engine = FraggleEngine() |
56 |
# TODO: move elsewhere! |
57 |
phpsessionid = "" |
58 |
application = BoaApp(0) |
59 |
application.MainLoop() |
60 |
|
61 |
if __name__ == '__main__': |
62 |
main() |