- if (_inst) {
- if (!is_external_ui) {
- GtkWidget* c_widget = (GtkWidget*)GET_WIDGET(_inst);
- if (!c_widget) {
- error << _("failed to get LV2 UI widget") << endmsg;
- suil_instance_free((SuilInstance*)_inst);
- _inst = NULL;
- return;
- }
- if (!container->get_child()) {
- // Suil didn't add the UI to the container for us, so do it now
- container->add(*Gtk::manage(Glib::wrap(c_widget)));
- }
- container->show_all();
- gtk_widget_set_can_focus(c_widget, true);
- gtk_widget_grab_focus(c_widget);
- } else {
- _external_ui_ptr = (struct lv2_external_ui*)GET_WIDGET(_inst);
+ if (!is_external_ui) {
+ GtkWidget* c_widget = (GtkWidget*)GET_WIDGET(_inst);
+ if (!c_widget) {
+ error << _("failed to get LV2 UI widget") << endmsg;
+ suil_instance_free((SuilInstance*)_inst);
+ _inst = NULL;
+ return;
+ }
+ if (!container->get_child()) {
+ // Suil didn't add the UI to the container for us, so do it now
+ container->add(*Gtk::manage(Glib::wrap(c_widget)));