Always prefer text events by default

This improves text input, but it breaks the expected behavior in games
again: <https://github.com/Genymobile/scrcpy/issues/87>.

To get the previous behavior back, pass an explicit option:

    scrcpy --prefer-text-events=non-alpha
This commit is contained in:
Romain Vimont 2019-11-06 23:21:03 +01:00
parent 44791d6b40
commit 532843d856
3 changed files with 4 additions and 4 deletions

View File

@ -69,7 +69,7 @@ Possible \fImode\fRs are "always" (every text is sent as text), "non-alpha"
(only letters are sent as a sequence of key events, other characters are sent
as text) and "never" (every text is sent as a sequence of key events).
Default is "non-alpha".
Default is "always".
.TP
.BI "\-\-push\-target " path

View File

@ -73,10 +73,10 @@ static void usage(const char *arg0) {
" device.\n"
" Possible values are:\n"
" always:\n"
" Every text is sent as text.\n"
" Every text is sent as text. (default)\n"
" non-alpha:\n"
" Only letters are sent as a sequence of key events, other\n"
" characters are sent as text. (default)\n"
" characters are sent as text.\n"
" never:\n"
" Every text is sent as a sequence of key events.\n"
"\n"

View File

@ -35,7 +35,7 @@ struct scrcpy_options {
.window_title = NULL, \
.push_target = NULL, \
.record_format = RECORDER_FORMAT_AUTO, \
.text_events_pref = PREFER_TEXT_EVENTS_NON_ALPHA, \
.text_events_pref = PREFER_TEXT_EVENTS_ALWAYS, \
.port = DEFAULT_LOCAL_PORT, \
.max_size = DEFAULT_LOCAL_PORT, \
.bit_rate = DEFAULT_BIT_RATE, \