If all you need is to prevent pinch gestures, you can do that without any downstream changes. To disable touchscreen pinch zoom, you can use the touch-action CSS property. To disable touchpad pinch zoom, you can use a wheel event listener which preventDefaults wheel events with the ctrl key set (chromium sends synthetic wheel events for touchpad pinches).
If, instead of disabling, you want to restore the behaviour of touchpad pinch causing discrete zoom changes on Windows, I suppose you could maintain a downstream revert of the change that introduced touchpad pinch support on Windows. It would appear to be commit 77ff930c1685bca26a5c3b362f732f157f94bece , but I don't have a Windows machine to confirm this. In any case, the idea would be to not generate our gesture events from the OS's events, but to create a fake wheel event with the ctrl key set and send that instead.
Another option which would likely be less of a downstream maintenance burden would be to use the wheel event listener from the first suggestion and send a message back to the browser to adjust the zoom. I'm not very familiar with CEF, but from skimming their documentation, it looks like they provide a mechanism to send messages to a custom handler in the browser from javascript. So you might have something like:
myElement.addEventListener('wheel', (event) => {
if (!event.ctrlKey) {
return;
}
event.preventDefault();
// Send a message to your handler in the browser to adjust the zoom.
},{passive: false});
Then in your C++ handler in the browser, adjust the zoom level. See components/zoom/page_zoom.h for the function to call.