コード例 #1
0
        private void OnSelectedLanguage(string value)
        {
            if (_screenshot == null)
            {
                return;
            }

            IsOCRLoading = true;

            Task.Run(async() =>
            {
                var ocrResult = await _OCRService.GetText(SelectedOCRLanguage, _screenshot);

                Dispatcher.CurrentDispatcher.Invoke(() =>
                {
                    OCRResult    = ocrResult;
                    IsOCRLoading = false;
                });
            });
        }