Skip to content

Commit

Permalink
resolved duplicate import error and mutation variable setting
Browse files Browse the repository at this point in the history
  • Loading branch information
ramyananth committed Apr 22, 2020
1 parent 16664d4 commit ef66961
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions components/script/dom/window.rs
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,6 @@ use crate::task_manager::TaskManager;
use crate::task_source::{TaskSource, TaskSourceName};
use crate::timers::{IsInterval, TimerCallback};
use crate::webdriver_handlers::jsval_to_webdriver;
use crate::dom::promise::Promise;
use crate::dom::imagebitmap::ImageBitmap;
use app_units::Au;
use base64;
Expand Down Expand Up @@ -141,7 +140,7 @@ use style_traits::{CSSPixel, DevicePixel, ParsingMode};
use url::Position;
use webrender_api::units::{DeviceIntPoint, DeviceIntSize, LayoutPixel};
use webrender_api::{DocumentId, ExternalScrollId};
use canvas_state::Fetch_image_data;
use crate::canvas_state::CanvasState;

/// Current state of the window object
#[derive(Clone, Copy, Debug, JSTraceable, MallocSizeOf, PartialEq)]
Expand Down Expand Up @@ -920,11 +919,12 @@ impl WindowMethods for Window {
let (mut image_data, image_size) = image.fetch_image_data(url)
.ok_or(Error::InvalidState)?;
imageBitmap.bitmap_data = image_data;
let mut imageBitmap.origin_clean = image.origin_clean;
let mut imageBitmapOrigin = image.origin_clean;
imageBitmap.origin_clean = imageBitmapOrigin;
p.resolve_native(&());
}
}
p
};
p;
}

// https://html.spec.whatwg.org/multipage/#dom-window
Expand Down

0 comments on commit ef66961

Please sign in to comment.