| 1 |
From: Maximiliano Sandoval <[email protected]> |
| 2 |
Date: Sun, 14 Jul 2024 12:29:57 +0200 |
| 3 |
Subject: cargo: Update to gtk4-rs 0.9 |
| 4 |
|
| 5 |
(cherry picked from commit 0a12c33dcfb5d0774c3d331d5d2b74ac7149b396) |
| 6 |
|
| 7 |
Origin: upstream, after 3.0.1 |
| 8 |
--- |
| 9 |
Cargo.toml | 8 ++++---- |
| 10 |
src/actions.rs | 6 +++--- |
| 11 |
src/app.rs | 6 +++--- |
| 12 |
src/ui/about_dialog.rs | 2 +- |
| 13 |
4 files changed, 11 insertions(+), 11 deletions(-) |
| 14 |
|
| 15 |
diff --git a/Cargo.toml b/Cargo.toml |
| 16 |
index 2eeb505..e3f0b73 100644 |
| 17 |
--- a/Cargo.toml |
| 18 |
+++ b/Cargo.toml |
| 19 |
@@ -7,7 +7,7 @@ license = "GPL-3.0-or-later" |
| 20 |
|
| 21 |
[dependencies] |
| 22 |
anyhow = "1.0" |
| 23 |
-ashpd = { version = "0.8", features = ["gtk4"] } |
| 24 |
+ashpd = { version = "0.9", features = ["gtk4"] } |
| 25 |
async-process = "2.2" |
| 26 |
async-recursion = "1.1" |
| 27 |
base64 = "0.22" |
| 28 |
@@ -30,11 +30,11 @@ strum_macros = "0.28" |
| 29 |
url = "2.5" |
| 30 |
uuid = { version = "1.10", features = ["v4"] } |
| 31 |
|
| 32 |
-gtk = { package = "gtk4", version = "0.8", features = ["gnome_45"] } |
| 33 |
-adw = { package = "libadwaita", version = "0.6", features = ["v1_5"] } |
| 34 |
+gtk = { package = "gtk4", version = "0.9", features = ["gnome_47"] } |
| 35 |
+adw = { package = "libadwaita", version = "0.7", features = ["v1_6"] } |
| 36 |
|
| 37 |
[dependencies.transmission-gobject] |
| 38 |
-version = "0.1.5" |
| 39 |
+version = "0.1.6" |
| 40 |
#path = "./src/transmission-gobject" |
| 41 |
#git = "https://gitlab.gnome.org/haecker-felix/transmission-gobject" |
| 42 |
|
| 43 |
diff --git a/src/actions.rs b/src/actions.rs |
| 44 |
index 44218a1..1f4211a 100644 |
| 45 |
--- a/src/actions.rs |
| 46 |
+++ b/src/actions.rs |
| 47 |
@@ -123,7 +123,7 @@ pub fn install_torrent_actions(torrent: &TrTorrent, widget: gtk::Widget) { |
| 48 |
let show_dialog_action = SimpleAction::new("show-dialog", None); |
| 49 |
show_dialog_action.connect_activate(clone!(@weak torrent, @weak widget => move |_, _| { |
| 50 |
let dialog = FrgTorrentDialog::new(&torrent); |
| 51 |
- dialog.present(&widget); |
| 52 |
+ dialog.present(Some(&widget)); |
| 53 |
})); |
| 54 |
actions.add_action(&show_dialog_action); |
| 55 |
|
| 56 |
@@ -300,7 +300,7 @@ fn show_remove_torrent_dialog(torrent: &TrTorrent, parent: gtk::Widget) { |
| 57 |
}), |
| 58 |
); |
| 59 |
|
| 60 |
- dialog.present(&parent); |
| 61 |
+ dialog.present(Some(&parent)); |
| 62 |
} |
| 63 |
|
| 64 |
// TODO: Consider rewriting this as async to get rid of the nested closures |
| 65 |
@@ -327,7 +327,7 @@ fn show_set_torrent_location(torrent: &TrTorrent, parent: >k::Widget) { |
| 66 |
dialog.set_default_response(Some("move-data")); |
| 67 |
dialog.set_response_appearance("move-data", adw::ResponseAppearance::Suggested); |
| 68 |
|
| 69 |
- dialog.present(&parent); |
| 70 |
+ dialog.present(Some(&parent)); |
| 71 |
dialog.connect_response( |
| 72 |
None, |
| 73 |
clone!(@strong dialog, @strong torrent, @strong folder => move |_ , resp| { |
| 74 |
diff --git a/src/app.rs b/src/app.rs |
| 75 |
index 0b95c22..987ea22 100644 |
| 76 |
--- a/src/app.rs |
| 77 |
+++ b/src/app.rs |
| 78 |
@@ -189,7 +189,7 @@ mod imp { |
| 79 |
// app.show-stats |
| 80 |
let action = gio::SimpleAction::new("show-stats", None); |
| 81 |
action.connect_activate(clone!(@weak window => move |_, _| { |
| 82 |
- FrgStatsDialog::new().present(&window); |
| 83 |
+ FrgStatsDialog::new().present(Some(&window)); |
| 84 |
})); |
| 85 |
utils::bind_connected_property(&action); |
| 86 |
obj.add_action(&action); |
| 87 |
@@ -218,14 +218,14 @@ mod imp { |
| 88 |
let action = gio::SimpleAction::new("add-remote-connection", None); |
| 89 |
action.connect_activate(clone!(@weak window => move |_, _| { |
| 90 |
let dialog = FrgAddConnectionDialog::new(); |
| 91 |
- dialog.present(&window); |
| 92 |
+ dialog.present(Some(&window)); |
| 93 |
})); |
| 94 |
obj.add_action(&action); |
| 95 |
|
| 96 |
// app.show-preferences |
| 97 |
let action = gio::SimpleAction::new("show-preferences", None); |
| 98 |
action.connect_activate(clone!(@weak window => move |_, _| { |
| 99 |
- FrgPreferencesDialog::default().present(&window); |
| 100 |
+ FrgPreferencesDialog::default().present(Some(&window)); |
| 101 |
})); |
| 102 |
obj.set_accels_for_action("app.show-preferences", &["<primary>comma"]); |
| 103 |
obj.add_action(&action); |
| 104 |
diff --git a/src/ui/about_dialog.rs b/src/ui/about_dialog.rs |
| 105 |
index e11abad..d505ec9 100644 |
| 106 |
--- a/src/ui/about_dialog.rs |
| 107 |
+++ b/src/ui/about_dialog.rs |
| 108 |
@@ -43,5 +43,5 @@ pub fn show(parent: &FrgApplicationWindow) { |
| 109 |
dialog.set_designers(&["Tobias Bernard", "Jakub Steiner", "Sam Hewitt"]); |
| 110 |
dialog.set_translator_credits(&i18n("translator-credits")); |
| 111 |
|
| 112 |
- dialog.present(parent); |
| 113 |
+ dialog.present(Some(parent)); |
| 114 |
} |