diff options
author | 2015-08-16 13:07:43 -0400 | |
---|---|---|
committer | 2015-08-16 13:07:43 -0400 | |
commit | e64e61779e70c80875e3a8e00ad041265f50787d (patch) | |
tree | e7c21763fde8e7400406d7d2e9db956817e821aa /sway | |
parent | Remove WLC_IDLE_TIME environment variable (diff) | |
download | sway-e64e61779e70c80875e3a8e00ad041265f50787d.tar.gz sway-e64e61779e70c80875e3a8e00ad041265f50787d.tar.zst sway-e64e61779e70c80875e3a8e00ad041265f50787d.zip |
Set C_OUTPUT name to name from wlc
Diffstat (limited to 'sway')
-rw-r--r-- | sway/container.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sway/container.c b/sway/container.c index 98941b2c..1f9b250f 100644 --- a/sway/container.c +++ b/sway/container.c | |||
@@ -45,11 +45,15 @@ static void add_output_widths(swayc_t *container, void *_width) { | |||
45 | swayc_t *new_output(wlc_handle handle) { | 45 | swayc_t *new_output(wlc_handle handle) { |
46 | sway_log(L_DEBUG, "Added output %d", handle); | 46 | sway_log(L_DEBUG, "Added output %d", handle); |
47 | const struct wlc_size* size = wlc_output_get_resolution(handle); | 47 | const struct wlc_size* size = wlc_output_get_resolution(handle); |
48 | const char *name = wlc_output_get_name(handle); | ||
48 | 49 | ||
49 | swayc_t *output = new_swayc(C_OUTPUT); | 50 | swayc_t *output = new_swayc(C_OUTPUT); |
50 | output->width = size->w; | 51 | output->width = size->w; |
51 | output->height = size->h; | 52 | output->height = size->h; |
52 | output->handle = handle; | 53 | output->handle = handle; |
54 | if (name) { | ||
55 | output->name = strdup(name); | ||
56 | } | ||
53 | 57 | ||
54 | add_child(&root_container, output); | 58 | add_child(&root_container, output); |
55 | 59 | ||