IconEditor/IconEditorWindow.py

changeset 456
d766de2ccbc7
parent 455
9a7e0b7b801e
parent 454
d28d558f7484
child 457
608a9c14f4c9
--- a/IconEditor/IconEditorWindow.py	Wed Aug 04 14:03:01 2010 +0200
+++ b/IconEditor/IconEditorWindow.py	Thu Aug 05 08:35:30 2010 +0200
@@ -172,7 +172,7 @@
                 """<b>New</b>"""
                 """<p>This creates a new icon.</p>"""
         ))
-        self.newAct.triggered.connect(self.__newIcon)
+        self.newAct.triggered[()].connect(self.__newIcon)
         self.__actions.append(self.newAct)
         
         self.newWindowAct = E5Action(self.trUtf8('New Window'), 
@@ -184,7 +184,7 @@
                 """<b>New Window</b>"""
                 """<p>This opens a new icon editor window.</p>"""
         ))
-        self.newWindowAct.triggered.connect(self.__newWindow)
+        self.newWindowAct.triggered[()].connect(self.__newWindow)
         self.__actions.append(self.newWindowAct)
         
         self.openAct = E5Action(self.trUtf8('Open'), 
@@ -198,7 +198,7 @@
                 """<p>This opens a new icon file for editing."""
                 """ It pops up a file selection dialog.</p>"""
         ))
-        self.openAct.triggered.connect(self.__openIcon)
+        self.openAct.triggered[()].connect(self.__openIcon)
         self.__actions.append(self.openAct)
         
         self.saveAct = E5Action(self.trUtf8('Save'),
@@ -211,7 +211,7 @@
             """<b>Save File</b>"""
             """<p>Save the contents of the icon editor window.</p>"""
         ))
-        self.saveAct.triggered.connect(self.__saveIcon)
+        self.saveAct.triggered[()].connect(self.__saveIcon)
         self.__actions.append(self.saveAct)
         
         self.saveAsAct = E5Action(self.trUtf8('Save As'), 
@@ -225,7 +225,7 @@
                 """<b>Save As...</b>"""
                 """<p>Saves the current icon to a new file.</p>"""
         ))
-        self.saveAsAct.triggered.connect(self.__saveIconAs)
+        self.saveAsAct.triggered[()].connect(self.__saveIconAs)
         self.__actions.append(self.saveAsAct)
         
         self.closeAct = E5Action(self.trUtf8('Close'), 
@@ -238,7 +238,7 @@
                 """<b>Close</b>"""
                 """<p>Closes the current icon editor window.</p>"""
         ))
-        self.closeAct.triggered.connect(self.close)
+        self.closeAct.triggered[()].connect(self.close)
         self.__actions.append(self.closeAct)
         
         self.closeAllAct = E5Action(self.trUtf8('Close All'), 
@@ -249,7 +249,7 @@
                 """<b>Close All</b>"""
                 """<p>Closes all icon editor windows except the first one.</p>"""
         ))
-        self.closeAllAct.triggered.connect(self.__closeAll)
+        self.closeAllAct.triggered[()].connect(self.__closeAll)
         self.__actions.append(self.closeAllAct)
         
         self.exitAct = E5Action(self.trUtf8('Quit'), 
@@ -263,7 +263,7 @@
                 """<p>Quit the icon editor.</p>"""
         ))
         if self.fromEric:
-            self.exitAct.triggered.connect(self.close)
+            self.exitAct.triggered[()].connect(self.close)
         else:
             self.exitAct.triggered.connect(qApp.closeAllWindows)
         self.__actions.append(self.exitAct)
@@ -283,7 +283,7 @@
             """<b>Undo</b>"""
             """<p>Undo the last change done.</p>"""
         ))
-        self.undoAct.triggered.connect(self.__editor.editUndo)
+        self.undoAct.triggered[()].connect(self.__editor.editUndo)
         self.__actions.append(self.undoAct)
         
         self.redoAct = E5Action(self.trUtf8('Redo'),
@@ -296,7 +296,7 @@
             """<b>Redo</b>"""
             """<p>Redo the last change done.</p>"""
         ))
-        self.redoAct.triggered.connect(self.__editor.editRedo)
+        self.redoAct.triggered[()].connect(self.__editor.editRedo)
         self.__actions.append(self.redoAct)
         
         self.cutAct = E5Action(self.trUtf8('Cut'),
@@ -310,7 +310,7 @@
             """<b>Cut</b>"""
             """<p>Cut the selected image area to the clipboard.</p>"""
         ))
-        self.cutAct.triggered.connect(self.__editor.editCut)
+        self.cutAct.triggered[()].connect(self.__editor.editCut)
         self.__actions.append(self.cutAct)
         
         self.copyAct = E5Action(self.trUtf8('Copy'),
@@ -324,7 +324,7 @@
             """<b>Copy</b>"""
             """<p>Copy the selected image area to the clipboard.</p>"""
         ))
-        self.copyAct.triggered.connect(self.__editor.editCopy)
+        self.copyAct.triggered[()].connect(self.__editor.editCopy)
         self.__actions.append(self.copyAct)
         
         self.pasteAct = E5Action(self.trUtf8('Paste'),
@@ -338,7 +338,7 @@
             """<b>Paste</b>"""
             """<p>Paste the clipboard image.</p>"""
         ))
-        self.pasteAct.triggered.connect(self.__editor.editPaste)
+        self.pasteAct.triggered[()].connect(self.__editor.editPaste)
         self.__actions.append(self.pasteAct)
         
         self.pasteNewAct = E5Action(self.trUtf8('Paste as New'),
@@ -350,7 +350,7 @@
             """<b>Paste as New</b>"""
             """<p>Paste the clipboard image replacing the current one.</p>"""
         ))
-        self.pasteNewAct.triggered.connect(self.__editor.editPasteAsNew)
+        self.pasteNewAct.triggered[()].connect(self.__editor.editPasteAsNew)
         self.__actions.append(self.pasteNewAct)
         
         self.deleteAct = E5Action(self.trUtf8('Clear'),
@@ -364,7 +364,7 @@
             """<b>Clear</b>"""
             """<p>Clear the icon image and set it to be completely transparent.</p>"""
         ))
-        self.deleteAct.triggered.connect(self.__editor.editClear)
+        self.deleteAct.triggered[()].connect(self.__editor.editClear)
         self.__actions.append(self.deleteAct)
         
         self.selectAllAct = E5Action(self.trUtf8('Select All'),
@@ -377,7 +377,7 @@
             """<b>Select All</b>"""
             """<p>Selects the complete icon image.</p>"""
         ))
-        self.selectAllAct.triggered.connect(self.__editor.editSelectAll)
+        self.selectAllAct.triggered[()].connect(self.__editor.editSelectAll)
         self.__actions.append(self.selectAllAct)
         
         self.resizeAct = E5Action(self.trUtf8('Change Size'),
@@ -390,7 +390,7 @@
             """<b>Change Size...</b>"""
             """<p>Changes the icon size.</p>"""
         ))
-        self.resizeAct.triggered.connect(self.__editor.editResize)
+        self.resizeAct.triggered[()].connect(self.__editor.editResize)
         self.__actions.append(self.resizeAct)
         
         self.grayscaleAct = E5Action(self.trUtf8('Grayscale'),
@@ -403,7 +403,7 @@
             """<b>Grayscale</b>"""
             """<p>Changes the icon to grayscale.</p>"""
         ))
-        self.grayscaleAct.triggered.connect(self.__editor.grayScale)
+        self.grayscaleAct.triggered[()].connect(self.__editor.grayScale)
         self.__actions.append(self.grayscaleAct)
         
         self.redoAct.setEnabled(False)
@@ -442,7 +442,7 @@
                 """<b>Zoom in</b>"""
                 """<p>Zoom in on the icon. This makes the grid bigger.</p>"""
         ))
-        self.zoomInAct.triggered.connect(self.__zoomIn)
+        self.zoomInAct.triggered[()].connect(self.__zoomIn)
         self.__actions.append(self.zoomInAct)
         
         self.zoomOutAct = E5Action(self.trUtf8('Zoom out'), 
@@ -455,7 +455,7 @@
                 """<b>Zoom out</b>"""
                 """<p>Zoom out on the icon. This makes the grid smaller.</p>"""
         ))
-        self.zoomOutAct.triggered.connect(self.__zoomOut)
+        self.zoomOutAct.triggered[()].connect(self.__zoomOut)
         self.__actions.append(self.zoomOutAct)
         
         self.zoomResetAct = E5Action(self.trUtf8('Zoom reset'), 
@@ -469,7 +469,7 @@
                 """<p>Reset the zoom of the icon. """
                 """This sets the zoom factor to 100%.</p>"""
         ))
-        self.zoomResetAct.triggered.connect(self.__zoomReset)
+        self.zoomResetAct.triggered[()].connect(self.__zoomReset)
         self.__actions.append(self.zoomResetAct)
         
         self.zoomToAct = E5Action(self.trUtf8('Zoom'),
@@ -484,7 +484,7 @@
                 """<p>Zoom the icon. This opens a dialog where the"""
                 """ desired zoom factor can be entered.</p>"""
                 ))
-        self.zoomToAct.triggered.connect(self.__zoom)
+        self.zoomToAct.triggered[()].connect(self.__zoom)
         self.__actions.append(self.zoomToAct)
         
         self.showGridAct = E5Action(self.trUtf8('Show Grid'),
@@ -524,7 +524,7 @@
         ))
         self.drawPencilAct.setCheckable(True)
         self.esm.setMapping(self.drawPencilAct, IconEditorGrid.Pencil)
-        self.drawPencilAct.triggered.connect(self.esm.map)
+        self.drawPencilAct.triggered[()].connect(self.esm.map)
         self.__actions.append(self.drawPencilAct)
         
         self.drawColorPickerAct = E5Action(self.trUtf8('Color Picker'), 
@@ -539,7 +539,7 @@
         ))
         self.drawColorPickerAct.setCheckable(True)
         self.esm.setMapping(self.drawColorPickerAct, IconEditorGrid.ColorPicker)
-        self.drawColorPickerAct.triggered.connect(self.esm.map)
+        self.drawColorPickerAct.triggered[()].connect(self.esm.map)
         self.__actions.append(self.drawColorPickerAct)
         
         self.drawRectangleAct = E5Action(self.trUtf8('Rectangle'), 
@@ -553,7 +553,7 @@
         ))
         self.drawRectangleAct.setCheckable(True)
         self.esm.setMapping(self.drawRectangleAct, IconEditorGrid.Rectangle)
-        self.drawRectangleAct.triggered.connect(self.esm.map)
+        self.drawRectangleAct.triggered[()].connect(self.esm.map)
         self.__actions.append(self.drawRectangleAct)
         
         self.drawFilledRectangleAct = E5Action(self.trUtf8('Filled Rectangle'), 
@@ -567,7 +567,7 @@
         ))
         self.drawFilledRectangleAct.setCheckable(True)
         self.esm.setMapping(self.drawFilledRectangleAct, IconEditorGrid.FilledRectangle)
-        self.drawFilledRectangleAct.triggered.connect(self.esm.map)
+        self.drawFilledRectangleAct.triggered[()].connect(self.esm.map)
         self.__actions.append(self.drawFilledRectangleAct)
         
         self.drawCircleAct = E5Action(self.trUtf8('Circle'), 
@@ -581,7 +581,7 @@
         ))
         self.drawCircleAct.setCheckable(True)
         self.esm.setMapping(self.drawCircleAct, IconEditorGrid.Circle)
-        self.drawCircleAct.triggered.connect(self.esm.map)
+        self.drawCircleAct.triggered[()].connect(self.esm.map)
         self.__actions.append(self.drawCircleAct)
         
         self.drawFilledCircleAct = E5Action(self.trUtf8('Filled Circle'), 
@@ -595,7 +595,7 @@
         ))
         self.drawFilledCircleAct.setCheckable(True)
         self.esm.setMapping(self.drawFilledCircleAct, IconEditorGrid.FilledCircle)
-        self.drawFilledCircleAct.triggered.connect(self.esm.map)
+        self.drawFilledCircleAct.triggered[()].connect(self.esm.map)
         self.__actions.append(self.drawFilledCircleAct)
         
         self.drawEllipseAct = E5Action(self.trUtf8('Ellipse'), 
@@ -609,7 +609,7 @@
         ))
         self.drawEllipseAct.setCheckable(True)
         self.esm.setMapping(self.drawEllipseAct, IconEditorGrid.Ellipse)
-        self.drawEllipseAct.triggered.connect(self.esm.map)
+        self.drawEllipseAct.triggered[()].connect(self.esm.map)
         self.__actions.append(self.drawEllipseAct)
         
         self.drawFilledEllipseAct = E5Action(self.trUtf8('Filled Ellipse'), 
@@ -623,7 +623,7 @@
         ))
         self.drawFilledEllipseAct.setCheckable(True)
         self.esm.setMapping(self.drawFilledEllipseAct, IconEditorGrid.FilledEllipse)
-        self.drawFilledEllipseAct.triggered.connect(self.esm.map)
+        self.drawFilledEllipseAct.triggered[()].connect(self.esm.map)
         self.__actions.append(self.drawFilledEllipseAct)
         
         self.drawFloodFillAct = E5Action(self.trUtf8('Flood Fill'), 
@@ -638,7 +638,7 @@
         ))
         self.drawFloodFillAct.setCheckable(True)
         self.esm.setMapping(self.drawFloodFillAct, IconEditorGrid.Fill)
-        self.drawFloodFillAct.triggered.connect(self.esm.map)
+        self.drawFloodFillAct.triggered[()].connect(self.esm.map)
         self.__actions.append(self.drawFloodFillAct)
         
         self.drawLineAct = E5Action(self.trUtf8('Line'), 
@@ -652,7 +652,7 @@
         ))
         self.drawLineAct.setCheckable(True)
         self.esm.setMapping(self.drawLineAct, IconEditorGrid.Line)
-        self.drawLineAct.triggered.connect(self.esm.map)
+        self.drawLineAct.triggered[()].connect(self.esm.map)
         self.__actions.append(self.drawLineAct)
         
         self.drawEraserAct = E5Action(self.trUtf8('Eraser (Transparent)'), 
@@ -666,7 +666,7 @@
         ))
         self.drawEraserAct.setCheckable(True)
         self.esm.setMapping(self.drawEraserAct, IconEditorGrid.Rubber)
-        self.drawEraserAct.triggered.connect(self.esm.map)
+        self.drawEraserAct.triggered[()].connect(self.esm.map)
         self.__actions.append(self.drawEraserAct)
         
         self.drawRectangleSelectionAct = E5Action(self.trUtf8('Rectangular Selection'), 
@@ -681,7 +681,7 @@
         self.drawRectangleSelectionAct.setCheckable(True)
         self.esm.setMapping(self.drawRectangleSelectionAct, 
                             IconEditorGrid.RectangleSelection)
-        self.drawRectangleSelectionAct.triggered.connect(self.esm.map)
+        self.drawRectangleSelectionAct.triggered[()].connect(self.esm.map)
         self.__actions.append(self.drawRectangleSelectionAct)
         
         self.drawCircleSelectionAct = E5Action(self.trUtf8('Circular Selection'), 
@@ -696,7 +696,7 @@
         self.drawCircleSelectionAct.setCheckable(True)
         self.esm.setMapping(self.drawCircleSelectionAct, 
                             IconEditorGrid.CircleSelection)
-        self.drawCircleSelectionAct.triggered.connect(self.esm.map)
+        self.drawCircleSelectionAct.triggered[()].connect(self.esm.map)
         self.__actions.append(self.drawCircleSelectionAct)
         
         self.drawPencilAct.setChecked(True)
@@ -712,7 +712,7 @@
         self.aboutAct.setWhatsThis(self.trUtf8(
             """<b>About</b>"""
             """<p>Display some information about this software.</p>"""))
-        self.aboutAct.triggered.connect(self.__about)
+        self.aboutAct.triggered[()].connect(self.__about)
         self.__actions.append(self.aboutAct)
         
         self.aboutQtAct = E5Action(self.trUtf8('About Qt'),
@@ -724,7 +724,7 @@
             """<b>About Qt</b>"""
             """<p>Display some information about the Qt toolkit.</p>"""
         ))
-        self.aboutQtAct.triggered.connect(self.__aboutQt)
+        self.aboutQtAct.triggered[()].connect(self.__aboutQt)
         self.__actions.append(self.aboutQtAct)
         
         self.whatsThisAct = E5Action(self.trUtf8('What\'s This?'), 
@@ -741,7 +741,7 @@
                 """ dialogs, this feature can be accessed using the context help button"""
                 """ in the titlebar.</p>"""
         ))
-        self.whatsThisAct.triggered.connect(self.__whatsThis)
+        self.whatsThisAct.triggered[()].connect(self.__whatsThis)
         self.__actions.append(self.whatsThisAct)
     
     def __initMenus(self):

eric ide

mercurial