Improve support for iPad #5

Closed
mamcx opened this Issue Apr 3, 2012 · 3 comments

Comments

Projects
None yet
2 participants
@mamcx

mamcx commented Apr 3, 2012

The lib as is have some issues when used in iPad apps.

Mainly, the photo selection is based in tables, and when is in iPad show a lot of blank space. Is better to use a grid control here.

Also, if I try to use a different modal style this is not respected at all (always show full screen).

@costonb

This comment has been minimized.

Show comment Hide comment
@costonb

costonb Apr 4, 2012

Contributor

I tried several different modal styles and it seemed to respect them all. I have included the display code I used for the form sheet style. I have also tested full screen, page sheet and using a popover and all of them seemed to work as they should... I do need to make some adjustments to the thumb size though so that it's based on the frame size and not the device type.

PhotoPickerPlus *picker = [[PhotoPickerPlus alloc] init];
[picker setDelegate:self];
[picker setSourceType:PhotoPickerPlusSourceTypeAll];
[picker setModalPresentationStyle:UIModalPresentationFormSheet];
[self presentViewController:picker animated:YES completion:^(void){
    [picker release];
}];

As far as the grid control instead of the regular table, I'll look into this for a future version.

Contributor

costonb commented Apr 4, 2012

I tried several different modal styles and it seemed to respect them all. I have included the display code I used for the form sheet style. I have also tested full screen, page sheet and using a popover and all of them seemed to work as they should... I do need to make some adjustments to the thumb size though so that it's based on the frame size and not the device type.

PhotoPickerPlus *picker = [[PhotoPickerPlus alloc] init];
[picker setDelegate:self];
[picker setSourceType:PhotoPickerPlusSourceTypeAll];
[picker setModalPresentationStyle:UIModalPresentationFormSheet];
[self presentViewController:picker animated:YES completion:^(void){
    [picker release];
}];

As far as the grid control instead of the regular table, I'll look into this for a future version.

@costonb costonb closed this Apr 4, 2012

@mamcx

This comment has been minimized.

Show comment Hide comment
@mamcx

mamcx Apr 4, 2012

Perhaps the issue is related to when this is executed from another modal
view controller.

I report something similar here:

http://stackoverflow.com/questions/9960346/how-present-a-modal-controller-from-a-modal-controller-with-storyboard

Mario A.Montoya
Gerente
http://www.elmalabarista.com

Haz pedidos & facturas con tu iPhone: http://www.bestsellerapp.com

mamcx commented Apr 4, 2012

Perhaps the issue is related to when this is executed from another modal
view controller.

I report something similar here:

http://stackoverflow.com/questions/9960346/how-present-a-modal-controller-from-a-modal-controller-with-storyboard

Mario A.Montoya
Gerente
http://www.elmalabarista.com

Haz pedidos & facturas con tu iPhone: http://www.bestsellerapp.com

@costonb

This comment has been minimized.

Show comment Hide comment
@costonb

costonb Apr 14, 2012

Contributor

If you are trying to have the picker use the same modal style as another controller that is calling it then you can simply do

PhotoPickerPlus *temp = [[PhotoPickerPlus alloc] init];
[temp setDelegate:self];
[temp setSourceType:PhotoPickerPlusSourceTypeAll];
[temp setModalPresentationStyle:[self modalPresentationStyle]];
[self presentModalViewController:temp animated:YES];
[temp release];

I'm not sure if you're looking for something other than that, but from what you said, that seems like it would solve your issue.

Contributor

costonb commented Apr 14, 2012

If you are trying to have the picker use the same modal style as another controller that is calling it then you can simply do

PhotoPickerPlus *temp = [[PhotoPickerPlus alloc] init];
[temp setDelegate:self];
[temp setSourceType:PhotoPickerPlusSourceTypeAll];
[temp setModalPresentationStyle:[self modalPresentationStyle]];
[self presentModalViewController:temp animated:YES];
[temp release];

I'm not sure if you're looking for something other than that, but from what you said, that seems like it would solve your issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment