summaryrefslogtreecommitdiffstats
path: root/sway/output.c
diff options
context:
space:
mode:
authorLibravatar Drew DeVault <sir@cmpwn.com>2016-07-29 07:35:43 -0400
committerLibravatar Drew DeVault <sir@cmpwn.com>2016-07-29 07:35:43 -0400
commit966127222439620233c27ab835062f6cc69e23ea (patch)
tree7e233c68e7063b7c0c7857a73111e95141fb5b44 /sway/output.c
parentMerge pull request #802 from acrisci/feature/timestamp-log-messages (diff)
parentUpdate IPC JSON responses for HiDPI setups (diff)
downloadsway-0.9-rc2.tar.gz
sway-0.9-rc2.tar.zst
sway-0.9-rc2.zip
Merge remote-tracking branch 'origin/hidpi'0.9-rc2
Diffstat (limited to 'sway/output.c')
-rw-r--r--sway/output.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/sway/output.c b/sway/output.c
index d56a2f30..97b8a4a6 100644
--- a/sway/output.c
+++ b/sway/output.c
@@ -5,6 +5,13 @@
5#include "log.h" 5#include "log.h"
6#include "list.h" 6#include "list.h"
7 7
8void output_get_scaled_size(wlc_handle handle, struct wlc_size *size) {
9 *size = *wlc_output_get_resolution(handle);
10 uint32_t scale = wlc_output_get_scale(handle);
11 size->w /= scale;
12 size->h /= scale;
13}
14
8swayc_t *output_by_name(const char* name, const struct wlc_point *abs_pos) { 15swayc_t *output_by_name(const char* name, const struct wlc_point *abs_pos) {
9 if (strcasecmp(name, "left") == 0) { 16 if (strcasecmp(name, "left") == 0) {
10 return swayc_adjacent_output(NULL, MOVE_LEFT, abs_pos, true); 17 return swayc_adjacent_output(NULL, MOVE_LEFT, abs_pos, true);