diff options
Diffstat (limited to 'qtruby/rubylib/examples/qtscribble/scribble.rb')
-rw-r--r-- | qtruby/rubylib/examples/qtscribble/scribble.rb | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/qtruby/rubylib/examples/qtscribble/scribble.rb b/qtruby/rubylib/examples/qtscribble/scribble.rb index 0ba2a4b4..a2ce927b 100644 --- a/qtruby/rubylib/examples/qtscribble/scribble.rb +++ b/qtruby/rubylib/examples/qtscribble/scribble.rb @@ -26,7 +26,7 @@ require 'Qt' # create a pop-up menu @_popupmenu = TQt::PopupMenu.new() - @_popupmenu.insertItem( "&Clear", self, SLOT( "slotClearArea()" ) ) + @_popupmenu.insertItem( "&Clear", self, TQ_SLOT( "slotClearArea()" ) ) end # @@ -159,10 +159,10 @@ class ScribbleWindow < TQt::Widget # The next lines build the menu bar. We first create the menus # one by one, then add them to the menu bar. # @_filemenu = TQt::PopupMenu.new() # create a file menu - @_filemenu.insertItem( "&Load", self, SLOT( "slotLoad()" ) ) - @_filemenu.insertItem( "&Save", self, SLOT( "slotSave()" ) ) + @_filemenu.insertItem( "&Load", self, TQ_SLOT( "slotLoad()" ) ) + @_filemenu.insertItem( "&Save", self, TQ_SLOT( "slotSave()" ) ) @_filemenu.insertSeparator() - @_filemenu.insertItem( "&Quit", $qApp, SLOT( "quit()" ) ) + @_filemenu.insertItem( "&Quit", $qApp, TQ_SLOT( "quit()" ) ) @_colormenu = TQt::PopupMenu.new() # create a color menu @_colormenu.insertItem( "B&lack", COLOR_MENU_ID_BLACK) @@ -170,12 +170,12 @@ class ScribbleWindow < TQt::Widget @_colormenu.insertItem( "&Blue", COLOR_MENU_ID_BLUE) @_colormenu.insertItem( "&Green", COLOR_MENU_ID_GREEN) @_colormenu.insertItem( "&Yellow", COLOR_MENU_ID_YELLOW) - TQt::Object.connect( @_colormenu, SIGNAL( "activated( int )" ), - self, SLOT( "slotColorMenu( int )" ) ) + TQt::Object.connect( @_colormenu, TQ_SIGNAL( "activated( int )" ), + self, TQ_SLOT( "slotColorMenu( int )" ) ) @_helpmenu = TQt::PopupMenu.new() # create a help menu - @_helpmenu.insertItem( "&About QtScribble", self, SLOT( "slotAbout()" ) ) - @_helpmenu.insertItem( "&About Qt", self, SLOT( "slotAboutQt()" ) ) + @_helpmenu.insertItem( "&About QtScribble", self, TQ_SLOT( "slotAbout()" ) ) + @_helpmenu.insertItem( "&About Qt", self, TQ_SLOT( "slotAboutQt()" ) ) @_menubar = TQt::MenuBar.new( self, "" ) # create a menu bar @_menubar.insertItem( "&File", @_filemenu ) @@ -190,12 +190,12 @@ class ScribbleWindow < TQt::Widget @_scribblearea = ScribbleArea.new() @_scribblearea.setGeometry( 0, 0, 1000, 1000 ) @_scrollview.addChild( @_scribblearea ) - TQt::Object.connect( self, SIGNAL( "colorChanged(TQColor)" ), - @_scribblearea, SLOT( "setColor(TQColor)" ) ) - TQt::Object.connect( self, SIGNAL( "save(const TQString&)" ), - @_scribblearea, SLOT( "slotSave(const TQString&)" ) ) - TQt::Object.connect( self, SIGNAL( "load(const TQString&)" ), - @_scribblearea, SLOT( "slotLoad(const TQString&)" ) ) + TQt::Object.connect( self, TQ_SIGNAL( "colorChanged(TQColor)" ), + @_scribblearea, TQ_SLOT( "setColor(TQColor)" ) ) + TQt::Object.connect( self, TQ_SIGNAL( "save(const TQString&)" ), + @_scribblearea, TQ_SLOT( "slotSave(const TQString&)" ) ) + TQt::Object.connect( self, TQ_SIGNAL( "load(const TQString&)" ), + @_scribblearea, TQ_SLOT( "slotLoad(const TQString&)" ) ) end def resizeEvent( event ) |