Qt 6.3 ( beta1 ) incompatibilities fixed
This commit is contained in:
parent
6295b137f3
commit
96e210ce3c
|
@ -14,6 +14,10 @@ QSK_QT_PRIVATE_BEGIN
|
||||||
#include <private/qquickwindow_p.h>
|
#include <private/qquickwindow_p.h>
|
||||||
QSK_QT_PRIVATE_END
|
QSK_QT_PRIVATE_END
|
||||||
|
|
||||||
|
#if QT_VERSION >= QT_VERSION_CHECK( 6, 3, 0 )
|
||||||
|
#include <private/qeventpoint_p.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
static QMouseEvent* qskClonedMouseEventAt(
|
static QMouseEvent* qskClonedMouseEventAt(
|
||||||
const QMouseEvent* event, QPointF* localPos )
|
const QMouseEvent* event, QPointF* localPos )
|
||||||
{
|
{
|
||||||
|
@ -25,13 +29,23 @@ static QMouseEvent* qskClonedMouseEventAt(
|
||||||
#else
|
#else
|
||||||
auto clonedEvent = event->clone();
|
auto clonedEvent = event->clone();
|
||||||
|
|
||||||
auto& point = QMutableEventPoint::from( clonedEvent->point( 0 ) );
|
|
||||||
point.detach();
|
|
||||||
point.setTimestamp( event->timestamp() );
|
|
||||||
|
|
||||||
if ( localPos )
|
if ( localPos )
|
||||||
|
{
|
||||||
|
#if QT_VERSION < QT_VERSION_CHECK( 6, 3, 0 )
|
||||||
|
auto& point = QMutableEventPoint::from( clonedEvent->point( 0 ) );
|
||||||
|
|
||||||
|
point.detach();
|
||||||
point.setPosition( *localPos );
|
point.setPosition( *localPos );
|
||||||
|
#else
|
||||||
|
auto& point = clonedEvent->point( 0 );
|
||||||
|
|
||||||
|
QMutableEventPoint::detach( point );
|
||||||
|
QMutableEventPoint::setPosition( point, *localPos );
|
||||||
#endif
|
#endif
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
Q_ASSERT( event->timestamp() == clonedEvent->timestamp() );
|
||||||
|
|
||||||
return clonedEvent;
|
return clonedEvent;
|
||||||
}
|
}
|
||||||
|
|
|
@ -25,8 +25,6 @@ namespace
|
||||||
class Option
|
class Option
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
Option() = default; // some compilers need this
|
|
||||||
|
|
||||||
Option( const QUrl& graphicSource, const QString& text )
|
Option( const QUrl& graphicSource, const QString& text )
|
||||||
: graphicSource( graphicSource )
|
: graphicSource( graphicSource )
|
||||||
, text( text )
|
, text( text )
|
||||||
|
@ -35,8 +33,8 @@ namespace
|
||||||
graphic = Qsk::loadGraphic( graphicSource );
|
graphic = Qsk::loadGraphic( graphicSource );
|
||||||
}
|
}
|
||||||
|
|
||||||
const QUrl graphicSource;
|
QUrl graphicSource;
|
||||||
const QString text;
|
QString text;
|
||||||
|
|
||||||
QskGraphic graphic;
|
QskGraphic graphic;
|
||||||
};
|
};
|
||||||
|
|
|
@ -240,12 +240,11 @@ void QskQuickItemPrivate::cleanupNodes()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
QSGTransformNode* QskQuickItemPrivate::createTransformNode()
|
/*
|
||||||
{
|
Can we do something useful with overloading:
|
||||||
return Inherited::createTransformNode();
|
|
||||||
}
|
|
||||||
|
|
||||||
void QskQuickItemPrivate::transformChanged()
|
- QQuickItemPrivate::createTransformNode
|
||||||
{
|
- QQuickItemPrivate::transformChanged
|
||||||
Inherited::transformChanged();
|
|
||||||
}
|
TODO ...
|
||||||
|
*/
|
||||||
|
|
|
@ -29,8 +29,6 @@ class QskQuickItemPrivate : public QQuickItemPrivate
|
||||||
virtual void implicitSizeChanged();
|
virtual void implicitSizeChanged();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
QSGTransformNode* createTransformNode() override;
|
|
||||||
void transformChanged() override;
|
|
||||||
|
|
||||||
void cleanupNodes();
|
void cleanupNodes();
|
||||||
void mirrorChange() override;
|
void mirrorChange() override;
|
||||||
|
|
|
@ -177,7 +177,7 @@ static inline void qskExecCommand(
|
||||||
if ( data->flags & QPaintEngine::DirtyHints )
|
if ( data->flags & QPaintEngine::DirtyHints )
|
||||||
{
|
{
|
||||||
#if 1
|
#if 1
|
||||||
auto state = QPainterPrivate::get( painter )->state;
|
auto& state = QPainterPrivate::get( painter )->state;
|
||||||
state->renderHints = data->renderHints;
|
state->renderHints = data->renderHints;
|
||||||
|
|
||||||
// to trigger internal updates we have to set at least one flag
|
// to trigger internal updates we have to set at least one flag
|
||||||
|
|
Loading…
Reference in New Issue