diff options
author | bors-servo <lbergstrom+bors@mozilla.com> | 2020-02-06 13:27:29 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-02-06 13:27:29 -0500 |
commit | c67b3d71e23f10ba2049bdd9aed822b19ed8527f (patch) | |
tree | 12ea008cfd24d348b3c6a1a0bb857b78f1826f28 /components/canvas_traits/lib.rs | |
parent | 5ef30c67334739c52fd3e82c21ff39e058a16fe5 (diff) | |
parent | a4ba33376a86775c4bef43fec8f8301a6a3fa113 (diff) | |
download | servo-c67b3d71e23f10ba2049bdd9aed822b19ed8527f.tar.gz servo-c67b3d71e23f10ba2049bdd9aed822b19ed8527f.zip |
Auto merge of #25694 - kunalmohan:24891-Constellation, r=Manishearth
Remove dependency of constellation on canvas
move `ConstellationCanvasMsg` to canvas_traits and start canvas paint thread
to components/servo. This, however, does not remove dependency for conditional
compilation options.
https://github.com/servo/servo/blob/5f55cd5d71df9c555fbc24777168396ddd539f28/components/constellation/Cargo.toml#L13-L15
<!-- Please describe your changes on the following line: -->
---
<!-- 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 #24891 (GitHub issue number if applicable)
<!-- Either: -->
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because ___
<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->
<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->
Diffstat (limited to 'components/canvas_traits/lib.rs')
-rw-r--r-- | components/canvas_traits/lib.rs | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/components/canvas_traits/lib.rs b/components/canvas_traits/lib.rs index c19ca073658..d7d893b2b32 100644 --- a/components/canvas_traits/lib.rs +++ b/components/canvas_traits/lib.rs @@ -6,6 +6,10 @@ #![crate_type = "rlib"] #![deny(unsafe_code)] +use crate::canvas::CanvasId; +use crossbeam_channel::Sender; +use euclid::default::Size2D; + #[macro_use] extern crate lazy_static; #[macro_use] @@ -17,3 +21,13 @@ pub mod canvas; #[macro_use] pub mod webgl; mod webgl_channel; + +pub enum ConstellationCanvasMsg { + Create { + id_sender: Sender<CanvasId>, + size: Size2D<u64>, + webrender_sender: webrender_api::RenderApiSender, + antialias: bool, + }, + Exit, +} |