Is UnBind() method safe?
Posted: Wed Aug 08, 2018 2:33 pm
Hi,
What I am trying to do is the following:
1. On some condition in the program I'm doing Bind(). If condition is false Bind() is not executed. The event I'm binding is wxFileSystemWatcher one.
2. Inside some other event handler I want to execute UnBind() method.
2 questions:
1. If the Bind() was not executed, is it safe to un-bind the event?
2. If the answer to 1 is no - what is the best way to achieve it? I don't think there is an IsEventBound() method...
Thank you.
What I am trying to do is the following:
1. On some condition in the program I'm doing Bind(). If condition is false Bind() is not executed. The event I'm binding is wxFileSystemWatcher one.
2. Inside some other event handler I want to execute UnBind() method.
2 questions:
1. If the Bind() was not executed, is it safe to un-bind the event?
2. If the answer to 1 is no - what is the best way to achieve it? I don't think there is an IsEventBound() method...
Thank you.