holding last look is the behavior of a universe, not the receiver
This commit is contained in:
parent
3835cee9bd
commit
0292051392
|
@ -71,7 +71,6 @@
|
|||
<addaction name="actionDiscovery"/>
|
||||
<addaction name="separator"/>
|
||||
<addaction name="menuMerge_Mode"/>
|
||||
<addaction name="actionReceiverHoldLastLook"/>
|
||||
</widget>
|
||||
<widget class="QMenu" name="menuSource">
|
||||
<property name="title">
|
||||
|
@ -254,23 +253,6 @@
|
|||
<string>Ctrl+D</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionReceiverHoldLastLook">
|
||||
<property name="checkable">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="checked">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="enabled">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Hold Last Look</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Retain at least 1 inacitve source on all universes.</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionUniverseHoldLastLook">
|
||||
<property name="checkable">
|
||||
<bool>true</bool>
|
||||
|
|
|
@ -37,7 +37,6 @@ namespace sACN {
|
|||
Receiver::Receiver(UUID::uuid cid, std::string fctn)
|
||||
: Component(cid, fctn)
|
||||
, discovery_enabled_(false)
|
||||
, HoldLastLook(true)
|
||||
{
|
||||
RlpRegisterVector(VECTOR_ROOT_E131_DATA, std::bind(&Receiver::dataReceiver,
|
||||
this, std::placeholders::_1));
|
||||
|
@ -56,28 +55,6 @@ Receiver::~Receiver()
|
|||
}
|
||||
|
||||
|
||||
/**
|
||||
* @brief Receiver::setHoldLastLook
|
||||
* @param state
|
||||
*/
|
||||
void Receiver::setHoldLastLook(const bool state)
|
||||
{
|
||||
HoldLastLook = state;
|
||||
for (const auto & [_, universe] : universes_)
|
||||
universe->setHoldLastLook(state);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @brief Receiver::isEnabledHoldLastLook
|
||||
* @return
|
||||
*/
|
||||
bool Receiver::isEnabledHoldLastLook() const
|
||||
{
|
||||
return HoldLastLook;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @brief Receiver::subscribe
|
||||
* @param num
|
||||
|
@ -88,7 +65,6 @@ void Receiver::subscribe(const uint16_t num)
|
|||
return;
|
||||
universes_.emplace(num, std::make_shared<ArbitratingUniverse>());
|
||||
universes_.at(num)->expectedUniverse = num;
|
||||
universes_.at(num)->setHoldLastLook(HoldLastLook);
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -68,8 +68,8 @@ public:
|
|||
Receiver(UUID::uuid = UUID::uuid(), std::string fctn = "OpenLCP sACN Receiver");
|
||||
~Receiver();
|
||||
|
||||
void setHoldLastLook(const bool);
|
||||
bool isEnabledHoldLastLook() const;
|
||||
// void setHoldLastLook(const bool);
|
||||
// bool isEnabledHoldLastLook() const;
|
||||
|
||||
virtual void subscribe(const uint16_t);
|
||||
virtual void unsubscribe(const uint16_t);
|
||||
|
@ -102,7 +102,7 @@ private:
|
|||
std::unordered_map<uint16_t, std::shared_ptr<ArbitratingUniverse>> universes_;
|
||||
std::vector<std::function<void()>> discoveryCallbacks_;
|
||||
bool discovery_enabled_;
|
||||
bool HoldLastLook;
|
||||
// bool HoldLastLook;
|
||||
};
|
||||
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue