/*public WordsPair this[string s] * { * get { return Dict[s]; } * set { Dict[s] = value; } * }*/ public void Add(WordsPair pair) { pair.WordStudied += moveWordPair; if (pair.Studied) { LearnedWords.Add(pair); } else { WordsToStudy.Add(pair); } }
public void moveWordPair(WordsPair wPair) { if (wPair.Studied) { if (WordsToStudy.Remove(wPair)) { LearnedWords.Add(wPair); } } if (WordsToStudy.Count == 0) { WordsToStudy = LearnedWords; LearnedWords = new List <WordsPair>(); foreach (WordsPair pair in WordsToStudy) { pair.Reset(); } } }