Search Unity

  1. Get all the Unite Berlin 2018 news on the blog.
    Dismiss Notice
  2. Unity 2018.2 has arrived! Read about it here.
    Dismiss Notice
  3. Improve your Unity skills with a certified instructor in a private, interactive classroom. Learn more.
    Dismiss Notice
  4. ARCore is out of developer preview! Read about it here.
    Dismiss Notice
  5. Magic Leap’s Lumin SDK Technical Preview for Unity lets you get started creating content for Magic Leap One™. Find more information on our blog!
    Dismiss Notice
  6. Want to see the most recent patch releases? Take a peek at the patch release page.
    Dismiss Notice

Help!!! Texfield opened by TouchScreenKeyboard() is not display

Discussion in 'Extensions & OnGUI' started by MilC, May 14, 2015.

  1. MilC

    MilC

    Joined:
    May 28, 2013
    Posts:
    1
    Usually call TouchScreenKeyboard() to show input UI(include keyboard, textfield, and buttons), as following diagram:


    however, After the third party’s UI display and native keyboard is called, then go back to the game login UI and call the TouchScreenKeyboard() method, the textfield is not show, as follow:

    Any idea on what the issue is? Any help will be greatly appreciated..
     

    Attached Files:

  2. LiuLie

    LiuLie

    Joined:
    May 29, 2015
    Posts:
    2
    Hi,
    I found the same problem on IOS(Unity 4.6.5 p4 il2cpp) after using the 3rd party's SDK..
     
  3. dayong

    dayong

    Joined:
    Nov 27, 2013
    Posts:
    1
    I fixed this bug by change a line in Keyboard.mm

    Code (CSharp):
    1. diff -uNr a/Classes/UI/Keyboard.mm b/Classes/UI/Keyboard.mm
    2. --- a/Classes/UI/Keyboard.mm    2015-07-16 17:34:58.000000000 +0800
    3. +++ b/Classes/UI/Keyboard.mm    2015-08-03 10:05:50.000000000 +0800
    4. @@ -254,8 +254,8 @@
    5.          unsigned statusHeight = statusFrame.size.height;
    6.          fieldToolbar.frame    = CGRectMake(0, y - kInputBarSize - statusHeight, kbRect.size.width, kInputBarSize);
    7. -        textField.frame    = CGRectMake(inputView.frame.origin.x, inputView.frame.origin.y,
    8. -                                     kbRect.size.width - 3*18 - 2*50, inputView.frame.size.height
    9. +        textField.frame    = CGRectMake(textField.frame.origin.x, textField.frame.origin.y,
    10. +                                     kbRect.size.width - 3*18 - 2*50, textField.frame.size.height
    11.                                       );
    12.      }
    13.  
     
  4. swanky_wu

    swanky_wu

    Joined:
    Oct 17, 2015
    Posts:
    1
    @dayong works for me! like +1