UIPopoverController's view controller gets resized after keyboard disappears?

Up vote 2 down vote favorite 4 share g+ share fb share tw.

I have a view controller inside a UIPopoverController. When I open a keyboard for a text field that belongs to the view in the popover, the view resizes to accommodate the keyboard. However, the view doesn't go back to the original size when the keyboard is dismissed.

Any ideas how to get it to resize back to what it was? Ios ipad uipopovercontroller link|improve this question edited Apr 4 '11 at 12:43AlexVogel1,399417 asked Mar 25 '11 at 4:05raheel366312 62% accept rate.

Related question keyboard resigning reduces popover height – AlexVogel Apr 4 '11 at 12:45.

Had this problem myself recently. The way I got around it was to observe the keyboard disappearing in the controller which controls the UIPopoverController: NSNotificationCenter defaultCenter addObserver:self selector:@selector(presentSearchPopover) name:UIKeyboardDidHideNotification object:nil; And then in -presentSearchPopover, present the UIPopoverController again (it's quite a seamless transition): - (void)presentSearchPopover { self. SearchPopoverController.

PopoverContentSize = CGSizeMake(width, height)); self. SearchPopoverController presentPopoverFromRect:someRect) inView:self. View permittedArrowDirections:UIPopoverArrowDirectionUp animated:YES; } Don't forget to remove the observer in -dealloc or similar too: - (void)dealloc { NSNotificationCenter defaultCenter removeObserver:self name:UIKeyboardDidHideNotification object:nil; super dealloc; }.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions