예제 #1
0
void MainWindow::slotLanguageChanged(QAction* action)
{
    WriteToLog(QtDebugMsg, QString("Translation->SlotStarted"));
    if(0 != action)
    {
        // load the language depending on the action content
        GlobalSettings::locale = m_currLang;

        lockTilesetBox=true;

        int doorType = ui->WarpType->currentIndex(); //backup combobox's index
        int npcGenType = ui->PROPS_NPCGenType->currentIndex(); //backup combobox's index

        loadLanguage(action->data().toString());

        ui->WarpType->setCurrentIndex(doorType); //restore combobox's index
        ui->PROPS_NPCGenType->setCurrentIndex(npcGenType);

        lockTilesetBox=false;

        setLvlItemBoxes();
        setLevelSectionData();
        setEventData(-1);
        setSoundList();
        WldLvlExitTypeListReset();
        setCurrentWorldSettings();
        setTileSetBox();

        DevConsole::retranslate();
    }
}
예제 #2
0
void WorldSettingsBox::re_translate()
{
    ui->retranslateUi(this);
    setCurrentWorldSettings();
}