提交 31585e0d 编写于 作者: 5 5u3it 提交者: Chris Bracken

Native keyboard behavior update for multiline input (#4234)

Use sentence capitalization for non-obscuretext fields of TextInputType.text
and TextInputType.multiline on iOS and Android.
上级 ca2a9ce4
......@@ -98,8 +98,11 @@ public class TextInputPlugin implements MethodCallHandler {
// Note: both required. Some devices ignore TYPE_TEXT_FLAG_NO_SUGGESTIONS.
textType |= InputType.TYPE_TEXT_FLAG_NO_SUGGESTIONS;
textType |= InputType.TYPE_TEXT_VARIATION_PASSWORD;
} else if (autocorrect) {
} else {
if (autocorrect)
textType |= InputType.TYPE_TEXT_FLAG_AUTO_CORRECT;
if (inputType.equals("TextInputType.text") || inputType.equals("TextInputType.multiline"))
textType |= InputType.TYPE_TEXT_FLAG_CAP_SENTENCES;
}
return textType;
}
......
......@@ -34,6 +34,8 @@ static UIReturnKeyType ToUIReturnKeyType(NSString* inputType) {
static UITextAutocapitalizationType ToUITextAutocapitalizationType(NSString* inputType) {
if ([inputType isEqualToString:@"TextInputType.text"])
return UITextAutocapitalizationTypeSentences;
if ([inputType isEqualToString:@"TextInputType.multiline"])
return UITextAutocapitalizationTypeSentences;
return UITextAutocapitalizationTypeNone;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册