Properly handle load when QPixmap is null
This commit is contained in:
+2
-2
@@ -19,13 +19,13 @@ Image::Image(const QString name, ImageRingList *ringList) :
|
||||
|
||||
void Image::load()
|
||||
{
|
||||
if(m_pixmap.isNull() && !m_loading)
|
||||
if(m_pixmap.isNull() && !m_rawImage && !m_loading)
|
||||
{
|
||||
m_loading = true;
|
||||
m_released = false;
|
||||
QThreadPool::globalInstance()->start(new LoadRunable(m_name, this, m_ringList->analyzeLevel()));
|
||||
}
|
||||
if(!m_loading && !m_pixmap.isNull())
|
||||
if(!m_loading && (!m_pixmap.isNull() || m_rawImage))
|
||||
emit pixmapLoaded(this);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user