Fix Android build on Windows hosts

This commit is contained in:
Brad Davis 2018-10-22 11:22:30 -07:00
parent 3f2f5b18ec
commit 4cf4a5582d
2 changed files with 2 additions and 4 deletions

View file

@ -292,8 +292,8 @@ int InteractiveWindow::getPresentationMode() const {
return _qmlWindow->property(PRESENTATION_MODE_PROPERTY).toInt();
}
#ifdef Q_OS_WIN
void InteractiveWindow::parentNativeWindowToMainWindow() {
#ifdef Q_OS_WIN
if (QThread::currentThread() != thread()) {
QMetaObject::invokeMethod(this, "parentNativeWindowToMainWindow");
return;
@ -307,8 +307,8 @@ void InteractiveWindow::parentNativeWindowToMainWindow() {
}
const auto nativeWindow = qvariant_cast<QQuickWindow*>(nativeWindowProperty);
SetWindowLongPtr((HWND)nativeWindow->winId(), GWLP_HWNDPARENT, (LONG)MainWindow::findMainWindow()->winId());
}
#endif
}
void InteractiveWindow::setPresentationMode(int presentationMode) {
if (QThread::currentThread() != thread()) {

View file

@ -84,9 +84,7 @@ private:
Q_INVOKABLE void setPresentationMode(int presentationMode);
Q_INVOKABLE int getPresentationMode() const;
#ifdef Q_OS_WIN
Q_INVOKABLE void parentNativeWindowToMainWindow();
#endif
public slots: