mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-01-03 17:37:18 +00:00
renaming of translation component; removing of C++11 features
This commit is contained in:
parent
74ae479780
commit
1f71395660
@ -8,7 +8,7 @@
|
||||
|
||||
#include <components/bsa/bsa_archive.hpp>
|
||||
#include <components/files/configurationmanager.hpp>
|
||||
#include <components/translation_data/translation_data.hpp>
|
||||
#include <components/translation/translation.hpp>
|
||||
#include <components/nifoverrides/nifoverrides.hpp>
|
||||
|
||||
#include <components/nifbullet/bullet_nif_loader.hpp>
|
||||
@ -336,7 +336,7 @@ void OMW::Engine::go()
|
||||
mResDir, mCfgMgr.getCachePath(), mNewGame, mEncoding, mFallbackMap));
|
||||
|
||||
//Load translation data
|
||||
std::unique_ptr<TranslationData::Storage> translationDataStorage(new TranslationData::Storage(mEncoding));
|
||||
std::auto_ptr<TranslationData::Storage> translationDataStorage(new TranslationData::Storage(mEncoding));
|
||||
translationDataStorage->loadTranslationData(mFileCollections, mMaster);
|
||||
|
||||
// Create window manager - this manages all the MW-specific GUI windows
|
||||
|
@ -14,7 +14,7 @@
|
||||
#include <string>
|
||||
|
||||
#include <components/esm/loadclas.hpp>
|
||||
#include <components/translation_data/translation_data.hpp>
|
||||
#include <components/translation/translation.hpp>
|
||||
|
||||
#include "../mwbase/windowmanager.hpp"
|
||||
|
||||
@ -252,7 +252,7 @@ namespace MWGui
|
||||
SpellCreationDialog* mSpellCreationDialog;
|
||||
EnchantingDialog* mEnchantingDialog;
|
||||
TrainingWindow* mTrainingWindow;
|
||||
std::unique_ptr<TranslationData::Storage> mTranslationDataStorage;
|
||||
std::auto_ptr<TranslationData::Storage> mTranslationDataStorage;
|
||||
|
||||
CharacterCreation* mCharGen;
|
||||
|
||||
|
@ -62,8 +62,8 @@ add_component_dir (interpreter
|
||||
miscopcodes opcodes runtime scriptopcodes spatialopcodes types
|
||||
)
|
||||
|
||||
add_component_dir (translation_data
|
||||
translation_data
|
||||
add_component_dir (translation
|
||||
translation
|
||||
)
|
||||
|
||||
include_directories(${BULLET_INCLUDE_DIRS})
|
||||
|
@ -1,4 +1,4 @@
|
||||
#include "translation_data.hpp"
|
||||
#include "translation.hpp"
|
||||
#include <components/misc/stringops.hpp>
|
||||
|
||||
#include <fstream>
|
||||
@ -74,7 +74,8 @@ namespace TranslationData
|
||||
|
||||
std::string Storage::translateCellName(const std::string& cellName) const
|
||||
{
|
||||
auto entry = mCellNamesTranslations.find(cellName);
|
||||
std::map<std::string, std::string>::const_iterator entry =
|
||||
mCellNamesTranslations.find(cellName);
|
||||
|
||||
if (entry == mCellNamesTranslations.end())
|
||||
return cellName;
|
||||
@ -87,7 +88,9 @@ namespace TranslationData
|
||||
std::string result;
|
||||
|
||||
//seeking for the standard phrase form
|
||||
auto phraseFormsIterator = mPhraseForms.find(phrase);
|
||||
std::map<std::string, std::string>::const_iterator phraseFormsIterator =
|
||||
mPhraseForms.find(phrase);
|
||||
|
||||
if (phraseFormsIterator != mPhraseForms.end())
|
||||
result = phraseFormsIterator->second;
|
||||
else
|
||||
@ -95,7 +98,9 @@ namespace TranslationData
|
||||
|
||||
|
||||
//seeking for the topic ID
|
||||
auto topicIDIterator = mTopicIDs.find(result);
|
||||
std::map<std::string, std::string>::const_iterator topicIDIterator =
|
||||
mTopicIDs.find(result);
|
||||
|
||||
if (topicIDIterator != mTopicIDs.end())
|
||||
result = topicIDIterator->second;
|
||||
|
Loading…
Reference in New Issue
Block a user