[ease/buidler: 9/9] Ugly hack to load UI files locally and system-wide
- From: Stéphane Maniaci <maniacis src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [ease/buidler: 9/9] Ugly hack to load UI files locally and system-wide
- Date: Wed, 14 Jul 2010 06:33:54 +0000 (UTC)
commit 9ae6bfc71f16dc2b110120c4e1bf0676fb0e661f
Author: Stéphane Maniaci <stephane maniaci gmail com>
Date: Wed Jul 14 01:30:14 2010 -0500
Ugly hack to load UI files locally and system-wide
src/ease-welcome-window.vala | 11 ++++++++---
1 files changed, 8 insertions(+), 3 deletions(-)
---
diff --git a/src/ease-welcome-window.vala b/src/ease-welcome-window.vala
index ac52741..f651f96 100644
--- a/src/ease-welcome-window.vala
+++ b/src/ease-welcome-window.vala
@@ -91,9 +91,14 @@ public class Ease.WelcomeWindow : Gtk.Window
var builder = new Gtk.Builder ();
try {
- builder.add_from_file (data_path(Path.build_filename(Temp.TEMP_DIR,
- Temp.UI_DIR,
- "welcome-window.ui")));
+ // FIXME : it's ugly.
+ string ui_path = data_path(Path.build_filename(Temp.TEMP_DIR,
+ Temp.UI_DIR,
+ "welcome-window.ui"));
+ if (ui_path == null)
+ ui_path = "data/ui/welcome-window.ui";
+
+ builder.add_from_file (ui_path);
} catch (Error e) {
error ("Unable to load UI : %s", e.message);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]