X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=libs%2Fsurfaces%2Fcontrol_protocol%2Fcontrol_protocol.cc;h=6ac673925a52d347f7fe1700197e20135cc52dde;hb=fcbf359dd6123ca55d89f859e41149d6e3f39975;hp=cd379b10dcdef026fa6ec5728c8a91a6f5ee9ee2;hpb=658bb3ccd43658de18fbd43cd91a8e66650e27a7;p=ardour.git diff --git a/libs/surfaces/control_protocol/control_protocol.cc b/libs/surfaces/control_protocol/control_protocol.cc index cd379b10dc..6ac673925a 100644 --- a/libs/surfaces/control_protocol/control_protocol.cc +++ b/libs/surfaces/control_protocol/control_protocol.cc @@ -281,7 +281,7 @@ ControlProtocol::route_get_peak_input_power (uint32_t table_index, uint32_t whic return 0.0f; } - return r->peak_meter().peak_power (which_input); + return r->peak_meter().meter_level (which_input, MeterPeak); } @@ -374,6 +374,19 @@ ControlProtocol::get_state () XMLNode* node = new XMLNode (state_node_name); node->add_property ("name", _name); + node->add_property ("feedback", get_feedback() ? "yes" : "no"); return *node; } + +int +ControlProtocol::set_state (XMLNode const & node, int /* version */) +{ + const XMLProperty* prop; + + if ((prop = node.property ("feedback")) != 0) { + set_feedback (string_is_affirmative (prop->value())); + } + + return 0; +}