mirror of
https://github.com/alicevision/Meshroom.git
synced 2025-07-30 14:58:37 +02:00
[graph] ListAttribute: replace '__getitem__ by 'at'
__getitem__ is spuriously called when the object is used inside a Qt model and exposed to QML, leading to unexpected behaviors
This commit is contained in:
parent
a5cda66670
commit
2cd724f957
4 changed files with 25 additions and 22 deletions
|
@ -122,7 +122,7 @@ class LiveSfmManager(QObject):
|
|||
def imagePathsInCameraInit(self, node):
|
||||
""" Get images in the given CameraInit node. """
|
||||
assert node.nodeType == 'CameraInit'
|
||||
return [vp.path.value for vp in node.viewpoints]
|
||||
return [vp.path.value for vp in node.viewpoints.value]
|
||||
|
||||
def imagesInStep(self):
|
||||
""" Get images in the current augmentation step. """
|
||||
|
@ -304,11 +304,11 @@ class Reconstruction(UIGraph):
|
|||
|
||||
def allImagePaths(self):
|
||||
""" Get all image paths in the reconstruction. """
|
||||
return [vp.path.value for node in self._cameraInits for vp in node.viewpoints]
|
||||
return [vp.path.value for node in self._cameraInits for vp in node.viewpoints.value]
|
||||
|
||||
def allViewIds(self):
|
||||
""" Get all view Ids involved in the reconstruction. """
|
||||
return [vp.viewId.value for node in self._cameraInits for vp in node.viewpoints]
|
||||
return [vp.viewId.value for node in self._cameraInits for vp in node.viewpoints.value]
|
||||
|
||||
@Slot(QObject, graph.Node)
|
||||
def handleFilesDrop(self, drop, cameraInit):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue