aboutsummaryrefslogtreecommitdiffstats
path: root/src/macterm.c
diff options
context:
space:
mode:
authorMiles Bader2008-01-30 07:57:28 +0000
committerMiles Bader2008-01-30 07:57:28 +0000
commitd235ca2ff8fab139ce797757fcb159d1e28fa7e0 (patch)
tree96c5cd1a06a0d9dc26e8470c6eabfc032c0046f3 /src/macterm.c
parent3709a060f679dba14df71ae64a0035fa2b5b3106 (diff)
parent02cbe062bee38a6705bafb1699d77e3c44cfafcf (diff)
downloademacs-d235ca2ff8fab139ce797757fcb159d1e28fa7e0.tar.gz
emacs-d235ca2ff8fab139ce797757fcb159d1e28fa7e0.zip
Merge from emacs--devo--0
Revision: emacs@sv.gnu.org/emacs--unicode--0--patch-324
Diffstat (limited to 'src/macterm.c')
-rw-r--r--src/macterm.c36
1 files changed, 28 insertions, 8 deletions
diff --git a/src/macterm.c b/src/macterm.c
index a46c9cbbda4..2d03c8918c5 100644
--- a/src/macterm.c
+++ b/src/macterm.c
@@ -5071,6 +5071,7 @@ x_scroll_bar_create (w, top, left, width, height, disp_top, disp_height)
5071#ifdef MAC_OSX 5071#ifdef MAC_OSX
5072 bar->fringe_extended_p = Qnil; 5072 bar->fringe_extended_p = Qnil;
5073#endif 5073#endif
5074 bar->redraw_needed_p = Qnil;
5074#ifdef USE_TOOLKIT_SCROLL_BARS 5075#ifdef USE_TOOLKIT_SCROLL_BARS
5075 bar->track_top = Qnil; 5076 bar->track_top = Qnil;
5076 bar->track_height = Qnil; 5077 bar->track_height = Qnil;
@@ -5287,14 +5288,24 @@ XTset_vertical_scroll_bar (w, portion, whole, position)
5287 BLOCK_INPUT; 5288 BLOCK_INPUT;
5288 5289
5289 /* If already correctly positioned, do nothing. */ 5290 /* If already correctly positioned, do nothing. */
5290 if (!(XINT (bar->left) == sb_left 5291 if (XINT (bar->left) == sb_left
5291 && XINT (bar->top) == top 5292 && XINT (bar->top) == top
5292 && XINT (bar->width) == sb_width 5293 && XINT (bar->width) == sb_width
5293 && XINT (bar->height) == height 5294 && XINT (bar->height) == height
5294#ifdef MAC_OSX 5295#ifdef MAC_OSX
5295 && !NILP (bar->fringe_extended_p) == fringe_extended_p 5296 && !NILP (bar->fringe_extended_p) == fringe_extended_p
5296#endif 5297#endif
5297 )) 5298 )
5299 {
5300 if (!NILP (bar->redraw_needed_p))
5301 {
5302#if USE_CG_DRAWING
5303 mac_prepare_for_quickdraw (f);
5304#endif
5305 Draw1Control (SCROLL_BAR_CONTROL_REF (bar));
5306 }
5307 }
5308 else
5298 { 5309 {
5299 /* Since toolkit scroll bars are smaller than the space reserved 5310 /* Since toolkit scroll bars are smaller than the space reserved
5300 for them on the frame, we have to clear "under" them. */ 5311 for them on the frame, we have to clear "under" them. */
@@ -5336,6 +5347,8 @@ XTset_vertical_scroll_bar (w, portion, whole, position)
5336 bar->fringe_extended_p = fringe_extended_p ? Qt : Qnil; 5347 bar->fringe_extended_p = fringe_extended_p ? Qt : Qnil;
5337#endif 5348#endif
5338 5349
5350 bar->redraw_needed_p = Qnil;
5351
5339#ifdef USE_TOOLKIT_SCROLL_BARS 5352#ifdef USE_TOOLKIT_SCROLL_BARS
5340 if (NILP (bar->track_top)) 5353 if (NILP (bar->track_top))
5341 { 5354 {
@@ -5693,8 +5706,15 @@ void
5693x_scroll_bar_clear (f) 5706x_scroll_bar_clear (f)
5694 FRAME_PTR f; 5707 FRAME_PTR f;
5695{ 5708{
5696 XTcondemn_scroll_bars (f); 5709 Lisp_Object bar;
5697 XTjudge_scroll_bars (f); 5710
5711 /* We can have scroll bars even if this is 0,
5712 if we just turned off scroll bar mode.
5713 But in that case we should not clear them. */
5714 if (FRAME_HAS_VERTICAL_SCROLL_BARS (f))
5715 for (bar = FRAME_SCROLL_BARS (f); VECTORP (bar);
5716 bar = XSCROLL_BAR (bar)->next)
5717 XSCROLL_BAR (bar)->redraw_needed_p = Qt;
5698} 5718}
5699 5719
5700 5720