Commit fb4a4a88 authored by Martin Kröning's avatar Martin Kröning

Fix Windows locale folder

parent c002cc88
......@@ -15,6 +15,7 @@ public:
static void removeWindow(Gtk::Window &window);
private:
static void initGettext();
static Glib::RefPtr<Gtk::Application> application;
static std::thread thread;
};
#include "MapApplication.hpp"
#include <glibmm/i18n.h>
#include <glibmm/refptr.h>
#include <gtkmm/application.h>
#include <gtkmm/window.h>
#include <vector>
Glib::RefPtr<Gtk::Application> MapApplication::application =
Gtk::Application::create();
void MapApplication::initGettext() {
#ifdef G_OS_WIN32
gchar *win32_dir = g_win32_get_package_installation_directory_of_module(NULL);
bindtextdomain("pi2-view",
g_build_filename(win32_dir, "share", "locale", NULL));
g_free(win32_dir);
#endif /* G_OS_WIN32 */
bind_textdomain_codeset("pi2-view", "UTF-8");
}
Glib::RefPtr<Gtk::Application> MapApplication::application = []() {
initGettext();
return Gtk::Application::create();
}();
std::thread MapApplication::thread;
void MapApplication::addWindow(Gtk::Window &window) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment