QWidgetWindow: Avoid using global static non-trivial type.
Don't initialize it before main, instead, do it whenever QWidgetWindow::handleTabletEvent() is called, which is seldomly. Change-Id: I16935e223d4f9879257e7be026fee0215b9dde22 Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
This commit is contained in:
parent
decd18536c
commit
8458b4054a
@ -51,7 +51,6 @@ QT_BEGIN_NAMESPACE
|
|||||||
Q_WIDGETS_EXPORT extern bool qt_tab_all_widgets();
|
Q_WIDGETS_EXPORT extern bool qt_tab_all_widgets();
|
||||||
|
|
||||||
QWidget *qt_button_down = 0; // widget got last button-down
|
QWidget *qt_button_down = 0; // widget got last button-down
|
||||||
static QPointer<QWidget> qt_tablet_target = 0;
|
|
||||||
|
|
||||||
// popup control
|
// popup control
|
||||||
QWidget *qt_popup_down = 0; // popup that contains the pressed widget
|
QWidget *qt_popup_down = 0; // popup that contains the pressed widget
|
||||||
@ -873,6 +872,7 @@ bool QWidgetWindow::nativeEvent(const QByteArray &eventType, void *message, long
|
|||||||
#ifndef QT_NO_TABLETEVENT
|
#ifndef QT_NO_TABLETEVENT
|
||||||
void QWidgetWindow::handleTabletEvent(QTabletEvent *event)
|
void QWidgetWindow::handleTabletEvent(QTabletEvent *event)
|
||||||
{
|
{
|
||||||
|
static QPointer<QWidget> qt_tablet_target = 0;
|
||||||
if (event->type() == QEvent::TabletPress) {
|
if (event->type() == QEvent::TabletPress) {
|
||||||
QWidget *widget = m_widget->childAt(event->pos());
|
QWidget *widget = m_widget->childAt(event->pos());
|
||||||
if (!widget)
|
if (!widget)
|
||||||
|
Loading…
Reference in New Issue
Block a user