void ParticleSystem::update(sf::Time dt) { for (auto& particle : mParticles) { particle.lifeTime -= dt; } // Particles will be order by increasing lifetime, so pop until lifetime > 0 while (!mParticles.empty() && mParticles.front().lifeTime <= sf::seconds(0.f)) { mParticles.pop_front(); mVertexNeedsUpdate = true; } // If this is a moving particle system, the vertex needs to constantly update // due to moving particles if (mType != Particle::Trail) { applyEffects(dt); mVertexNeedsUpdate = true; } if (mVertexNeedsUpdate) { updateVertexArray(); mVertexNeedsUpdate = false; } }
void WidgetBorder::setTopmost(bool) { updateVertexArray(); }
void WidgetBorder::setBorderPadding(int value) { // TODO: getOrconst Widget & widgetCreateStateSet()->setAttribute(new osg::LineWidth(value)); updateVertexArray(); }
void WidgetBorder::setRect(int, int, int, int) { updateVertexArray(); }
void WidgetBorder::resize(unsigned int, unsigned int) { updateVertexArray(); }
void WidgetBorder::dragWidget(int deltaX, int deltaY) { updateVertexArray(); }
void WidgetBorder::setZ(float) { updateVertexArray(); }