Update for GNOME 49
This commit is contained in:
kramo
2025-09-24 13:22:16 +02:00
parent c77973e5d6
commit 4990953119
9 changed files with 110 additions and 84 deletions

View File

@@ -2,13 +2,12 @@
<gresources>
<gresource prefix="@PREFIX@">
<file preprocess="xml-stripblanks">@APP_ID@.metainfo.xml</file>
<file preprocess="xml-stripblanks">gtk/window.ui</file>
<file preprocess="xml-stripblanks">gtk/help-overlay.ui</file>
<file preprocess="xml-stripblanks">gtk/details-dialog.ui</file>
<file preprocess="xml-stripblanks">gtk/game.ui</file>
<file preprocess="xml-stripblanks">gtk/preferences.ui</file>
<file preprocess="xml-stripblanks">gtk/details-dialog.ui</file>
<file preprocess="xml-stripblanks">gtk/window.ui</file>
<file preprocess="xml-stripblanks" alias="shortcuts-dialog.ui">gtk/shortcuts-dialog.ui</file>
<file alias="style.css">gtk/style.css</file>
<file alias="style-dark.css">gtk/style-dark.css</file>
<file>library_placeholder.svg</file>
<file>library_placeholder_small.svg</file>
</gresource>

View File

@@ -1,73 +0,0 @@
using Gtk 4.0;
ShortcutsWindow help_overlay {
modal: true;
ShortcutsSection {
section-name: "shortcuts";
max-height: 10;
ShortcutsGroup {
title: _("General");
ShortcutsShortcut {
title: _("Search");
action-name: "win.toggle_search";
}
ShortcutsShortcut {
title: _("Preferences");
action-name: "app.preferences";
}
ShortcutsShortcut {
title: _("Keyboard Shortcuts");
action-name: "win.show-help-overlay";
}
ShortcutsShortcut {
title: _("Undo");
action-name: "win.undo";
}
ShortcutsShortcut {
title: _("Quit");
action-name: "app.quit";
}
ShortcutsShortcut {
title: _("Toggle Sidebar");
action-name: "win.show_sidebar";
}
ShortcutsShortcut {
title: _("Main Menu");
action-name: "win.open_menu";
}
}
ShortcutsGroup {
title: _("Games");
ShortcutsShortcut {
title: _("Add Game");
action-name: "app.add_game";
}
ShortcutsShortcut {
title: _("Import");
action-name: "app.import";
}
ShortcutsShortcut {
title: _("Show Hidden Games");
action-name: "win.show_hidden";
}
ShortcutsShortcut {
title: _("Remove Game");
action-name: "app.remove_game_details_view";
}
}
}
}

View File

@@ -0,0 +1,67 @@
using Gtk 4.0;
using Adw 1;
Adw.ShortcutsDialog shortcuts_dialog {
Adw.ShortcutsSection {
title: _("General");
Adw.ShortcutsItem {
title: _("Search");
action-name: "win.toggle_search";
}
Adw.ShortcutsItem {
title: _("Preferences");
action-name: "app.preferences";
}
Adw.ShortcutsItem {
title: _("Keyboard Shortcuts");
action-name: "app.shortcuts";
}
Adw.ShortcutsItem {
title: _("Undo");
action-name: "win.undo";
}
Adw.ShortcutsItem {
title: _("Quit");
action-name: "app.quit";
}
Adw.ShortcutsItem {
title: _("Toggle Sidebar");
action-name: "win.show_sidebar";
}
Adw.ShortcutsItem {
title: _("Main Menu");
action-name: "win.open_menu";
}
}
Adw.ShortcutsSection {
title: _("Games");
Adw.ShortcutsItem {
title: _("Add Game");
action-name: "app.add_game";
}
Adw.ShortcutsItem {
title: _("Import");
action-name: "app.import";
}
Adw.ShortcutsItem {
title: _("Show Hidden Games");
action-name: "win.show_hidden";
}
Adw.ShortcutsItem {
title: _("Remove Game");
action-name: "app.remove_game_details_view";
}
}
}

View File

@@ -3,11 +3,31 @@
--accent-bg-color: var(--purple-3);
}
.no-hover > flowboxchild:hover {
background-color: transparent;
}
#details_view {
background-color: white;
background-color: white;
}
#details_view_play_button {
color: white;
background-color: rgba(0, 0, 0, .8);
color: white;
background-color: rgba(0, 0, 0, 0.8);
}
@media (prefers-color-scheme: dark) {
:root {
--accent-color: var(--purple-1);
--accent-bg-color: var(--purple-4);
}
#details_view {
background-color: black;
}
#details_view_play_button {
color: rgba(0, 0, 0, 0.8);
background-color: white;
}
}

View File

@@ -246,6 +246,10 @@ template $CartridgesWindow: Adw.ApplicationWindow {
margin-start: 15;
margin-end: 15;
selection-mode: none;
styles [
"no-hover",
]
}
}
}
@@ -306,6 +310,10 @@ Adw.NavigationPage hidden_library_page {
margin-start: 15;
margin-end: 15;
selection-mode: none;
styles [
"no-hover",
]
}
}
}
@@ -541,7 +549,7 @@ menu primary_menu {
section {
item (_("Preferences"), "app.preferences")
item (_("Keyboard Shortcuts"), "win.show-help-overlay")
item (_("Keyboard Shortcuts"), "app.shortcuts")
item (_("About Cartridges"), "app.about")
}
}

View File

@@ -3,8 +3,8 @@ blueprints = custom_target(
input: files(
'gtk/details-dialog.blp',
'gtk/game.blp',
'gtk/help-overlay.blp',
'gtk/preferences.blp',
'gtk/shortcuts-dialog.blp',
'gtk/window.blp',
),
output: '.',

View File

@@ -54,6 +54,11 @@
</screenshots>
<content_rating type="oars-1.1" />
<releases>
<release version="2.13" date="2025-09-24">
<description translate="no">
<p>Updated for GNOME 49, using the new keyboard shortcuts dialog.</p>
</description>
</release>
<release version="2.12.1" date="2025-03-23">
<description translate="no">
<p>Removed an option used for debugging that would accidentally show up for all users.</p>

View File

@@ -1,6 +1,6 @@
project(
'cartridges',
version: '2.12.1',
version: '2.13',
meson_version: '>= 0.59.0',
default_options: [
'warning_level=2',

View File

@@ -4,8 +4,8 @@ data/page.kramo.Cartridges.metainfo.xml.in
data/gtk/details-dialog.blp
data/gtk/game.blp
data/gtk/help-overlay.blp
data/gtk/preferences.blp
data/gtk/shortcuts-dialog.blp
data/gtk/window.blp
cartridges/main.py