mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-07-21 03:06:15 +03:00

This work is mainly targeted at adding the crosshair for when ctrl/super+alt is pressed. We also add this for when mouse tracking is enabled so that we show the crosshair when ctrl/super+alt+shift is pressed at the same time. I've also changed the event processing logic here because the amount of keys we have to process has greatly increased. Instead of processing each individual event, we now process the modifier state. Additionally, some refactoring has been done geared at starting to re-work the mouse for the core surface into a something stateful. My hope is that we can continue to unravel some of this from the core surface so that we can process key inputs, motion events, and anything else relevant as inputs to transitions for shape display, click behavior, etc. This commit now also moves the ctrlOrSuper handlers to respective parts in the Key hierarchy, while also adding additional helpers for other modifiers.