more properties

This commit is contained in:
Uwe Rathmann 2021-02-01 10:09:37 +01:00
parent 6ee7a0c840
commit 38d0397c5e
4 changed files with 10 additions and 6 deletions

View File

@ -422,7 +422,7 @@ bool QskQuickItem::isUpdateNodeScheduled() const
bool QskQuickItem::isInitiallyPainted() const bool QskQuickItem::isInitiallyPainted() const
{ {
return d_func()->isInitiallyPainted; return d_func()->initiallyPainted;
} }
bool QskQuickItem::maybeUnresized() const bool QskQuickItem::maybeUnresized() const
@ -755,7 +755,7 @@ void QskQuickItem::itemChange( QQuickItem::ItemChange change,
if ( d->controlFlags & QskQuickItem::CleanupOnVisibility ) if ( d->controlFlags & QskQuickItem::CleanupOnVisibility )
d->cleanupNodes(); d->cleanupNodes();
d->isInitiallyPainted = false; d->initiallyPainted = false;
} }
if ( parentItem() && parentItem()->isVisible() ) if ( parentItem() && parentItem()->isVisible() )
@ -837,7 +837,7 @@ void QskQuickItem::updatePolish()
d->blockedPolish = false; d->blockedPolish = false;
if ( !d->isInitiallyPainted ) if ( !d->initiallyPainted )
{ {
/* /*
We should find a better way for identifying, when We should find a better way for identifying, when
@ -866,7 +866,7 @@ QSGNode* QskQuickItem::updatePaintNode( QSGNode* node, UpdatePaintNodeData* data
Q_ASSERT( isVisible() || !( d->controlFlags & QskQuickItem::DeferredUpdate ) ); Q_ASSERT( isVisible() || !( d->controlFlags & QskQuickItem::DeferredUpdate ) );
d->isInitiallyPainted = true; d->initiallyPainted = true;
if ( d->clearPreviousNodes ) if ( d->clearPreviousNodes )
{ {

View File

@ -28,6 +28,10 @@ class QSK_EXPORT QskQuickItem : public QQuickItem
Q_PROPERTY( bool polishOnResize READ polishOnResize Q_PROPERTY( bool polishOnResize READ polishOnResize
WRITE setPolishOnResize NOTIFY itemFlagsChanged FINAL ) WRITE setPolishOnResize NOTIFY itemFlagsChanged FINAL )
Q_PROPERTY( bool visibleToParent READ isVisibleToParent )
Q_PROPERTY( bool hasChildItems READ hasChildItems )
Q_PROPERTY( bool initiallyPainted READ isInitiallyPainted )
using Inherited = QQuickItem; using Inherited = QQuickItem;
public: public:

View File

@ -25,7 +25,7 @@ QskQuickItemPrivate::QskQuickItemPrivate()
, blockedPolish( false ) , blockedPolish( false )
, blockedImplicitSize( true ) , blockedImplicitSize( true )
, clearPreviousNodes( false ) , clearPreviousNodes( false )
, isInitiallyPainted( false ) , initiallyPainted( false )
{ {
if ( controlFlags & QskQuickItem::DeferredLayout ) if ( controlFlags & QskQuickItem::DeferredLayout )
{ {

View File

@ -55,7 +55,7 @@ class QskQuickItemPrivate : public QQuickItemPrivate
bool blockedImplicitSize : 1; bool blockedImplicitSize : 1;
bool clearPreviousNodes : 1; bool clearPreviousNodes : 1;
bool isInitiallyPainted : 1; bool initiallyPainted : 1;
}; };
#endif #endif