mirror of
https://github.com/swaywm/sway.git
synced 2025-11-06 13:29:50 -05:00
Update for swaywm/wlroots#1126
This commit is contained in:
parent
ebcdce457a
commit
63b4bf5000
85 changed files with 391 additions and 385 deletions
|
|
@ -163,7 +163,7 @@ struct cmd_handler *find_handler(char *line, struct cmd_handler *cmd_handlers,
|
|||
int handlers_size) {
|
||||
struct cmd_handler d = { .command=line };
|
||||
struct cmd_handler *res = NULL;
|
||||
wlr_log(L_DEBUG, "find_handler(%s)", line);
|
||||
wlr_log(WLR_DEBUG, "find_handler(%s)", line);
|
||||
|
||||
bool config_loading = config->reading || !config->active;
|
||||
|
||||
|
|
@ -248,10 +248,10 @@ struct cmd_results *execute_command(char *_exec, struct sway_seat *seat) {
|
|||
cmd = argsep(&cmdlist, ",");
|
||||
cmd += strspn(cmd, whitespace);
|
||||
if (strcmp(cmd, "") == 0) {
|
||||
wlr_log(L_INFO, "Ignoring empty command.");
|
||||
wlr_log(WLR_INFO, "Ignoring empty command.");
|
||||
continue;
|
||||
}
|
||||
wlr_log(L_INFO, "Handling command '%s'", cmd);
|
||||
wlr_log(WLR_INFO, "Handling command '%s'", cmd);
|
||||
//TODO better handling of argv
|
||||
int argc;
|
||||
char **argv = split_args(cmd, &argc);
|
||||
|
|
@ -355,7 +355,7 @@ struct cmd_results *config_command(char *exec) {
|
|||
results = cmd_results_new(CMD_BLOCK_END, NULL, NULL);
|
||||
goto cleanup;
|
||||
}
|
||||
wlr_log(L_INFO, "handling config command '%s'", exec);
|
||||
wlr_log(WLR_INFO, "handling config command '%s'", exec);
|
||||
struct cmd_handler *handler = find_handler(argv[0], NULL, 0);
|
||||
if (!handler) {
|
||||
char *input = argv[0] ? argv[0] : "(empty)";
|
||||
|
|
@ -388,7 +388,7 @@ cleanup:
|
|||
struct cmd_results *config_subcommand(char **argv, int argc,
|
||||
struct cmd_handler *handlers, size_t handlers_size) {
|
||||
char *command = join_args(argv, argc);
|
||||
wlr_log(L_DEBUG, "Subcommand: %s", command);
|
||||
wlr_log(WLR_DEBUG, "Subcommand: %s", command);
|
||||
free(command);
|
||||
|
||||
struct cmd_handler *handler = find_handler(argv[0], handlers,
|
||||
|
|
@ -479,7 +479,7 @@ struct cmd_results *config_commands_command(char *exec) {
|
|||
}
|
||||
policy->context = context;
|
||||
|
||||
wlr_log(L_INFO, "Set command policy for %s to %d",
|
||||
wlr_log(WLR_INFO, "Set command policy for %s to %d",
|
||||
policy->command, policy->context);
|
||||
|
||||
results = cmd_results_new(CMD_SUCCESS, NULL, NULL);
|
||||
|
|
@ -493,7 +493,7 @@ struct cmd_results *cmd_results_new(enum cmd_status status,
|
|||
const char *input, const char *format, ...) {
|
||||
struct cmd_results *results = malloc(sizeof(struct cmd_results));
|
||||
if (!results) {
|
||||
wlr_log(L_ERROR, "Unable to allocate command results");
|
||||
wlr_log(WLR_ERROR, "Unable to allocate command results");
|
||||
return NULL;
|
||||
}
|
||||
results->status = status;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue