Permalink
Browse files

Fixed issue on retina display.

  • Loading branch information...
1 parent 617d74f commit abf8ea45e3777b9f1fa3d4b8ea40e409d2435177 @kishikawakatsumi committed Jul 7, 2010
Showing with 12 additions and 4 deletions.
  1. +2 −2 Classes/TiledLayerViewController.m
  2. +6 −0 Classes/TiledView.m
  3. +4 −2 TiledLayerView.xcodeproj/project.pbxproj
@@ -21,8 +21,8 @@ - (void)viewDidLoad {
scrollView = [[UIScrollView alloc] initWithFrame:CGRectMake(0.0f, 0.0f, 320.0f, 460.0f)];
scrollView.contentSize = tiledView.bounds.size;
- scrollView.maximumZoomScale = 4.0f;
- scrollView.minimumZoomScale = 0.5f;
+ scrollView.maximumZoomScale = 4.0f;
+ scrollView.minimumZoomScale = 0.5f;
scrollView.delegate = tiledView;
[scrollView addSubview:tiledView];
[tiledView release];
View
@@ -36,6 +36,12 @@ - (void)drawRect:(CGRect)rect {
[image drawInRect:rect];
}
+- (void)layoutSubviews {
+ if ([self respondsToSelector:@selector(contentScaleFactor)]) {
+ self.contentScaleFactor = 1.0f;
+ }
+}
+
- (BOOL)scrollViewShouldScrollToTop:(UIScrollView *)scrollView {
[self setNeedsDisplay];
return NO;
@@ -626,10 +626,11 @@
GCC_C_LANGUAGE_STANDARD = c99;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
+ IPHONEOS_DEPLOYMENT_TARGET = 3.0;
ONLY_ACTIVE_ARCH = YES;
PREBINDING = NO;
"PROVISIONING_PROFILE[sdk=iphoneos*]" = "FE70928C-E17E-408F-B53C-6EAD529373A7";
- SDKROOT = iphoneos2.2.1;
+ SDKROOT = iphoneos4.0;
};
name = Debug;
};
@@ -641,8 +642,9 @@
GCC_C_LANGUAGE_STANDARD = c99;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
+ IPHONEOS_DEPLOYMENT_TARGET = 3.0;
PREBINDING = NO;
- SDKROOT = iphoneos2.2.1;
+ SDKROOT = iphoneos4.0;
};
name = Release;
};

0 comments on commit abf8ea4

Please sign in to comment.