Remove redundant check in ModifiersState::matches
This commit is contained in:
parent
18f016cba7
commit
31aaf207d6
@ -20,10 +20,10 @@ impl ModifiersState {
|
||||
///
|
||||
/// [`ModifiersState`]: struct.ModifiersState.html
|
||||
pub fn matches(&self, modifiers: ModifiersState) -> bool {
|
||||
let shift = !modifiers.shift || modifiers.shift && self.shift;
|
||||
let control = !modifiers.control || modifiers.control && self.control;
|
||||
let alt = !modifiers.alt || modifiers.alt && self.alt;
|
||||
let logo = !modifiers.logo || modifiers.logo && self.logo;
|
||||
let shift = !modifiers.shift || self.shift;
|
||||
let control = !modifiers.control || self.control;
|
||||
let alt = !modifiers.alt || self.alt;
|
||||
let logo = !modifiers.logo || self.logo;
|
||||
|
||||
shift && control && alt && logo
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user