[gnome-games/wip/exalm/gtk4: 41/44] application: Don't catch errors from gtk_css_provider_load_from_file()
- From: Alexander Mikhaylenko <alexm src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-games/wip/exalm/gtk4: 41/44] application: Don't catch errors from gtk_css_provider_load_from_file()
- Date: Mon, 25 Feb 2019 11:40:52 +0000 (UTC)
commit 39218e7aff0b481fcf08a50ec5c9e156164eb4c3
Author: Alexander Mikhaylenko <exalm7659 gmail com>
Date: Wed Aug 1 20:42:52 2018 +0500
application: Don't catch errors from gtk_css_provider_load_from_file()
Doing so results in warning in gtk4.
src/ui/application.vala | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)
---
diff --git a/src/ui/application.vala b/src/ui/application.vala
index 53da7737..e9f3cd4c 100644
--- a/src/ui/application.vala
+++ b/src/ui/application.vala
@@ -409,12 +409,10 @@ public class Games.Application : Gtk.Application {
private static Gtk.CssProvider load_css (string css) {
var provider = new Gtk.CssProvider ();
- try {
- var file = File.new_for_uri ("resource:///org/gnome/Games/" + css);
- provider.load_from_file (file);
- } catch (GLib.Error e) {
- warning ("Loading CSS file ā%sā failed: %s", css, e.message);
- }
+
+ var file = File.new_for_uri ("resource:///org/gnome/Games/" + css);
+ provider.load_from_file (file);
+
return provider;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]