Handling mouse events properly when creating a custom title bar

I’m working on creating a custom title bar + window frame for my app and so far I’ve implemented a drag-able title bar region + edge resizing support using SDL_SetWindowHitTest.

I was wondering if there is any cross-platform way to also access mouse/click events from the drag-able region as I am also trying to implement double click to maximize/minimize behavior. I’ve considered simulating mouse events from the hit test callback but from reading the wiki it doesn’t look like that would provide correct behavior across all platforms.

I know GTK has an API where you can manually tell window manager to start dragging the window (gtk_window_begin_move_drag.) Is there a possibility of implementing a similar API in SDL, or is this something I should write platform specific code for?