My use case is the following: use gestures only on the specified windows/applications (browser windows), other windows should work completely without the gestures support.
The configuration could be the same as it is for the default Desktop and Internet Browsers applications - allow to enable/disable all Global Actions directly from the root tree item.
When the global actions are enabled, usual message flow in mouse hook would be used - gestures work everywhere, but do not work on the excluded windows. When the global actions are disabled, the reversed logic could be used - gestures do not work anywhere, but do work on the explicitly defined applications/windows (defined exclusions would be useless in this use case).
Yes, that is what I was searching for. In order to get things working, I also needed to disable Keep Gestures Draw Window On Top, which prevented usage of Inkscape (free SVG image editor). So now it looks like working. Thanks for the hint!