diff options
author | fiaxh <git@lightrise.org> | 2023-01-06 17:24:52 +0100 |
---|---|---|
committer | Marvin W <git@larma.de> | 2023-01-24 19:21:25 +0100 |
commit | 6a182ba313026b93d54a9d2246a0ab68894c6833 (patch) | |
tree | edc6068c19363db1af725033521555c91bbfb0a9 /main/src/ui/application.vala | |
parent | ef98adb18a016dba65162602eb336fb82c64805e (diff) | |
download | dino-6a182ba313026b93d54a9d2246a0ab68894c6833.tar.gz dino-6a182ba313026b93d54a9d2246a0ab68894c6833.zip |
Only use Adw.AboutWindow for Adwaita >= 1.2
Diffstat (limited to 'main/src/ui/application.vala')
-rw-r--r-- | main/src/ui/application.vala | 36 |
1 files changed, 21 insertions, 15 deletions
diff --git a/main/src/ui/application.vala b/main/src/ui/application.vala index b810852c..8e252dc6 100644 --- a/main/src/ui/application.vala +++ b/main/src/ui/application.vala @@ -272,24 +272,30 @@ public class Dino.Ui.Application : Adw.Application, Dino.Application { case "0.3": version = @"$version - <span font_style='italic'>Theikenmeer</span>"; break; } } - Adw.AboutWindow about = new Adw.AboutWindow(); - about.destroy_with_parent = true; - about.transient_for = window; - about.modal = true; - about.title = _("About Dino"); - - about.application_icon = "im.dino.Dino"; - about.application_name = "Dino"; - about.version = version; - about.comments = "Dino. Communicating happiness."; - about.website = "https://dino.im/"; - about.copyright = "Copyright © 2016-2022 - Dino Team"; - about.license_type = License.GPL_3_0; +#if Adw_1_2 + Adw.AboutWindow about_window = new Adw.AboutWindow(); + about_window.application_icon = "im.dino.Dino"; + about_window.application_name = "Dino"; +#else + Gtk.AboutDialog about_window = new Gtk.AboutDialog(); + about_window.logo_icon_name = "im.dino.Dino"; + about_window.program_name = "Dino"; + about_window.website_label = "dino.im"; +#endif + about_window.destroy_with_parent = true; + about_window.transient_for = window; + about_window.modal = true; + about_window.title = _("About Dino"); + about_window.version = version; + about_window.comments = "Dino. Communicating happiness."; + about_window.website = "https://dino.im/"; + about_window.copyright = "Copyright © 2016-2022 - Dino Team"; + about_window.license_type = License.GPL_3_0; if (!use_csd()) { - about.set_titlebar(null); + about_window.set_titlebar(null); } - about.present(); + about_window.present(); } private void show_join_muc_dialog(Account? account, string jid) { |