зеркало из https://github.com/mozilla/gecko-dev.git
b=444870 no need to increase the cliprect for scrollbar thumbs because the cliprect already includes the extra size r=roc
This commit is contained in:
Родитель
5cad92a1be
Коммит
3cdacbe838
|
@ -1335,21 +1335,12 @@ moz_gtk_scrollbar_thumb_paint(GtkThemeWidgetType widget,
|
|||
surrounding the scrollbar if the theme thinks that it's butted
|
||||
up against the scrollbar arrows. Note the increases of the
|
||||
clip rect below. */
|
||||
/* Changing the cliprect is pretty bogus. This lets themes draw
|
||||
outside the frame, which means we don't invalidate them
|
||||
correctly. See bug 297508. But some themes do seem to need
|
||||
it. So we modify the frame's overflow area to account for what
|
||||
we're doing here; see nsNativeThemeGTK::GetWidgetOverflow. */
|
||||
adj = gtk_range_get_adjustment(GTK_RANGE(scrollbar));
|
||||
|
||||
if (widget == MOZ_GTK_SCROLLBAR_THUMB_HORIZONTAL) {
|
||||
cliprect->x -= 1;
|
||||
cliprect->width += 2;
|
||||
adj->page_size = rect->width;
|
||||
}
|
||||
else {
|
||||
cliprect->y -= 1;
|
||||
cliprect->height += 2;
|
||||
adj->page_size = rect->height;
|
||||
}
|
||||
|
||||
|
|
|
@ -662,7 +662,7 @@ GetExtraSizeForWidget(PRUint8 aWidgetType, PRBool aWidgetIsDefault,
|
|||
*aExtra = nsIntMargin(0,0,0,0);
|
||||
// Allow an extra one pixel above and below the thumb for certain
|
||||
// GTK2 themes (Ximian Industrial, Bluecurve, Misty, at least);
|
||||
// see moz_gtk_scrollbar_thumb_paint in gtk2drawing.c
|
||||
// We modify the frame's overflow area. See bug 297508.
|
||||
switch (aWidgetType) {
|
||||
case NS_THEME_SCROLLBAR_THUMB_VERTICAL:
|
||||
aExtra->top = aExtra->bottom = 1;
|
||||
|
|
Загрузка…
Ссылка в новой задаче