1
0
mirror of https://github.com/emilk/egui.git synced 2026-08-29 04:40:03 -04:00

simpler hashing

This commit is contained in:
Emil Ernerfeldt
2026-08-04 13:34:59 +02:00
committed by GitHub
parent fab34fc5b8
commit ae472fc1b1

View File

@@ -36,7 +36,7 @@ impl<Theme: StyleProvider<S>, S: WidgetStyle> StyleProvider<S> for ThemeCache<Th
/// save the output for later. /// save the output for later.
fn style(&mut self, modifiers: &StyleArgs<'_>) -> S { fn style(&mut self, modifiers: &StyleArgs<'_>) -> S {
let StyleArgs { classes, state, .. } = modifiers; let StyleArgs { classes, state, .. } = modifiers;
let style_id = Id::new(classes).with(state); let style_id = Id::new((classes, state));
if let Some(style) = self.cache.get_temp::<S>(style_id) { if let Some(style) = self.cache.get_temp::<S>(style_id) {
style style
} else { } else {