mirror of
https://github.com/OpenMW/openmw.git
synced 2025-03-27 03:40:24 +00:00
Make it build again (but remove the new functionality).
This commit is contained in:
parent
d9d5a6561b
commit
59639e3988
2 changed files with 18 additions and 8 deletions
|
@ -193,7 +193,7 @@ bool parseOptions (int argc, char** argv, OMW::Engine& engine, Files::Configurat
|
||||||
// directory settings
|
// directory settings
|
||||||
engine.enableFSStrict(variables["fs-strict"].as<bool>());
|
engine.enableFSStrict(variables["fs-strict"].as<bool>());
|
||||||
|
|
||||||
Files::PathContainer dataDirs(variables["data"].as<Files::EscapePathContainer>().mContainer);
|
Files::PathContainer dataDirs(Files::EscapePath::toPathContainer(variables["data"].as<Files::EscapePathContainer>()));
|
||||||
|
|
||||||
std::string local(variables["data-local"].as<Files::EscapeHashString>().toStdString());
|
std::string local(variables["data-local"].as<Files::EscapeHashString>().toStdString());
|
||||||
if (!local.empty())
|
if (!local.empty())
|
||||||
|
|
|
@ -70,21 +70,31 @@ namespace Files {
|
||||||
eSV->mVector.push_back(EscapeHashString(*it));
|
eSV->mVector.push_back(EscapeHashString(*it));
|
||||||
}
|
}
|
||||||
|
|
||||||
struct EscapePathContainer {
|
struct EscapePath {
|
||||||
PathContainer mContainer;
|
boost::filesystem::path mPath;
|
||||||
|
|
||||||
|
static PathContainer toPathContainer(const std::vector<EscapePath> & escapePathContainer);
|
||||||
};
|
};
|
||||||
|
|
||||||
std::istream & operator>> (std::istream & istream, EscapePathContainer & escapePathContainer)
|
typedef std::vector<EscapePath> EscapePathContainer;
|
||||||
|
|
||||||
|
PathContainer EscapePath::toPathContainer(const EscapePathContainer & escapePathContainer)
|
||||||
|
{
|
||||||
|
PathContainer temp;
|
||||||
|
for (EscapePathContainer::const_iterator it = escapePathContainer.begin(); it != escapePathContainer.end(); ++it)
|
||||||
|
temp.push_back(it->mPath);
|
||||||
|
return temp;
|
||||||
|
}
|
||||||
|
|
||||||
|
std::istream & operator>> (std::istream & istream, EscapePath & escapePath)
|
||||||
{
|
{
|
||||||
std::cout << "The new dodgy operator>> is being used" << std::endl;
|
std::cout << "The new dodgy operator>> is being used" << std::endl;
|
||||||
|
|
||||||
boost::iostreams::filtering_istream filteredStream;
|
boost::iostreams::filtering_istream filteredStream;
|
||||||
filteredStream.push(unescape_hash_filter());
|
//filteredStream.push(unescape_hash_filter());
|
||||||
filteredStream.push(istream);
|
filteredStream.push(istream);
|
||||||
|
|
||||||
boost::filesystem::path path;
|
filteredStream >> escapePath.mPath;
|
||||||
filteredStream >> path;
|
|
||||||
escapePathContainer.mContainer.push_back(path);
|
|
||||||
|
|
||||||
return istream;
|
return istream;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue