diff --git a/.github/workflows/badges.yml b/.github/workflows/badges.yml index d6dd88f..a3aa072 100644 --- a/.github/workflows/badges.yml +++ b/.github/workflows/badges.yml @@ -14,7 +14,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout Repository - uses: actions/checkout@v2 + uses: actions/checkout@v4 - name: Download cloc run: sudo apt-get update -y && sudo apt-get install -y cloc - name: Get the Numbers diff --git a/.github/workflows/checks.yml b/.github/workflows/checks.yml index 0d853cc..0600eb1 100644 --- a/.github/workflows/checks.yml +++ b/.github/workflows/checks.yml @@ -17,7 +17,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout Repository - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Download Clang-Format run: | sudo apt update -qq @@ -33,7 +33,7 @@ jobs: name: Check Compliance with REUSE Specification runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: REUSE Compliance Check uses: fsfe/reuse-action@v1 @@ -43,12 +43,12 @@ jobs: if: github.event_name == 'pull_request' steps: - name: Checkout Current Repository - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: path: current ref: ${{ github.ref }} - name: Checkout Base Repository - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: path: base ref: ${{ github.base_ref }} @@ -74,7 +74,7 @@ jobs: name: Run ShellCheck runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Run ShellCheck run: | find $GITHUB_WORKSPACE -type f -and \( -name "*.sh" \) | xargs shellcheck @@ -91,26 +91,26 @@ jobs: matrix: version: - "39" - - "rawhide" + - "40" + - "41" session: - "gnome-xsession" - - "gnome-wayland-nested" steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Download Dependencies run: | - sudo apt update -qq - sudo apt install gettext -qq + sudo apt update -q + sudo apt install gettext libglib2.0-dev imagemagick - name: Build Desktop Cube run: make - name: Test Desktop Cube run: sudo $GITHUB_WORKSPACE/tests/run-test.sh -v ${{ matrix.version }} -s ${{ matrix.session }} - - uses: actions/upload-artifact@v2 + - uses: actions/upload-artifact@v4 if: failure() with: name: log_${{ matrix.version }}_${{ matrix.session }} path: fail.log - - uses: actions/upload-artifact@v2 + - uses: actions/upload-artifact@v4 if: failure() with: name: screen_${{ matrix.version }}_${{ matrix.session }} diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 1ddd6c4..850780d 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -14,11 +14,11 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout Repository - uses: actions/checkout@v2 + uses: actions/checkout@v4 - name: Install Dependencies run: | sudo apt-get update -q - sudo apt-get install gettext + sudo apt-get install libglib2.0-dev gettext - name: Create Release run: | make zip diff --git a/docs/changelog.md b/docs/changelog.md index 5439827..269499d 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -5,7 +5,15 @@ SPDX-License-Identifier: CC-BY-4.0 # Changelog of the Desktop Cube Extension -## [Desktop Cube 26](https://github.com/schneegans/Desktop-Cube/releases/tag/v25) +## [Desktop Cube 27](https://github.com/schneegans/Desktop-Cube/releases/tag/v27) + +**Release Date:** TBD + +#### Enhancements + +- Ported the extension to GNOME 48. + +## [Desktop Cube 26](https://github.com/schneegans/Desktop-Cube/releases/tag/v26) **Release Date:** 2024-08-23 diff --git a/metadata.json b/metadata.json index e1f11c8..21f54f9 100644 --- a/metadata.json +++ b/metadata.json @@ -1,19 +1,15 @@ { - "uuid": "desktop-cube@schneegans.github.com", - "description": "Indulge in nostalgia with useless 3D effects.", - "name": "Desktop Cube", - "donations": { - "kofi": "schneegans", - "github": "schneegans", - "paypal": "simonschneegans" - }, - "gettext-domain": "desktop-cube", - "settings-schema": "org.gnome.shell.extensions.desktop-cube", - "shell-version": [ - "45", - "46", - "47" - ], - "url": "https://github.com/Schneegans/Desktop-Cube", - "version": 26 -} \ No newline at end of file + "uuid": "desktop-cube@schneegans.github.com", + "description": "Indulge in nostalgia with useless 3D effects.", + "name": "Desktop Cube", + "donations": { + "kofi": "schneegans", + "github": "schneegans", + "paypal": "simonschneegans" + }, + "gettext-domain": "desktop-cube", + "settings-schema": "org.gnome.shell.extensions.desktop-cube", + "shell-version": ["45", "46", "47", "48"], + "url": "https://github.com/Schneegans/Desktop-Cube", + "version": 27 +} diff --git a/src/Skybox.js b/src/Skybox.js index 022c881..5043cb1 100644 --- a/src/Skybox.js +++ b/src/Skybox.js @@ -17,6 +17,7 @@ import GObject from 'gi://GObject'; import Shell from 'gi://Shell'; import GdkPixbuf from 'gi://GdkPixbuf'; import Cogl from 'gi://Cogl'; +import St from 'gi://St'; import * as Main from 'resource:///org/gnome/shell/ui/main.js'; @@ -66,8 +67,9 @@ var SkyboxEffect = GObject.registerClass({ vfunc_build_pipeline() { // In the vertex shader, we compute the view space position of the actor's corners. - this.add_glsl_snippet(Shell.SnippetHook.VERTEX, 'varying vec4 vsPos;', - 'vsPos = cogl_modelview_matrix * cogl_position_in;', false); + this.add_glsl_snippet( + Cogl.SnippetHook ? Cogl.SnippetHook.VERTEX : Shell.SnippetHook.VERTEX, + 'varying vec4 vsPos;', 'vsPos = cogl_modelview_matrix * cogl_position_in;', false); const fragmentDeclares = ` varying vec4 vsPos; @@ -102,8 +104,9 @@ var SkyboxEffect = GObject.registerClass({ cogl_color_out = texture2D(uTexture, vec2(x, y)); `; - this.add_glsl_snippet(Shell.SnippetHook.FRAGMENT, fragmentDeclares, fragmentCode, - false); + this.add_glsl_snippet( + Cogl.SnippetHook ? Cogl.SnippetHook.FRAGMENT : Shell.SnippetHook.FRAGMENT, + fragmentDeclares, fragmentCode, false); } // For each draw call, we have to set some uniform values. @@ -132,7 +135,7 @@ var SkyboxEffect = GObject.registerClass({ try { const pixbuf = GdkPixbuf.Pixbuf.new_from_stream_finish(result); - const texture = new Clutter.Image(); + const texture = new St.ImageContent(); texture.set_data(pixbuf.get_pixels(), FORMATS[pixbuf.get_n_channels() - 1], pixbuf.get_width(), pixbuf.get_height(), pixbuf.get_rowstride());