Remove redundant mutability

This commit is contained in:
Dr. Dystopia 2021-06-14 19:22:47 +02:00
parent 4c3d59ab98
commit cfb92ad7d8

View File

@ -122,7 +122,7 @@ impl<'a> Widget for Buttons<'a> {
#[allow(clippy::unused_unit)] // TODO: Pending review in #587 #[allow(clippy::unused_unit)] // TODO: Pending review in #587
fn style(&self) -> Self::Style { () } fn style(&self) -> Self::Style { () }
fn update(mut self, args: widget::UpdateArgs<Self>) -> Self::Event { fn update(self, args: widget::UpdateArgs<Self>) -> Self::Event {
let widget::UpdateArgs { state, ui, .. } = args; let widget::UpdateArgs { state, ui, .. } = args;
let invs = self.client.inventories(); let invs = self.client.inventories();
let inventory = match invs.get(self.client.entity()) { let inventory = match invs.get(self.client.entity()) {
@ -429,7 +429,7 @@ impl<'a> Widget for Buttons<'a> {
} }
impl<'a> Buttons<'a> { impl<'a> Buttons<'a> {
fn create_button_tooltip(&mut self, ui: &mut UiCell) -> Tooltip<'a> { fn create_button_tooltip(&self, ui: &mut UiCell) -> Tooltip<'a> {
Tooltip::new({ Tooltip::new({
// Edge images [t, b, r, l] // Edge images [t, b, r, l]
// Corner images [tr, tl, br, bl] // Corner images [tr, tl, br, bl]