【发布时间】:2013-02-28 10:23:16
【问题描述】:
条形样式为BlackOpaque 我的人员选择器看起来像:
但是当我希望 barStyle 为 BlackTranslucent 时,它看起来像这样:
我已经尝试过here的解决方案
代码:
- (void)showPeoplePickerController
{
ABPeoplePickerNavigationController *picker = [[ABPeoplePickerNavigationController alloc] init];
picker.peoplePickerDelegate = self;
NSArray *displayedItems = [NSArray arrayWithObjects:[NSNumber numberWithInt:kABPersonPhoneProperty],
[NSNumber numberWithInt:kABPersonEmailProperty],
[NSNumber numberWithInt:kABPersonBirthdayProperty],[NSNumber numberWithInt:kABPersonAddressProperty],nil];
picker.displayedProperties = displayedItems;
picker.navigationBar.barStyle = UIBarStyleBlack;
// picker.navigationBar.translucent = YES; //uncommented for translucent bar
[self.navigationController presentModalViewController:picker animated:YES];
}
但是我该如何从 PeoplePicker 下移呢?
【问题讨论】:
-
分享一些代码...如何添加 ABPeoplePickerNavigationController 导航栏样式...
-
@Vishal:请看我的编辑
标签: iphone ios abpeoplepickerview peoplepicker