After calling the system's address book interface CNContactPickerViewController, the contact list is offset upward and then blocked by the search box.

problem description

after calling the system"s address book interface CNContactPickerViewController, the contact list is offset upward and then blocked by the search box.

the environmental background of the problems and what methods you have tried

I have tried to create a separate clean demo (completely native) to implement it, but the above bug, did not appear, so I thought it might have something to do with my own settings

.

related codes

/ / Please paste the code text below (do not replace the code with pictures)
[HXHAddressBookManager checkAddressBookIOS9AfterAuthorization: ^ (bool isAuthorized) {

]
        if (isAuthorized) {
            CNContactPickerViewController *contactPicker = [[CNContactPickerViewController alloc] init];
            
            contactPicker.displayedPropertyKeys = @[CNContactPhoneNumbersKey];
            contactPicker.predicateForSelectionOfContact = [NSPredicate predicateWithFormat:@"emailAddresses.@count == 1"];
            
            contactPicker.delegate = weakSelf;
            [weakSelf presentViewController:contactPicker animated:YES completion:nil];
        } else {
            [self setTextHUD:@""];
        }
    }];

what result do you expect? What is the error message actually seen?

look forward to the support of the big gods who encounter the same or similar problems. Thank you now.


if contentInsetAdjustmentBehavior = UIScrollViewContentInsetAdjustmentNever; of UIScrollView is set, the problem of automatic adaptation will occur.

Menu