Merge pull request #192659 from PaulGrandperrin/vscode-fix-wayland

electron apps: fix wayland window decorations

authored by maxine and committed by GitHub c44d41af 5e2ce525

+14 -14
+1 -1
pkgs/applications/editors/vscode/generic.nix
··· 109 109 gappsWrapperArgs+=( 110 110 # Add gio to PATH so that moving files to the trash works when not using a desktop environment 111 111 --prefix PATH : ${glib.bin}/bin 112 - --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--enable-features=UseOzonePlatform --ozone-platform=wayland}}" 112 + --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" 113 113 --add-flags ${lib.escapeShellArg commandLineArgs} 114 114 ) 115 115 '';
+1 -1
pkgs/applications/misc/whalebird/default.nix
··· 74 74 75 75 makeWrapper ${electron}/bin/electron $out/bin/whalebird \ 76 76 --add-flags $out/opt/Whalebird/resources/app.asar \ 77 - --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--enable-features=UseOzonePlatform --ozone-platform=wayland}}" 77 + --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" 78 78 79 79 runHook postInstall 80 80 '';
+1 -1
pkgs/applications/networking/browsers/brave/default.nix
··· 177 177 ${optionalString (disableFeatures != []) '' 178 178 --add-flags "--disable-features=${strings.concatStringsSep "," disableFeatures}" 179 179 ''} 180 - --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform=wayland}}" 180 + --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" 181 181 ${optionalString vulkanSupport '' 182 182 --prefix XDG_DATA_DIRS : "${addOpenGLRunpath.driverLink}/share" 183 183 --add-flags ${escapeShellArg commandLineArgs}
+1 -1
pkgs/applications/networking/browsers/chromium/default.nix
··· 184 184 mkdir -p "$out/bin" 185 185 186 186 makeWrapper "${browserBinary}" "$out/bin/chromium" \ 187 - --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--enable-features=UseOzonePlatform --ozone-platform=wayland}}" \ 187 + --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" \ 188 188 --add-flags ${escapeShellArg commandLineArgs} 189 189 190 190 ed -v -s "$out/bin/chromium" << EOF
+1 -1
pkgs/applications/networking/browsers/google-chrome/default.nix
··· 148 148 --suffix PATH : "${lib.makeBinPath [ xdg-utils ]}" \ 149 149 --prefix XDG_DATA_DIRS : "$XDG_ICON_DIRS:$GSETTINGS_SCHEMAS_PATH:${addOpenGLRunpath.driverLink}/share" \ 150 150 --set CHROME_WRAPPER "google-chrome-$dist" \ 151 - --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--enable-features=UseOzonePlatform --ozone-platform=wayland}}" \ 151 + --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" \ 152 152 --add-flags ${escapeShellArg commandLineArgs} 153 153 154 154 for elf in $out/share/google/$appname/{chrome,chrome-sandbox,${crashpadHandlerBinary},nacl_helper}; do
+1 -1
pkgs/applications/networking/instant-messengers/discord/linux.nix
··· 83 83 84 84 wrapProgramShell $out/opt/${binaryName}/${binaryName} \ 85 85 "''${gappsWrapperArgs[@]}" \ 86 - --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--enable-features=UseOzonePlatform --ozone-platform=wayland}}" \ 86 + --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" \ 87 87 --prefix XDG_DATA_DIRS : "${gtk3}/share/gsettings-schemas/${gtk3.name}/" \ 88 88 --prefix LD_LIBRARY_PATH : ${libPath}:$out/opt/${binaryName} 89 89
+1 -1
pkgs/applications/networking/instant-messengers/element/element-desktop.nix
··· 99 99 makeWrapper '${electron}/bin/electron' "$out/bin/${executableName}" \ 100 100 --set LD_PRELOAD ${sqlcipher}/lib/libsqlcipher.so \ 101 101 --add-flags "$out/share/element/electron" \ 102 - --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--enable-features=UseOzonePlatform --ozone-platform=wayland}}" 102 + --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" 103 103 104 104 runHook postInstall 105 105 '';
+1 -1
pkgs/applications/networking/instant-messengers/feishu/default.nix
··· 160 160 wrapProgram $executable \ 161 161 --prefix XDG_DATA_DIRS : "$XDG_ICON_DIRS:$GSETTINGS_SCHEMAS_PATH" \ 162 162 --prefix LD_LIBRARY_PATH : ${rpath}:$out/opt/bytedance/feishu:${addOpenGLRunpath.driverLink}/share \ 163 - --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--enable-features=UseOzonePlatform --ozone-platform=wayland}}" \ 163 + --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" \ 164 164 ${lib.optionalString (commandLineArgs!="") "--add-flags ${lib.escapeShellArg commandLineArgs}"} 165 165 done 166 166
+1 -1
pkgs/applications/networking/instant-messengers/jitsi-meet-electron/default.nix
··· 47 47 makeWrapper ${electron}/bin/electron $out/bin/${pname} \ 48 48 --add-flags $out/share/${pname}/resources/app.asar \ 49 49 --prefix LD_LIBRARY_PATH : "${lib.makeLibraryPath [ stdenv.cc.cc xorg.libXtst pipewire ]}" \ 50 - --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--enable-features=UseOzonePlatform --ozone-platform=wayland}}" 50 + --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" 51 51 ''; 52 52 53 53 meta = with lib; {
+1 -1
pkgs/applications/networking/instant-messengers/schildichat/schildichat-desktop.nix
··· 89 89 # executable wrapper 90 90 makeWrapper '${electron}/bin/electron' "$out/bin/${executableName}" \ 91 91 --add-flags "$out/share/element/electron" \ 92 - --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--enable-features=UseOzonePlatform --ozone-platform=wayland}}" 92 + --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" 93 93 94 94 runHook postInstall 95 95 '';
+1 -1
pkgs/applications/networking/instant-messengers/session-desktop/default.nix
··· 50 50 cp -r bin $out/bin 51 51 52 52 wrapProgram $out/bin/session-desktop \ 53 - --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--enable-features=UseOzonePlatform --ozone-platform=wayland}}" 53 + --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" 54 54 55 55 runHook postInstall 56 56 '';
+1 -1
pkgs/applications/networking/instant-messengers/signal-desktop/default.nix
··· 108 108 preFixup = '' 109 109 gappsWrapperArgs+=( 110 110 --prefix LD_LIBRARY_PATH : "${lib.makeLibraryPath [ stdenv.cc.cc ] }" 111 - --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--enable-features=UseOzonePlatform --ozone-platform=wayland}}" 111 + --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" 112 112 --suffix PATH : ${lib.makeBinPath [ xdg-utils ]} 113 113 ) 114 114
+1 -1
pkgs/applications/networking/instant-messengers/slack/default.nix
··· 170 170 makeWrapper $out/lib/slack/slack $out/bin/slack \ 171 171 --prefix XDG_DATA_DIRS : $GSETTINGS_SCHEMAS_PATH \ 172 172 --suffix PATH : ${lib.makeBinPath [xdg-utils]} \ 173 - --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--enable-features=UseOzonePlatform --ozone-platform=wayland}}" 173 + --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" 174 174 175 175 # Fix the desktop link 176 176 substituteInPlace $out/share/applications/slack.desktop \
+1 -1
pkgs/applications/office/micropad/default.nix
··· 62 62 # executable wrapper 63 63 makeWrapper '${electron}/bin/electron' "$out/bin/${executableName}" \ 64 64 --add-flags "$out/share/micropad" \ 65 - --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--enable-features=UseOzonePlatform --ozone-platform=wayland}}" 65 + --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" 66 66 67 67 runHook postInstall 68 68 '';