private void DeviceRemoved(ControlPoint.CpDeviceList aList, ControlPoint.ICpDevice aDevice)
{
lock (this)
{
if (!iListFrozen)
{
PrintDeviceInfo("Removed", aDevice);
string udn = aDevice.Udn();
int count = iDeviceList.Count;
for (int i = 0; i < count; i++)
{
if (iDeviceList[i].Udn() == udn)
{
iDeviceList[i].RemoveRef();
iDeviceList.RemoveAt(i);
break;
}
}
}
}
}