Bug 1341362 - Use default values for RendererOptions instead of explicitly specifying each one. r=jrmuizel
authorKartikaya Gupta <kgupta@mozilla.com>
Wed, 22 Feb 2017 15:15:05 -0500
changeset 373505 684fa301b65d5c7cff0012c69fd2b741cd707476
parent 373504 4069aff634580f3bd35c8dbc63a35a132212539c
child 373506 9d9cc19f0627ed80c8f245cfcb22a79c09936144
push id10863
push userjlorenzo@mozilla.com
push dateMon, 06 Mar 2017 23:02:23 +0000
treeherdermozilla-aurora@0931190cd725 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjrmuizel
bugs1341362
milestone54.0a1
Bug 1341362 - Use default values for RendererOptions instead of explicitly specifying each one. r=jrmuizel MozReview-Commit-ID: 275n8D1KfOK
gfx/webrender_bindings/src/bindings.rs
--- a/gfx/webrender_bindings/src/bindings.rs
+++ b/gfx/webrender_bindings/src/bindings.rs
@@ -184,30 +184,20 @@ pub extern fn wr_window_new(window_id: W
     gl::load_with(|symbol| get_proc_address(gl_context, symbol));
     gl::clear_color(0.3, 0.0, 0.0, 1.0);
 
     let version = gl::get_string(gl::VERSION);
 
     println!("WebRender - OpenGL version new {}", version);
 
     let opts = RendererOptions {
-        device_pixel_ratio: 1.0,
-        resource_override_path: None,
         enable_aa: false,
-        enable_subpixel_aa: false,
         enable_profiler: enable_profiler,
-        enable_scrollbars: false,
-        precache_shaders: false,
-        renderer_kind: RendererKind::Native,
-        debug: false,
-        clear_framebuffer: true,
-        render_target_debug: false,
-        clear_color: ColorF::new(1.0, 1.0, 1.0, 1.0),
         recorder: recorder,
-        workers: None,
+        .. Default::default()
     };
 
     let (mut renderer, sender) = match Renderer::new(opts) {
         Ok((renderer, sender)) => { (renderer, sender) }
         Err(e) => {
             println!(" Failed to create a Renderer: {:?}", e);
             return false;
         }