summaryrefslogtreecommitdiffstats
path: root/src/libs/gui/GladeFactory.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/libs/gui/GladeFactory.cpp')
-rw-r--r--src/libs/gui/GladeFactory.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/libs/gui/GladeFactory.cpp b/src/libs/gui/GladeFactory.cpp
index b3d24eb2..8b1f1e1f 100644
--- a/src/libs/gui/GladeFactory.cpp
+++ b/src/libs/gui/GladeFactory.cpp
@@ -31,8 +31,12 @@ Glib::ustring GladeFactory::glade_filename = "";
void
GladeFactory::find_glade_file()
{
- // Check for the .glade file in current directory
- glade_filename = "./ingen_gui.glade";
+ char* env_path = getenv("INGEN_GLADE_PATH");
+ if (env_path)
+ glade_filename = env_path;
+ else
+ glade_filename = "./ingen_gui.glade";
+
ifstream fs(glade_filename.c_str());
if (fs.fail()) { // didn't find it, check PKGDATADIR
fs.clear();