title: Disable mouse events
body: <p>During script execution, I need to disable (or enable) mouse events, depending on the task ($React = $False or $True). I do it like this:</p>
  
  <pre><code>$React = $False (or $True, depending on the task)
  
  $Element01.Add_MouseLeave({ if ( $React ) { Do something 01 } })   
  $Element01.Add_MouseEnter({ if ( $React ) { Do something 02 } })
  
  $Element02.Add_MouseLeave({ if ( $React ) { Do something 03 } })   
  $Element02.Add_MouseHover({ if ( $React ) { Do something 04 } })
  
  </code></pre>
  
  <p>Is there a better way to enable or disable all mouse events (Enter, Click, Hover, Up, Down, Move and more) or specific events, for example, only all MouseEnter?</p>
  
  <p>I do not want to use .Enabled, as in this case the visual display of form elements, for example, such as text, is disrupted:</p>
  
  <pre><code># Not suitable
  
  $Element01.Enabled = $False
  $Element02.Enabled = $False
  </code></pre>
  
  <p>I want to know a similar opportunity (if any), as described below.</p>
  
  <pre><code>$Form.DisableEventMouse() # That would be perfect
  </code></pre>
  
  <p>or</p>
  
  <pre><code># The first case
  # Disable all mouse events using which $Something
  
  $Something = $False
  
  $Element01.Add_MouseLeave({ Do something 01 }) # The event is not executing
  $Element01.Add_MouseEnter({ Do something 02 }) # The event is not executing
  
  $Element02.Add_MouseLeave({ Do something 03 }) # The event is not executing
  $Element02.Add_MouseHover({ Do something 04 }) # The event is not executing
  
  # The second case
  # Enable all mouse events using which $Something
  
  $Something = $True
  
  $Element01.Add_MouseLeave({ Do something 01 }) # The event is executing
  $Element01.Add_MouseEnter({ Do something 02 }) # The event is executing
  
  $Element02.Add_MouseLeave({ Do something 03 }) # The event is executing
  $Element02.Add_MouseHover({ Do something 04 }) # The event is executing
  
  </code></pre>
  
  <p>Many thanks</p>