Skip to content

Commit

Permalink
CHG:边角的一像素缺陷
Browse files Browse the repository at this point in the history
  • Loading branch information
Vincent7 committed May 25, 2015
1 parent 5775af9 commit 03c4b6c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions QRCodeReaderViewController/QRCodeReaderView.m
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,8 @@ - (void)drawRect:(CGRect)rect{
CGRect offsetRect = CGRectOffset(innerRect, 0, 15);

_overlay.lineDashPattern = @[@(rectWidth/3), @(rectWidth*2/3)];
_overlay.lineDashPhase = rectWidth/6;
_overlay.path = [UIBezierPath bezierPathWithRoundedRect:offsetRect cornerRadius:0].CGPath;
_overlay.lineDashPhase = rectWidth*1.0/6.0+2;
_overlay.path = [UIBezierPath bezierPathWithRoundedRect:offsetRect cornerRadius:1].CGPath;

// CGContextRef context = UIGraphicsGetCurrentContext();
CGMutablePathRef path = CGPathCreateMutable();
Expand Down
4 changes: 2 additions & 2 deletions QRCodeReaderViewController/QRCodeReaderViewController.m
Original file line number Diff line number Diff line change
Expand Up @@ -239,10 +239,10 @@ - (void)setupAutoLayoutConstraints

[self.view addConstraints:[NSLayoutConstraint constraintsWithVisualFormat:@"V:|-(0)-[_navigationBarView(64)]-(0)-[_imgShadow(9)]-(-9)-[_cameraView]-(0)-|" options:0 metrics:nil views:views]];
[self.navigationBarView addConstraints:[NSLayoutConstraint constraintsWithVisualFormat:@"V:|-17-[_cancelButton(30)]" options:0 metrics:nil views:views]];
[self.navigationBarView addConstraints:[NSLayoutConstraint constraintsWithVisualFormat:@"H:|-4-[_cancelButton(60)]" options:0 metrics:nil views:views]];
[self.navigationBarView addConstraints:[NSLayoutConstraint constraintsWithVisualFormat:@"H:|-0-[_cancelButton(60)]" options:0 metrics:nil views:views]];

[self.navigationBarView addConstraints:[NSLayoutConstraint constraintsWithVisualFormat:@"V:|-17-[_helpButton(30)]" options:0 metrics:nil views:views]];
[self.navigationBarView addConstraints:[NSLayoutConstraint constraintsWithVisualFormat:@"H:[_helpButton(60)]-4-|" options:0 metrics:nil views:views]];
[self.navigationBarView addConstraints:[NSLayoutConstraint constraintsWithVisualFormat:@"H:[_helpButton(60)]-0-|" options:0 metrics:nil views:views]];

[self.navigationBarView addConstraints:[NSLayoutConstraint constraintsWithVisualFormat:@"V:|-0-[_titleLabel]|" options:0 metrics:nil views:views]];
[self.navigationBarView addConstraints:[NSLayoutConstraint constraintsWithVisualFormat:@"H:|[_titleLabel]|" options:0 metrics:nil views:views]];
Expand Down

0 comments on commit 03c4b6c

Please sign in to comment.