Forward "_q_platform_*" QWidgets's properties to QWindow.
This way we can customize QPlatformWindow by using dynamic "_q_platform_" properties in corresponding QWindow. Change-Id: I987b7a17d252541fe766af6aa37a6cffb67f1807 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com> Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com> Reviewed-by: Andy Shaw <andy.shaw@digia.com>bb10
parent
7d012552b0
commit
041c4d9c0b
|
|
@ -8358,6 +8358,8 @@ bool QWidget::event(QEvent *event)
|
|||
d->extra->customDpiY = value;
|
||||
d->updateFont(d->data.fnt);
|
||||
}
|
||||
if (windowHandle() && !qstrncmp(propName, "_q_platform_", 12))
|
||||
windowHandle()->setProperty(propName, property(propName));
|
||||
// fall through
|
||||
}
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -110,6 +110,11 @@ void QWidgetPrivate::create_sys(WId window, bool initializeWindow, bool destroyO
|
|||
win = topData()->window;
|
||||
}
|
||||
|
||||
foreach (const QByteArray &propertyName, q->dynamicPropertyNames()) {
|
||||
if (!qstrncmp(propertyName, "_q_platform_", 12))
|
||||
win->setProperty(propertyName, q->property(propertyName));
|
||||
}
|
||||
|
||||
win->setFlags(data.window_flags);
|
||||
fixPosIncludesFrame();
|
||||
if (q->testAttribute(Qt::WA_Moved)
|
||||
|
|
|
|||
Loading…
Reference in New Issue