diff options
author | Martin Rudalics <rudalics@gmx.at> | 2014-08-28 08:46:58 +0200 |
---|---|---|
committer | Martin Rudalics <rudalics@gmx.at> | 2014-08-28 08:46:58 +0200 |
commit | a7ef7a0e53ae1f391f4bda207bb5e9b9d833d354 (patch) | |
tree | 47c95273a03b30fdcc7f5c4e3224a6fe298668a0 /src/w32term.c | |
parent | f1fdf67b4e87cf5974fa4e445b23fef1d10bb7cb (diff) | |
download | emacs-a7ef7a0e53ae1f391f4bda207bb5e9b9d833d354.tar.gz |
Some fixes for scroll bar code.
* w32term.c (w32_horizontal_scroll_bar_handle_click): In
`event->y' return entire range (the size of the scroll bar minus
that of the thumb).
* xterm.c (xm_scroll_callback, xaw_jump_callback): In `whole'
return entire range (the scaled size of the scroll bar minus
that of the slider). In `portion' return the scaled position of
the slider.
(xaw_jump_callback): Restore part of code for vertical scroll
bar broken in change from 2014-07-27.
(xaw_scroll_callback): Provide incremental scrolling with
horizontal scroll bars.
(x_scroll_bar_handle_click): Fix typo introduced in change from
2014-07-27.
* scroll-bar.el (scroll-bar-horizontal-drag-1): Handle new
interpretation of `portion-whole'.
Diffstat (limited to 'src/w32term.c')
-rw-r--r-- | src/w32term.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/w32term.c b/src/w32term.c index d9e051be870..55c2d718346 100644 --- a/src/w32term.c +++ b/src/w32term.c @@ -4293,7 +4293,7 @@ w32_horizontal_scroll_bar_handle_click (struct scroll_bar *bar, W32Msg *msg, x = si.nTrackPos; else x = si.nPos; - y = si.nMax - x - si.nPage; + y = si.nMax - si.nPage; bar->dragging = 0; FRAME_DISPLAY_INFO (f)->last_mouse_scroll_bar_pos = msg->msg.wParam; @@ -4350,12 +4350,9 @@ w32_horizontal_scroll_bar_handle_click (struct scroll_bar *bar, W32Msg *msg, int end = bar->end; si.cbSize = sizeof (si); -/** si.fMask = SIF_PAGE | SIF_POS; **/ si.fMask = SIF_POS; -/** si.nPage = end - start + HORIZONTAL_SCROLL_BAR_MIN_HANDLE; **/ si.nPos = min (last_scroll_bar_drag_pos, XWINDOW (bar->window)->hscroll_whole - 1); -/** si.nPos = last_scroll_bar_drag_pos; **/ SetScrollInfo (SCROLL_BAR_W32_WINDOW (bar), SB_CTL, &si, TRUE); } /* fall through */ |