diff options
author | Patrick Walton <pcwalton@mimiga.net> | 2015-03-18 13:18:12 -0700 |
---|---|---|
committer | Patrick Walton <pcwalton@mimiga.net> | 2015-03-20 10:09:52 -0700 |
commit | 2c22467d530bce33f65c348b7136d44b4c65cdc0 (patch) | |
tree | 606527f36d14094a437a1a1c90886364a7bef2b0 /components/script/script_task.rs | |
parent | fda3791487abeee9f910d8476632eeebe69c3685 (diff) | |
download | servo-2c22467d530bce33f65c348b7136d44b4c65cdc0.tar.gz servo-2c22467d530bce33f65c348b7136d44b4c65cdc0.zip |
script: Stop rebuilding every flow in the document when an image
finishes loading.
Diffstat (limited to 'components/script/script_task.rs')
-rw-r--r-- | components/script/script_task.rs | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/components/script/script_task.rs b/components/script/script_task.rs index ce4dd123d00..80441a60c9b 100644 --- a/components/script/script_task.rs +++ b/components/script/script_task.rs @@ -1212,7 +1212,11 @@ impl ScriptTask { fn handle_reflow_event(&self, pipeline_id: PipelineId) { debug!("script got reflow event"); let page = get_page(&self.root_page(), pipeline_id); - self.force_reflow(&*page, ReflowReason::ReceivedReflowEvent); + let document = page.document().root(); + let window = window_from_node(document.r()).root(); + window.r().reflow(ReflowGoal::ForDisplay, + ReflowQueryType::NoQuery, + ReflowReason::ReceivedReflowEvent); } /// Initiate a non-blocking fetch for a specified resource. Stores the InProgressLoad |