diff --git a/APParallaxHeader/UIScrollView+APParallaxHeader.m b/APParallaxHeader/UIScrollView+APParallaxHeader.m index b9106ea..a732d70 100755 --- a/APParallaxHeader/UIScrollView+APParallaxHeader.m +++ b/APParallaxHeader/UIScrollView+APParallaxHeader.m @@ -43,7 +43,7 @@ - (void)addParallaxWithImage:(UIImage *)image andHeight:(CGFloat)height andShado } else { - APParallaxView *parallaxView = [[APParallaxView alloc] initWithFrame:CGRectMake(0, 0, self.bounds.size.width*2, height) andShadow:shadow]; + APParallaxView *parallaxView = [[APParallaxView alloc] initWithFrame:CGRectMake(0, 0, self.bounds.size.width, height) andShadow:shadow]; [parallaxView setClipsToBounds:YES]; [parallaxView.imageView setImage:image]; @@ -190,7 +190,7 @@ - (id)initWithFrame:(CGRect)frame andShadow:(BOOL)shadow { [self setBackgroundColor:[UIColor clearColor]]; // default styling values - [self setAutoresizingMask:UIViewAutoresizingFlexibleHeight]; + [self setAutoresizingMask:UIViewAutoresizingFlexibleWidth|UIViewAutoresizingFlexibleHeight]; [self setState:APParallaxTrackingActive]; self.imageView = [[UIImageView alloc] init];