fn key_up(&mut self, screen: &mut Screen) {
        if self.is_cancelling() && self.menu.options.len() > 0 {
            self.cancel = Some(false);
            self.render(screen);
        } else if self.selected > 0 {
            self.selected -= 1;
            if self.selected < self.first_row {
                self.first_row -= 1;
                self.update_last_row(screen.size());
            }
            self.render(screen);
        }
    }
/// Should be triggered when UP key is pressed.
Should be triggered when UP key is pressed.
Should be triggered when UP key is pressed .
fn key_up(&mut self, screen: &mut Screen) {
        if self.is_cancelling() && self.menu.options.len() > 0 {
            self.cancel = Some(false);
            self.render(screen);
        } else if self.selected > 0 {
            self.selected -= 1;
            if self.selected < self.first_row {
                self.first_row -= 1;
                self.update_last_row(screen.size());
            }
            self.render(screen);
        }
    }
fn key_up ( & mut self , screen : & mut Screen ) { if self . is_cancelling ( ) && self . menu . options . len ( ) > 0 { self . cancel = Some ( false ) ; self . render ( screen ) ; } else if self . selected > 0 { self . selected -= 1 ; if self . selected < self . first_row { self . first_row -= 1 ; self . update_last_row ( screen . size ( ) ) ; } self . render ( screen ) ; } }
Should be triggered when UP key is pressed.
Should be triggered when UP key is pressed .
&mut self
screen
&mut Screen
&mut self
screen
&mut Screen