Add Platform::screenNumberFor, removes more asQWidget() usage

This commit is contained in:
Sergio Martins
2022-04-21 21:47:55 +01:00
parent eff3798987
commit 4946cdeed3
10 changed files with 55 additions and 23 deletions

View File

@@ -29,6 +29,7 @@ public:
QVector<std::shared_ptr<Window>> windows() const override;
std::shared_ptr<Window> qobjectAsWindow(QObject *) const override;
virtual std::shared_ptr<Window> windowFromQWindow(QWindow *) const = 0;
int screenNumberFor(std::shared_ptr<Window>) const override;
void sendEvent(View *, QEvent *) const override;
@@ -43,6 +44,8 @@ public:
void tests_sendEvent(std::shared_ptr<Window>, QEvent *) const override;
void tests_initTests() const override;
#endif
protected:
int screenNumberForQWindow(QWindow *) const;
};
}