pub struct Icon {
pub path: &'static str,
pub bytes: &'static [u8],
}
pub const DESKTOP: &[Icon] = &[
Icon {
path: "32x32.png",
bytes: include_bytes!("../assets/icons/32x32.png"),
},
Icon {
path: "128x128.png",
bytes: include_bytes!("../assets/icons/128x128.png"),
},
Icon {
path: "128x128@2x.png",
bytes: include_bytes!("../assets/icons/128x128@2x.png"),
},
Icon {
path: "icon.png",
bytes: include_bytes!("../assets/icons/icon.png"),
},
Icon {
path: "icon.ico",
bytes: include_bytes!("../assets/icons/icon.ico"),
},
];
pub const ANDROID: &[Icon] = &[
Icon {
path: "android/mipmap-anydpi-v26/ic_launcher.xml",
bytes: include_bytes!("../assets/icons/android/mipmap-anydpi-v26/ic_launcher.xml"),
},
Icon {
path: "android/values/ic_launcher_background.xml",
bytes: include_bytes!("../assets/icons/android/values/ic_launcher_background.xml"),
},
Icon {
path: "android/mipmap-mdpi/ic_launcher.png",
bytes: include_bytes!("../assets/icons/android/mipmap-mdpi/ic_launcher.png"),
},
Icon {
path: "android/mipmap-mdpi/ic_launcher_round.png",
bytes: include_bytes!("../assets/icons/android/mipmap-mdpi/ic_launcher_round.png"),
},
Icon {
path: "android/mipmap-mdpi/ic_launcher_foreground.png",
bytes: include_bytes!("../assets/icons/android/mipmap-mdpi/ic_launcher_foreground.png"),
},
Icon {
path: "android/mipmap-hdpi/ic_launcher.png",
bytes: include_bytes!("../assets/icons/android/mipmap-hdpi/ic_launcher.png"),
},
Icon {
path: "android/mipmap-hdpi/ic_launcher_round.png",
bytes: include_bytes!("../assets/icons/android/mipmap-hdpi/ic_launcher_round.png"),
},
Icon {
path: "android/mipmap-hdpi/ic_launcher_foreground.png",
bytes: include_bytes!("../assets/icons/android/mipmap-hdpi/ic_launcher_foreground.png"),
},
Icon {
path: "android/mipmap-xhdpi/ic_launcher.png",
bytes: include_bytes!("../assets/icons/android/mipmap-xhdpi/ic_launcher.png"),
},
Icon {
path: "android/mipmap-xhdpi/ic_launcher_round.png",
bytes: include_bytes!("../assets/icons/android/mipmap-xhdpi/ic_launcher_round.png"),
},
Icon {
path: "android/mipmap-xhdpi/ic_launcher_foreground.png",
bytes: include_bytes!("../assets/icons/android/mipmap-xhdpi/ic_launcher_foreground.png"),
},
Icon {
path: "android/mipmap-xxhdpi/ic_launcher.png",
bytes: include_bytes!("../assets/icons/android/mipmap-xxhdpi/ic_launcher.png"),
},
Icon {
path: "android/mipmap-xxhdpi/ic_launcher_round.png",
bytes: include_bytes!("../assets/icons/android/mipmap-xxhdpi/ic_launcher_round.png"),
},
Icon {
path: "android/mipmap-xxhdpi/ic_launcher_foreground.png",
bytes: include_bytes!("../assets/icons/android/mipmap-xxhdpi/ic_launcher_foreground.png"),
},
Icon {
path: "android/mipmap-xxxhdpi/ic_launcher.png",
bytes: include_bytes!("../assets/icons/android/mipmap-xxxhdpi/ic_launcher.png"),
},
Icon {
path: "android/mipmap-xxxhdpi/ic_launcher_round.png",
bytes: include_bytes!("../assets/icons/android/mipmap-xxxhdpi/ic_launcher_round.png"),
},
Icon {
path: "android/mipmap-xxxhdpi/ic_launcher_foreground.png",
bytes: include_bytes!("../assets/icons/android/mipmap-xxxhdpi/ic_launcher_foreground.png"),
},
];
pub fn all() -> impl Iterator<Item = &'static Icon> {
DESKTOP.iter().chain(ANDROID.iter())
}
#[cfg(test)]
#[path = "tests/icons.rs"]
mod tests;