aboutsummaryrefslogtreecommitdiffstats
path: root/src/declarative/particles/qsgmodelparticle.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/declarative/particles/qsgmodelparticle.cpp')
-rw-r--r--src/declarative/particles/qsgmodelparticle.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/declarative/particles/qsgmodelparticle.cpp b/src/declarative/particles/qsgmodelparticle.cpp
index 844b76dcb2..cb295d6717 100644
--- a/src/declarative/particles/qsgmodelparticle.cpp
+++ b/src/declarative/particles/qsgmodelparticle.cpp
@@ -171,7 +171,9 @@ void QSGModelParticle::initialize(int gIdx, int pIdx)
void QSGModelParticle::processPending()
{//can't create/delete arbitrary items in the render thread
foreach (QSGItem* item, m_deletables){
- item->setOpacity(0.);
+ item->setVisible(false);
+ if (m_fade)
+ item->setOpacity(0.);
m_model->release(item);
}
m_deletables.clear();
@@ -267,6 +269,7 @@ void QSGModelParticle::prepareNextFrame()
m_activeCount--;
continue;
}else{//Fade
+ data->delegate->setVisible(true);
if (m_fade){
qreal o = 1.;
if (t<0.2)
@@ -274,8 +277,6 @@ void QSGModelParticle::prepareNextFrame()
if (t>0.8)
o = (1-t)*5;
data->delegate->setOpacity(o);
- }else{
- data->delegate->setOpacity(1.);//###Without fade, it's just a binary toggle - if we turn it off we have to turn it back on
}
}
data->delegate->setX(data->curX() - data->delegate->width()/2 - m_systemOffset.x());