Lua bind MonitorProcessor
[ardour.git] / gtk2_ardour / splash.cc
index 2b28ff4953d6d262373db4e5566e6aaf55f07ebe..1784ac8164584d7a78b59c1ee43cb2718e178d3e 100644 (file)
@@ -25,6 +25,8 @@
 #include "ardour/ardour.h"
 #include "ardour/filesystem_paths.h"
 
+#include "gtkmm2ext/utils.h"
+
 #ifdef check
 #undef check
 #endif
@@ -32,7 +34,7 @@
 #include "gui_thread.h"
 #include "splash.h"
 
-#include "i18n.h"
+#include "pbd/i18n.h"
 
 using namespace Gtk;
 using namespace Glib;
@@ -45,10 +47,13 @@ Splash* Splash::the_splash = 0;
 Splash::Splash ()
 {
        assert (the_splash == 0);
-       
+
        std::string splash_file;
 
-       if (!find_file (ardour_data_search_path(), "splash.png", splash_file)) {
+       Searchpath rc (ARDOUR::ardour_data_search_path());
+       rc.add_subdirectory_to_paths ("resources");
+
+       if (!find_file (rc, PROGRAM_NAME "-splash.png", splash_file)) {
                 cerr << "Cannot find splash screen image file\n";
                throw failed_constructor();
        }
@@ -109,9 +114,9 @@ Splash::pop_back_for (Gtk::Window& win)
 
            So for OS X, we just hide ourselves.
 
-                                        Oct 2014: The Windows situation is similar, although it should be possible
-                                        to play tricks with gdk's set_type_hint() or directly hack things using
-                                        SetWindowLong() and UpdateLayeredWindow()
+           Oct 2014: The Windows situation is similar, although it should be possible
+           to play tricks with gdk's set_type_hint() or directly hack things using
+           SetWindowLong() and UpdateLayeredWindow()
         */
         (void) win;
         hide();
@@ -202,7 +207,7 @@ void
 Splash::display ()
 {
        bool was_mapped = is_mapped ();
-       
+
        if (!was_mapped) {
                expose_done = false;
                expose_is_the_one = false;
@@ -210,7 +215,7 @@ Splash::display ()
 
        pop_front ();
        present ();
-       
+
        if (!was_mapped) {
                while (!expose_done) {
                        gtk_main_iteration ();
@@ -223,14 +228,14 @@ void
 Splash::message (const string& msg)
 {
        string str ("<b>");
-       str += Glib::Markup::escape_text (msg).c_str();
+       str += Gtkmm2ext::markup_escape_text (msg);
        str += "</b>";
 
         show ();
 
        layout->set_markup (str);
        Glib::RefPtr<Gdk::Window> win = darea.get_window();
-       
+
        if (win) {
                 expose_done = false;