mirror of
https://github.com/servo/servo.git
synced 2025-08-03 12:40:06 +01:00
Auto merge of #18138 - glennw:update-wr-remove-webgl, r=jdm
Update WR (remove internal webgl implementation). <!-- 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/18138) <!-- Reviewable:end -->
This commit is contained in:
commit
0fcbcf7fc5
3 changed files with 29 additions and 52 deletions
|
@ -19,6 +19,6 @@ gleam = "0.4"
|
|||
ipc-channel = "0.8"
|
||||
log = "0.3.5"
|
||||
num-traits = "0.1.32"
|
||||
offscreen_gl_context = { version = "0.11", features = ["serde"] }
|
||||
offscreen_gl_context = { version = "0.11", features = ["serde", "osmesa"] }
|
||||
webrender = {git = "https://github.com/servo/webrender"}
|
||||
webrender_api = {git = "https://github.com/servo/webrender", features = ["ipc"]}
|
||||
|
|
|
@ -327,17 +327,6 @@ impl webrender_api::RenderNotifier for RenderNotifier {
|
|||
}
|
||||
}
|
||||
|
||||
// Used to dispatch functions from webrender to the main thread's event loop.
|
||||
struct CompositorThreadDispatcher {
|
||||
compositor_proxy: CompositorProxy
|
||||
}
|
||||
|
||||
impl webrender_api::RenderDispatcher for CompositorThreadDispatcher {
|
||||
fn dispatch(&self, f: Box<Fn() + Send>) {
|
||||
self.compositor_proxy.send(Msg::Dispatch(f));
|
||||
}
|
||||
}
|
||||
|
||||
impl<Window: WindowMethods> IOCompositor<Window> {
|
||||
fn new(window: Rc<Window>, state: InitialCompositorState)
|
||||
-> IOCompositor<Window> {
|
||||
|
@ -394,15 +383,6 @@ impl<Window: WindowMethods> IOCompositor<Window> {
|
|||
compositor.constellation_chan.clone());
|
||||
compositor.webrender.set_render_notifier(Box::new(render_notifier));
|
||||
|
||||
if cfg!(target_os = "windows") {
|
||||
// Used to dispatch functions from webrender to the main thread's event loop.
|
||||
// Required to allow WGL GLContext sharing in Windows.
|
||||
let dispatcher = Box::new(CompositorThreadDispatcher {
|
||||
compositor_proxy: compositor.channel_to_self.clone_compositor_proxy()
|
||||
});
|
||||
compositor.webrender.set_main_thread_dispatcher(dispatcher);
|
||||
}
|
||||
|
||||
// Set the size of the root layer.
|
||||
compositor.update_zoom_transform();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue