Ejemplo n.º 1
0
 /// <summary>
 /// Calculates the score for how closely this window matches the search string
 /// </summary>
 /// <remarks>
 /// Higher Score is better
 /// </remarks>
 private void CalculateScore()
 {
     if (FuzzyMatching.CalculateScoreForMatches(SearchMatchesInProcessName) >
         FuzzyMatching.CalculateScoreForMatches(SearchMatchesInTitle))
     {
         Score           = FuzzyMatching.CalculateScoreForMatches(SearchMatchesInProcessName);
         BestScoreSource = TextType.ProcessName;
     }
     else
     {
         Score           = FuzzyMatching.CalculateScoreForMatches(SearchMatchesInTitle);
         BestScoreSource = TextType.WindowTitle;
     }
 }