mirror of https://github.com/snes9xgit/snes9x.git
Gtk: Unthread preferences creation.
This commit is contained in:
parent
2bab4c41b1
commit
77fb6ff958
|
@ -22,19 +22,10 @@
|
|||
|
||||
static Snes9xPreferences *preferences = nullptr;
|
||||
|
||||
void snes9x_preferences_create(Snes9xConfig *config)
|
||||
{
|
||||
Glib::Thread::create([config] {
|
||||
Snes9xPreferences *new_preferences;
|
||||
new_preferences = new Snes9xPreferences(config);
|
||||
preferences = new_preferences;
|
||||
}, true);
|
||||
}
|
||||
|
||||
void snes9x_preferences_open(Snes9xWindow *window)
|
||||
{
|
||||
if (!preferences)
|
||||
return;
|
||||
preferences = new Snes9xPreferences(window->config);
|
||||
|
||||
auto &config = preferences->config;
|
||||
|
||||
|
|
|
@ -78,8 +78,6 @@ Snes9xWindow::Snes9xWindow(Snes9xConfig *config)
|
|||
cairo_owned = false;
|
||||
mouse_grabbed = false;
|
||||
|
||||
snes9x_preferences_create(config);
|
||||
|
||||
if (Gtk::IconTheme::get_default()->has_icon("snes9x"))
|
||||
{
|
||||
window->set_default_icon_name("snes9x");
|
||||
|
|
Loading…
Reference in New Issue