[RFC] BigBanana: mouseless navigation

Well… maybe I’ve mixed things.
The fundamental problem that bigbanana is trying to solve is:

  • provide a mouseless and keyboardless navigation
  • provide API for developers and GUI for users for configurable mappings

Therefore, there must be a default activate and back. Besides, Xinput has brought some unification, but I digress.
I also think that “start” should be part of navigation because… well you usually press “start” before playing.
But is up to the game developer to make use of them.

I’ve updated the sources

which include a sample app

Any comment is welcome! :slight_smile:

But it’s not navigating… it’s starting. So I think the it’s up to something above the focus management. As I said, “activate” was kind of already crossing the line and now I’m kind of regretting putting it there since it is also not about focus navigation.

Yes not strictly focus management, but If is used on the menu, to me is not yet game-specific. However, I think you are suggesting me to provide another layer of input group, so that we have

the Lemur navigation
the BigBanana navigation
the game-specific input

All of these will then be mapped on a file and can be changed on a gui.

For some reasons, my library works even without this fix.

Also this fix causes an exception when navigating beyond the limits

java.lang.StackOverflowError
at com.simsilica.lemur.component.SpringGridLayout.getChildren(SpringGridLayout.java:418)
at com.simsilica.lemur.core.FocusTraversalAdapter$ChildIterator.(FocusTraversalAdapter.java:175)
at com.simsilica.lemur.core.FocusTraversalAdapter.getNext(FocusTraversalAdapter.java:140)
at com.simsilica.lemur.core.FocusTraversalAdapter.getRelativeFocus(FocusTraversalAdapter.java:111)
at com.simsilica.lemur.core.GuiControl.getRelativeFocus(GuiControl.java:231)
at com.simsilica.lemur.focus.FocusNavigationState.requestChangeFocus(FocusNavigationState.java:99)

Was there more stack trace than that? Usually for a stack overflow, I expect it to start to repeat at some point.

Indeed it does

java.lang.StackOverflowError
at com.simsilica.lemur.component.SpringGridLayout.getChildren(SpringGridLayout.java:418)
at com.simsilica.lemur.core.FocusTraversalAdapter$ChildIterator.(FocusTraversalAdapter.java:175)
at com.simsilica.lemur.core.FocusTraversalAdapter.getNext(FocusTraversalAdapter.java:140)
at com.simsilica.lemur.core.FocusTraversalAdapter.getRelativeFocus(FocusTraversalAdapter.java:111)
at com.simsilica.lemur.core.GuiControl.getRelativeFocus(GuiControl.java:231)
at com.simsilica.lemur.focus.FocusNavigationState.requestChangeFocus(FocusNavigationState.java:99)
at com.simsilica.lemur.focus.FocusNavigationState.requestChangeFocus(FocusNavigationState.java:106)
at com.simsilica.lemur.focus.FocusNavigationState.requestChangeFocus(FocusNavigationState.java:106)
at com.simsilica.lemur.focus.FocusNavigationState.requestChangeFocus(FocusNavigationState.java:106)
at com.simsilica.lemur.focus.FocusNavigationState.requestChangeFocus(FocusNavigationState.java:106)
at com.simsilica.lemur.focus.FocusNavigationState.requestChangeFocus(FocusNavigationState.java:106)
at com.simsilica.lemur.focus.FocusNavigationState.requestChangeFocus(FocusNavigationState.java:106)

Last line is repeated many times

1 Like