forked from imgly/pesdk-ios-examples
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Updated Focus Lock to mimic Camera app
- Loading branch information
Showing
4 changed files
with
116 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
// | ||
// IMGLYAnimationDelegate.swift | ||
// imglyKit | ||
// | ||
// Created by Sascha Schwabbauer on 11/05/15. | ||
// Copyright (c) 2015 9elements GmbH. All rights reserved. | ||
// | ||
|
||
import QuartzCore | ||
|
||
public typealias IMGLYAnimationDelegateBlock = (Bool) -> (Void) | ||
|
||
public class IMGLYAnimationDelegate: NSObject { | ||
|
||
// MARK: - Properties | ||
|
||
public let block: IMGLYAnimationDelegateBlock | ||
|
||
// MARK: - Initializers | ||
|
||
init(block: IMGLYAnimationDelegateBlock) { | ||
self.block = block | ||
} | ||
|
||
// MARK: - Animation Delegate | ||
|
||
public override func animationDidStop(anim: CAAnimation!, finished flag: Bool) { | ||
block(flag) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters