Skip to content

Commit fed2365

Browse files
masonry: Remove focus from PointerState
This is unused. It was added to Druid in <linebender/druid#842>. In the `winit` world, this would be done instead by customizing the window creation with `WindowAttributesExtMacOS` and the `with_accepts_first_mouse` function. (So it would no longer be something that you have to check on every mouse click event as it is part of the `WinitView` within `winit`.
1 parent d4e4635 commit fed2365

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

masonry/src/core/event.rs

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -269,10 +269,6 @@ pub struct PointerState {
269269
/// The number of successive clicks registered. This is used to detect e.g. double-clicks.
270270
pub count: u8,
271271

272-
// TODO - Find out why this was added, maybe remove it.
273-
/// Currently unused.
274-
pub focus: bool,
275-
276272
/// The force of a touch event.
277273
pub force: Option<Force>,
278274
}
@@ -444,7 +440,6 @@ impl PointerEvent {
444440
buttons: PointerButtons::default(),
445441
mods: Modifiers::default(),
446442
count: 0,
447-
focus: false,
448443
force: None,
449444
};
450445
Self::PointerLeave(pointer_state)
@@ -553,7 +548,6 @@ impl PointerState {
553548
buttons: PointerButtons::default(),
554549
mods: Modifiers::default(),
555550
count: 0,
556-
focus: false,
557551
force: None,
558552
}
559553
}

0 commit comments

Comments
 (0)