fix: plugin can not popup content window.

Change-Id: I2bdaf64964061b686a7e2fd946a467a23277289f
This commit is contained in:
rekols 2018-04-26 20:05:54 +08:00
parent afd0a52421
commit a3c84e3c98
Notes: gerrit 2018-05-02 16:32:50 +08:00
Verified+1: Anonymous Coward #1000004
Code-Review+2: rekols <rekols@foxmail.com>
Submitted-by: rekols <rekols@foxmail.com>
Submitted-at: Wed, 02 May 2018 16:32:50 +0800
Reviewed-on: https://cr.deepin.io/34134
Project: dde/dde-dock
Branch: refs/heads/master

View File

@ -81,10 +81,11 @@ void DockPopupWindow::show(const QPoint &pos, const bool model)
show(pos.x(), pos.y());
const bool regionRegistered = m_regionInter->registered();
if (!m_model && regionRegistered)
if (!m_model && regionRegistered) {
m_regionInter->unregisterRegion();
else if (m_model && !regionRegistered)
m_regionInter->registerRegion();
} else if (m_model && !regionRegistered) {
QTimer::singleShot(100, this, [=] { m_regionInter->registerRegion(); });
}
}
void DockPopupWindow::show(const int x, const int y)