Bug Fix in Settings:

- The slider related to the maximum cache size is not working.
- The user is logged out when he press "Clear cache" button.
This commit is contained in:
giomfo 2015-08-07 15:34:28 +02:00
parent 4718da2503
commit d652815f55

View file

@ -238,7 +238,6 @@
- (IBAction)onButtonPressed:(id)sender
{
if (sender == allEventsSwitch)
{
_settings.showAllEventsInRoomHistory = allEventsSwitch.on;
@ -390,6 +389,8 @@
}
[logoutBtnCell.mxkButton setTitle:NSLocalizedStringFromTable(@"account_logout_all", @"MatrixConsole", nil) forState:UIControlStateNormal];
[logoutBtnCell.mxkButton setTitle:NSLocalizedStringFromTable(@"account_logout_all", @"MatrixConsole", nil) forState:UIControlStateHighlighted];
[logoutBtnCell.mxkButton removeTarget:self action:nil forControlEvents:UIControlEventTouchUpInside];
[logoutBtnCell.mxkButton addTarget:self action:@selector(logout:) forControlEvents:UIControlEventTouchUpInside];
cell = logoutBtnCell;
@ -483,7 +484,9 @@
[clearCacheBtnCell.mxkButton setTitle:btnTitle forState:UIControlStateHighlighted];
clearCacheButton = clearCacheBtnCell.mxkButton;
[clearCacheBtnCell.mxkButton addTarget:self action:@selector(onButtonPressed:) forControlEvents:UIControlEventTouchUpInside];
[clearCacheButton removeTarget:self action:nil forControlEvents:UIControlEventTouchUpInside];
[clearCacheButton addTarget:self action:@selector(onButtonPressed:) forControlEvents:UIControlEventTouchUpInside];
cell = clearCacheBtnCell;
}
@ -500,6 +503,8 @@
maxCacheSizeCell.mxkSlider.value = self.currentMaxCachesSize;
[self onSliderValueChange:maxCacheSizeCell.mxkSlider];
[maxCacheSizeCell.mxkSlider addTarget:self action:@selector(onSliderValueChange:) forControlEvents:UIControlEventValueChanged];
cell = maxCacheSizeCell;
}
else