Fix LiveWindow attempting to start listeners on uninitialized sendables (#1463)

Additionally adds a defensive check in SendableBuilderImpl to avoid the NPE.
This commit is contained in:
Sam Carlberg
2018-12-07 22:38:22 -05:00
committed by Peter Johnson
parent 3d546428ab
commit 97ba195b88
5 changed files with 24 additions and 8 deletions

View File

@@ -33,12 +33,12 @@ void SendableBuilderImpl::UpdateTable() {
void SendableBuilderImpl::StartListeners() {
for (auto& property : m_properties) property.StartListener();
m_controllableEntry.SetBoolean(true);
if (m_controllableEntry) m_controllableEntry.SetBoolean(true);
}
void SendableBuilderImpl::StopListeners() {
for (auto& property : m_properties) property.StopListener();
m_controllableEntry.SetBoolean(false);
if (m_controllableEntry) m_controllableEntry.SetBoolean(false);
}
void SendableBuilderImpl::StartLiveWindowMode() {