Skip to content

Commit

Permalink
Bug 1556597 - Fix warnings in webrender_bindings in nightly rust. r=G…
Browse files Browse the repository at this point in the history
…ankro

Depends on D33782

Differential Revision: https://phabricator.services.mozilla.com/D33783

--HG--
extra : moz-landing-system : lando
  • Loading branch information
staktrace committed Jun 5, 2019
1 parent 8d93d33 commit be43915
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions gfx/webrender_bindings/src/bindings.rs
Expand Up @@ -577,7 +577,7 @@ extern "C" {
}

impl RenderNotifier for CppNotifier {
fn clone(&self) -> Box<RenderNotifier> {
fn clone(&self) -> Box<dyn RenderNotifier> {
Box::new(CppNotifier {
window_id: self.window_id,
})
Expand Down Expand Up @@ -1167,7 +1167,7 @@ pub extern "C" fn wr_window_new(window_id: WrWindowId,
-> bool {
assert!(unsafe { is_in_render_thread() });

let recorder: Option<Box<ApiRecordingReceiver>> = if unsafe { gfx_use_wrench() } {
let recorder: Option<Box<dyn ApiRecordingReceiver>> = if unsafe { gfx_use_wrench() } {
let name = format!("wr-record-{}.bin", window_id.0);
Some(Box::new(BinaryRecorder::new(&PathBuf::from(name))))
} else {
Expand Down
8 changes: 4 additions & 4 deletions gfx/webrender_bindings/src/moz2d_renderer.rs
Expand Up @@ -590,7 +590,7 @@ impl BlobImageHandler for Moz2dBlobImageHandler {
self.blob_commands.remove(&key);
}

fn create_blob_rasterizer(&mut self) -> Box<AsyncBlobImageRasterizer> {
fn create_blob_rasterizer(&mut self) -> Box<dyn AsyncBlobImageRasterizer> {
Box::new(Moz2dBlobRasterizer {
workers: Arc::clone(&self.workers),
blob_commands: self.blob_commands.clone(),
Expand All @@ -611,7 +611,7 @@ impl BlobImageHandler for Moz2dBlobImageHandler {

fn prepare_resources(
&mut self,
resources: &BlobImageResources,
resources: &dyn BlobImageResources,
requests: &[BlobImageParams]
) {
for params in requests {
Expand Down Expand Up @@ -655,7 +655,7 @@ impl Moz2dBlobImageHandler {
/// Does early preprocessing of a blob's resources.
///
/// Currently just sets up fonts found in the blob.
fn prepare_request(&self, blob: &[u8], resources: &BlobImageResources) {
fn prepare_request(&self, blob: &[u8], resources: &dyn BlobImageResources) {
#[cfg(target_os = "windows")]
fn process_native_font_handle(key: FontKey, handle: &NativeFontHandle) {
let file = dwrote::FontFile::new_from_path(&handle.path).unwrap();
Expand All @@ -676,7 +676,7 @@ impl Moz2dBlobImageHandler {

fn process_fonts(
mut extra_data: BufReader,
resources: &BlobImageResources,
resources: &dyn BlobImageResources,
unscaled_fonts: &mut Vec<FontKey>,
scaled_fonts: &mut Vec<FontInstanceKey>,
) {
Expand Down

0 comments on commit be43915

Please sign in to comment.