EventType.MouseUp seems to dislike buttons

Simple code:

void OnGUI () {
  if( e.type == EventType.MouseUp ){
    print( "mouse up!" );	
  }
}

The “mouse up!” message only appears when I mouse up and the cursor is NOT over a button.

Basically, I’ve got a button that I need to use to track clicks and click-drags.

So the element is a GUILayout.RepeatButton(), and when you click and drag, it allows for moving of the element, while clicking or double clicking has other effects-- so, I’ve got to determine click states on my own. The point of the mouseup event thing is to look for these complete clicks after an isPressed boolean has been set by pressing the button.

Because the mouseup event type doesn’t seem to fire when the cursor is over a button, I can’t track said complete clicks.

Whatcha think?

I’ve worked around this by using Input.GetMouseButtonUp().