Kaydet (Commit) a0fd9de7 authored tarafından Gábor Stefanik's avatar Gábor Stefanik Kaydeden (comit) Michael Meeks

fdo#42779 followup: Do not check for icons in nonexistent lookaside directory.

Change-Id: Ic493c2e33767968e5a1c1cced66a88295c694b2b
üst 1bec4348
......@@ -391,16 +391,18 @@ bool ImplImageTree::iconCacheLookup(
bool ImplImageTree::find(
std::vector< rtl::OUString > const & paths, BitmapEx & bitmap)
{
for (Paths::iterator i(m_paths.begin()); i != m_paths.end(); ++i) {
for (std::vector< rtl::OUString >::const_reverse_iterator j(
paths.rbegin());
j != paths.rend(); ++j)
{
osl::File file(i->first + "/" + *j);
if (file.open(osl_File_OpenFlag_Read) == ::osl::FileBase::E_None) {
loadFromFile(file, *j, bitmap);
file.close();
return true;
if (!m_cacheIcons) {
for (Paths::iterator i(m_paths.begin()); i != m_paths.end(); ++i) {
for (std::vector< rtl::OUString >::const_reverse_iterator j(
paths.rbegin());
j != paths.rend(); ++j)
{
osl::File file(i->first + "/" + *j);
if (file.open(osl_File_OpenFlag_Read) == ::osl::FileBase::E_None) {
loadFromFile(file, *j, bitmap);
file.close();
return true;
}
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment