mirror of
https://github.com/Genymobile/scrcpy.git
synced 2026-04-21 01:33:36 +00:00
Add --list-displays
Add an option to list the device displays properly.
This commit is contained in:
parent
2596ca02f0
commit
b65301f672
14 changed files with 69 additions and 28 deletions
|
|
@ -303,6 +303,9 @@ execute_server(struct sc_server *server,
|
|||
if (params->list_encoders) {
|
||||
ADD_PARAM("list_encoders=true");
|
||||
}
|
||||
if (params->list_displays) {
|
||||
ADD_PARAM("list_displays=true");
|
||||
}
|
||||
|
||||
#undef ADD_PARAM
|
||||
|
||||
|
|
@ -856,9 +859,9 @@ run_server(void *data) {
|
|||
goto error_connection_failed;
|
||||
}
|
||||
|
||||
// If --list-encoders is passed, then the server just prints the encoders
|
||||
// If --list-* is passed, then the server just prints the requested data
|
||||
// then exits.
|
||||
if (params->list_encoders) {
|
||||
if (params->list_encoders || params->list_displays) {
|
||||
sc_pid pid = execute_server(server, params);
|
||||
if (pid == SC_PROCESS_NONE) {
|
||||
goto error_connection_failed;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue