Corrects issues with order of operations so that InCallFeedback isn't null when dependent routines check it's state.

This commit is contained in:
Neil Dorin
2019-11-27 10:32:21 -07:00
parent 2fe1ac0e75
commit f2e2166146
4 changed files with 83 additions and 70 deletions

View File

@@ -33,9 +33,9 @@ namespace PepperDash.Essentials.Core
{
Audio = 1,
Video = 2,
//AudioVideo = 4,
UsbOutput = 4,
UsbInput = 8
AudioVideo = 4,
UsbOutput = 8,
UsbInput = 16
}
public enum eRoutingPortConnectionType

View File

@@ -33,7 +33,7 @@ namespace PepperDash.Essentials.Core
public ushort Count
{
get { return SetNumberOfItemsSig.UShortValue; }
set { SetNumberOfItemsSig.UShortValue = value; }
set { SetNumberOfItemsSig.UShortValue = value; }
}
public ushort MaxDefinedItems { get; private set; }
@@ -100,8 +100,9 @@ namespace PepperDash.Essentials.Core
// Empty the list
Items.Clear();
// Clean up the SRL
Count = 0;
ScrollToItemSig.UShortValue = 1;
Count = 1;
ScrollToItemSig.UShortValue = 1;
}
/// <summary>

View File

@@ -87,7 +87,11 @@ namespace PepperDash.Essentials.Devices.Common.Microphones
else
Debug.Console(0, this, "Unable to add Red LED device");
CheckPrivacyMode();
AddPostActivationAction(() => {
CheckPrivacyMode();
PrivacyDevice.PrivacyModeIsOnFeedback.OutputChange -= PrivacyModeIsOnFeedback_OutputChange;
PrivacyDevice.PrivacyModeIsOnFeedback.OutputChange += PrivacyModeIsOnFeedback_OutputChange;
});
initialized = true;
@@ -97,8 +101,6 @@ namespace PepperDash.Essentials.Devices.Common.Microphones
public void SetPrivacyDevice(IPrivacy privacyDevice)
{
PrivacyDevice = privacyDevice;
PrivacyDevice.PrivacyModeIsOnFeedback.OutputChange += PrivacyModeIsOnFeedback_OutputChange;
}
void PrivacyModeIsOnFeedback_OutputChange(object sender, EventArgs e)