Commit d7d82914 authored by NICLAUSSE Nicolas's avatar NICLAUSSE Nicolas

do not take snapshot if region is not visible

parent 5e51e200
......@@ -113,6 +113,8 @@ void dtkWidgetsWorkspaceStackBarItem::setSource(QWidget *source)
timer->setSingleShot(false);
connect(timer, &QTimer::timeout, [=] (void) {
if (this->visibleRegion().isNull())
return;
QPixmap pixmap(this->source->size());
this->source->render(&pixmap);
this->overview->setPixmap(pixmap.scaledToWidth(280));
......
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