Search Unity

Question Navigation locked until ESC pressed when selecting TMP Input Field

Discussion in 'UGUI & TextMesh Pro' started by kukurenaiz, Oct 26, 2020.

  1. kukurenaiz

    kukurenaiz

    Joined:
    Sep 12, 2017
    Posts:
    57
    Good day everyone, I'm trying to do a UI navigation with a gamepad, the problem is, whenever I select a TMP Input Field, I'm forced to press ESC to stop typing, and only then I can continue navigating. I'm using the new input system only. A quick example.
    upload_2020-10-26_14-31-11.png
    In order for me to reach the IP input field, starting from the Private Toggle, I need to:
    Down > ESC > Down > ESC > Down
    I would like to just
    Down > Down > Down
    And then submit to start typing.

    What I have tried:
    I tried calling ReleaseSelection() and DeactivateInputField() on the OnSelect Unity Event, but nothing happens. I can structure my UI in a way it would work, I can actually think of multiple solutions, but I feel like I'm missing something, this can't be the intended behavior.
     
    Last edited: Oct 26, 2020
  2. Diablo_492

    Diablo_492

    Joined:
    Apr 8, 2019
    Posts:
    1
  3. kukurenaiz

    kukurenaiz

    Joined:
    Sep 12, 2017
    Posts:
    57
    That would work as a script solution, unfortunately, considering that I would need to overcome the default behavior, not overriding it. My critique is about this inconvenient behavior as the default one, submitting to start typing is just better, but navigating with the Up and Down key, even while typing, is way more natural and common, since they don't affect anything while typing something that doesn't require more than one line. Ended implementing my own Input Field. Thanks for the help.
     
    Last edited: Aug 6, 2021
  4. thiskidcalledtom

    thiskidcalledtom

    Joined:
    Nov 9, 2017
    Posts:
    35
    I'm also having this problem right now, Did you find a way to fix it? or did you end up using your own implimentation
     
  5. kukurenaiz

    kukurenaiz

    Joined:
    Sep 12, 2017
    Posts:
    57
    Dropped unity altogether in the past year, sorry for the delay. My solution was to implement my own input/navigation system, because I wanted to do that anyway. A more simple solution would be to have buttons on top of each Input Field, you would disable the navigation for each Input, so you just navigate through the buttons, when you press the button, you select the underlying Input Field.
     
    thiskidcalledtom likes this.