Skip to content

Commit

Permalink
Always prefer text events by default
Browse files Browse the repository at this point in the history
This improves text input, but it breaks the expected behavior in games
again: <#87>.

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

    scrcpy --prefer-text-events=non-alpha
  • Loading branch information
rom1v committed Nov 6, 2019
1 parent 44791d6 commit 532843d
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion app/scrcpy.1
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
4 changes: 2 additions & 2 deletions app/src/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand Down
2 changes: 1 addition & 1 deletion app/src/scrcpy.h
Original file line number Diff line number Diff line change
Expand Up @@ -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, \
Expand Down

0 comments on commit 532843d

Please sign in to comment.