mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-25 13:51:41 +00:00
Bug 528792 - :-moz-lwtheme incorrectly depends on the lwthemetextcolor attribute. r=dbaron
This commit is contained in:
parent
efd1c0daa3
commit
b325aad4d2
@ -1178,14 +1178,16 @@ public:
|
||||
enum DocumentTheme {
|
||||
Doc_Theme_Uninitialized, // not determined yet
|
||||
Doc_Theme_None,
|
||||
Doc_Theme_Neutral,
|
||||
Doc_Theme_Dark,
|
||||
Doc_Theme_Bright
|
||||
};
|
||||
|
||||
/**
|
||||
* Returns Doc_Theme_None if there is no lightweight theme specified, Doc_Theme_Dark
|
||||
* for a dark theme and Doc_Theme_Bright for a light theme. This is used to
|
||||
* determine the state of the pseudoclasses :-moz-lwtheme and :-moz-lwtheme-text.
|
||||
* Returns Doc_Theme_None if there is no lightweight theme specified,
|
||||
* Doc_Theme_Dark for a dark theme, Doc_Theme_Bright for a light theme, and
|
||||
* Doc_Theme_Neutral for any other theme. This is used to determine the state
|
||||
* of the pseudoclasses :-moz-lwtheme and :-moz-lwtheme-text.
|
||||
*/
|
||||
virtual int GetDocumentLWTheme() { return Doc_Theme_None; }
|
||||
|
||||
|
@ -4759,6 +4759,7 @@ nsXULDocument::GetDocumentLWTheme()
|
||||
content->GetAttr(kNameSpaceID_None, nsGkAtoms::lwtheme, hasLWTheme) &&
|
||||
!(hasLWTheme.IsEmpty()) &&
|
||||
hasLWTheme.EqualsLiteral("true")) {
|
||||
mDocLWTheme = Doc_Theme_Neutral;
|
||||
nsAutoString lwTheme;
|
||||
content->GetAttr(kNameSpaceID_None, nsGkAtoms::lwthemetextcolor, lwTheme);
|
||||
if (!(lwTheme.IsEmpty())) {
|
||||
|
Loading…
Reference in New Issue
Block a user