CPersonalizeGui: try to fix wrong active mode after changed settings

By treating of notifier methods or generally changed personalization
settings of items, the values of "active" and "current_active" may differ
and although that could be active = true, current_active = false, or
vice versa. After restart of neutrino it would not conspicuous because
activ and current_active will be equated.
Otherwise it can happen, the modified items could be displayed
in wrong mode at runtime.
This try should fix this by writing the values from the current
settings into the current_active variable.


Origin commit data
------------------
Commit: 4875f81491
Author: Thilo Graf <dbt@novatux.de>
Date: 2015-12-26 (Sat, 26 Dec 2015)
This commit is contained in:
2015-12-26 21:09:00 +01:00
parent edf48f0011
commit 0737b16c6b

View File

@@ -976,6 +976,9 @@ void CPersonalizeGui::addPersonalizedItems()
sigc::slot0<void> sl = sigc::bind<0>(sigc::mem_fun1(v_item[i].menuItem, &CMenuForwarder::disableByCondition), v_item[i].condition); sigc::slot0<void> sl = sigc::bind<0>(sigc::mem_fun1(v_item[i].menuItem, &CMenuForwarder::disableByCondition), v_item[i].condition);
v_item[i].menuItem->OnPaintItem.connect(sl); v_item[i].menuItem->OnPaintItem.connect(sl);
v_item[i].default_selected = false; v_item[i].default_selected = false;
//value of current_active for personalized item must have value of current settings state here!
v_item[i].menuItem->current_active = (p_mode || i_mode);
} }
//add item if it's set to visible or pin protected and allow to add an forwarder as next //add item if it's set to visible or pin protected and allow to add an forwarder as next