[UI/UX] Make left button also go back to run history from run info (#5474)

This commit is contained in:
David Yang 2025-03-04 08:40:04 +08:00 committed by GitHub
parent ff4184e23f
commit 6181afc6d2
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -889,7 +889,7 @@ export default class RunInfoUiHandler extends UiHandler {
/** /**
* Takes input from the user to perform a desired action. * Takes input from the user to perform a desired action.
* @param button - Button object to be processed * @param button - Button object to be processed
* Button.CANCEL - removes all containers related to RunInfo and returns the user to Run History * Button.CANCEL, Button.LEFT - removes all containers related to RunInfo and returns the user to Run History
* Button.CYCLE_FORM, Button.CYCLE_SHINY, Button.CYCLE_ABILITY - runs the function buttonCycleOption() * Button.CYCLE_FORM, Button.CYCLE_SHINY, Button.CYCLE_ABILITY - runs the function buttonCycleOption()
*/ */
override processInput(button: Button): boolean { override processInput(button: Button): boolean {
@ -900,6 +900,7 @@ export default class RunInfoUiHandler extends UiHandler {
switch (button) { switch (button) {
case Button.CANCEL: case Button.CANCEL:
case Button.LEFT:
success = true; success = true;
if (this.pageMode === RunInfoUiMode.MAIN) { if (this.pageMode === RunInfoUiMode.MAIN) {
this.runInfoContainer.removeAll(true); this.runInfoContainer.removeAll(true);