]> git.eshelyaron.com Git - emacs.git/commit
Improve scroll bar button handling on Haiku
authorPo Lu <luangruo@yahoo.com>
Sat, 26 Feb 2022 06:56:31 +0000 (06:56 +0000)
committerPo Lu <luangruo@yahoo.com>
Sat, 26 Feb 2022 06:57:00 +0000 (06:57 +0000)
commit974c44414a1bd3dced0f77ce65c60a41e0f25a1a
treee9c8ccfbdcf8a9ce28cf37abcad8911312aaf097
parentc215158756b127f77a1cf298e80529e2589a23b4
Improve scroll bar button handling on Haiku

* src/haiku_io.c (haiku_len): Add `SCROLL_BAR_PART_EVENT'.
* src/haiku_support.cc (class EmacsScrollBar): New fields
`dragging' and `current_state', along with `old_value' and
`current_part'.
(EmacsScrollBar): Set horizontal flag to `horizontal_p'.
(MessageReceived): Set old_value when receiving
SCROLL_BAR_UPDATE message.
(ValueChanged): Don't allow scroll bar values to change while
dragging.
(MouseUp, MouseDown): Calculate button under mouse and act
accordingly.
* src/haiku_support.h (enum haiku_event_type): New event
`SCROLL_BAR_PART_EVENT'.
(enum haiku_scroll_bar_part): New enumerator.
(struct haiku_scroll_bar_part_event): New struct.
* src/haikuterm.c (haiku_read_socket): Handle
SCROLL_BAR_PART_EVENTs.
src/haiku_io.c
src/haiku_support.cc
src/haiku_support.h
src/haikuterm.c