fix: tooltips showing out-of-bounds after loading images (#5186)

This commit is contained in:
nerix
2024-02-24 12:52:16 +01:00
committed by GitHub
parent dcd6179434
commit dd61482046
5 changed files with 32 additions and 0 deletions
+15
View File
@@ -531,14 +531,29 @@ void BaseWindow::leaveEvent(QEvent *)
void BaseWindow::moveTo(QPoint point, widgets::BoundsChecking mode)
{
this->lastBoundsCheckPosition_ = point;
this->lastBoundsCheckMode_ = mode;
widgets::moveWindowTo(this, point, mode);
}
void BaseWindow::showAndMoveTo(QPoint point, widgets::BoundsChecking mode)
{
this->lastBoundsCheckPosition_ = point;
this->lastBoundsCheckMode_ = mode;
widgets::showAndMoveWindowTo(this, point, mode);
}
bool BaseWindow::applyLastBoundsCheck()
{
if (this->lastBoundsCheckMode_ == widgets::BoundsChecking::Off)
{
return false;
}
this->moveTo(this->lastBoundsCheckPosition_, this->lastBoundsCheckMode_);
return true;
}
void BaseWindow::resizeEvent(QResizeEvent *)
{
// Queue up save because: Window resized