Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>If anyone else encounters this particular warning in the console "Could not find mapped image UIPickerViewFrameRight-162-Popover.png", I think I've figured out why it appears.</p> <p>The HIG indicates loosely that UIPickerView should only be added to a Popover on the iPad.</p> <p>"On iPad, present a date and time picker only within a popover."</p> <p><a href="http://developer.apple.com/library/ios/#documentation/userexperience/conceptual/mobilehig/UIElementGuidelines/UIElementGuidelines.html">http://developer.apple.com/library/ios/#documentation/userexperience/conceptual/mobilehig/UIElementGuidelines/UIElementGuidelines.html</a></p> <p>In my experiments, the UIPickerView must be the direct and only view of the current UIViewController in a popover. If the UIPickerView appears elsewhere in a view hierarchy, the warning appears and the UIPickerView will look bad (like it's missing the left and right portions of the view).</p> <p>In the code above, you can see that the UIPickerView was added as a subview of the rootView in the customController:</p> <pre><code>[customViewController.view addSubview:menu]; </code></pre> <p>This probably would have worked if the UIPickerView was the root view in the customController. </p> <p>You can programmatically make the UIPickerView the root view of the controller by overriding the loadView method of the controller and assigning the UIPickerView directly to the root view of the controller:</p> <pre><code>- (void)loadView { CGRect frame = CGRectMake(0,0, 300, 300); UIPickerView *v = [[[UIPickerView alloc] initWithFrame:frame] autorelease]; v.delegate = self; // assuming controller adopts UIPickerViewDelegate v.dataSource = self; // assuming controller adopts UIPickerViewDataSource self.view = v; } </code></pre> <p>Hope this helps someone.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload