mirror of
https://git.sr.ht/~eliasnaur/gio
synced 2026-07-01 07:35:40 +00:00
io/pointer,io/router,gesture: add pointer.Foremost priority
Replace the pointer.Scroll special case with a new priority that indicates the foremost handler, checked in gesture.Scroll. Signed-off-by: Elias Naur <mail@eliasnaur.com>
This commit is contained in:
@@ -225,6 +225,9 @@ func (s *Scroll) Scroll(cfg unit.Converter, q event.Queue, t time.Time, axis Axi
|
||||
s.dragging = false
|
||||
s.grab = false
|
||||
case pointer.Scroll:
|
||||
if e.Priority < pointer.Foremost {
|
||||
continue
|
||||
}
|
||||
switch s.axis {
|
||||
case Horizontal:
|
||||
s.scroll += e.Scroll.X
|
||||
|
||||
Reference in New Issue
Block a user