removed Caching related setting from NoNet

This commit is contained in:
Philipp Crocoll 2013-09-03 21:37:43 +02:00
parent dd5710cf79
commit 2ca50c5778
2 changed files with 15 additions and 2 deletions

View File

@ -435,7 +435,6 @@ namespace keepass2android
///Application class for Keepass2Android: Contains static Database variable to be used by all components.
#if NoNet
[Application(Debuggable=false, Label=AppNames.AppName)]
todo: remove caching preference
#else
#if RELEASE
[Application(Debuggable=false, Label=AppNames.AppName)]

View File

@ -44,7 +44,21 @@ namespace keepass2android
FindPreference(GetString(Resource.String.keyfile_key)).PreferenceChange += OnRememberKeyFileHistoryChanged;
FindPreference(GetString(Resource.String.ShowUnlockedNotification_key)).PreferenceChange += OnShowUnlockedNotificationChanged;;
FindPreference(GetString(Resource.String.UseOfflineCache_key)).PreferenceChange += OnUseOfflineCacheChanged;
Preference cachingPreference = FindPreference(GetString(Resource.String.UseOfflineCache_key));
cachingPreference.PreferenceChange += OnUseOfflineCacheChanged;
#if NoNet
try
{
((PreferenceCategory) FindPreference(GetString(Resource.String.db_key))).RemovePreference(cachingPreference);
}
catch (Exception ex)
{
Kp2aLog.Log(ex.ToString());
}
#endif
FindPreference(GetString(Resource.String.db_key)).Enabled = false;
}