We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0f82685 commit 6dedd3eCopy full SHA for 6dedd3e
NodeGraphQt/custom_widgets/properties_bin/node_property_widgets.py
@@ -798,14 +798,16 @@ def add_node(self, node):
798
if self.limit() == 0 or self._lock:
799
return
800
801
- rows = self._prop_list.rowCount() - 1
802
- if rows >= self.limit():
803
- self._prop_list.removeRow(rows - 1)
804
-
+ # remove pre-existing instance
805
itm_find = self._prop_list.findItems(node.id, QtCore.Qt.MatchExactly)
806
if itm_find:
807
self._prop_list.removeRow(itm_find[0].row())
808
+ rows = self._prop_list.rowCount() - 1
+ if rows >= (self.limit()-1):
+ # remove last row
809
+ self._prop_list.removeRow(rows - 1)
810
+
811
self._prop_list.insertRow(0)
812
813
prop_widget = self.create_property_editor(node=node)
0 commit comments