Logo Search packages:      
Sourcecode: kanagram version File versions  Download package

void Kanagram::refreshVocabularies (  ) [private, slot]

refresh the list of vocabularies in the vocabulary chooser in the config window. This queries the files on disk to see what vocabularies have been added/removed.

Definition at line 886 of file kanagram.cpp.

References KanagramGame::getFilename(), hideHint(), m_game, m_vocabSettings, KanagramGame::nextAnagram(), KanagramGame::nextVocab(), play(), VocabSettings::refreshView(), and KanagramGame::refreshVocabList().

Referenced by reloadSettings().

{
    if (m_game->refreshVocabList())
    {
        // vocab/word are no longer valid, so get new ones and hide the hint
        m_game->nextVocab();
        m_game->nextAnagram();
        hideHint();

        if (m_useSounds)
        {
            play("chalk.ogg");
        }

        // save the default vocab now that it's changed
        KanagramSettings::setDefaultVocab(m_game->getFilename());
        KanagramSettings::self()->writeConfig();
        m_vocabSettings->refreshView();
    }
}

Here is the call graph for this function:

Here is the caller graph for this function:


Generated by  Doxygen 1.6.0   Back to index