Avoid to update ribbon widget too many times.

It fixes displaying screenshots in GP editor after switching between category tabs.
This commit is contained in:
deve 2014-09-23 15:41:31 +02:00
parent cfa4d455b0
commit 227b6aee22

View File

@ -489,6 +489,11 @@ void DynamicRibbonWidget::addAnimatedItem( const irr::core::stringw& user_name,
// -----------------------------------------------------------------------------
void DynamicRibbonWidget::clearItems()
{
if (m_animated_contents)
{
GUIEngine::needsUpdate.remove(this);
}
m_items.clear();
m_animated_contents = false;
m_scroll_offset = 0;