From 2871f998ce599a4b1c472dc6559396db27ca041f Mon Sep 17 00:00:00 2001 From: Erik Kundt Date: Tue, 23 Apr 2024 17:44:58 +0200 Subject: [PATCH] issue: Remove on_event and on_update overwrites --- bin/commands/issue/select/ui.rs | 33 +-------------------------------- 1 file changed, 1 insertion(+), 32 deletions(-) diff --git a/bin/commands/issue/select/ui.rs b/bin/commands/issue/select/ui.rs index 719b190c..0d7a647f 100644 --- a/bin/commands/issue/select/ui.rs +++ b/bin/commands/issue/select/ui.rs @@ -25,8 +25,7 @@ use tui::ui::widget::input::{TextField, TextFieldProps, TextFieldState}; use tui::ui::widget::text::{Paragraph, ParagraphProps, ParagraphState}; use tui::ui::widget::{self, BaseView}; use tui::ui::widget::{ - Column, EventCallback, Properties, Shortcuts, ShortcutsProps, Table, TableProps, TableUtils, - UpdateCallback, View, Widget, + Column, Properties, Shortcuts, ShortcutsProps, Table, TableProps, TableUtils, View, Widget, }; use tui::Selection; @@ -200,16 +199,6 @@ where &mut self.base } - fn on_update(mut self, callback: UpdateCallback) -> Self { - self.base.on_update = Some(callback); - self - } - - fn on_event(mut self, callback: EventCallback) -> Self { - self.base.on_event = Some(callback); - self - } - fn update(&mut self, state: &State) { self.props = BrowsePageProps::from_callback(self.base.on_update, state) .unwrap_or(BrowsePageProps::from(state)); @@ -464,16 +453,6 @@ impl View for Search { &mut self.base } - fn on_update(mut self, callback: UpdateCallback) -> Self { - self.base.on_update = Some(callback); - self - } - - fn on_event(mut self, callback: EventCallback) -> Self { - self.base.on_event = Some(callback); - self - } - fn update(&mut self, state: &State) { self.input.update(state); } @@ -622,16 +601,6 @@ where &mut self.base } - fn on_update(mut self, callback: UpdateCallback) -> Self { - self.base.on_update = Some(callback); - self - } - - fn on_event(mut self, callback: EventCallback) -> Self { - self.base.on_event = Some(callback); - self - } - fn update(&mut self, state: &State) { self.props = HelpPageProps::from_callback(self.base.on_update, state) .unwrap_or(HelpPageProps::from(state));