servo: Merge #17913 - Have check_allowed_in read gPropertyEabled table directly (from upsuper:prop-enabled); r=Manishearth

This is the Servo side change of [bug 1381690](https://bugzilla.mozilla.org/show_bug.cgi?id=1381690).

Source-Repo: https://github.com/servo/servo
Source-Revision: b47e1876bd36656aefdc78d630be554bf3956a19

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : e3baefb43dea7eadf397e910ef9a30bcbdd6d9b9
This commit is contained in:
Xidorn Quan 2017-07-28 21:49:38 -05:00
parent 4383c4b9db
commit c687dc7b7a
2 changed files with 2 additions and 4 deletions

View File

@ -1418,9 +1418,6 @@ extern "C" {
pub fn Gecko_ReleaseCSSValueSharedListArbitraryThread(aPtr:
*mut nsCSSValueSharedList);
}
extern "C" {
pub fn Gecko_PropertyId_IsPrefEnabled(id: nsCSSPropertyID) -> bool;
}
extern "C" {
pub fn Gecko_nsStyleFont_SetLang(font: *mut nsStyleFont,
atom: *mut nsIAtom);

View File

@ -1184,8 +1184,9 @@ impl PropertyId {
}
% endif
% if product == "gecko":
use gecko_bindings::structs;
let id = self.to_nscsspropertyid().unwrap();
unsafe { bindings::Gecko_PropertyId_IsPrefEnabled(id) }
unsafe { structs::nsCSSProps_gPropertyEnabled[id as usize] }
% endif
};