remove unused and error-prone function

This commit is contained in:
Juergen Spitzmueller 2013-09-15 17:19:51 +02:00
parent 6102e4c39c
commit 00cd9ce4a9
2 changed files with 0 additions and 28 deletions

View File

@ -100,19 +100,6 @@ private:
};
class FormatPrettyNameEqual : public unary_function<Format, bool> {
public:
FormatPrettyNameEqual(string const & prettyname)
: prettyname_(prettyname)
{}
bool operator()(Format const & f) const
{
return f.prettyname() == prettyname_;
}
private:
string prettyname_;
};
} //namespace anon
bool Format::formatSorter(Format const * lhs, Format const * rhs)
@ -473,19 +460,6 @@ string Formats::getFormatFromExtension(string const & ext) const
}
string Formats::getFormatFromPrettyName(string const & prettyname) const
{
if (!prettyname.empty()) {
Formats::const_iterator cit =
find_if(formatlist.begin(), formatlist.end(),
FormatPrettyNameEqual(prettyname));
if (cit != formats.end())
return cit->name();
}
return string();
}
/// Used to store last timestamp of file and whether it is (was) zipped
struct ZippedInfo {
bool zipped;

View File

@ -156,8 +156,6 @@ public:
std::string getFormatFromFile(support::FileName const & filename) const;
/// Finds a format from a file extension. Returns string() if not found.
std::string getFormatFromExtension(std::string const & ext) const;
/// Finds a format by pretty name. Returns string() if not found.
std::string getFormatFromPrettyName(std::string const & prettyname) const;
/** Returns true if the file referenced by \p filename is zipped and
** needs to be unzipped for being handled
** @note For natively zipped formats, such as dia/odg, this returns false.