Need Help Detecting Mouse Release Event After CLICK_DRAG in Blender Modal

Hi there,

I’m running into an issue with detecting mouse release events after a mouse drag in Blender. It seems like Blender can detect LEFTMOUSE up and down events just fine when the mouse isn’t moved. However, if I click and drag, Blender triggers the PRESS (mouse down) event, but doesn’t seem to trigger anything with the RELEASE event after the drag.

Here’s the snippet of code I’m using to check for mouse up:

def _is_mouse_up(self, event: Event) -> bool:
    return event.type == "LEFTMOUSE" and event.value == "RELEASE"

This works perfectly if I don’t drag the mouse. But if there’s a drag involved, I can still detect the PRESS event, but not the RELEASE after finishing the drag.

Has anyone encountered this before? Any advice on how to handle this would be greatly appreciated!

Thanks in advance!