Author Topic: Problem with UIInput Input event  (Read 2793 times)

TillR

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 1
    • View Profile
Problem with UIInput Input event
« on: February 13, 2013, 10:10:58 AM »
Hi, I am using the UIInput for a player name field in a unity game (Windows PC) and have a problem dealing with the deselection of the field using Enter - In some cases, if the Enter button is pressed fastly, OnInput() works correctly but right afterwards a selection event is triggering OnSelect(), causing the field to stay selected.
Yielding for one or several frame at OnInput() unfortunately does not solve the problem.
EDIT: The solution for iPhone applications provided at http://www.tasharen.com/forum/index.php?topic=621.msg3598#msg3598 apparently does not work when adapted to Windows games.

Is there a workaround existing?

I'm using NGUI 2.2.3.
« Last Edit: February 13, 2013, 12:06:28 PM by TillRiemer »

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Problem with UIInput Input event
« Reply #1 on: February 13, 2013, 01:38:40 PM »
1. Update your NGUI to the latest. I can't support older versions.
2. Check what I do with the chat window example. I set a flag that will ignore the next Enter press.