* Must match a `begin` and should be called when done with Python snippet * processing. Undoes all overrides set up in `begin`. */
| 136 | * processing. Undoes all overrides set up in `begin`. |
| 137 | */ |
| 138 | void end() |
| 139 | { |
| 140 | this->ExecutionCounter--; |
| 141 | assert(this->ExecutionCounter >= 0); |
| 142 | if (this->ExecutionCounter == 0) |
| 143 | { |
| 144 | vtkPythonInterpreter::SetCaptureStdin(this->OldCapture); |
| 145 | this->OldCapture = false; |
| 146 | vtkOutputWindow::SetInstance(this->OldInstance); |
| 147 | this->OldInstance = nullptr; |
| 148 | Q_EMIT this->Parent->executing(false); |
| 149 | } |
| 150 | } |
| 151 | |
| 152 | bool isExecuting() const { return this->ExecutionCounter > 0; } |
| 153 | bool isInterpreterInitialized() const { return this->InterpreterInitialized; } |
no outgoing calls