asset_container/assets/
flags.rs

1#![allow(clippy::same_name_method)]
2
3bitflags::bitflags! {
4  #[derive(Debug, Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash)]
5  pub struct AssetFlags: u32 {
6      const Lazy = 0b00000001;
7      const NoFetch = 0b00000010;
8  }
9}
10
11impl PartialEq<u32> for AssetFlags {
12  fn eq(&self, other: &u32) -> bool {
13    self.bits() == *other
14  }
15}
16
17impl PartialEq<AssetFlags> for u32 {
18  fn eq(&self, other: &AssetFlags) -> bool {
19    other.bits() == *self
20  }
21}