Stop tracking pressed_modifiers in PaneGrid

This commit is contained in:
Héctor Ramón Jiménez 2020-07-09 05:28:19 +02:00
parent e3cd947437
commit 2334c7d1d5
2 changed files with 0 additions and 8 deletions

View file

@ -88,7 +88,6 @@ use crate::{
#[allow(missing_debug_implementations)] #[allow(missing_debug_implementations)]
pub struct PaneGrid<'a, Message, Renderer: self::Renderer> { pub struct PaneGrid<'a, Message, Renderer: self::Renderer> {
state: &'a mut state::Internal, state: &'a mut state::Internal,
pressed_modifiers: &'a mut keyboard::ModifiersState,
elements: Vec<(Pane, Content<'a, Message, Renderer>)>, elements: Vec<(Pane, Content<'a, Message, Renderer>)>,
width: Length, width: Length,
height: Length, height: Length,
@ -143,7 +142,6 @@ where
Self { Self {
state: &mut state.internal, state: &mut state.internal,
pressed_modifiers: &mut state.modifiers,
elements, elements,
width: Length::Fill, width: Length::Fill,
height: Length::Fill, height: Length::Fill,
@ -558,9 +556,6 @@ where
} }
} }
} }
keyboard::Event::ModifiersChanged(modifiers) => {
*self.pressed_modifiers = modifiers;
}
_ => {} _ => {}
} }
} }

View file

@ -1,5 +1,4 @@
use crate::{ use crate::{
keyboard,
pane_grid::{Axis, Configuration, Direction, Node, Pane, Split}, pane_grid::{Axis, Configuration, Direction, Node, Pane, Split},
Hasher, Point, Rectangle, Size, Hasher, Point, Rectangle, Size,
}; };
@ -25,7 +24,6 @@ use std::collections::HashMap;
pub struct State<T> { pub struct State<T> {
pub(super) panes: HashMap<Pane, T>, pub(super) panes: HashMap<Pane, T>,
pub(super) internal: Internal, pub(super) internal: Internal,
pub(super) modifiers: keyboard::ModifiersState,
} }
/// The current focus of a [`Pane`]. /// The current focus of a [`Pane`].
@ -76,7 +74,6 @@ impl<T> State<T> {
last_id, last_id,
action: Action::Idle { focus: None }, action: Action::Idle { focus: None },
}, },
modifiers: keyboard::ModifiersState::default(),
} }
} }