diff options
author | webbeef <me@webbeef.org> | 2025-03-23 11:52:46 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-03-23 18:52:46 +0000 |
commit | 1c9f486f88b23b575317ee0b2462e26fba07c5f4 (patch) | |
tree | 17274d9605e8ea494623bafe6755ce5cccaaf245 /components/shared/script/script_msg.rs | |
parent | 4814cbdb1f09e97be70f7c72defee19e67fff473 (diff) | |
download | servo-1c9f486f88b23b575317ee0b2462e26fba07c5f4.tar.gz servo-1c9f486f88b23b575317ee0b2462e26fba07c5f4.zip |
webgpu: leverage routed_promise in calls returning promises (#35859)
Using the RoutedPromiseListener let us define a different
response type for each promise. This removes unreachable branches
that used to exist when they all shared the same WebGPUResponse.
Signed-off-by: webbeef <me@webbeef.org>
Diffstat (limited to 'components/shared/script/script_msg.rs')
-rw-r--r-- | components/shared/script/script_msg.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/components/shared/script/script_msg.rs b/components/shared/script/script_msg.rs index f67a7d0ac07..33ebb496dc7 100644 --- a/components/shared/script/script_msg.rs +++ b/components/shared/script/script_msg.rs @@ -24,7 +24,7 @@ use servo_url::{ImmutableOrigin, ServoUrl}; use strum_macros::IntoStaticStr; use style_traits::CSSPixel; #[cfg(feature = "webgpu")] -use webgpu::{WebGPU, WebGPUResponse, wgc}; +use webgpu::{WebGPU, WebGPUAdapterResponse, wgc}; use webrender_api::ImageKey; use crate::mem::MemoryReportResult; @@ -204,7 +204,7 @@ pub enum ScriptMsg { #[cfg(feature = "webgpu")] /// Create a WebGPU Adapter instance RequestAdapter( - IpcSender<WebGPUResponse>, + IpcSender<WebGPUAdapterResponse>, wgc::instance::RequestAdapterOptions, wgc::id::AdapterId, ), |