Clone in a terminal:
Commit 5d2f14a
Johan Mattsson - 2012-05-19T11:22:41+00:00
5d2f14acb0255651bef5e0f3e28912c1b0d168aejohan.mattsson.m@gmail.com

catch glib error in ContentDisplay

Changed files (1)

Diff

diff --git a/src/ContentDisplay.vala b/src/ContentDisplay.valaindex a6e5829..6f7b927 100644--- a/src/ContentDisplay.vala+++ b/src/ContentDisplay.vala@@ -523,7 +523,11 @@ class ContentDisplay : FontDisplay { 		FileChooserDialog file_chooser = new FileChooserDialog ("Open font file", MainWindow.get_current_window (), FileChooserAction.OPEN, Stock.CANCEL, ResponseType.CANCEL, Stock.OPEN, ResponseType.ACCEPT); 		Font f = Supplement.get_current_font (); 		-		file_chooser.set_current_folder_file (f.get_folder ());+		try {+			file_chooser.set_current_folder_file (f.get_folder ());+		} catch (GLib.Error e) {+			stderr.printf (e.message);+		} 		 		if (file_chooser.run () == ResponseType.ACCEPT) {	 			MainWindow.get_glyph_canvas ().redraw ();

Contact

Email: johan.mattsson.m@gmail.com
Mastodon: typo.social/@birdfont
GitHub: johanmattssonm
LinkedIn: johan-mattsson-2ab324112