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

Replace ui.ctx().foo with ui.foo in a few places (#7774)

Internal code cleanup after
* https://github.com/emilk/egui/pull/7770
This commit is contained in:
Emil Ernerfeldt
2025-12-14 17:12:10 +01:00
committed by GitHub
parent 453e34b4df
commit bfaf1b44f2
53 changed files with 108 additions and 128 deletions

View File

@@ -143,7 +143,7 @@ pub fn global_theme_preference_switch(ui: &mut Ui) {
/// Show larger buttons for switching between light and dark mode (globally).
pub fn global_theme_preference_buttons(ui: &mut Ui) {
let mut theme_preference = ui.ctx().options(|opt| opt.theme_preference);
let mut theme_preference = ui.options(|opt| opt.theme_preference);
theme_preference.radio_buttons(ui);
ui.ctx().set_theme(theme_preference);
}