fix bug in path_expand() when passed an empty string
[ardour.git] / libs / ardour / globals.cc
index ca2432eda77d60477e5a7a3784ea5b72fcea5a0c..0e12883d8235d992f11a157d6196e5fd3597c611 100644 (file)
@@ -69,7 +69,7 @@
 #include "ardour/debug.h"
 #include "ardour/filesystem_paths.h"
 #include "ardour/mix.h"
-#include "ardour/playlist.h"
+#include "ardour/audioplaylist.h"
 #include "ardour/plugin_manager.h"
 #include "ardour/process_thread.h"
 #include "ardour/profile.h"
@@ -251,6 +251,7 @@ ARDOUR::init (bool use_vst, bool try_optimization)
        AudioRegion::make_property_quarks ();
        RouteGroup::make_property_quarks ();
         Playlist::make_property_quarks ();
+        AudioPlaylist::make_property_quarks ();
 
        /* this is a useful ready to use PropertyChange that many
           things need to check. This avoids having to compose
@@ -526,3 +527,15 @@ ARDOUR::coverage (framepos_t sa, framepos_t ea,
        return OverlapNone;
 }
 
+string
+ARDOUR::translation_kill_path ()
+{
+        return Glib::build_filename (user_config_directory().to_string(), ".love_is_the_language_of_audio");
+}
+
+bool
+ARDOUR::translations_are_disabled ()
+{
+        /* if file does not exist, we don't translate (bundled ardour only) */
+        return Glib::file_test (translation_kill_path(), Glib::FILE_TEST_EXISTS) == false;
+}