Skip to content

Commit

Permalink
Merge pull request #3651 from nirvn/processing_modeler_fix
Browse files Browse the repository at this point in the history
[processing] fix broken modeler under pyqt5/python3 (fixes #15734)
  • Loading branch information
volaya authored Oct 21, 2016
2 parents 89fa21e + bd7149c commit 81e86ac
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion python/plugins/processing/gui/EditRenderingStylesDialog.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ def __init__(self, alg):

self.alg = alg.getCopy()

self.tblStyles.horizontalHeader().setResizeMode(QHeaderView.Stretch)
self.tblStyles.horizontalHeader().setSectionResizeMode(QHeaderView.Stretch)
self.setWindowTitle(self.alg.name)

self.valueItems = {}
Expand Down
2 changes: 1 addition & 1 deletion python/plugins/processing/modeler/ModelerAlgorithm.py
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,7 @@ def getCopy(self):
newone.provider = self.provider

newone.algs = {}
for algname, alg in self.algs.iteritems():
for algname, alg in self.algs.items():
newone.algs[algname] = Algorithm()
newone.algs[algname].__dict__.update(copy.deepcopy(alg.todict()))
newone.inputs = copy.deepcopy(self.inputs)
Expand Down
2 changes: 1 addition & 1 deletion python/plugins/processing/modeler/ModelerArrowItem.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ class ModelerArrowItem(QGraphicsPathItem):

def __init__(self, startItem, startIndex, endItem, endIndex,
parent=None, scene=None):
super(ModelerArrowItem, self).__init__(parent, scene)
super(ModelerArrowItem, self).__init__(parent)
self.arrowHead = QPolygonF()
self.endIndex = endIndex
self.startIndex = startIndex
Expand Down
4 changes: 2 additions & 2 deletions python/plugins/processing/modeler/ModelerGraphicItem.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class ModelerGraphicItem(QGraphicsItem):
BOX_WIDTH = 200

def __init__(self, element, model):
super(ModelerGraphicItem, self).__init__(None, None)
super(ModelerGraphicItem, self).__init__(None)
self.model = model
self.element = element
if isinstance(element, ModelerParameter):
Expand Down Expand Up @@ -337,7 +337,7 @@ class FlatButtonGraphicItem(QGraphicsItem):
HEIGHT = 16

def __init__(self, icon, position, action):
super(FlatButtonGraphicItem, self).__init__(None, None)
super(FlatButtonGraphicItem, self).__init__(None)
self.setAcceptHoverEvents(True)
self.setFlag(QGraphicsItem.ItemIsMovable, False)
self.pixmap = icon.pixmap(self.WIDTH, self.HEIGHT,
Expand Down

0 comments on commit 81e86ac

Please sign in to comment.