Suppose I want to react to input in on_modified EventListener when a user writes something to a view. But I will also be inserting characters to the same view programmatically, and I want to ignore these in on_modified.
Somehow I would like to be able to take over control of the view and disable the on_modified listener, and subsequently give back release that control. Is this possible?
A flawed idea for a solution would be to set a flag in the view’s settings when I edit it programmatically and check for this in on_modified. However, I suspect this might not be bullet proof, as the user input and the programmatic input might get interleaved. Or am I wrong about this?
Thanks.