mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-10 00:34:59 +01:00
remember plugin-UI type (custom/basic) with session.
amend to 3.1-81-g1acf8bd
This commit is contained in:
parent
04967de3af
commit
4341d675dc
3 changed files with 42 additions and 1 deletions
|
|
@ -2642,6 +2642,38 @@ ProcessorWindowProxy::session_handle()
|
|||
return 0;
|
||||
}
|
||||
|
||||
XMLNode&
|
||||
ProcessorWindowProxy::get_state () const
|
||||
{
|
||||
XMLNode *node;
|
||||
node = &ProxyBase::get_state();
|
||||
node->add_property (X_("custom-ui"), is_custom? X_("yes") : X_("no"));
|
||||
return *node;
|
||||
}
|
||||
|
||||
void
|
||||
ProcessorWindowProxy::set_state (const XMLNode& node)
|
||||
{
|
||||
XMLNodeList children = node.children ();
|
||||
XMLNodeList::const_iterator i = children.begin ();
|
||||
while (i != children.end()) {
|
||||
XMLProperty* prop = (*i)->property (X_("name"));
|
||||
if ((*i)->name() == X_("Window") && prop && prop->value() == _name) {
|
||||
break;
|
||||
}
|
||||
++i;
|
||||
}
|
||||
|
||||
if (i != children.end()) {
|
||||
XMLProperty* prop;
|
||||
if ((prop = (*i)->property (X_("custom-ui"))) != 0) {
|
||||
want_custom = PBD::string_is_affirmative (prop->value ());
|
||||
}
|
||||
}
|
||||
|
||||
ProxyBase::set_state(node);
|
||||
}
|
||||
|
||||
Gtk::Window*
|
||||
ProcessorWindowProxy::get (bool create)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue