fixed(dock): fixed bug 1979

This commit is contained in:
wangxuwen 2019-09-20 16:05:22 +08:00
parent 116c2c5022
commit 2b3b52bbe8
3 changed files with 9 additions and 0 deletions

View File

@ -384,6 +384,11 @@ void DockSettings::resetFrontendGeometry()
m_dockInter->SetFrontendWindowRect(p.x(), p.y(), w, h);
}
void DockSettings::updateFrontendGeometry()
{
resetFrontendGeometry();
}
bool DockSettings::test(const Position pos, const QList<QRect> &otherScreens) const
{
QRect maxStrut(0, 0, m_screenRawWidth, m_screenRawHeight);

View File

@ -83,6 +83,8 @@ public:
qreal dockRatio() const;
void showDockSettingsMenu();
void updateFrontendGeometry();
QSize m_mainWindowSize;
DBusDock *m_dockInter;

View File

@ -365,6 +365,7 @@ void MainWindow::internalMove(const QPoint &p)
case Right: rp.setX(r.right() - 1); break;
case Bottom: rp.setY(r.bottom() - 1); break;
}
int hx = height() * ratio, wx = width() * ratio;
if (m_settings->hideMode() != HideMode::KeepShowing &&
isHide &&
@ -909,6 +910,7 @@ void MainWindow::onDragFinished()
}
setStrutPartial();
m_settings->updateFrontendGeometry();
}
#include "mainwindow.moc"