refactor: clarify content and tui ownership

This commit is contained in:
objz committed 2026-07-27 11:03:46 +02:00
1 parent 078afe4b9d
commit 15d76c18a0
32 files changed
+893 -1144

No files matched your search

+11
View File
@@ -27,6 +27,17 @@ impl ContentKind {
Self::Shader => "shaderpacks",
}
}
pub fn unavailable_message(self, loader: crate::instance::ModLoader) -> Option<&'static str> {
if loader != crate::instance::ModLoader::Vanilla {
return None;
}
match self {
Self::Mod => Some("Vanilla does not support mods."),
Self::Shader => Some("Vanilla does not support shaders."),
Self::ResourcePack => None,
}
}
}
#[derive(Debug, Clone, PartialEq, Eq, Serialize, Deserialize)]