mirror of
https://codeberg.org/dwl/dwl.git
synced 2024-12-27 03:36:31 +00:00
simplify ROUND macro
This commit is contained in:
parent
128c2926e1
commit
7803022d33
1 changed files with 1 additions and 1 deletions
2
dwl.c
2
dwl.c
|
@ -53,7 +53,7 @@
|
||||||
#define LENGTH(X) (sizeof X / sizeof X[0])
|
#define LENGTH(X) (sizeof X / sizeof X[0])
|
||||||
#define END(A) ((A) + LENGTH(A))
|
#define END(A) ((A) + LENGTH(A))
|
||||||
#define TAGMASK ((1 << LENGTH(tags)) - 1)
|
#define TAGMASK ((1 << LENGTH(tags)) - 1)
|
||||||
#define ROUND(X) ((X)>=0?(long)((X)+0.5):(long)((X)-0.5))
|
#define ROUND(X) ((int)((X)+0.5))
|
||||||
#ifdef XWAYLAND
|
#ifdef XWAYLAND
|
||||||
#define WLR_SURFACE(C) ((C)->type != XDGShell ? (C)->surface.xwayland->surface : (C)->surface.xdg->surface)
|
#define WLR_SURFACE(C) ((C)->type != XDGShell ? (C)->surface.xwayland->surface : (C)->surface.xdg->surface)
|
||||||
#else
|
#else
|
||||||
|
|
Loading…
Reference in a new issue