diff options
| author | Matthias Vogelgesang <matthias.vogelgesang@kit.edu> | 2014-12-04 08:50:55 +0100 | 
|---|---|---|
| committer | Matthias Vogelgesang <matthias.vogelgesang@kit.edu> | 2014-12-04 08:50:55 +0100 | 
| commit | 6823f2cd04d84144d32caa9e32651c28254b2d56 (patch) | |
| tree | be10fcb723ebede82a68506459658ab964936cb3 | |
| parent | 321d465a5d787674a0e9a3553fb16b494a6f2dd5 (diff) | |
If glade file cannot be load, try locally
| -rw-r--r-- | bin/gui/control.c | 7 | 
1 files changed, 6 insertions, 1 deletions
diff --git a/bin/gui/control.c b/bin/gui/control.c index 5f4416e..16fb342 100644 --- a/bin/gui/control.c +++ b/bin/gui/control.c @@ -1363,7 +1363,12 @@ main (int argc, char *argv[])      builder = gtk_builder_new ();      if (!gtk_builder_add_from_file (builder, CONTROL_GLADE_PATH, &error)) { -        g_print ("Could not load UI file: %s\n", error->message); +        g_warning ("Cannot load UI: `%s'. Trying in current working directory.", error->message); +        g_error_free (error); +    } + +    if (!gtk_builder_add_from_file (builder, "control.glade", &error)) { +        g_warning ("Cannot load UI: `%s'.", error->message);          return 1;      }  | 
