mirror of
https://github.com/emilk/egui.git
synced 2026-08-31 22:00: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:
@@ -41,7 +41,7 @@ impl FractalClock {
|
||||
pub fn ui(&mut self, ui: &mut Ui, seconds_since_midnight: Option<f64>) {
|
||||
if !self.paused {
|
||||
self.time = seconds_since_midnight.unwrap_or_else(|| ui.input(|i| i.time));
|
||||
ui.ctx().request_repaint();
|
||||
ui.request_repaint();
|
||||
}
|
||||
|
||||
let painter = Painter::new(
|
||||
|
||||
@@ -195,7 +195,7 @@ fn ui_resource(ui: &mut egui::Ui, resource: &Resource) {
|
||||
if let Some(text) = &text {
|
||||
let tooltip = "Click to copy the response body";
|
||||
if ui.button("📋").on_hover_text(tooltip).clicked() {
|
||||
ui.ctx().copy_text(text.clone());
|
||||
ui.copy_text(text.clone());
|
||||
}
|
||||
ui.separator();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user