summaryrefslogtreecommitdiff
path: root/common/util.c
AgeCommit message (Collapse)AuthorLines
2018-08-26Remove layout.cRyan Dwyer-0/+21
When we have type safety we'll need to have functions for workspace_add_tiling and so on. This means the existing container functions will be just for containers, so they are being moved to container.c. At this point layout.c doesn't contain much else, so I've relocated everything and removed the file. * container_swap and its static functions have been moved to the swap command and made static. * container_recursive_resize has been moved to the resize command and made static. * The following have been moved to container.c: * container_handle_fullscreen_reparent * container_insert_child * container_add_sibling * container_add_child * container_remove_child * container_replace_child * container_split * enum movement_direction and sway_dir_to_wlr have been moved to util.c. Side note: Several commands included layout.h which then included root.h. With layout.h gone, root.h has to be included by those commands.
2018-07-23Address review comments on parse_booleanBrian Ashworth-8/+9
2018-07-23Remove unneeded constBrian Ashworth-1/+1
2018-07-23Switch to using a function to parse booleansBrian Ashworth-0/+15
2018-07-09Update for swaywm/wlroots#1126emersion-1/+1
2018-07-02get_parent_pid: fix memory leakDominique Martinet-1/+1
Found through static analysis.
2018-01-05sway: change all sway_log to wlr_logDominique Martinet-1/+1
2017-11-23common/util: replace WLC_BIT_MOD_* by WLR_MODIFIER_*Dominique Martinet-11/+11
This removes the last wlc/wlc.h include actually in use
2017-06-06FreeBSD fixesjohalun-1/+1
Increase _POSIX_SOURCE value where needed. Increase _XOPEN_SOURCE value where needed. Conditionally link to libcap (only on Linux). Possibly some trailing whitespace fixes (automatic).
2017-05-11Replace spaces with tabs in resolve_pathMykyta Holubakha-33/+33
2017-04-16Add resolve_path() to utilsJerzi Kaminsky-0/+41
2017-03-10UnGNUify the codebaseDrew DeVault-0/+1
2017-02-21Feature for #1078: Configurable swaylock colorsCalvin Lee-3/+7
Colors are configured through the command line so that swaylock conforms to the i3lock fork 'github.com/chrjguill/i3lock-color'. Differences from it are that one letter options '-r' and '-s' are not implimentend because '-s' is already used by '--scaling' in swaylock. This commit also fixed whitespace in 'include/swaylock/swaylock.h' and changed `parse_color` in 'common/util.h' so that it can accept colors that do not start with a hash. This was done to keep compatability with the i3lock fork.
2016-09-01Reorganize includesDrew DeVault-2/+5
2016-08-04common: use strtoul in parse_color to avoid clampprogandy-1/+1
Some implementations of strtol may clamp the values to LONG_MAX instead of wrapping around to negative values, so use strtoul instead to parse colors.
2016-07-30implement solid color rendering for swaybgZandr Martin-0/+13
2016-06-11couple small fixesZandr Martin-8/+12
2016-06-11cleanup + add timeouts for pid_workspace listZandr Martin-18/+10
2016-06-10semi-working (only non-client/server wayland apps)Zandr Martin-1/+38
2016-01-24numlen(0) == 1Mikkel Oscar Lyderik-1/+1
2016-01-24use log10 in numlenMikkel Oscar Lyderik-7/+6
2016-01-23Revert "s/numlen/log10/g"Drew DeVault-0/+10
This reverts commit 038bb8cc7c4dee77f8ee4ba3ac1ffc47409b2370.
2016-01-23s/numlen/log10/gDrew DeVault-10/+0
2016-01-08Add function for getting list of modifier names.Mikkel Oscar Lyderik-0/+14
Get an array of modifier names from modifier masks.
2016-01-05Move modifier name table to common/util.cMikkel Oscar Lyderik-0/+38
Lookup of modifier names is required in several places, thus it makes sense to move it to a general place.
2015-12-14Move sway/util.c to common/util.cMikkel Oscar Lyderik-0/+15