Merge remote-tracking branch 'origin/GP-1217-dragonmacher-menu-exception'

This commit is contained in:
Ryan Kurtz
2021-08-19 11:07:06 -04:00

View File

@@ -169,6 +169,9 @@ abstract class MenuKeyHandler {
}
int itemCount = getItemCount(popup);
if (itemCount == 0) {
return -1;
}
// handle wrapping around to the top again
int updatedOffset = offset >= itemCount ? offset % itemCount : offset;