private void SaveChoices()
 {
     if (_currentDeviceSpecificID != null)
     {
         CacheCurrentState();
     }
     foreach (DictionaryEntry entry in _cachedDeviceSpecifics)
     {
         AppliedFiltersCachedState state =
             (AppliedFiltersCachedState)entry.Value;
         state.SaveChoicesFromTreeView(
             _designer,
             (String)entry.Key
             );
     }
 }
 private bool RestoreState(String deviceSpecificID)
 {
     if (null != deviceSpecificID)
     {
         _currentDeviceSpecificID = deviceSpecificID;
         AppliedFiltersCachedState state =
             (AppliedFiltersCachedState)_cachedDeviceSpecifics[
                 _currentDeviceSpecificID
             ];
         if (state != null)
         {
             state.Restore(_appliedFiltersList.TvList);
             EnsureDefaultFilterAvailableXorApplied();
             return(true);
         }
     }
     else
     {
         _currentDeviceSpecificID = null;
     }
     return(false);
 }
 private void CacheState(String deviceSpecificID)
 {
     _cachedDeviceSpecifics[deviceSpecificID] = new AppliedFiltersCachedState(
         _appliedFiltersList.TvList
         );
 }
 private void CacheState(String deviceSpecificID)
 {
     _cachedDeviceSpecifics[deviceSpecificID] = new AppliedFiltersCachedState(
         _appliedFiltersList.TvList
     );
 }