mirror of
https://gitlab.opencode.de/bwi/bundesmessenger/clients/bundesmessenger-ios.git
synced 2026-04-25 19:10:49 +02:00
Fix iOS11 disruption
- RoomViewController, RoomDetailsVC, ContactDetailsVC: fix header layout. - Use UIScrollView+MatrixKit category to handle the adjusted content inset which is not defined before iOS 11.
This commit is contained in:
@@ -415,7 +415,7 @@ typedef void (^blockSettingsViewController_onReadyToDestroy)();
|
||||
// Observe kAppDelegateDidTapStatusBarNotificationObserver.
|
||||
kAppDelegateDidTapStatusBarNotificationObserver = [[NSNotificationCenter defaultCenter] addObserverForName:kAppDelegateDidTapStatusBarNotification object:nil queue:[NSOperationQueue mainQueue] usingBlock:^(NSNotification *notif) {
|
||||
|
||||
[self.tableView setContentOffset:CGPointMake(-self.tableView.contentInset.left, -self.tableView.contentInset.top) animated:YES];
|
||||
[self.tableView setContentOffset:CGPointMake(-self.tableView.mxk_adjustedContentInset.left, -self.tableView.mxk_adjustedContentInset.top) animated:YES];
|
||||
|
||||
}];
|
||||
|
||||
@@ -1702,7 +1702,7 @@ typedef void (^blockSettingsViewController_onReadyToDestroy)();
|
||||
NSString *theme = [[NSUserDefaults standardUserDefaults] stringForKey:@"userInterfaceTheme"];
|
||||
if (!theme)
|
||||
{
|
||||
if ([GBDeviceInfo deviceInfo].osVersion.major >= 11) //(@available(iOS 11.0, *)) requires Xcode 9
|
||||
if (@available(iOS 11.0, *))
|
||||
{
|
||||
// "auto" is used the default value from iOS 11
|
||||
theme = @"auto";
|
||||
@@ -3477,7 +3477,7 @@ typedef void (^blockSettingsViewController_onReadyToDestroy)();
|
||||
}
|
||||
};
|
||||
|
||||
if ([GBDeviceInfo deviceInfo].osVersion.major >= 11) //(@available(iOS 11.0, *)) requires Xcode 9
|
||||
if (@available(iOS 11.0, *))
|
||||
{
|
||||
// Show "auto" only from iOS 11
|
||||
autoAction = [UIAlertAction actionWithTitle:NSLocalizedStringFromTable(@"settings_ui_theme_auto", @"Vector", nil)
|
||||
|
||||
Reference in New Issue
Block a user