+ fixes #0001859: Unable to select PNG files for icons for macros in Tools-Customize

This commit is contained in:
wmayer
2014-12-22 03:07:26 +01:00
parent 02cc02eaee
commit 5aefd2d346
5 changed files with 212 additions and 31 deletions

View File

@@ -114,16 +114,6 @@ BitmapFactoryInst::~BitmapFactoryInst()
delete d;
}
void BitmapFactoryInst::addCustomPath(const QString& path)
{
Base::Reference<ParameterGrp> group = App::GetApplication().GetParameterGroupByPath
("User parameter:BaseApp/Preferences/Bitmaps");
std::vector<std::string> paths = group->GetASCIIs("CustomPath");
std::stringstream str;
str << "CustomPath" << paths.size();
group->SetASCII(str.str().c_str(), (const char*)path.toUtf8());
}
void BitmapFactoryInst::restoreCustomPaths()
{
Base::Reference<ParameterGrp> group = App::GetApplication().GetParameterGroupByPath
@@ -145,6 +135,11 @@ void BitmapFactoryInst::removePath(const QString& path)
if (pos != -1) d->paths.removeAt(pos);
}
QStringList BitmapFactoryInst::getPaths() const
{
return d->paths;
}
QStringList BitmapFactoryInst::findIconFiles() const
{
QStringList files, filters;