mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-12-02 01:48:05 +00:00
Don't apply a border to <toolbox> (bug 184588). r=blizzard, sr=ben.
This commit is contained in:
parent
1ed178c74d
commit
db1a60582b
@ -380,20 +380,30 @@ nsNativeThemeGTK::GetWidgetBorder(nsIDeviceContext* aContext, nsIFrame* aFrame,
|
||||
PRUint8 aWidgetType, nsMargin* aResult)
|
||||
{
|
||||
aResult->top = aResult->left = 0;
|
||||
if (aWidgetType == NS_THEME_SCROLLBAR_TRACK_VERTICAL ||
|
||||
aWidgetType == NS_THEME_SCROLLBAR_TRACK_HORIZONTAL)
|
||||
switch (aWidgetType) {
|
||||
case NS_THEME_SCROLLBAR_TRACK_VERTICAL:
|
||||
case NS_THEME_SCROLLBAR_TRACK_HORIZONTAL:
|
||||
{
|
||||
gint trough_border;
|
||||
moz_gtk_get_scrollbar_metrics(nsnull, &trough_border,
|
||||
nsnull, nsnull, nsnull);
|
||||
aResult->top = aResult->left = trough_border;
|
||||
} else {
|
||||
}
|
||||
break;
|
||||
case NS_THEME_TOOLBOX:
|
||||
// gtk has no toolbox equivalent. So, although we map toolbox to
|
||||
// gtk's 'toolbar' for purposes of painting the widget background,
|
||||
// we don't use the toolbar border for toolbox.
|
||||
break;
|
||||
default:
|
||||
{
|
||||
GtkThemeWidgetType gtkWidgetType;
|
||||
if (GetGtkWidgetAndState(aWidgetType, aFrame, gtkWidgetType, nsnull,
|
||||
nsnull))
|
||||
moz_gtk_get_widget_border(gtkWidgetType, &aResult->left,
|
||||
&aResult->top);
|
||||
}
|
||||
}
|
||||
|
||||
aResult->right = aResult->left;
|
||||
aResult->bottom = aResult->top;
|
||||
|
Loading…
Reference in New Issue
Block a user