13
0

fix logic bomb

This commit is contained in:
Paul Davis 2016-04-27 20:12:15 -04:00
parent 42983959d2
commit 04d86ebd8d

View File

@ -851,14 +851,12 @@ AUPluginUI::parent_cocoa_window ()
resizable = false;
if (!toplevel || !toplevel->is_toplevel()) {
error << _("AUPluginUI: no top level window!") << endmsg;
if (toplevel && toplevel->is_toplevel()) {
toplevel->size_request (req);
toplevel->set_size_request (req.width, req.height);
dynamic_cast<Gtk::Window*>(toplevel)->set_resizable (false);
}
toplevel->size_request (req);
toplevel->set_size_request (req.width, req.height);
dynamic_cast<Gtk::Window*>(toplevel)->set_resizable (false);
#endif
return 0;
}