Skip to content

Commit f47f35c

Browse files
rebase: Sway 1.11 (#431)
Co-authored-by: Erik Reider <35975961+ErikReider@users.noreply.github.com>
1 parent 1710f7d commit f47f35c

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

86 files changed

+1020
-705
lines changed

.gitignore

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,6 @@ test/
77
build/
88
build-*/
99
.cache/
10-
!build-scripts
11-
!build-scripts/*
1210
.lvimrc
1311
config-debug
1412
wayland-*-protocol.*

README.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
<img src="assets/swayfx_logo.svg" width="256" alt="swayfx logo">
33
</p>
44

5-
---
65

76
Sway is an incredible window manager, and certainly one of the most well established wayland window managers. However, it is restricted to only include the functionality that existed in i3. This fork ditches the simple wlr_renderer, and replaces it with our fx_renderer, capable of rendering with fancy GLES2 effects. This, along with a couple of minor changes, expands sway's featureset to include the following:
87

common/stringop.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -360,3 +360,8 @@ char *format_str(const char *fmt, ...) {
360360
va_end(args);
361361
return str;
362362
}
363+
364+
bool has_prefix(const char *str, const char *prefix) {
365+
return strncmp(str, prefix, strlen(prefix)) == 0;
366+
}
367+

config.in

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,14 +46,18 @@ output * bg @datadir@/backgrounds/sway/Sway_Wallpaper_Blue_1920x1080.png fill
4646
#
4747
# Example configuration:
4848
#
49-
# input "2:14:SynPS/2_Synaptics_TouchPad" {
49+
# input type:touchpad {
5050
# dwt enabled
5151
# tap enabled
5252
# natural_scroll enabled
5353
# middle_emulation enabled
5454
# }
5555
#
56-
# You can get the names of your inputs by running: swaymsg -t get_inputs
56+
# input type:keyboard {
57+
# xkb_layout "eu"
58+
# }
59+
#
60+
# You can also configure each device individually.
5761
# Read `man 5 sway-input` for more information about this section.
5862

5963
### Key bindings

flake.lock

Lines changed: 6 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

flake.nix

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,10 @@
2525
version = "0.4.0-git";
2626
src = pkgs.lib.cleanSource ./.;
2727
nativeBuildInputs = old.nativeBuildInputs ++ [ pkgs.cmake ];
28-
# Add wlroots_0_18 here
28+
# Add wlroots_0_19 here
2929
buildInputs = old.buildInputs ++ [
3030
pkgs.scenefx
31-
pkgs.wlroots_0_18 # <-- Added this line
31+
pkgs.wlroots_0_19 # <-- Added this line
3232
];
3333
providedSessions = [ pkgs.swayfx-unwrapped.meta.mainProgram ];
3434
patches = []; ## Consider if you need patches from the original derivation
@@ -77,13 +77,13 @@
7777
# Adding wlroots and scenefx explicitly here is fine, but they are also included via inputsFrom
7878
inputsFrom = [
7979
self.packages.${pkgs.system}.swayfx-unwrapped
80-
# pkgs.wlroots_0_18 # Included via swayfx-unwrapped buildInputs now
80+
# pkgs.wlroots_0_19 # Included via swayfx-unwrapped buildInputs now
8181
# pkgs.scenefx # Included via swayfx-unwrapped buildInputs now
8282
];
8383
# You still might want wlroots/scenefx here if you need tools/headers directly in the shell
8484
# outside of what swayfx uses.
8585
buildInputs = [
86-
pkgs.wlroots_0_18
86+
pkgs.wlroots_0_19
8787
pkgs.scenefx
8888
];
8989
packages = with pkgs; [
@@ -96,7 +96,7 @@
9696
echo "Copying wlroots and scenefx sources to ./subprojects for dev environment..."
9797
mkdir -p "$PWD/subprojects" && cd "$PWD/subprojects"
9898
rm -rf wlroots scenefx # Clean previous copies if they exist
99-
cp -R --no-preserve=mode,ownership ${pkgs.wlroots_0_18.src} wlroots
99+
cp -R --no-preserve=mode,ownership ${pkgs.wlroots_0_19.src} wlroots
100100
cp -R --no-preserve=mode,ownership ${pkgs.scenefx.src} scenefx
101101
echo "Done copying sources."
102102
cd "$OLDPWD"

include/stringop.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,4 +40,6 @@ bool expand_path(char **path);
4040
char *vformat_str(const char *fmt, va_list args) _SWAY_ATTRIB_PRINTF(1, 0);
4141
char *format_str(const char *fmt, ...) _SWAY_ATTRIB_PRINTF(1, 2);
4242

43+
bool has_prefix(const char *str, const char *prefix);
44+
4345
#endif

include/sway/config.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
#ifndef _SWAY_CONFIG_H
22
#define _SWAY_CONFIG_H
33
#include <libinput.h>
4-
#include <scenefx/types/fx/blur_data.h>
54
#include <stdint.h>
65
#include <string.h>
76
#include <time.h>

include/sway/criteria.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,9 @@ struct criteria {
5353
char urgent; // 'l' for latest or 'o' for oldest
5454
struct pattern *workspace;
5555
pid_t pid;
56+
struct pattern *sandbox_engine;
57+
struct pattern *sandbox_app_id;
58+
struct pattern *sandbox_instance_id;
5659
};
5760

5861
bool criteria_is_empty(struct criteria *criteria);

include/sway/desktop/idle_inhibit_v1.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ enum sway_idle_inhibit_mode {
1313
struct sway_idle_inhibit_manager_v1 {
1414
struct wlr_idle_inhibit_manager_v1 *wlr_manager;
1515
struct wl_listener new_idle_inhibitor_v1;
16+
struct wl_listener manager_destroy;
1617
struct wl_list inhibitors;
1718
};
1819

0 commit comments

Comments
 (0)