Skip to content

Commit 90e748f

Browse files
masonry_winit: Remove window ID from on_wgpu_ready (linebender#1604)
Per review comment from Daniel, this isn't needed as we move forward, and if it is, we'll have more work to do fix things. In the meantime, having this here results in incorrect assumptions.
1 parent b440edd commit 90e748f

File tree

2 files changed

+3
-6
lines changed

2 files changed

+3
-6
lines changed

masonry_winit/src/app_driver.rs

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -112,11 +112,8 @@ pub trait AppDriver {
112112
ctx.exit();
113113
}
114114

115-
/// Called when Masonry has created a WGPU device.
116-
///
117-
/// This may be called more than once if multiple devices are created (e.g. multiple windows
118-
/// requiring different compatible adapters).
119-
fn on_wgpu_ready(&mut self, _window_id: WindowId, _wgpu: &WgpuContext<'_>) {}
115+
/// Called when Masonry has created its WGPU device.
116+
fn on_wgpu_ready(&mut self, _wgpu: &WgpuContext<'_>) {}
120117
}
121118

122119
impl DriverCtx<'_, '_> {

masonry_winit/src/event_loop_runner.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -663,7 +663,7 @@ impl MasonryState<'_> {
663663
device: &device_handle.device,
664664
queue: &device_handle.queue,
665665
};
666-
app_driver.on_wgpu_ready(window.id, &wgpu);
666+
app_driver.on_wgpu_ready(&wgpu);
667667
}
668668

669669
surface

0 commit comments

Comments
 (0)