mirror of https://github.com/FreeRDP/FreeRDP
Merge pull request #10567 from akallabeth/client-common-improve
[client,common] extended parser
This commit is contained in:
commit
fbd9aae501
|
@ -278,6 +278,16 @@ out_error:
|
|||
|
||||
int freerdp_client_settings_parse_command_line(rdpSettings* settings, int argc, char** argv,
|
||||
BOOL allowUnknown)
|
||||
|
||||
{
|
||||
return freerdp_client_settings_parse_command_line_ex(settings, argc, argv, allowUnknown, NULL,
|
||||
0, NULL, NULL);
|
||||
}
|
||||
|
||||
int freerdp_client_settings_parse_command_line_ex(
|
||||
rdpSettings* settings, int argc, char** argv, BOOL allowUnknown, COMMAND_LINE_ARGUMENT_A* args,
|
||||
size_t count, int (*handle_option)(const COMMAND_LINE_ARGUMENT* arg, void* custom),
|
||||
void* handle_userdata)
|
||||
{
|
||||
int status = 0;
|
||||
|
||||
|
@ -287,8 +297,8 @@ int freerdp_client_settings_parse_command_line(rdpSettings* settings, int argc,
|
|||
if (!argv)
|
||||
return -1;
|
||||
|
||||
status =
|
||||
freerdp_client_settings_parse_command_line_arguments(settings, argc, argv, allowUnknown);
|
||||
status = freerdp_client_settings_parse_command_line_arguments_ex(
|
||||
settings, argc, argv, allowUnknown, args, count, handle_option, handle_userdata);
|
||||
|
||||
if (status < 0)
|
||||
return status;
|
||||
|
|
|
@ -20,6 +20,8 @@
|
|||
#ifndef FREERDP_CLIENT_H
|
||||
#define FREERDP_CLIENT_H
|
||||
|
||||
#include <winpr/cmdline.h>
|
||||
|
||||
#include <freerdp/config.h>
|
||||
#include <freerdp/api.h>
|
||||
#include <freerdp/types.h>
|
||||
|
@ -152,6 +154,12 @@ extern "C"
|
|||
FREERDP_API int freerdp_client_settings_parse_command_line(rdpSettings* settings, int argc,
|
||||
char** argv, BOOL allowUnknown);
|
||||
|
||||
FREERDP_API int freerdp_client_settings_parse_command_line_ex(
|
||||
rdpSettings* settings, int argc, char** argv, BOOL allowUnknown,
|
||||
COMMAND_LINE_ARGUMENT_A* args, size_t count,
|
||||
int (*handle_option)(const COMMAND_LINE_ARGUMENT* arg, void* custom),
|
||||
void* handle_userdata);
|
||||
|
||||
FREERDP_API int freerdp_client_settings_parse_connection_file(rdpSettings* settings,
|
||||
const char* filename);
|
||||
FREERDP_API int freerdp_client_settings_parse_connection_file_buffer(rdpSettings* settings,
|
||||
|
|
|
@ -30,6 +30,8 @@ extern "C"
|
|||
{
|
||||
#endif
|
||||
|
||||
FREERDP_API const char* rdpgfx_caps_version_str(UINT32 capsVersion);
|
||||
|
||||
FREERDP_API const char* rdpgfx_get_cmd_id_string(UINT16 cmdId);
|
||||
|
||||
FREERDP_API const char* rdpgfx_get_codec_id_string(UINT16 codecId);
|
||||
|
|
|
@ -1941,3 +1941,34 @@ void gdi_graphics_pipeline_uninit(rdpGdi* gdi, RdpgfxClientContext* gfx)
|
|||
PROFILER_PRINT_FOOTER
|
||||
PROFILER_FREE(gfx->SurfaceProfiler)
|
||||
}
|
||||
|
||||
const char* rdpgfx_caps_version_str(UINT32 capsVersion)
|
||||
{
|
||||
switch (capsVersion)
|
||||
{
|
||||
case RDPGFX_CAPVERSION_8:
|
||||
return "RDPGFX_CAPVERSION_8";
|
||||
case RDPGFX_CAPVERSION_81:
|
||||
return "RDPGFX_CAPVERSION_81";
|
||||
case RDPGFX_CAPVERSION_10:
|
||||
return "RDPGFX_CAPVERSION_10";
|
||||
case RDPGFX_CAPVERSION_101:
|
||||
return "RDPGFX_CAPVERSION_101";
|
||||
case RDPGFX_CAPVERSION_102:
|
||||
return "RDPGFX_CAPVERSION_102";
|
||||
case RDPGFX_CAPVERSION_103:
|
||||
return "RDPGFX_CAPVERSION_103";
|
||||
case RDPGFX_CAPVERSION_104:
|
||||
return "RDPGFX_CAPVERSION_104";
|
||||
case RDPGFX_CAPVERSION_105:
|
||||
return "RDPGFX_CAPVERSION_105";
|
||||
case RDPGFX_CAPVERSION_106:
|
||||
return "RDPGFX_CAPVERSION_106";
|
||||
case RDPGFX_CAPVERSION_106_ERR:
|
||||
return "RDPGFX_CAPVERSION_106_ERR";
|
||||
case RDPGFX_CAPVERSION_107:
|
||||
return "RDPGFX_CAPVERSION_107";
|
||||
default:
|
||||
return "RDPGFX_CAPVERSION_UNKNOWN";
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue