Skip to content

Commit

Permalink
Auto merge of #15016 - prampey:doc-deactivate, r=cbrewster
Browse files Browse the repository at this point in the history
Documents now fully deactivate when a freeze message is sent

<!-- Please describe your changes on the following line: -->
Documents now fully deactivate when a freeze message is sent

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #14906  (github issue number if applicable).

<!-- Either: -->
- [ ] There are tests for these changes OR
- [X] These changes do not require tests because minimal changes.

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/15016)
<!-- Reviewable:end -->
  • Loading branch information
bors-servo committed Jan 13, 2017
2 parents a46e630 + 584f72d commit 2fb9a34
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions components/script/script_thread.rs
Expand Up @@ -1354,9 +1354,10 @@ impl ScriptThread {

/// Handles freeze message
fn handle_freeze_msg(&self, id: PipelineId) {
let window = self.documents.borrow().find_window(id);
if let Some(window) = window {
window.freeze();
let document = self.documents.borrow().find_document(id);
if let Some(document) = document {
document.window().freeze();
document.fully_deactivate();
return;
}
let mut loads = self.incomplete_loads.borrow_mut();
Expand Down

0 comments on commit 2fb9a34

Please sign in to comment.