mirror of
https://github.com/swaywm/sway.git
synced 2025-11-08 13:29:50 -05:00
Add new_output_config, update root container size on output hotplug
This commit is contained in:
parent
41dd291612
commit
8764dc26c6
4 changed files with 9 additions and 6 deletions
|
|
@ -27,11 +27,10 @@ struct cmd_results *cmd_output(int argc, char **argv) {
|
|||
}
|
||||
const char *name = argv[0];
|
||||
|
||||
struct output_config *output = calloc(1, sizeof(struct output_config));
|
||||
struct output_config *output = new_output_config();
|
||||
if (!output) {
|
||||
return cmd_results_new(CMD_FAILURE, "output", "Unable to allocate output config");
|
||||
}
|
||||
output_config_defaults(output);
|
||||
output->name = strdup(name);
|
||||
|
||||
// TODO: atoi doesn't handle invalid numbers
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue