Skip to content

Commit

Permalink
Fix image not showing in zoom window
Browse files Browse the repository at this point in the history
  • Loading branch information
Bionus committed Jul 15, 2018
1 parent 346d0db commit ee7a203
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions gui/src/viewer/zoom-window.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -713,7 +713,7 @@ void ZoomWindow::draw()
// GIF (using QLabel support for QMovie)
if (!m_isAnimated.isEmpty())
{
m_displayMovie = new QMovie(m_source, m_isAnimated.toLatin1(), this);
m_displayMovie = new QMovie(m_imagePath, m_isAnimated.toLatin1(), this);
m_displayMovie->start();
const QSize &movieSize = m_displayMovie->currentPixmap().size();
const QSize &imageSize = m_labelImage->size();
Expand All @@ -734,7 +734,7 @@ void ZoomWindow::draw()
else
{
m_displayImage = QPixmap();
m_displayImage.load(m_source);
m_displayImage.load(m_imagePath);
update();

if (m_isFullscreen && m_fullScreen != nullptr && m_fullScreen->isVisible())
Expand Down Expand Up @@ -832,9 +832,6 @@ void ZoomWindow::saveImage(bool fav)

case SaveButtonState::Delete:
{
QString ip = m_imagePath;
QString s = m_source;
bool eq = m_imagePath == m_source;
if (m_imagePath.isEmpty() || m_imagePath == m_source)
{ m_imagePath = m_profile->tempPath() + QDir::separator() + QUuid::createUuid().toString().mid(1, 36) + ".tmp"; }
if (QFile::exists(m_imagePath))
Expand Down

0 comments on commit ee7a203

Please sign in to comment.