diff options
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/App.cpp | 21 | ||||
-rw-r--r-- | src/gui/ingen_gui.cpp | 2 |
2 files changed, 13 insertions, 10 deletions
diff --git a/src/gui/App.cpp b/src/gui/App.cpp index 35d31b3e..055b4ef7 100644 --- a/src/gui/App.cpp +++ b/src/gui/App.cpp @@ -133,21 +133,22 @@ App::init(Ingen::Shared::World* world) "widget \"*ingen_embedded_node_gui_container*\" style \"ingen_embedded_node_gui_style\"\n"; Gtk::RC::parse_string(rc_style); - - App::instance().connect_window()->start(world); - - // Run main iterations here until we're attached to the engine - // (otherwise with 'ingen -egl' we'll get a bunch of notifications about load immediately - // before even knowing about the root patch or plugins) - while (!App::instance().connect_window()->attached()) - if (_main->iteration()) - break; } void App::run() { - assert(_main); + App& me = App::instance(); + + me._connect_window->start(me.world()); + + // Run main iterations here until we're attached to the engine. Otherwise + // with 'ingen -egl' we'd get a bunch of notifications about load + // immediately before even knowing about the root patch or plugins) + while (!me._connect_window->attached()) + if (me._main->iteration()) + break; + _main->run(); LOG(info) << "Exiting" << endl; } diff --git a/src/gui/ingen_gui.cpp b/src/gui/ingen_gui.cpp index 83f4029d..88d27b39 100644 --- a/src/gui/ingen_gui.cpp +++ b/src/gui/ingen_gui.cpp @@ -21,6 +21,8 @@ struct IngenGUIModule : public Ingen::Shared::Module { void load(Ingen::Shared::World* world) { Ingen::GUI::App::init(world); + } + void run(Ingen::Shared::World* world) { Ingen::GUI::App::run(); } }; |