core: Fix detection of button events

This commit is contained in:
Toad06 2022-01-24 13:13:34 +01:00 committed by Mike Welsh
parent 3e9f9741ea
commit da50d44460
1 changed files with 1 additions and 1 deletions

View File

@ -286,7 +286,7 @@ impl<'gc> ClipEvent<'gc> {
/// Indicates whether this is an event type used by Buttons (i.e., on that can be used in an `on` handler in Flash).
pub const fn is_button_event(self) -> bool {
if let Some(flag) = self.flag() {
flag.contains(Self::BUTTON_EVENT_FLAGS)
flag.intersects(Self::BUTTON_EVENT_FLAGS)
} else {
false
}