[ui] GraphEditor: add action to clear node internal data

This commit is contained in:
Yann Lanthony 2017-12-11 15:13:56 +01:00
parent b771352694
commit 5c179cce6e
2 changed files with 15 additions and 1 deletions

View file

@ -831,6 +831,15 @@ class Node(BaseObject):
return False
return True
@Slot()
def clearData(self):
""" Delete this Node internal folder.
Status will be reset to Status.NONE
"""
if os.path.exists(self.internalFolder):
shutil.rmtree(self.internalFolder)
self.updateStatusFromCache()
def isAlreadySubmitted(self):
for chunk in self._chunks:
if chunk.isAlreadySubmitted():