mirror of
https://github.com/servo/servo.git
synced 2025-08-03 20:50:07 +01:00
util: Rename ops::set_opts
to ops::set
, to match get
This commit is contained in:
parent
8975a3bd9b
commit
f8bbc0a974
2 changed files with 4 additions and 4 deletions
|
@ -400,7 +400,7 @@ pub fn from_cmdline_args(args: &[String]) -> bool {
|
|||
disable_share_style_cache: debug_options.contains(&"disable-share-style-cache"),
|
||||
};
|
||||
|
||||
set_opts(opts);
|
||||
set(opts);
|
||||
true
|
||||
}
|
||||
|
||||
|
@ -423,7 +423,7 @@ pub fn experimental_enabled() -> bool {
|
|||
// when passing through the DOM structures.
|
||||
static mut OPTIONS: *mut Opts = 0 as *mut Opts;
|
||||
|
||||
pub fn set_opts(opts: Opts) {
|
||||
pub fn set(opts: Opts) {
|
||||
unsafe {
|
||||
assert!(OPTIONS.is_null());
|
||||
let box_opts = box opts;
|
||||
|
@ -439,7 +439,7 @@ pub fn get<'a>() -> &'a Opts {
|
|||
// set of options. This is mostly useful for unit tests that
|
||||
// run through a code path which queries the cmd line options.
|
||||
if OPTIONS == ptr::null_mut() {
|
||||
set_opts(default_opts());
|
||||
set(default_opts());
|
||||
}
|
||||
mem::transmute(OPTIONS)
|
||||
}
|
||||
|
|
|
@ -78,7 +78,7 @@ pub extern "C" fn cef_initialize(args: *const cef_main_args_t,
|
|||
temp_opts.hard_fail = false;
|
||||
temp_opts.enable_text_antialiasing = true;
|
||||
temp_opts.resources_path = resources_path();
|
||||
opts::set_opts(temp_opts);
|
||||
opts::set(temp_opts);
|
||||
|
||||
return 1
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue