aboutsummaryrefslogtreecommitdiff
path: root/swaybar
AgeCommit message (Collapse)Author
2019-02-28tray: fix pixmap colorsIan Fan
by converting from network byte order to host byte order
2019-02-24swaybar: add overlay mode (fix #1620)Milkey Mouse
Overlay mode puts the bar above normal windows and passes through/ignores any touch/mouse/keyboard events that would be sent to it.
2019-02-23swaybar: cycle workspaces on touch dragDrew DeVault
2019-02-23swaybar: process hotspots on touch tapDrew DeVault
2019-02-16tray: fix memory leaksIan Fan
2019-02-16tray: when a service is lost, remove all matching itemsIan Fan
Before, only the first matching item would be removed, which could leave stale items.
2019-02-15tray: use correct parameter to set bus slot to floatingIan Fan
Counter-intuitively, `sd_bus_slot_set_floating` expects 0 to set it to floating.
2019-02-15swaybar: prevent signal handler from firing during terminationIan Fan
This prevents a heap-use-after-free crash when sway terminates.
2019-02-03Merge pull request #3551 from c-edw/RevertDoubleFreesDrew DeVault
Revert double frees.
2019-02-01Fix #3445: swaybar tray inerited thems not processedStefan Schick
2019-02-01Revert "More frees."Connor E
This reverts commit eda1bf769f239a9e8d5a9907255a330e3113a649.
2019-02-01Revert "Add some missing frees."Connor E
This reverts commit b5d95f264d5b08f6228e05be680ee36fc06ca6d6.
2019-01-31Rebase #1636 against current masterv44r
2019-01-23Make json-c include respect pkg-config --cflagsJan Beich
json-c.pc contains `Cflags: -I${includedir}/json-c`, so `<json-c/json.h>` won't be found unless the parent directory is searched by default.
2019-01-23Merge pull request #3500 from progandy/validate_pixmapsDrew DeVault
swaybar: fix crash with some tray icon pixmaps
2019-01-23Fix tray icon updatesLukas Lihotzki
Apparently, IconThemePath needs to be reread on NewIcon signal. This fixes tray icon updates in electron apps with libappindicator-gtk3.
2019-01-23swaybar: fix crash with some tray icon pixmapsprogandy
Discard pixmaps for icons where width and height are 0 or not equal. Fixes #3487
2019-01-22swaybar: fix command malloc in workspace commandBrian Ashworth
This fixes a typo on the malloc line in ipc_send_workspace_command. The plus one to the size for the null-terminator was outside of the malloc call, which was causing the incorrect pointer to be freed later in the function.
2019-01-22swaybar: fix workspace commandIan Fan
Escape quotes and backslashes, allowing switching to workspace names like "1" (including quotes) and \
2019-01-22Fix dead stores found by scan-buildM Stoeckl
In addition to removing unused code, two minor problems are fixed: (1) `resize set` and `resize adjust` did not error when given too many arguments. (2) `orientation` was incorrectly overridden to be 'U' for scroll events in the swaybar tray `handle_click` function.
2019-01-22util.c: remove numlen functionIan Fan
Its uses have been replaced by snprintf, which is more in line with its usage.
2019-01-21Removed unused wlroots dependency for sway(bg|bar|msg|nag)M Stoeckl
Also remove direct libm dependency where unused.
2019-01-21swaybar: fix setting floating watcher slotsIan Fan
2019-01-21Replace wlr_log with sway_logM Stoeckl
This commit mostly duplicates the wlr_log functions, although with a sway_* prefix. (This is very similar to PR #2009.) However, the logging function no longer needs to be replaceable, so sway_log_init's second argument is used to set the exit callback for sway_abort. wlr_log_init is still invoked in sway/main.c This commit makes it easier to remove the wlroots dependency for the helper programs swaymsg, swaybg, swaybar, and swaynag.
2019-01-19Fix memory leaks in swaybarM Stoeckl
2019-01-18meson: remove rpath optionsemersion
2019-01-17Use Meson feature optionsemersion
2019-01-16Fixes for small existing bugs.Connor E
2019-01-16Remove usage of VLAs.Connor E
2019-01-16bar_cmd_tray_bind: Use mouse button helpersBrian Ashworth
This modifies `bar_cmd_tray_bindsym` to use `get_mouse_bindsym` for parsing mouse buttons. This also introduces `bar_cmd_tray_bindcode`, which will use `get_mouse_bindcode` for parsing mouse buttons. Like with sway bindings, the two commands are encapsulated in a single file to maximize shared code. This also modifies tray bindings to work off of events codes rather than x11 buttons, which allows for any mouse buttons to be used. For `get_bar_config`, `event_code` has been added to the `tray_bindings` section and will include to event code for the button. If the event code can be mapped to a x11 button, `input_code` will still be the x11 button number. Otherwise, `input_code` will be `0`.
2019-01-13Merge pull request #3344 from RedSoxFan/bar-mouse-bindings-improvedDrew DeVault
Improve mouse button parsing: bar mouse bindings
2019-01-13Merge pull request #3397 from RedSoxFan/fix-swaybar-heightDrew DeVault
swaybar: obey height if given
2019-01-13Merge pull request #3408 from RedSoxFan/bar-paddingDrew DeVault
swaybar: adjustable status padding
2019-01-13swaybar: allow identifiers for output and trayBrian Ashworth
This allows `bar output` and `bar tray_output` to specify an output identifier. Output names should still work as well. This parses the output identifier from the xdg_output description, which wlroots currently sets to `make model serial (name)`. Since this could change in the future, all identifier comparisons are guarded by NULL-checks in case the description cannot be parsed to an identifier.
2019-01-11swaybar: add status_edge_padding commandBrian Ashworth
This adds the bar subcommand `status_edge_padding <padding>` to set the padding used when the status line is on the right edge of the bar.
2019-01-11swaybar: add status_padding commandBrian Ashworth
Adds the bar subcommand `status_padding <padding>` which allows setting the padding used for swaybar. If `status_padding` is set to `0`, blocks will be able to take up the full height of the bar.
2019-01-10bar_cmd_bind: utilize mouse button helpersBrian Ashworth
This modifies `bar_cmd_bindsym` to use `get_mouse_bindsym` for parsing mouse buttons. This also introduces `cmd_bar_bindcode`, which will use `get_mouse_bindcode` for parsing mouse buttons. Like sway bindings, the two commands are encapsulated in a single file with shared code. This also modifies swaybar to operate off of event codes rather than x11 button numbers, which allows for any mouse button to be used. This introduces two new IPC properties: - For `get_bar_config`, `event_code` has been added to the `bindings` section and will include to event code for the button. If the event code can be mapped to a x11 button, `input_code` will still be the x11 button number. Otherwise, `input_code` will be `0`. - Likewise for `click_events`, `event` has been added and will include the event code for the button clicked. If the event code can be mapped to a x11 button, `button` will still be the x11 button number. Otherwise, `button` will be `0`.
2019-01-09swaybar: obey height if givenBrian Ashworth
If there is a bar height given, use that as the height rather than as a minimum height. This matches i3-gaps behavior.
2019-01-09swaybar: fix rendering of border and backgroundBrian Ashworth
This fixes the rendering of borders and backgrounds for blocks. This also makes the following changes: * both borders and padding are scaled with the output * both lines and rectangles are rendered without an antialiasing to avoid bleeding outside the desired area
2019-01-09Simplify evdev includes on FreeBSD by relying on up-to-date packageJan Beich
evdev-proto is installed by a dependency, so some files have been missed: In file included from ../sway/input/cursor.c:3: /usr/local/include/libevdev-1.0/libevdev/libevdev.h:30:10: fatal error: 'linux/input.h' file not found #include <linux/input.h> ^~~~~~~~~~~~~~~ ../swaybar/i3bar.c:3:10: fatal error: 'linux/input-event-codes.h' file not found #include <linux/input-event-codes.h> ^~~~~~~~~~~~~~~~~~~~~~~~~~~
2019-01-08swaybar: improve tray loggingIan Fan
2019-01-08swaybar: handle SNI signals betterIan Fan
This fixes a crash caused by callbacks not matching the right sender, and frees old values later, before they are re-assigned.
2019-01-08swaybar: free the right item during tray destructionIan Fan
Also added a comment to make more obvious the reason for comparing sni->status[0] == 'N'
2019-01-01Remove readline.cIan Fan
All occurrences of read_line have been replaced by getline. peek_line has been absorbed into detect_brace.
2018-12-31swaybar: use KDE's SNI IconThemePath propertyIan Fan
2018-12-31swaybar: handle new and lost StatusNotifierWatcherIan Fan
2018-12-31swaybar: draw a sad face if SNI has no iconIan Fan
2018-12-31swaybar: do not create tray if hiddenIan Fan
2018-12-31swaybar: set bar dirty on SNI eventIan Fan
2018-12-31swaybar: implement mouse events for trayIan Fan