This repository has been archived by the owner on Jul 1, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 389
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
11 changed files
with
388 additions
and
130 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
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,39 @@ | ||
// | ||
// CroppingParameters.swift | ||
// ALCameraViewController | ||
// | ||
// Created by Guillaume Bellut on 02/09/2017. | ||
// Copyright © 2017 zero. All rights reserved. | ||
// | ||
|
||
import UIKit | ||
|
||
public struct CroppingParameters { | ||
|
||
/// Enable the cropping feature. | ||
/// Default value is set to false. | ||
var isEnabled: Bool | ||
|
||
/// Allow the cropping area to be resized by the user. | ||
/// Default value is set to true. | ||
var allowResizing: Bool | ||
|
||
/// Allow the cropping area to be moved by the user. | ||
/// Default value is set to false. | ||
var allowMoving: Bool | ||
|
||
/// Prevent the user to resize the cropping area below a minimum size. | ||
/// Default value is (60, 60). Below this value, corner buttons will overlap. | ||
var minimumSize: CGSize | ||
|
||
public init(isEnabled: Bool = false, | ||
allowResizing: Bool = true, | ||
allowMoving: Bool = true, | ||
minimumSize: CGSize = CGSize(width: 60, height: 60)) { | ||
|
||
self.isEnabled = isEnabled | ||
self.allowResizing = allowResizing | ||
self.allowMoving = allowMoving | ||
self.minimumSize = minimumSize | ||
} | ||
} |
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
Oops, something went wrong.