From bf0ee18f55dd63e327fcea14968c957a9bcf731b Mon Sep 17 00:00:00 2001 From: Ralf Zerres Date: Fri, 3 Jul 2020 01:04:21 +0200 Subject: [PATCH] callbacks: global_state: compiler sanitization * use unspecific lifetimes Signed-off-by: Ralf Zerres --- advotracker/src/callbacks/global_state.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/advotracker/src/callbacks/global_state.rs b/advotracker/src/callbacks/global_state.rs index cc4ab84..ffb9733 100644 --- a/advotracker/src/callbacks/global_state.rs +++ b/advotracker/src/callbacks/global_state.rs @@ -16,7 +16,7 @@ use orbtk::prelude::*; /// Provides generic methods to handle states of datatypes (e.g. used in `PolicyList`). pub trait GlobalState { /// Navigates to the given entity. - fn navigate(&self, to: Entity, ctx: &mut Context) { + fn navigate(&self, to: Entity, ctx: &mut Context<'_>) { if let Some(old_focused_element) = ctx.window().get::("global").focused_widget { let mut old_focused_element = ctx.get_widget(old_focused_element); old_focused_element.set("focused", false); @@ -28,7 +28,7 @@ pub trait GlobalState { } /// Get the text of a widget. - fn get_text(&self, ctx: &mut Context, entity: Entity) -> Option { + fn get_text(&self, ctx: &mut Context<'_>, entity: Entity) -> Option { let mut widget = ctx.get_widget(entity); let entry = widget.get_mut::("text");