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
+14
View File
@@ -65,6 +65,15 @@ public:
**/
void showAndMoveTo(QPoint point, widgets::BoundsChecking mode);
/// @brief Applies the last moveTo operation if that one was bounds-checked
///
/// If there was a previous moveTo or showAndMoveTo operation with a mode
/// other than `Off`, a moveTo is repeated with the last supplied @a point
/// and @a mode. Note that in the case of showAndMoveTo, moveTo is run.
///
/// @returns true if there was a previous bounds-checked moveTo operation
bool applyLastBoundsCheck();
float scale() const override;
float qtFontScale() const;
@@ -152,6 +161,11 @@ private:
std::vector<Button *> buttons;
} ui_;
/// The last @a pos from moveTo and showAndMoveTo
QPoint lastBoundsCheckPosition_;
/// The last @a mode from moveTo and showAndMoveTo
widgets::BoundsChecking lastBoundsCheckMode_ = widgets::BoundsChecking::Off;
#ifdef USEWINSDK
/// @brief Returns the HWND of this window if it has one
///