This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
#include "ardour/lxvst_plugin.h"
#include "ardour/linux_vst_support.h"
#include "lxvst_plugin_ui.h"
#include "ardour/lxvst_plugin.h"
#include "ardour/linux_vst_support.h"
#include "lxvst_plugin_ui.h"
// plugin destructor destroys the custom GUI, via the vstfx engine,
// and then our PluginUIWindow does the rest
}
// plugin destructor destroys the custom GUI, via the vstfx engine,
// and then our PluginUIWindow does the rest
}
if (!_vst->state()->want_resize) {
return;
}
int new_height = _vst->state()->height;
int new_width = _vst->state()->width;
if (!_vst->state()->want_resize) {
return;
}
int new_height = _vst->state()->height;
int new_width = _vst->state()->width;
/* We have to return the required height of the plugin UI window + a fiddle factor
because we can't know how big the preset menu bar is until the window is realised
and we can't realise it until we have told it how big we would like it to be
which we can't do until it is realised etc
*/
/* We have to return the required height of the plugin UI window + a fiddle factor
because we can't know how big the preset menu bar is until the window is realised
and we can't realise it until we have told it how big we would like it to be
which we can't do until it is realised etc
*/
win.signal_map_event().connect (mem_fun (*this, &LXVSTPluginUI::start_updating));
win.signal_unmap_event().connect (mem_fun (*this, &LXVSTPluginUI::stop_updating));
win.signal_map_event().connect (mem_fun (*this, &LXVSTPluginUI::start_updating));
win.signal_unmap_event().connect (mem_fun (*this, &LXVSTPluginUI::stop_updating));
spin here until it has been activated. Possible
deadlock if the window never gets activated but
should not be called here if the window doesn't
exist or will never exist
*/
spin here until it has been activated. Possible
deadlock if the window never gets activated but
should not be called here if the window doesn't
exist or will never exist
*/
problems will arise if we return either a zero ID
and GTK tries to socket it or if we return an ID
which hasn't yet become real to the server
*/
problems will arise if we return either a zero ID
and GTK tries to socket it or if we return an ID
which hasn't yet become real to the server
*/
gtk_xerror_handler (Display*, XErrorEvent*)
{
std::cerr << "** ERROR ** LXVSTPluginUI : Trapped an X Window System Error" << std::endl;
gtk_xerror_handler (Display*, XErrorEvent*)
{
std::cerr << "** ERROR ** LXVSTPluginUI : Trapped an X Window System Error" << std::endl;