mirror of
https://github.com/zed-industries/zed.git
synced 2025-01-16 15:11:25 +00:00
Set cursor style only if we're the active window (#3607)
Release Notes: - N/A
This commit is contained in:
commit
c0846d6f74
1 changed files with 6 additions and 1 deletions
|
@ -1314,12 +1314,17 @@ impl<'a> WindowContext<'a> {
|
|||
mem::swap(&mut window.rendered_frame, &mut window.next_frame);
|
||||
|
||||
let scene = self.window.rendered_frame.scene_builder.build();
|
||||
|
||||
// Set the cursor only if we're the active window.
|
||||
let cursor_style = self
|
||||
.window
|
||||
.requested_cursor_style
|
||||
.take()
|
||||
.unwrap_or(CursorStyle::Arrow);
|
||||
if self.is_window_active() {
|
||||
self.platform.set_cursor_style(cursor_style);
|
||||
}
|
||||
|
||||
self.window.dirty = false;
|
||||
|
||||
scene
|
||||
|
|
Loading…
Reference in a new issue