summaryrefslogtreecommitdiffstats
path: root/examples/SQL/runform2.py
blob: 659034a26067a02f57b60cac668df0bf045db09b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#!/usr/bin/env python

import sys
from PyTQt.tqt import *

from form2 import Form2
from dbconnect import createConnection

class mainWindow(Form2):
    def __init__(self,parent = None,name = None,fl = 0):
        Form2.__init__(self,parent,name,fl)

if __name__ == "__main__":
    a = TQApplication(sys.argv)
    if createConnection():
        TQObject.connect(a,TQ_SIGNAL("lastWindowClosed()"),a,TQ_SLOT("quit()"))
        w = mainWindow()
        a.setMainWidget(w)
        w.show()
        a.exec_loop()