#8539 Config preferences backend restructure

This commit is contained in:
Peter Hall 2019-02-14 12:53:59 +00:00
parent 34fda66dfa
commit 8bfd4dc1e2
53 changed files with 1748 additions and 680 deletions

View file

@ -42,7 +42,7 @@ use js::jsapi::JSContext;
use js::rust::HandleValue;
use profile_traits::ipc;
use script_layout_interface::{HTMLCanvasData, HTMLCanvasDataSource};
use servo_config::prefs::PREFS;
use servo_config::pref;
use std::cell::Ref;
use style::attr::{AttrValue, LengthOrPercentageOrAuto};
@ -232,7 +232,7 @@ impl HTMLCanvasElement {
cx: *mut JSContext,
options: HandleValue,
) -> Option<DomRoot<WebGL2RenderingContext>> {
if !PREFS.is_webgl2_enabled() {
if !pref!(dom.webgl2.enabled) {
return None;
}
if let Some(ctx) = self.context() {