diff options
author | Michele Calgaro <michele.calgaro@yahoo.it> | 2024-01-08 11:54:27 +0900 |
---|---|---|
committer | Michele Calgaro <michele.calgaro@yahoo.it> | 2024-01-11 10:03:08 +0900 |
commit | 27f46d6031d41aa6ce071885a7e280e1097680e1 (patch) | |
tree | dbb592ad2f606c9a8e56ed6aa4f4f562c8928002 /examples/mdi.py | |
parent | a131499f339ae27686e9effc8088ebdf7bb77dde (diff) | |
download | pytqt-27f46d6031d41aa6ce071885a7e280e1097680e1.tar.gz pytqt-27f46d6031d41aa6ce071885a7e280e1097680e1.zip |
Use new TQ_METHOD, TQ_SIGNAL, TQ_SLOT defines
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
(cherry picked from commit 7d5aea7e8497095f76841f3dd8f2eab9c4cb58aa)
Diffstat (limited to 'examples/mdi.py')
-rwxr-xr-x | examples/mdi.py | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/examples/mdi.py b/examples/mdi.py index 591a4eb..961c54a 100755 --- a/examples/mdi.py +++ b/examples/mdi.py @@ -163,13 +163,13 @@ class ApplicationWindow(TQMainWindow): self.file.insertSeparator() - self.file.insertItem('&Close',self,SLOT('close()'),TQt.CTRL + TQt.Key_W) - self.file.insertItem('&Quit',tqApp,SLOT('closeAllWindows()'),TQt.CTRL + TQt.Key_Q) + self.file.insertItem('&Close',self,TQ_SLOT('close()'),TQt.CTRL + TQt.Key_W) + self.file.insertItem('&Quit',tqApp,TQ_SLOT('closeAllWindows()'),TQt.CTRL + TQt.Key_Q) self.menuBar().insertSeparator() self.windows = TQPopupMenu( self ) self.windows.setCheckable( True ) - self.connect( self.windows, SIGNAL( "aboutToShow()" ), + self.connect( self.windows, TQ_SIGNAL( "aboutToShow()" ), self.windowsMenuAboutToShow ) self.menuBar().insertItem( "&Windows", self.windows ) @@ -180,7 +180,7 @@ class ApplicationWindow(TQMainWindow): self.help.insertItem('&About',self.about,TQt.Key_F1) self.help.insertItem('About &TQt',self.aboutTQt) self.help.insertSeparator() - self.help.insertItem( "What's &This", self, SLOT("whatsThis()"), TQt.SHIFT+TQt.Key_F1) + self.help.insertItem( "What's &This", self, TQ_SLOT("whatsThis()"), TQt.SHIFT+TQt.Key_F1) self.menuBar().insertSeparator() @@ -195,7 +195,7 @@ class ApplicationWindow(TQMainWindow): def newDoc(self): w = MDIWindow( self.ws, "", TQt.WDestructiveClose ) - self.connect( w, PYSIGNAL( "message" ), self.statusBar(), SLOT( "message(const TQString&, int )") ) + self.connect( w, PYSIGNAL( "message" ), self.statusBar(), TQ_SLOT( "message(const TQString&, int )") ) w.setCaption("unnamed document") w.setIcon( TQPixmap(document) ) # show the very first window in maximized mode @@ -243,8 +243,8 @@ class ApplicationWindow(TQMainWindow): def windowsMenuAboutToShow(self): self.windows.clear() - cascadeId = self.windows.insertItem("&Cascade", self.ws, SLOT("cascade() ") ) - tileId = self.windows.insertItem("&Tile", self.ws, SLOT("tile()" ) ) + cascadeId = self.windows.insertItem("&Cascade", self.ws, TQ_SLOT("cascade() ") ) + tileId = self.windows.insertItem("&Tile", self.ws, TQ_SLOT("tile()" ) ) if len(self.ws.windowList())==0 : self.windows.setItemEnabled( cascadeId, False ) self.windows.setItemEnabled( tileId, False ) @@ -356,5 +356,5 @@ if __name__=='__main__': mw = ApplicationWindow() mw.setCaption("PyTQt Example - Multiple Documents Interface (MDI)") mw.show() - a.connect(a, SIGNAL('lastWindowClosed()'), a, SLOT('quit()')) + a.connect(a, TQ_SIGNAL('lastWindowClosed()'), a, TQ_SLOT('quit()')) a.exec_loop() |