Write corrected text to separate property
This commit is contained in:
		
							parent
							
								
									ab23b6ba6c
								
							
						
					
					
						commit
						d945081dab
					
				@ -14,7 +14,7 @@ void Corrector::correct(const TaskPtr &task)
 | 
			
		||||
  SOFT_ASSERT(task->isValid(), return );
 | 
			
		||||
 | 
			
		||||
  if (!userSubstitutions_.empty())
 | 
			
		||||
    task->recognized = substituteUser(task->recognized, task->sourceLanguage);
 | 
			
		||||
    task->corrected = substituteUser(task->recognized, task->sourceLanguage);
 | 
			
		||||
 | 
			
		||||
  manager_.corrected(task);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
@ -13,6 +13,7 @@ public:
 | 
			
		||||
  QPoint capturePoint;
 | 
			
		||||
  QPixmap captured;
 | 
			
		||||
  QString recognized;
 | 
			
		||||
  QString corrected;
 | 
			
		||||
  QString translated;
 | 
			
		||||
 | 
			
		||||
  LanguageId sourceLanguage;
 | 
			
		||||
 | 
			
		||||
@ -102,8 +102,7 @@ void WebPage::start(const TaskPtr &task)
 | 
			
		||||
  isBusy_ = true;
 | 
			
		||||
  nextIdleTime_ = QDateTime::currentDateTime().addSecs(timeout_.count());
 | 
			
		||||
 | 
			
		||||
  proxy_->translate(task->recognized, task->sourceLanguage,
 | 
			
		||||
                    langCodes->iso639_1);
 | 
			
		||||
  proxy_->translate(task->corrected, task->sourceLanguage, langCodes->iso639_1);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
bool WebPage::isBusy() const
 | 
			
		||||
 | 
			
		||||
		Loading…
	
		Reference in New Issue
	
	Block a user