def __init__(self): QtGui.QMainWindow.__init__(self) self.ui = Ui_MainWindow() self.ui.setupUi(self) # Connect the pushButton to a message method. self.connect(self.ui.pushButton, QtCore.SIGNAL("clicked()"), self.message)
class TestApp(QtGui.QMainWindow): def __init__(self): QtGui.QMainWindow.__init__(self) self.ui = Ui_MainWindow() self.ui.setupUi(self) # Connect the pushButton to a message method. self.connect(self.ui.pushButton, QtCore.SIGNAL("clicked()"), self.message) def message(self): print dir(self.ui.listView)