зеркало из https://github.com/mozilla/pjs.git
Fix for bug 53723 (gray form control on Linux). r=pierre, ianh,
pavlov. sr/a=ben.
This commit is contained in:
Родитель
8460f58942
Коммит
3fcba76e2b
|
@ -51,6 +51,7 @@ CSS_KEY(-moz-all, _moz_all)
|
|||
CSS_KEY(-moz-bg-inset, _moz_bg_inset)
|
||||
CSS_KEY(-moz-bg-outset, _moz_bg_outset)
|
||||
CSS_KEY(-moz-center, _moz_center)
|
||||
CSS_KEY(-moz-field, _moz_field)
|
||||
CSS_KEY(-moz-right, _moz_right)
|
||||
CSS_KEY(-moz-pre-wrap, _moz_pre_wrap)
|
||||
CSS_KEY(-moz-scrollbars-none, _moz_scrollbars_none)
|
||||
|
|
|
@ -51,6 +51,7 @@ CSS_KEY(-moz-all, _moz_all)
|
|||
CSS_KEY(-moz-bg-inset, _moz_bg_inset)
|
||||
CSS_KEY(-moz-bg-outset, _moz_bg_outset)
|
||||
CSS_KEY(-moz-center, _moz_center)
|
||||
CSS_KEY(-moz-field, _moz_field)
|
||||
CSS_KEY(-moz-right, _moz_right)
|
||||
CSS_KEY(-moz-pre-wrap, _moz_pre_wrap)
|
||||
CSS_KEY(-moz-scrollbars-none, _moz_scrollbars_none)
|
||||
|
|
|
@ -226,6 +226,7 @@ const PRInt32 nsCSSProps::kColorKTable[] = {
|
|||
eCSSKeyword_window, nsILookAndFeel::eColor_window,
|
||||
eCSSKeyword_windowframe, nsILookAndFeel::eColor_windowframe,
|
||||
eCSSKeyword_windowtext, nsILookAndFeel::eColor_windowtext,
|
||||
eCSSKeyword__moz_field, nsILookAndFeel::eColor__moz_field,
|
||||
-1,-1
|
||||
};
|
||||
|
||||
|
|
|
@ -424,7 +424,7 @@ fieldset {
|
|||
|
||||
/* default inputs, text inputs, and selects */
|
||||
input {
|
||||
background-color: Window;
|
||||
background-color: -moz-field;
|
||||
border: 2px inset ThreeDFace;
|
||||
color: WindowText;
|
||||
cursor: text;
|
||||
|
@ -437,7 +437,7 @@ input {
|
|||
}
|
||||
|
||||
textarea {
|
||||
background-color: Window;
|
||||
background-color: -moz-field;
|
||||
border: 2px inset ThreeDFace;
|
||||
color: WindowText;
|
||||
font: field;
|
||||
|
@ -458,7 +458,7 @@ textarea {
|
|||
|
||||
select {
|
||||
font: list;
|
||||
background-color: Window;
|
||||
background-color: -moz-field;
|
||||
border: 2px inset ThreeDFace;
|
||||
margin: 1px 0 1px 0;
|
||||
vertical-align: bottom;
|
||||
|
@ -604,7 +604,7 @@ input[type="file"] > input[type="button"] {
|
|||
/* radio buttons */
|
||||
input[type="radio"] {
|
||||
border: 2px inset ThreeDFace;
|
||||
background-color: Window;
|
||||
background-color: -moz-field;
|
||||
color: WindowText;
|
||||
width: 12px;
|
||||
height: 12px;
|
||||
|
@ -617,7 +617,7 @@ input[type="radio"] {
|
|||
/* check boxes */
|
||||
input[type="checkbox"] {
|
||||
border: 2px inset ThreeDFace;
|
||||
background-color: Window;
|
||||
background-color: -moz-field;
|
||||
color: WindowText;
|
||||
width: 13px;
|
||||
height: 13px;
|
||||
|
|
|
@ -51,6 +51,7 @@ CSS_KEY(-moz-all, _moz_all)
|
|||
CSS_KEY(-moz-bg-inset, _moz_bg_inset)
|
||||
CSS_KEY(-moz-bg-outset, _moz_bg_outset)
|
||||
CSS_KEY(-moz-center, _moz_center)
|
||||
CSS_KEY(-moz-field, _moz_field)
|
||||
CSS_KEY(-moz-right, _moz_right)
|
||||
CSS_KEY(-moz-pre-wrap, _moz_pre_wrap)
|
||||
CSS_KEY(-moz-scrollbars-none, _moz_scrollbars_none)
|
||||
|
|
|
@ -226,6 +226,7 @@ const PRInt32 nsCSSProps::kColorKTable[] = {
|
|||
eCSSKeyword_window, nsILookAndFeel::eColor_window,
|
||||
eCSSKeyword_windowframe, nsILookAndFeel::eColor_windowframe,
|
||||
eCSSKeyword_windowtext, nsILookAndFeel::eColor_windowtext,
|
||||
eCSSKeyword__moz_field, nsILookAndFeel::eColor__moz_field,
|
||||
-1,-1
|
||||
};
|
||||
|
||||
|
|
|
@ -424,7 +424,7 @@ fieldset {
|
|||
|
||||
/* default inputs, text inputs, and selects */
|
||||
input {
|
||||
background-color: Window;
|
||||
background-color: -moz-field;
|
||||
border: 2px inset ThreeDFace;
|
||||
color: WindowText;
|
||||
cursor: text;
|
||||
|
@ -437,7 +437,7 @@ input {
|
|||
}
|
||||
|
||||
textarea {
|
||||
background-color: Window;
|
||||
background-color: -moz-field;
|
||||
border: 2px inset ThreeDFace;
|
||||
color: WindowText;
|
||||
font: field;
|
||||
|
@ -458,7 +458,7 @@ textarea {
|
|||
|
||||
select {
|
||||
font: list;
|
||||
background-color: Window;
|
||||
background-color: -moz-field;
|
||||
border: 2px inset ThreeDFace;
|
||||
margin: 1px 0 1px 0;
|
||||
vertical-align: bottom;
|
||||
|
@ -604,7 +604,7 @@ input[type="file"] > input[type="button"] {
|
|||
/* radio buttons */
|
||||
input[type="radio"] {
|
||||
border: 2px inset ThreeDFace;
|
||||
background-color: Window;
|
||||
background-color: -moz-field;
|
||||
color: WindowText;
|
||||
width: 12px;
|
||||
height: 12px;
|
||||
|
@ -617,7 +617,7 @@ input[type="radio"] {
|
|||
/* check boxes */
|
||||
input[type="checkbox"] {
|
||||
border: 2px inset ThreeDFace;
|
||||
background-color: Window;
|
||||
background-color: -moz-field;
|
||||
color: WindowText;
|
||||
width: 13px;
|
||||
height: 13px;
|
||||
|
|
|
@ -51,6 +51,7 @@ CSS_KEY(-moz-all, _moz_all)
|
|||
CSS_KEY(-moz-bg-inset, _moz_bg_inset)
|
||||
CSS_KEY(-moz-bg-outset, _moz_bg_outset)
|
||||
CSS_KEY(-moz-center, _moz_center)
|
||||
CSS_KEY(-moz-field, _moz_field)
|
||||
CSS_KEY(-moz-right, _moz_right)
|
||||
CSS_KEY(-moz-pre-wrap, _moz_pre_wrap)
|
||||
CSS_KEY(-moz-scrollbars-none, _moz_scrollbars_none)
|
||||
|
|
|
@ -226,6 +226,7 @@ const PRInt32 nsCSSProps::kColorKTable[] = {
|
|||
eCSSKeyword_window, nsILookAndFeel::eColor_window,
|
||||
eCSSKeyword_windowframe, nsILookAndFeel::eColor_windowframe,
|
||||
eCSSKeyword_windowtext, nsILookAndFeel::eColor_windowtext,
|
||||
eCSSKeyword__moz_field, nsILookAndFeel::eColor__moz_field,
|
||||
-1,-1
|
||||
};
|
||||
|
||||
|
|
|
@ -82,7 +82,10 @@ public:
|
|||
eColor_threedshadow,
|
||||
eColor_window,
|
||||
eColor_windowframe,
|
||||
eColor_windowtext
|
||||
eColor_windowtext,
|
||||
|
||||
// Colors which will hopefully become CSS3
|
||||
eColor__moz_field
|
||||
|
||||
} nsColorID;
|
||||
|
||||
|
|
|
@ -197,6 +197,13 @@ NS_IMETHODIMP nsLookAndFeel::GetColor(const nsColorID aID, nscolor &aColor)
|
|||
aColor = GDK_COLOR_TO_NS_RGB(mStyle->fg[GTK_STATE_NORMAL]);
|
||||
break;
|
||||
|
||||
// from the CSS3 working draft (not yet finalized)
|
||||
// http://www.w3.org/tr/2000/wd-css3-userint-20000216.html#color
|
||||
|
||||
case eColor__moz_field:
|
||||
aColor = GDK_COLOR_TO_NS_RGB(mStyle->base[GTK_STATE_NORMAL]);
|
||||
break;
|
||||
|
||||
default:
|
||||
/* default color is BLACK */
|
||||
aColor = 0;
|
||||
|
|
|
@ -185,6 +185,9 @@ NS_IMETHODIMP nsLookAndFeel::GetColor(const nsColorID aID, nscolor &aColor)
|
|||
case eColor_window:
|
||||
aColor = NS_RGB(0xff,0xff,0xff);
|
||||
break;
|
||||
case eColor__moz_field:
|
||||
aColor = NS_RGB(0xff,0xff,0xff);
|
||||
break;
|
||||
|
||||
default:
|
||||
NS_WARNING("Someone asked nsILookAndFeel for a color I don't know about");
|
||||
|
|
|
@ -183,6 +183,9 @@ NS_IMETHODIMP nsLookAndFeel::GetColor(const nsColorID aID, nscolor &aColor)
|
|||
case eColor_windowtext:
|
||||
idx = SYSCLR_WINDOWTEXT;
|
||||
break;
|
||||
case eColor__moz_field:
|
||||
idx = SYSCLR_WINDOW;
|
||||
break;
|
||||
default:
|
||||
idx = SYSCLR_WINDOW;
|
||||
break;
|
||||
|
|
|
@ -176,6 +176,9 @@ NS_IMETHODIMP nsLookAndFeel::GetColor(const nsColorID aID, nscolor &aColor)
|
|||
case eColor_windowtext:
|
||||
idx = COLOR_WINDOWTEXT;
|
||||
break;
|
||||
case eColor__moz_field:
|
||||
idx = COLOR_WINDOW;
|
||||
break;
|
||||
default:
|
||||
idx = COLOR_WINDOW;
|
||||
break;
|
||||
|
|
|
@ -179,6 +179,10 @@ NS_IMETHODIMP nsLookAndFeel::GetColor(const nsColorID aID, nscolor &aColor)
|
|||
aColor = NS_RGB(0x00, 0x00, 0x00);
|
||||
break;
|
||||
|
||||
case eColor__moz_field:
|
||||
aColor = NS_RGB(0xc0, 0xc0, 0xc0);
|
||||
break;
|
||||
|
||||
default:
|
||||
/* default color is BLACK */
|
||||
aColor = 0;
|
||||
|
|
|
@ -167,6 +167,8 @@ nsLookAndFeelColorPref nsXPLookAndFeel::sColorPrefs[] =
|
|||
eColor_windowframe, PR_FALSE, nsLookAndFeelTypeColor, (nscolor)0 },
|
||||
{ "ui.windowtext",
|
||||
eColor_windowtext, PR_FALSE, nsLookAndFeelTypeColor, (nscolor)0 },
|
||||
{ "ui.-moz-field",
|
||||
eColor__moz_field, PR_FALSE, nsLookAndFeelTypeColor, (nscolor)0 },
|
||||
};
|
||||
|
||||
PRBool nsXPLookAndFeel::sInitialized = PR_FALSE;
|
||||
|
|
Загрузка…
Ссылка в новой задаче