Skip to content
This repository was archived by the owner on Jul 23, 2024. It is now read-only.

Commit f234ac3

Browse files
authored
Merge branch 'main' into refactor-shell
2 parents da37b65 + 2751d85 commit f234ac3

File tree

6 files changed

+22
-17
lines changed

6 files changed

+22
-17
lines changed

build-aux/flatpak/com.github.GradienceTeam.Gradience.Devel.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,8 @@
5050
"sources": [
5151
{
5252
"type": "archive",
53-
"url": "https://github.com/lxml/lxml/releases/download/lxml-4.9.2/lxml-4.9.2.tar.gz",
54-
"sha256": "d3fe33ffef3637e053cce7aa0bf26ad0943911c808e27962ba1202198e21a212"
53+
"url": "https://github.com/lxml/lxml/releases/download/lxml-4.9.3/lxml-4.9.3.tar.gz",
54+
"sha256": "48628bd53a426c9eb9bc066a923acaa0878d1e86129fd5359aee99285f4eed9c"
5555
}
5656
]
5757
},

build-aux/flatpak/com.github.GradienceTeam.Gradience.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,8 @@
5151
"sources": [
5252
{
5353
"type": "archive",
54-
"url": "https://github.com/lxml/lxml/releases/download/lxml-4.9.2/lxml-4.9.2.tar.gz",
55-
"sha256": "d3fe33ffef3637e053cce7aa0bf26ad0943911c808e27962ba1202198e21a212"
54+
"url": "https://github.com/lxml/lxml/releases/download/lxml-4.9.3/lxml-4.9.3.tar.gz",
55+
"sha256": "48628bd53a426c9eb9bc066a923acaa0878d1e86129fd5359aee99285f4eed9c"
5656
}
5757
]
5858
},

build-aux/flatpak/pypi-dependencies.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,8 @@
3636
},
3737
{
3838
"type": "file",
39-
"url": "https://files.pythonhosted.org/packages/18/df/401fd39ffd50062ff1e0344f95f8e2c141de4fd1eca1677d2f29609e5389/regex-2023.6.3.tar.gz",
40-
"sha256": "72d1a25bf36d2050ceb35b517afe13864865268dfb45910e2e17a84be6cbfeb0"
39+
"url": "https://files.pythonhosted.org/packages/4f/1d/6998ba539616a4c8f58b07fd7c9b90c6b0f0c0ecbe8db69095a6079537a7/regex-2023.8.8.tar.gz",
40+
"sha256": "fcbdc5f2b0f1cd0f6a56cdb46fe41d2cce1e644e3b68832f3eeebc5fb0f7712e"
4141
}
4242
]
4343
},

gradience/backend/theming/preset.py

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,17 +26,25 @@
2626
from gradience.backend.models.preset import Preset
2727

2828
from gradience.backend.utils.theming import generate_gtk_css
29-
from gradience.backend.globals import user_config_dir, presets_dir, get_gtk_theme_dir
29+
from gradience.backend.globals import user_config_dir, presets_dir, get_gtk_theme_dir, is_sandboxed
30+
from gradience.backend.utils.gsettings import GSettingsSetting, FlatpakGSettings, GSettingsMissingError
3031

3132
from gradience.backend.logger import Logger
3233

3334
logging = Logger()
3435

3536

3637
class PresetUtils:
38+
THEME_GSETTINGS_SCHEMA_ID = "org.gnome.desktop.interface"
39+
3740
def __init__(self):
3841
pass
3942

43+
def set_gtk3_theme(self):
44+
settings_retriever = FlatpakGSettings if is_sandboxed() else GSettingsSetting
45+
self.settings = settings_retriever(self.THEME_GSETTINGS_SCHEMA_ID, schema_dir=None)
46+
self.settings.set("gtk-theme", "adw-gtk3")
47+
4048
def get_presets_list(self, repo=None, full_list=False) -> dict:
4149
presets_list = {}
4250

@@ -108,6 +116,9 @@ def apply_preset(self, app_type: str, preset: Preset) -> None:
108116
theme_dir = get_gtk_theme_dir(app_type)
109117
gtk_css_path = os.path.join(theme_dir, "gtk.css")
110118

119+
if app_type == "gtk3":
120+
self.set_gtk3_theme()
121+
111122
if not os.path.exists(theme_dir):
112123
os.makedirs(theme_dir)
113124

po/nl.po

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ msgstr ""
1313
"Project-Id-Version: \n"
1414
"Report-Msgid-Bugs-To: Atrophaneura@proton.me\n"
1515
"POT-Creation-Date: 2023-06-27 13:11+0000\n"
16-
"PO-Revision-Date: 2023-07-13 02:27+0000\n"
17-
"Last-Translator: yangyangdaji <1504305527@qq.com>\n"
16+
"PO-Revision-Date: 2023-08-16 07:53+0000\n"
17+
"Last-Translator: Philip Goto <philip.goto@gmail.com>\n"
1818
"Language-Team: Dutch <https://hosted.weblate.org/projects/GradienceTeam/"
1919
"gradience/nl/>\n"
2020
"Language: nl\n"
@@ -461,14 +461,8 @@ msgid "Reset and Restore Presets"
461461
msgstr "Voorinstellingen resetten en herstellen"
462462

463463
#: data/ui/reset_preset_group.blp:6
464-
#, fuzzy
465-
#| msgid ""
466-
#| "This section allows you to reset an currently applied preset or restore "
467-
#| "the previous one."
468464
msgid "Reset a currently applied preset or restore the previous one."
469-
msgstr ""
470-
"In deze sectie kunt u een momenteel toegepaste voorinstelling resetten of de "
471-
"vorige herstellen."
465+
msgstr "Reset een momenteel toegepaste voorinstelling of herstel de vorige."
472466

473467
#: data/ui/reset_preset_group.blp:14 data/ui/reset_preset_group.blp:34
474468
msgid "Restore Previous Preset"

0 commit comments

Comments
 (0)