public DisplayCrossbarPropertyPage ( |
||
parentWindow | Handle of parent window. | |
Результат | void |
public void DisplayCrossbarPropertyPage(IntPtr parentWindow)
{
lock (sync)
{
// wait max 5 seconds till the flag gets initialized
for (int i = 0; (i < 500) && (!isCrossbarAvailable.HasValue) && (IsRunning); i++)
{
Thread.Sleep(10);
}
if ((!IsRunning) || (!isCrossbarAvailable.HasValue))
{
throw new ApplicationException("The video source must be running in order to display crossbar property page.");
}
if (!isCrossbarAvailable.Value)
{
throw new NotSupportedException("Crossbar configuration is not supported by currently running video source.");
}
// pass the request to background thread if video source is running
parentWindowForPropertyPage = parentWindow;
needToDisplayCrossBarPropertyPage = true;
}
}