forked from mia/Aegisub
Log a warning in icon::get if the icon doesn't exist rather than using printf
Originally committed to SVN as r5755.
This commit is contained in:
parent
c7d0ce60ee
commit
1da6f46cb2
1 changed files with 5 additions and 8 deletions
|
@ -43,20 +43,17 @@ wxBitmap const& get(std::string const& name, const int size) {
|
||||||
// concerned about it.
|
// concerned about it.
|
||||||
if (size != 24) {
|
if (size != 24) {
|
||||||
iconMap::iterator index;
|
iconMap::iterator index;
|
||||||
|
if ((index = icon16.find(name)) != icon16.end())
|
||||||
if ((index = icon16.find(name)) != icon16.end()) {
|
|
||||||
return index->second;
|
return index->second;
|
||||||
}
|
|
||||||
printf("icon::get NOT FOUND (%s)\n", name.c_str());
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
iconMap::iterator index;
|
iconMap::iterator index;
|
||||||
|
if ((index = icon24.find(name)) != icon24.end())
|
||||||
if ((index = icon24.find(name)) != icon24.end()) {
|
|
||||||
return index->second;
|
return index->second;
|
||||||
}
|
|
||||||
printf("icon::get NOT FOUND (%s)\n", name.c_str());
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
LOG_W("icon/get") << "Icon not found: " << name << " " << size;
|
||||||
|
|
||||||
static wxBitmap empty;
|
static wxBitmap empty;
|
||||||
return empty;
|
return empty;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue