Paypal Lib: Orientation Question

I have included Paypal lib in my application. Link: https://www.x.com/community/ppx/xspaces/mobile/mep

My application is in landscape mode, when you call PayPal, the screen comes in portrait mode.

in any case, this behavior should be redefined.

thanks.

+1
source share
2 answers

After talking with Tech guy from PayPal, the next answer I received

The payment part only works in portrait mode. It was a design decision to avoid over-scrolling.

+2
source

After I came across this line in the PayPal MPL documentation, I thought it was not possible to show the flag display in landscape mode. Fortunately, there is a way to do this manually. Thanks to my colleagues :)

The checkbox presented is an instance of PayPalViewClass. Just add a method to view all views and all subitems to find the instanse of this class. After you find the view you were looking for, just apply the setTransform method to it. The method should look like this:

-(void) cicle:(UIView*)v{ for (UIView *_v in [v subviews]) { if ([_v isKindOfClass:[NSClassFromString(@"PayPalViewClass") class]]) { [v setTransform:CGAffineTransformMakeRotation(-M_PI/2)]; } [self cicle:_v]; } } 

It must be called in your payWithPayPal method. Hope this helps;)

+1
source

All Articles