Note reasoning behind call order

This commit is contained in:
gandalf3
2017-07-09 14:57:22 -07:00
committed by Ellwood Zwovic
parent 32f0d9fdb6
commit a4a1f69cd1

View File

@@ -39,7 +39,10 @@ def subprocess_operator(cls: Operator, polling_interval=.01) -> Operator:
Create pipe and modal timer, start subprocess
"""
def invoke(self, context, event):
self.pipe = Pipe()
self.pipe = Pipe() #HACK: do this first so operator-defined invoke can access it
# this is needed because the operator is currently responsible for setting up the Process,
# and the pipe is needed for the subprocess_function decorator.
# TODO: Perhaps this responsibility should be handled here instead (simplifies things but looses some flexibility)
orig_invoke(self, context, event)