private void RefreshCapturingState() { if (null == mDxScreenCapture) { mDxScreenCapture = new DxScreenCapture(); } if (Settings.TransferActive || Settings.OverlayActive) { mDxScreenCapture.Start(); } else { mDxScreenCapture.Stop(); mDxScreenCapture = null; } }
private void StopBackgroundWorkers() { if (null != mOverlay) { mOverlay.Stop(); mOverlay = null; } if (null != mSerialStream) { mSerialStream.Stop(); mSerialStream = null; } if (null != mDxScreenCapture) { mDxScreenCapture.Stop(); mDxScreenCapture = null; } }