Showing the changes to input (3 of 3 files). Show all
Unified · Split
| @@ -316,7 +316,7 @@ error: · 315 unmodified lines | |||
| 316 | return NULL; | 316 | return NULL; |
| 317 | } | 317 | } |
| 318 | 318 | ||
| 319 | mp_cmd_t *mp_input_parse_cmd_(struct mp_log *log, bstr str, const char *loc) | 319 | mp_cmd_t *mp_input_parse_cmd_str(struct mp_log *log, bstr str, const char *loc) |
| 320 | { | 320 | { |
| 321 | void *tmp = talloc_new(NULL); | 321 | void *tmp = talloc_new(NULL); |
| 322 | bstr original = str; | 322 | bstr original = str; |
| @@ -124,7 +124,8 @@ void mp_print_cmd_list(struct mp_log *out); · 123 unmodified lines | |||
| 124 | 124 | ||
| 125 | // Parse text and return corresponding struct mp_cmd. | 125 | // Parse text and return corresponding struct mp_cmd. |
| 126 | // The location parameter is for error messages. | 126 | // The location parameter is for error messages. |
| 127 | struct mp_cmd *mp_input_parse_cmd_(struct mp_log *log, bstr str, const char *loc); | 127 | struct mp_cmd *mp_input_parse_cmd_str(struct mp_log *log, bstr str, |
| 128 | const char *loc); | ||
| 128 | 129 | ||
| 129 | // Similar to mp_input_parse_cmd(), but takes a list of strings instead. | 130 | // Similar to mp_input_parse_cmd(), but takes a list of strings instead. |
| 130 | // Also, MP_ON_OSD_AUTO | MP_EXPAND_PROPERTIES are not set by default. | 131 | // Also, MP_ON_OSD_AUTO | MP_EXPAND_PROPERTIES are not set by default. |
| @@ -1450,7 +1450,7 @@ bool mp_input_use_media_keys(struct input_ctx *ictx) · 1449 unmodified lines | |||
| 1450 | struct mp_cmd *mp_input_parse_cmd(struct input_ctx *ictx, bstr str, | 1450 | struct mp_cmd *mp_input_parse_cmd(struct input_ctx *ictx, bstr str, |
| 1451 | const char *location) | 1451 | const char *location) |
| 1452 | { | 1452 | { |
| 1453 | return mp_input_parse_cmd_(ictx->log, str, location); | 1453 | return mp_input_parse_cmd_str(ictx->log, str, location); |
| 1454 | } | 1454 | } |
| 1455 | 1455 | ||
| 1456 | void mp_input_run_cmd(struct input_ctx *ictx, const char **cmd) | 1456 | void mp_input_run_cmd(struct input_ctx *ictx, const char **cmd) |
| @@ -1603,7 +1603,7 @@ void mp_input_src_feed_cmd_text(struct mp_input_src *src, char *buf, size_t len) · 146 unmodified lines | |||
| 1603 | if (term) { | 1603 | if (term) { |
| 1604 | bstr s = {in->cmd_buffer, in->cmd_buffer_size}; | 1604 | bstr s = {in->cmd_buffer, in->cmd_buffer_size}; |
| 1605 | s = bstr_strip(s); | 1605 | s = bstr_strip(s); |
| 1606 | struct mp_cmd *cmd= mp_input_parse_cmd_(src->log, s, "<>"); | 1606 | struct mp_cmd *cmd = mp_input_parse_cmd_str(src->log, s, "<>"); |
| 1607 | if (cmd) | 1607 | if (cmd) |
| 1608 | mp_input_queue_cmd(src->input_ctx, cmd); | 1608 | mp_input_queue_cmd(src->input_ctx, cmd); |
| 1609 | in->cmd_buffer_size = 0; | 1609 | in->cmd_buffer_size = 0; |