2016-01-21 81 views
3

我用反应原生的Android,我想用 “下一个” 选项编辑一堆的TextInput像这里(IOS版本): https://github.com/facebook/react-native/pull/2149#issuecomment-129262565React Native android:如何在按下“actionNext”键盘按钮后选择下一个TextInput?

enter image description here

我想:

<TextInput 
    style = {styles.titleInput} 
    returnKeyType = {"next"} 
    autoFocus = {true} 
    placeholder = "Title" 
    onSubmitEditing={(event) => { 
    this.refs.SecondInput.focus(); 
    }} 
/> 

<TextInput 
ref='SecondInput' 
style = {styles.descriptionInput} 
multiline = {true} 
maxLength = {200} 
placeholder = "Description" /> 

但键盘是关闭和开放,这很烦人。

https://stackoverflow.com/a/4999372/1456487据我了解,在本机Android应用我会用:

android:imeOptions="actionNext" 

有没有办法做到这一点?

回答

相关问题