mirror of
https://github.com/HackPlan/IQKeyboardManager.git
synced 2026-06-15 01:19:13 +08:00
Upgraded Swift Version to match ObjC version
This commit is contained in:
@@ -26,7 +26,7 @@
|
||||
|
||||
@implementation UIWindow (IQ_UIWindow_Hierarchy)
|
||||
|
||||
- (UIViewController*) topMostController
|
||||
- (UIViewController*)topMostController
|
||||
{
|
||||
UIViewController *topController = [self rootViewController];
|
||||
|
||||
|
||||
@@ -247,11 +247,12 @@ void _IQShowLog(NSString *logString);
|
||||
//Creating gesture for @shouldResignOnTouchOutside. (Enhancement ID: #14)
|
||||
_tapGesture = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(tapRecognized:)];
|
||||
[_tapGesture setDelegate:self];
|
||||
|
||||
_tapGesture.enabled = _shouldResignOnTouchOutside;
|
||||
|
||||
//Setting it's initial values
|
||||
_enable = NO; //This enables in +(void)load method.
|
||||
_animationDuration = 0.25;
|
||||
_animationCurve = 7<<16;
|
||||
_animationCurve = UIViewAnimationCurveEaseInOut;
|
||||
[self setKeyboardDistanceFromTextField:10.0];
|
||||
_defaultToolbarTintColor = [UIColor blackColor];
|
||||
[self setCanAdjustTextView:NO];
|
||||
@@ -712,6 +713,7 @@ void _IQShowLog(NSString *logString);
|
||||
|
||||
} completion:NULL];
|
||||
|
||||
//Maintaining contentSize
|
||||
if (_lastScrollView.contentSize.height<_lastScrollView.frame.size.height)
|
||||
{
|
||||
CGSize contentSize = _lastScrollView.contentSize;
|
||||
@@ -962,7 +964,7 @@ void _IQShowLog(NSString *logString);
|
||||
}
|
||||
else
|
||||
{
|
||||
_animationCurve = 0;
|
||||
_animationCurve = UIViewAnimationOptionsCurveEaseOut
|
||||
}
|
||||
|
||||
// Getting keyboard animation duration
|
||||
@@ -1082,15 +1084,16 @@ void _IQShowLog(NSString *logString);
|
||||
|
||||
#ifdef NSFoundationVersionNumber_iOS_5_1
|
||||
|
||||
if([[_textFieldView viewController] IQLayoutGuideConstraint])
|
||||
NSLayoutConstraint *constraint = [[_textFieldView viewController] IQLayoutGuideConstraint];
|
||||
|
||||
//If done LayoutGuide tweak
|
||||
if (constraint &&
|
||||
((constraint.firstItem == [[_textFieldView viewController] topLayoutGuide] || constraint.secondItem == [[_textFieldView viewController] topLayoutGuide]) ||
|
||||
(constraint.firstItem == [[_textFieldView viewController] bottomLayoutGuide] || constraint.secondItem == [[_textFieldView viewController] bottomLayoutGuide])))
|
||||
{
|
||||
NSLayoutConstraint *constraint = [[_textFieldView viewController] IQLayoutGuideConstraint];
|
||||
|
||||
[UIView animateWithDuration:_animationDuration delay:0 options:(7<<16|UIViewAnimationOptionBeginFromCurrentState) animations:^{
|
||||
constraint.constant = _layoutGuideConstraintInitialConstant;
|
||||
[_rootViewController.view setNeedsLayout];
|
||||
[_rootViewController.view layoutIfNeeded];
|
||||
} completion:NULL];
|
||||
constraint.constant = _layoutGuideConstraintInitialConstant;
|
||||
[_rootViewController.view setNeedsLayout];
|
||||
[_rootViewController.view layoutIfNeeded];
|
||||
}
|
||||
else
|
||||
#endif
|
||||
@@ -1579,8 +1582,7 @@ void _IQShowLog(NSString *logString);
|
||||
UITextField *textField = nil;
|
||||
|
||||
if ([siblings count])
|
||||
textField = [siblings objectAtIndex:0];
|
||||
|
||||
textField = [siblings objectAtIndex:0]; //Not using firstObject method because iOS5 doesn't not support 'firstObject' method.
|
||||
|
||||
//Either there is no inputAccessoryView or if accessoryView is not appropriate for current situation(There is Previous/Next/Done toolbar).
|
||||
if (![textField inputAccessoryView] || ([[textField inputAccessoryView] tag] == kIQPreviousNextButtonToolbarTag))
|
||||
|
||||
@@ -0,0 +1,56 @@
|
||||
//
|
||||
// IQUITextFieldView+Additions.swift
|
||||
// https://github.com/hackiftekhar/IQKeyboardManager
|
||||
// Copyright (c) 2013-15 Iftekhar Qurashi.
|
||||
//
|
||||
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
// of this software and associated documentation files (the "Software"), to deal
|
||||
// in the Software without restriction, including without limitation the rights
|
||||
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
// copies of the Software, and to permit persons to whom the Software is
|
||||
// furnished to do so, subject to the following conditions:
|
||||
//
|
||||
// The above copyright notice and this permission notice shall be included in
|
||||
// all copies or substantial portions of the Software.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
// THE SOFTWARE.
|
||||
|
||||
import Foundation
|
||||
import UIKit
|
||||
|
||||
/**
|
||||
Uses default keyboard distance for textField.
|
||||
*/
|
||||
let kIQUseDefaultKeyboardDistance = CGFloat.max
|
||||
|
||||
private var kIQKeyboardDistanceFromTextField = "kIQKeyboardDistanceFromTextField"
|
||||
|
||||
/**
|
||||
UIView category for managing UITextField/UITextView
|
||||
*/
|
||||
extension UIView {
|
||||
|
||||
/**
|
||||
To set customized distance from keyboard for textField/textView. Can't be less than zero
|
||||
*/
|
||||
var keyboardDistanceFromTextField: CGFloat {
|
||||
get {
|
||||
|
||||
if let aValue = objc_getAssociatedObject(self, &kIQKeyboardDistanceFromTextField) as? CGFloat {
|
||||
return aValue
|
||||
} else {
|
||||
return kIQUseDefaultKeyboardDistance
|
||||
}
|
||||
}
|
||||
set(newValue) {
|
||||
objc_setAssociatedObject(self, &kIQKeyboardDistanceFromTextField, newValue, UInt(OBJC_ASSOCIATION_RETAIN_NONATOMIC))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -25,6 +25,8 @@
|
||||
import Foundation
|
||||
import UIKit
|
||||
|
||||
private var kIQIsAskingCanBecomeFirstResponder = "kIQIsAskingCanBecomeFirstResponder"
|
||||
|
||||
/**
|
||||
UIView hierarchy category.
|
||||
*/
|
||||
@@ -40,14 +42,14 @@ extension UIView {
|
||||
var isAskingCanBecomeFirstResponder: Bool {
|
||||
get {
|
||||
|
||||
if let aValue = objc_getAssociatedObject(self, "isAskingCanBecomeFirstResponder") as? Bool {
|
||||
if let aValue = objc_getAssociatedObject(self, &kIQIsAskingCanBecomeFirstResponder) as? Bool {
|
||||
return aValue
|
||||
} else {
|
||||
return false
|
||||
}
|
||||
}
|
||||
set(newValue) {
|
||||
objc_setAssociatedObject(self, "isAskingCanBecomeFirstResponder", newValue, UInt(OBJC_ASSOCIATION_RETAIN_NONATOMIC))
|
||||
objc_setAssociatedObject(self, &kIQIsAskingCanBecomeFirstResponder, newValue, UInt(OBJC_ASSOCIATION_RETAIN_NONATOMIC))
|
||||
}
|
||||
}
|
||||
|
||||
@@ -218,18 +220,19 @@ extension UIView {
|
||||
|
||||
var _IQcanBecomeFirstResponder = (canBecomeFirstResponder() == true && userInteractionEnabled == true && hidden == false && alpha != 0.0 && isAlertViewTextField() == false && isSearchBarTextField() == false) as Bool
|
||||
|
||||
// Setting toolbar to keyboard.
|
||||
if let textField = self as? UITextField {
|
||||
_IQcanBecomeFirstResponder = textField.enabled
|
||||
} else if let textView = self as? UITextView {
|
||||
_IQcanBecomeFirstResponder = textView.editable
|
||||
if _IQcanBecomeFirstResponder == true {
|
||||
// Setting toolbar to keyboard.
|
||||
if let textField = self as? UITextField {
|
||||
_IQcanBecomeFirstResponder = textField.enabled
|
||||
} else if let textView = self as? UITextView {
|
||||
_IQcanBecomeFirstResponder = textView.editable
|
||||
}
|
||||
}
|
||||
|
||||
isAskingCanBecomeFirstResponder = false
|
||||
|
||||
return _IQcanBecomeFirstResponder
|
||||
}
|
||||
|
||||
|
||||
///-------------------------
|
||||
/// MARK: Special TextFields
|
||||
|
||||
@@ -0,0 +1,46 @@
|
||||
//
|
||||
// IQUIViewController+Additions.swift
|
||||
// https://github.com/hackiftekhar/IQKeyboardManager
|
||||
// Copyright (c) 2013-15 Iftekhar Qurashi.
|
||||
//
|
||||
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
// of this software and associated documentation files (the "Software"), to deal
|
||||
// in the Software without restriction, including without limitation the rights
|
||||
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
// copies of the Software, and to permit persons to whom the Software is
|
||||
// furnished to do so, subject to the following conditions:
|
||||
//
|
||||
// The above copyright notice and this permission notice shall be included in
|
||||
// all copies or substantial portions of the Software.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
// THE SOFTWARE.
|
||||
|
||||
import Foundation
|
||||
import UIKit
|
||||
|
||||
|
||||
private var kIQLayoutGuideConstraint = "kIQLayoutGuideConstraint"
|
||||
|
||||
|
||||
extension UIViewController {
|
||||
|
||||
/**
|
||||
To set customized distance from keyboard for textField/textView. Can't be less than zero
|
||||
*/
|
||||
@IBOutlet var IQLayoutGuideConstraint: NSLayoutConstraint? {
|
||||
get {
|
||||
|
||||
return objc_getAssociatedObject(self, &kIQLayoutGuideConstraint) as? NSLayoutConstraint
|
||||
}
|
||||
|
||||
set(newValue) {
|
||||
objc_setAssociatedObject(self, &kIQLayoutGuideConstraint, newValue, UInt(OBJC_ASSOCIATION_RETAIN_NONATOMIC))
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -33,12 +33,12 @@ import UIKit
|
||||
/**
|
||||
Default tag for toolbar with Done button -1002.
|
||||
*/
|
||||
let kIQDoneButtonToolbarTag : Int = -1002
|
||||
let kIQDoneButtonToolbarTag = -1002
|
||||
|
||||
/**
|
||||
Default tag for toolbar with Previous/Next buttons -1005.
|
||||
*/
|
||||
let kIQPreviousNextButtonToolbarTag : Int = -1005
|
||||
let kIQPreviousNextButtonToolbarTag = -1005
|
||||
|
||||
/**
|
||||
Codeless drop-in universal library allows to prevent issues of keyboard sliding up and cover UITextField/UITextView. Neither need to write any code nor any setup required and much more. A generic version of KeyboardManagement. https://developer.apple.com/Library/ios/documentation/StringsTextFonts/Conceptual/TextAndWebiPhoneOS/KeyboardManagement/KeyboardManagement.html
|
||||
@@ -54,7 +54,7 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
/**
|
||||
Enable/disable managing distance between keyboard and textField. Default is YES(Enabled when class loads in `+(void)load` method).
|
||||
*/
|
||||
var enable: Bool = false {
|
||||
var enable = false {
|
||||
|
||||
didSet {
|
||||
//If not enable, enable it.
|
||||
@@ -104,7 +104,6 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
return Static.kbManager
|
||||
}
|
||||
|
||||
|
||||
///-------------------------
|
||||
/// MARK: IQToolbar handling
|
||||
///-------------------------
|
||||
@@ -112,7 +111,7 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
/**
|
||||
Automatic add the IQToolbar functionality. Default is YES.
|
||||
*/
|
||||
var enableAutoToolbar: Bool = true {
|
||||
var enableAutoToolbar = true {
|
||||
|
||||
didSet {
|
||||
|
||||
@@ -183,7 +182,7 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
/**
|
||||
Resigns Keyboard on touching outside of UITextField/View. Default is NO.
|
||||
*/
|
||||
var shouldResignOnTouchOutside: Bool = false {
|
||||
var shouldResignOnTouchOutside = false {
|
||||
|
||||
didSet {
|
||||
_tapGesture.enabled = shouldResignOnTouchOutside
|
||||
@@ -197,7 +196,7 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
/**
|
||||
Resigns currently first responder field.
|
||||
*/
|
||||
func resignFirstResponder() {
|
||||
func resignFirstResponder()-> Bool {
|
||||
|
||||
if let textFieldRetain = _textFieldView {
|
||||
|
||||
@@ -211,7 +210,11 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
|
||||
_IQShowLog("Refuses to resign first responder: \(_textFieldView?._IQDescription())")
|
||||
}
|
||||
|
||||
return isResignFirstResponder;
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -268,11 +271,11 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
/**
|
||||
Navigate to previous responder textField/textView.
|
||||
*/
|
||||
func goPrevious() {
|
||||
func goPrevious()-> Bool {
|
||||
|
||||
//Getting all responder view's.
|
||||
if let textFields = responderViews() {
|
||||
if let textFieldRetain = _textFieldView {
|
||||
if let textFieldRetain = _textFieldView {
|
||||
if let textFields = responderViews() {
|
||||
if textFields.containsObject(textFieldRetain) == true {
|
||||
//Getting index of current textField.
|
||||
let index = textFields.indexOfObject(textFieldRetain)
|
||||
@@ -291,20 +294,24 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
|
||||
_IQShowLog("Refuses to become first responder: \(nextTextField._IQDescription())")
|
||||
}
|
||||
|
||||
return isAcceptAsFirstResponder
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
/**
|
||||
Navigate to next responder textField/textView.
|
||||
*/
|
||||
func goNext() {
|
||||
func goNext()-> Bool {
|
||||
|
||||
//Getting all responder view's.
|
||||
if let textFields = responderViews() {
|
||||
if let textFieldRetain = _textFieldView {
|
||||
if let textFieldRetain = _textFieldView {
|
||||
if let textFields = responderViews() {
|
||||
if textFields.containsObject(textFieldRetain) == true {
|
||||
|
||||
//Getting index of current textField.
|
||||
@@ -324,10 +331,14 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
|
||||
_IQShowLog("Refuses to become first responder: \(nextTextField._IQDescription())")
|
||||
}
|
||||
|
||||
return isAcceptAsFirstResponder
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
/** previousAction. */
|
||||
@@ -340,7 +351,14 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
}
|
||||
|
||||
if canGoPrevious == true {
|
||||
goPrevious()
|
||||
|
||||
if let textFieldRetain = _textFieldView {
|
||||
let isAcceptAsFirstResponder = goPrevious()
|
||||
|
||||
// if isAcceptAsFirstResponder && textFieldRetain.previousInvocation == nil {
|
||||
// textFieldRetain.previousInvocation.invoke()
|
||||
// }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -353,8 +371,15 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
UIDevice.currentDevice().playInputClick()
|
||||
}
|
||||
|
||||
if canGoNext {
|
||||
goNext()
|
||||
if canGoNext == true {
|
||||
|
||||
if let textFieldRetain = _textFieldView {
|
||||
let isAcceptAsFirstResponder = goNext()
|
||||
|
||||
// if isAcceptAsFirstResponder && textFieldRetain.nextInvocation == nil {
|
||||
// textFieldRetain.nextInvocation.invoke()
|
||||
// }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -367,16 +392,23 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
UIDevice.currentDevice().playInputClick()
|
||||
}
|
||||
|
||||
//Resign textFieldView.
|
||||
resignFirstResponder()
|
||||
if let textFieldRetain = _textFieldView {
|
||||
//Resign textFieldView.
|
||||
let isResignedFirstResponder = resignFirstResponder()
|
||||
|
||||
// if isResignedFirstResponder && textFieldRetain.doneInvocation == nil {
|
||||
// textFieldRetain.doneInvocation.invoke()
|
||||
// }
|
||||
}
|
||||
}
|
||||
|
||||
/** Resigning on tap gesture. (Enhancement ID: #14)*/
|
||||
func tapRecognized(gesture: UITapGestureRecognizer) {
|
||||
|
||||
if gesture.state == UIGestureRecognizerState.Ended {
|
||||
|
||||
//Resigning currently responder textField.
|
||||
gesture.view?.endEditing(true)
|
||||
resignFirstResponder()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -532,9 +564,9 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
/** To save rootViewController */
|
||||
private weak var _rootViewController: UIViewController?
|
||||
|
||||
/** used with canAdjustTextView to detect a textFieldView frame is changes or not. (Bug ID: #92)*/
|
||||
private var _isTextFieldViewFrameChanged = false
|
||||
|
||||
/** To save topBottomLayoutConstraint original constant */
|
||||
private var _layoutGuideConstraintInitialConstant: CGFloat = 0.25
|
||||
|
||||
/*******************************************/
|
||||
|
||||
/** Variable to save lastScrollView that was scrolled. */
|
||||
@@ -563,9 +595,6 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
/** To mimic the keyboard animation */
|
||||
private var _animationCurve = UIViewAnimationOptions.CurveEaseOut
|
||||
|
||||
/** Boolean to maintain keyboard is showing or it is hide. To solve rootViewController.view.frame calculations. */
|
||||
private var _isKeyboardShowing = false
|
||||
|
||||
/*******************************************/
|
||||
|
||||
/** TapGesture to resign keyboard on view's touch. */
|
||||
@@ -579,22 +608,31 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
/*******************************************/
|
||||
|
||||
/** Set of restricted classes for library */
|
||||
private var _disabledClasses = NSMutableSet()
|
||||
private var _disabledClasses = NSMutableSet()
|
||||
|
||||
/** Set of restricted classes for adding toolbar */
|
||||
private var _disabledToolbarClasses = NSMutableSet()
|
||||
private var _disabledToolbarClasses = NSMutableSet()
|
||||
|
||||
/** Set of permitted classes to add all inner textField as siblings */
|
||||
private var _toolbarPreviousNextConsideredClass = NSMutableSet()
|
||||
private var _toolbarPreviousNextConsideredClass = NSMutableSet()
|
||||
|
||||
/*******************************************/
|
||||
|
||||
private struct flags {
|
||||
/** used with canAdjustTextView to detect a textFieldView frame is changes or not. (Bug ID: #92)*/
|
||||
var isTextFieldViewFrameChanged = false
|
||||
/** Boolean to maintain keyboard is showing or it is hide. To solve rootViewController.view.frame calculations. */
|
||||
var isKeyboardShowing = false
|
||||
}
|
||||
|
||||
/** Private flags to use within the project */
|
||||
private var _keyboardManagerFlags = flags(isTextFieldViewFrameChanged: false, isKeyboardShowing: false)
|
||||
|
||||
/** To use with keyboardDistanceFromTextField. */
|
||||
private var _privateKeyboardDistanceFromTextField: CGFloat = 10.0
|
||||
|
||||
/**************************************************************************************/
|
||||
|
||||
|
||||
///--------------------------------------
|
||||
/// MARK: Initialization/Deinitialization
|
||||
///--------------------------------------
|
||||
@@ -632,8 +670,8 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
_toolbarPreviousNextConsideredClass.addObject(NSStringFromClass(UICollectionView))
|
||||
}
|
||||
|
||||
|
||||
/** Override +load method to enable KeyboardManager when class loader load IQKeyboardManager. Enabling when app starts (No need to write any code) */
|
||||
/** It doesn't work on Swift 1.2 */
|
||||
// override class func load() {
|
||||
// super.load()
|
||||
//
|
||||
@@ -652,8 +690,8 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
/** Getting keyWindow. */
|
||||
private func keyWindow() -> UIWindow? {
|
||||
|
||||
if _textFieldView?.window != nil {
|
||||
return _textFieldView?.window
|
||||
if let keyWindow = _textFieldView?.window {
|
||||
return keyWindow
|
||||
} else {
|
||||
|
||||
struct Static {
|
||||
@@ -675,8 +713,7 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
return Static.keyWindow
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
///-----------------------
|
||||
/// MARK: Helper Functions
|
||||
///-----------------------
|
||||
@@ -717,7 +754,7 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
_IQShowLog("You must set UIWindow.rootViewController in your AppDelegate to work with IQKeyboardManager")
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* Adjusting RootViewController's frame according to device orientation. */
|
||||
private func adjustFrame() {
|
||||
|
||||
@@ -726,10 +763,12 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
return
|
||||
}
|
||||
|
||||
let textFieldView = _textFieldView!
|
||||
|
||||
_IQShowLog("****** \(__FUNCTION__) %@ started ******")
|
||||
|
||||
// Boolean to know keyboard is showing/hiding
|
||||
_isKeyboardShowing = true
|
||||
_keyboardManagerFlags.isKeyboardShowing = true
|
||||
|
||||
// Getting KeyWindow object.
|
||||
let optionalWindow = keyWindow()
|
||||
@@ -741,7 +780,7 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
}
|
||||
|
||||
// Converting Rectangle according to window bounds.
|
||||
let optionalTextFieldViewRect = _textFieldView?.superview?.convertRect(_textFieldView!.frame, toView: optionalWindow)
|
||||
let optionalTextFieldViewRect = textFieldView.superview?.convertRect(textFieldView.frame, toView: optionalWindow)
|
||||
|
||||
if optionalRootController == nil || optionalWindow == nil || optionalTextFieldViewRect == nil {
|
||||
return
|
||||
@@ -749,7 +788,6 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
|
||||
let rootController = optionalRootController!
|
||||
let window = optionalWindow!
|
||||
let textFieldView = _textFieldView!
|
||||
let textFieldViewRect = optionalTextFieldViewRect!
|
||||
|
||||
//If it's iOS8 then we should do calculations according to portrait orientations. // (Bug ID: #64, #66)
|
||||
@@ -757,17 +795,21 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
|
||||
// Getting RootViewRect.
|
||||
var rootViewRect = rootController.view.frame
|
||||
|
||||
//Getting statusBarFrame
|
||||
var topLayoutGuide : CGFloat = 0
|
||||
//Maintain keyboardDistanceFromTextField
|
||||
let newKeyboardDistanceFromTextField = (textFieldView.keyboardDistanceFromTextField == kIQUseDefaultKeyboardDistance) ? keyboardDistanceFromTextField : textFieldView.keyboardDistanceFromTextField
|
||||
var kbSize = _kbSize;
|
||||
|
||||
let statusBarFrame = UIApplication.sharedApplication().statusBarFrame
|
||||
|
||||
switch interfaceOrientation {
|
||||
case UIInterfaceOrientation.LandscapeLeft, UIInterfaceOrientation.LandscapeRight:
|
||||
topLayoutGuide = CGRectGetWidth(statusBarFrame)
|
||||
kbSize.width += newKeyboardDistanceFromTextField
|
||||
case UIInterfaceOrientation.Portrait, UIInterfaceOrientation.PortraitUpsideDown:
|
||||
topLayoutGuide = CGRectGetHeight(statusBarFrame)
|
||||
kbSize.height += newKeyboardDistanceFromTextField
|
||||
default: break
|
||||
}
|
||||
|
||||
@@ -778,20 +820,20 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
// Calculating move position. Common for both normal and special cases.
|
||||
switch interfaceOrientation {
|
||||
case UIInterfaceOrientation.LandscapeLeft:
|
||||
move = min(CGRectGetMinX(textFieldViewRect)-(topLayoutGuide+5), CGRectGetMaxX(textFieldViewRect)-(CGRectGetWidth(window.frame)-_kbSize.width))
|
||||
move = min(CGRectGetMinX(textFieldViewRect)-(topLayoutGuide+5), CGRectGetMaxX(textFieldViewRect)-(CGRectGetWidth(window.frame)-kbSize.width))
|
||||
case UIInterfaceOrientation.LandscapeRight:
|
||||
move = min(CGRectGetWidth(window.frame)-CGRectGetMaxX(textFieldViewRect)-(topLayoutGuide+5), _kbSize.width-CGRectGetMinX(textFieldViewRect))
|
||||
move = min(CGRectGetWidth(window.frame)-CGRectGetMaxX(textFieldViewRect)-(topLayoutGuide+5), kbSize.width-CGRectGetMinX(textFieldViewRect))
|
||||
case UIInterfaceOrientation.Portrait:
|
||||
move = min(CGRectGetMinY(textFieldViewRect)-(topLayoutGuide+5), CGRectGetMaxY(textFieldViewRect)-(CGRectGetHeight(window.frame)-_kbSize.height))
|
||||
move = min(CGRectGetMinY(textFieldViewRect)-(topLayoutGuide+5), CGRectGetMaxY(textFieldViewRect)-(CGRectGetHeight(window.frame)-kbSize.height))
|
||||
case UIInterfaceOrientation.PortraitUpsideDown:
|
||||
move = min(CGRectGetHeight(window.frame)-CGRectGetMaxY(textFieldViewRect)-(topLayoutGuide+5), _kbSize.height-CGRectGetMinY(textFieldViewRect))
|
||||
move = min(CGRectGetHeight(window.frame)-CGRectGetMaxY(textFieldViewRect)-(topLayoutGuide+5), kbSize.height-CGRectGetMinY(textFieldViewRect))
|
||||
default: break
|
||||
}
|
||||
|
||||
_IQShowLog("Need to move: \(move)")
|
||||
|
||||
// Getting it's superScrollView. // (Enhancement ID: #21, #24)
|
||||
let superScrollView : UIScrollView? = textFieldView.superviewOfClassType(UIScrollView) as? UIScrollView
|
||||
let superScrollView = textFieldView.superviewOfClassType(UIScrollView) as? UIScrollView
|
||||
|
||||
//If there was a lastScrollView. // (Bug ID: #34)
|
||||
if let lastScrollView = _lastScrollView {
|
||||
@@ -844,8 +886,7 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
|
||||
_IQShowLog("Saving \(unwrappedSuperScrollView._IQDescription()) contentInset : \(_startingContentInsets) and contentOffset : \(_startingContentOffset)")
|
||||
}
|
||||
|
||||
|
||||
|
||||
// Special case for ScrollView.
|
||||
// If we found lastScrollView then setting it's contentOffset to show textField.
|
||||
if let lastScrollView = _lastScrollView {
|
||||
@@ -856,7 +897,7 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
while let scrollView = superScrollView {
|
||||
|
||||
//Looping in upper hierarchy until we don't found any scrollView in it's upper hirarchy till UIWindow object.
|
||||
if move > 0 ? move > -scrollView.contentOffset.y - scrollView.contentInset.top : scrollView.contentOffset.y>0 {
|
||||
if move > 0 ? (move > (-scrollView.contentOffset.y - scrollView.contentInset.top)) : scrollView.contentOffset.y>0 {
|
||||
|
||||
//Getting lastViewRect.
|
||||
if let lastViewRect = lastView.superview?.convertRect(lastView.frame, toView: scrollView) {
|
||||
@@ -867,11 +908,11 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
//Rearranging the expected Y offset according to the view.
|
||||
shouldOffsetY = min(shouldOffsetY, lastViewRect.origin.y /*-5*/) //-5 is for good UI.//Commenting -5 (Bug ID: #69)
|
||||
|
||||
|
||||
//[_textFieldView isKindOfClass:[UITextView class]] If is a UITextView type
|
||||
//[superScrollView superviewOfClassType:[UIScrollView class]] == nil If processing scrollView is last scrollView in upper hierarchy (there is no other scrollView upper hierrchy.)
|
||||
//[_textFieldView isKindOfClass:[UITextView class]] If is a UITextView type
|
||||
//shouldOffsetY > 0 shouldOffsetY must be greater than in order to keep distance from navigationBar (Bug ID: #92)
|
||||
if textFieldView is UITextView == true && scrollView.superviewOfClassType(UIScrollView) == nil && shouldOffsetY > 0 {
|
||||
//shouldOffsetY >= 0 shouldOffsetY must be greater than in order to keep distance from navigationBar (Bug ID: #92)
|
||||
if textFieldView is UITextView == true && scrollView.superviewOfClassType(UIScrollView) == nil && shouldOffsetY >= 0 {
|
||||
var maintainTopLayout : CGFloat = 0
|
||||
|
||||
if let navigationBarFrame = textFieldView.viewController()?.navigationController?.navigationBar.frame {
|
||||
@@ -914,8 +955,6 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
move -= (shouldOffsetY-scrollView.contentOffset.y)
|
||||
}
|
||||
|
||||
|
||||
|
||||
//Getting problem while using `setContentOffset:animated:`, So I used animation API.
|
||||
UIView.animateWithDuration(_animationDuration, delay: 0, options: UIViewAnimationOptions.BeginFromCurrentState|_animationCurve, animations: { () -> Void in
|
||||
|
||||
@@ -934,7 +973,6 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
break
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//Updating contentInset
|
||||
if let lastScrollViewRect = lastScrollView.superview?.convertRect(lastScrollView.frame, toView: window) {
|
||||
@@ -943,13 +981,13 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
|
||||
switch interfaceOrientation {
|
||||
case UIInterfaceOrientation.LandscapeLeft:
|
||||
bottom = _kbSize.width-(CGRectGetWidth(window.frame)-CGRectGetMaxX(lastScrollViewRect))
|
||||
bottom = kbSize.width-(CGRectGetWidth(window.frame)-CGRectGetMaxX(lastScrollViewRect))
|
||||
case UIInterfaceOrientation.LandscapeRight:
|
||||
bottom = _kbSize.width-CGRectGetMinX(lastScrollViewRect)
|
||||
bottom = kbSize.width-CGRectGetMinX(lastScrollViewRect)
|
||||
case UIInterfaceOrientation.Portrait:
|
||||
bottom = _kbSize.height-(CGRectGetHeight(window.frame)-CGRectGetMaxY(lastScrollViewRect))
|
||||
bottom = kbSize.height-(CGRectGetHeight(window.frame)-CGRectGetMaxY(lastScrollViewRect))
|
||||
case UIInterfaceOrientation.PortraitUpsideDown:
|
||||
bottom = _kbSize.height-CGRectGetMinY(lastScrollViewRect)
|
||||
bottom = kbSize.height-CGRectGetMinY(lastScrollViewRect)
|
||||
default: break
|
||||
}
|
||||
|
||||
@@ -982,20 +1020,19 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
}
|
||||
//Going ahead. No else if.
|
||||
|
||||
|
||||
//Special case for UITextView(Readjusting the move variable when textView hight is too big to fit on screen)
|
||||
//_canAdjustTextView If we have permission to adjust the textView, then let's do it on behalf of user (Enhancement ID: #15)
|
||||
//_lastScrollView If not having inside any scrollView, (now contentInset manages the full screen textView.
|
||||
//[_textFieldView isKindOfClass:[UITextView class]] If is a UITextView type
|
||||
//_isTextFieldViewFrameChanged If frame is not change by library in past (Bug ID: #92)
|
||||
if canAdjustTextView == true && _lastScrollView == nil && textFieldView is UITextView == true && _isTextFieldViewFrameChanged == false {
|
||||
if canAdjustTextView == true && _lastScrollView == nil && textFieldView is UITextView == true && _keyboardManagerFlags.isTextFieldViewFrameChanged == false {
|
||||
var textViewHeight = CGRectGetHeight(textFieldView.frame)
|
||||
|
||||
switch interfaceOrientation {
|
||||
case UIInterfaceOrientation.LandscapeLeft, UIInterfaceOrientation.LandscapeRight:
|
||||
textViewHeight = min(textViewHeight, (CGRectGetWidth(window.frame)-_kbSize.width-(topLayoutGuide+5)))
|
||||
textViewHeight = min(textViewHeight, (CGRectGetWidth(window.frame)-kbSize.width-(topLayoutGuide+5)))
|
||||
case UIInterfaceOrientation.Portrait, UIInterfaceOrientation.PortraitUpsideDown:
|
||||
textViewHeight = min(textViewHeight, (CGRectGetHeight(window.frame)-_kbSize.height-(topLayoutGuide+5)))
|
||||
textViewHeight = min(textViewHeight, (CGRectGetHeight(window.frame)-kbSize.height-(topLayoutGuide+5)))
|
||||
default: break
|
||||
}
|
||||
|
||||
@@ -1006,125 +1043,176 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
var textFieldViewRect = textFieldView.frame
|
||||
textFieldViewRect.size.height = textViewHeight
|
||||
textFieldView.frame = textFieldViewRect
|
||||
self._isTextFieldViewFrameChanged = true
|
||||
self._keyboardManagerFlags.isTextFieldViewFrameChanged = true
|
||||
|
||||
self._IQShowLog("\(textFieldView._IQDescription()) New Frame : \(textFieldView.frame)")
|
||||
|
||||
}, completion: { (finished) -> Void in })
|
||||
}
|
||||
|
||||
var hasDoneTweakLayoutGuide = false
|
||||
|
||||
// Special case for iPad modalPresentationStyle.
|
||||
if rootController.modalPresentationStyle == UIModalPresentationStyle.FormSheet || rootController.modalPresentationStyle == UIModalPresentationStyle.PageSheet {
|
||||
if let viewController = textFieldView.viewController() {
|
||||
|
||||
_IQShowLog("Found Special case for Model Presentation Style: \(rootController.modalPresentationStyle)")
|
||||
|
||||
// Positive or zero.
|
||||
if move >= 0 {
|
||||
// We should only manipulate y.
|
||||
rootViewRect.origin.y -= move
|
||||
if let constraint = viewController.IQLayoutGuideConstraint {
|
||||
|
||||
// From now prevent keyboard manager to slide up the rootView to more than keyboard height. (Bug ID: #93)
|
||||
if preventShowingBottomBlankSpace == true {
|
||||
var minimumY: CGFloat = 0
|
||||
var layoutGuide : UILayoutSupport?
|
||||
if let itemLayoutGuide = constraint.firstItem as? UILayoutSupport {
|
||||
layoutGuide = itemLayoutGuide
|
||||
} else if let itemLayoutGuide = constraint.secondItem as? UILayoutSupport {
|
||||
layoutGuide = itemLayoutGuide
|
||||
}
|
||||
|
||||
if let itemLayoutGuide : UILayoutSupport = layoutGuide {
|
||||
|
||||
switch interfaceOrientation {
|
||||
case UIInterfaceOrientation.LandscapeLeft, UIInterfaceOrientation.LandscapeRight:
|
||||
minimumY = CGRectGetWidth(window.frame)-rootViewRect.size.height-topLayoutGuide-(_kbSize.width-keyboardDistanceFromTextField)
|
||||
case UIInterfaceOrientation.Portrait, UIInterfaceOrientation.PortraitUpsideDown:
|
||||
minimumY = (CGRectGetHeight(window.frame)-rootViewRect.size.height-topLayoutGuide)/2-(_kbSize.height-keyboardDistanceFromTextField)
|
||||
default: break
|
||||
if (itemLayoutGuide === viewController.topLayoutGuide) //If topLayoutGuide constraint
|
||||
{
|
||||
let constant = min(_layoutGuideConstraintInitialConstant, constraint.constant-move);
|
||||
|
||||
UIView.animateWithDuration(_animationDuration, delay: 0, options: (_animationCurve|UIViewAnimationOptions.BeginFromCurrentState), animations: { () -> Void in
|
||||
|
||||
constraint.constant = constant;
|
||||
self._rootViewController?.view.setNeedsLayout()
|
||||
self._rootViewController?.view.layoutIfNeeded()
|
||||
|
||||
}, completion: { (finished) -> Void in })
|
||||
|
||||
hasDoneTweakLayoutGuide = true
|
||||
}
|
||||
|
||||
rootViewRect.origin.y = max(CGRectGetMinY(rootViewRect), minimumY)
|
||||
}
|
||||
|
||||
_IQShowLog("Moving Upward")
|
||||
// Setting adjusted rootViewRect
|
||||
setRootViewFrame(rootViewRect)
|
||||
} else { // Negative
|
||||
// Calculating disturbed distance. Pull Request #3
|
||||
let disturbDistance = CGRectGetMinY(rootViewRect)-CGRectGetMinY(_topViewBeginRect)
|
||||
|
||||
// disturbDistance Negative = frame disturbed.
|
||||
// disturbDistance positive = frame not disturbed.
|
||||
if disturbDistance < 0 {
|
||||
// We should only manipulate y.
|
||||
rootViewRect.origin.y -= max(move, disturbDistance)
|
||||
else if (itemLayoutGuide === viewController.bottomLayoutGuide) //If bottomLayoutGuice constraint
|
||||
{
|
||||
let constant = max(_layoutGuideConstraintInitialConstant, constraint.constant+move);
|
||||
|
||||
UIView.animateWithDuration(_animationDuration, delay: 0, options: (_animationCurve|UIViewAnimationOptions.BeginFromCurrentState), animations: { () -> Void in
|
||||
|
||||
constraint.constant = constant;
|
||||
self._rootViewController?.view.setNeedsLayout()
|
||||
self._rootViewController?.view.layoutIfNeeded()
|
||||
|
||||
}, completion: { (finished) -> Void in })
|
||||
|
||||
_IQShowLog("Moving Downward")
|
||||
// Setting adjusted rootViewRect
|
||||
setRootViewFrame(rootViewRect)
|
||||
}
|
||||
}
|
||||
} else { //If presentation style is neither UIModalPresentationFormSheet nor UIModalPresentationPageSheet then going ahead.(General case)
|
||||
// Positive or zero.
|
||||
if move >= 0 {
|
||||
|
||||
switch interfaceOrientation {
|
||||
case UIInterfaceOrientation.LandscapeLeft: rootViewRect.origin.x -= move
|
||||
case UIInterfaceOrientation.LandscapeRight: rootViewRect.origin.x += move
|
||||
case UIInterfaceOrientation.Portrait: rootViewRect.origin.y -= move
|
||||
case UIInterfaceOrientation.PortraitUpsideDown: rootViewRect.origin.y += move
|
||||
default: break
|
||||
}
|
||||
|
||||
// From now prevent keyboard manager to slide up the rootView to more than keyboard height. (Bug ID: #93)
|
||||
if preventShowingBottomBlankSpace == true {
|
||||
|
||||
switch interfaceOrientation {
|
||||
case UIInterfaceOrientation.LandscapeLeft:
|
||||
rootViewRect.origin.x = max(rootViewRect.origin.x, min(0, -_kbSize.width+keyboardDistanceFromTextField))
|
||||
case UIInterfaceOrientation.LandscapeRight:
|
||||
rootViewRect.origin.x = min(rootViewRect.origin.x, +_kbSize.width-keyboardDistanceFromTextField)
|
||||
case UIInterfaceOrientation.Portrait:
|
||||
rootViewRect.origin.y = max(rootViewRect.origin.y, min(0, -_kbSize.height+keyboardDistanceFromTextField))
|
||||
case UIInterfaceOrientation.PortraitUpsideDown:
|
||||
rootViewRect.origin.y = min(rootViewRect.origin.y, +_kbSize.height-keyboardDistanceFromTextField)
|
||||
default: break
|
||||
hasDoneTweakLayoutGuide = true
|
||||
}
|
||||
}
|
||||
|
||||
_IQShowLog("Moving Upward")
|
||||
// Setting adjusted rootViewRect
|
||||
setRootViewFrame(rootViewRect)
|
||||
} else { // Negative
|
||||
var disturbDistance : CGFloat = 0
|
||||
|
||||
switch interfaceOrientation {
|
||||
case UIInterfaceOrientation.LandscapeLeft:
|
||||
disturbDistance = CGRectGetMinX(rootViewRect)-CGRectGetMinX(_topViewBeginRect)
|
||||
case UIInterfaceOrientation.LandscapeRight:
|
||||
disturbDistance = CGRectGetMinX(_topViewBeginRect)-CGRectGetMinX(rootViewRect)
|
||||
case UIInterfaceOrientation.Portrait:
|
||||
disturbDistance = CGRectGetMinY(rootViewRect)-CGRectGetMinY(_topViewBeginRect)
|
||||
case UIInterfaceOrientation.PortraitUpsideDown:
|
||||
disturbDistance = CGRectGetMinY(_topViewBeginRect)-CGRectGetMinY(rootViewRect)
|
||||
default: break
|
||||
}
|
||||
|
||||
// disturbDistance Negative = frame disturbed.
|
||||
// disturbDistance positive = frame not disturbed.
|
||||
if disturbDistance < 0 {
|
||||
|
||||
switch interfaceOrientation {
|
||||
case UIInterfaceOrientation.LandscapeLeft: rootViewRect.origin.x -= max(move, disturbDistance)
|
||||
case UIInterfaceOrientation.LandscapeRight: rootViewRect.origin.x += max(move, disturbDistance)
|
||||
case UIInterfaceOrientation.Portrait: rootViewRect.origin.y -= max(move, disturbDistance)
|
||||
case UIInterfaceOrientation.PortraitUpsideDown: rootViewRect.origin.y += max(move, disturbDistance)
|
||||
default: break
|
||||
}
|
||||
|
||||
_IQShowLog("Moving Downward")
|
||||
// Setting adjusted rootViewRect
|
||||
// Setting adjusted rootViewRect
|
||||
setRootViewFrame(rootViewRect)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//If not constraint
|
||||
if hasDoneTweakLayoutGuide == false {
|
||||
|
||||
// Special case for iPad modalPresentationStyle.
|
||||
if rootController.modalPresentationStyle == UIModalPresentationStyle.FormSheet || rootController.modalPresentationStyle == UIModalPresentationStyle.PageSheet {
|
||||
|
||||
_IQShowLog("Found Special case for Model Presentation Style: \(rootController.modalPresentationStyle)")
|
||||
|
||||
// +Positive or zero.
|
||||
if move >= 0 {
|
||||
// We should only manipulate y.
|
||||
rootViewRect.origin.y -= move
|
||||
|
||||
// From now prevent keyboard manager to slide up the rootView to more than keyboard height. (Bug ID: #93)
|
||||
if preventShowingBottomBlankSpace == true {
|
||||
var minimumY: CGFloat = 0
|
||||
|
||||
switch interfaceOrientation {
|
||||
case UIInterfaceOrientation.LandscapeLeft, UIInterfaceOrientation.LandscapeRight:
|
||||
minimumY = CGRectGetWidth(window.frame)-rootViewRect.size.height-topLayoutGuide-(kbSize.width-newKeyboardDistanceFromTextField)
|
||||
case UIInterfaceOrientation.Portrait, UIInterfaceOrientation.PortraitUpsideDown:
|
||||
minimumY = (CGRectGetHeight(window.frame)-rootViewRect.size.height-topLayoutGuide)/2-(kbSize.height-newKeyboardDistanceFromTextField)
|
||||
default: break
|
||||
}
|
||||
|
||||
rootViewRect.origin.y = max(CGRectGetMinY(rootViewRect), minimumY)
|
||||
}
|
||||
|
||||
_IQShowLog("Moving Upward")
|
||||
// Setting adjusted rootViewRect
|
||||
setRootViewFrame(rootViewRect)
|
||||
} else { // -Negative
|
||||
// Calculating disturbed distance. Pull Request #3
|
||||
let disturbDistance = CGRectGetMinY(rootViewRect)-CGRectGetMinY(_topViewBeginRect)
|
||||
|
||||
// disturbDistance Negative = frame disturbed.
|
||||
// disturbDistance positive = frame not disturbed.
|
||||
if disturbDistance < 0 {
|
||||
// We should only manipulate y.
|
||||
rootViewRect.origin.y -= max(move, disturbDistance)
|
||||
|
||||
_IQShowLog("Moving Downward")
|
||||
// Setting adjusted rootViewRect
|
||||
setRootViewFrame(rootViewRect)
|
||||
}
|
||||
}
|
||||
} else { //If presentation style is neither UIModalPresentationFormSheet nor UIModalPresentationPageSheet then going ahead.(General case)
|
||||
// +Positive or zero.
|
||||
if move >= 0 {
|
||||
|
||||
switch interfaceOrientation {
|
||||
case UIInterfaceOrientation.LandscapeLeft: rootViewRect.origin.x -= move
|
||||
case UIInterfaceOrientation.LandscapeRight: rootViewRect.origin.x += move
|
||||
case UIInterfaceOrientation.Portrait: rootViewRect.origin.y -= move
|
||||
case UIInterfaceOrientation.PortraitUpsideDown: rootViewRect.origin.y += move
|
||||
default: break
|
||||
}
|
||||
|
||||
// From now prevent keyboard manager to slide up the rootView to more than keyboard height. (Bug ID: #93)
|
||||
if preventShowingBottomBlankSpace == true {
|
||||
|
||||
switch interfaceOrientation {
|
||||
case UIInterfaceOrientation.LandscapeLeft:
|
||||
rootViewRect.origin.x = max(rootViewRect.origin.x, min(0, -kbSize.width+newKeyboardDistanceFromTextField))
|
||||
case UIInterfaceOrientation.LandscapeRight:
|
||||
rootViewRect.origin.x = min(rootViewRect.origin.x, +kbSize.width-newKeyboardDistanceFromTextField)
|
||||
case UIInterfaceOrientation.Portrait:
|
||||
rootViewRect.origin.y = max(rootViewRect.origin.y, min(0, -kbSize.height+newKeyboardDistanceFromTextField))
|
||||
case UIInterfaceOrientation.PortraitUpsideDown:
|
||||
rootViewRect.origin.y = min(rootViewRect.origin.y, +kbSize.height-newKeyboardDistanceFromTextField)
|
||||
default: break
|
||||
}
|
||||
}
|
||||
|
||||
_IQShowLog("Moving Upward")
|
||||
// Setting adjusted rootViewRect
|
||||
setRootViewFrame(rootViewRect)
|
||||
} else { // -Negative
|
||||
var disturbDistance : CGFloat = 0
|
||||
|
||||
switch interfaceOrientation {
|
||||
case UIInterfaceOrientation.LandscapeLeft:
|
||||
disturbDistance = CGRectGetMinX(rootViewRect)-CGRectGetMinX(_topViewBeginRect)
|
||||
case UIInterfaceOrientation.LandscapeRight:
|
||||
disturbDistance = CGRectGetMinX(_topViewBeginRect)-CGRectGetMinX(rootViewRect)
|
||||
case UIInterfaceOrientation.Portrait:
|
||||
disturbDistance = CGRectGetMinY(rootViewRect)-CGRectGetMinY(_topViewBeginRect)
|
||||
case UIInterfaceOrientation.PortraitUpsideDown:
|
||||
disturbDistance = CGRectGetMinY(_topViewBeginRect)-CGRectGetMinY(rootViewRect)
|
||||
default: break
|
||||
}
|
||||
|
||||
// disturbDistance Negative = frame disturbed.
|
||||
// disturbDistance positive = frame not disturbed.
|
||||
if disturbDistance < 0 {
|
||||
|
||||
switch interfaceOrientation {
|
||||
case UIInterfaceOrientation.LandscapeLeft: rootViewRect.origin.x -= max(move, disturbDistance)
|
||||
case UIInterfaceOrientation.LandscapeRight: rootViewRect.origin.x += max(move, disturbDistance)
|
||||
case UIInterfaceOrientation.Portrait: rootViewRect.origin.y -= max(move, disturbDistance)
|
||||
case UIInterfaceOrientation.PortraitUpsideDown: rootViewRect.origin.y += max(move, disturbDistance)
|
||||
default: break
|
||||
}
|
||||
|
||||
_IQShowLog("Moving Downward")
|
||||
// Setting adjusted rootViewRect
|
||||
// Setting adjusted rootViewRect
|
||||
setRootViewFrame(rootViewRect)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
_IQShowLog("****** \(__FUNCTION__) ended ******")
|
||||
}
|
||||
|
||||
|
||||
///-------------------------------
|
||||
/// MARK: UIKeyboard Notifications
|
||||
///-------------------------------
|
||||
@@ -1142,7 +1230,7 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
|
||||
//Due to orientation callback we need to resave it's original frame. // (Bug ID: #46)
|
||||
//Added _isTextFieldViewFrameChanged check. Saving textFieldView current frame to use it with canAdjustTextView if textViewFrame has already not been changed. (Bug ID: #92)
|
||||
if _isTextFieldViewFrameChanged == false {
|
||||
if _keyboardManagerFlags.isTextFieldViewFrameChanged == false && _textFieldView != nil {
|
||||
if let textFieldView = _textFieldView {
|
||||
_textFieldViewIntialFrame = textFieldView.frame
|
||||
_IQShowLog("Saving \(textFieldView._IQDescription()) Initial frame : \(_textFieldViewIntialFrame)")
|
||||
@@ -1203,23 +1291,6 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
topMostController = keyWindow()?.topMostController()
|
||||
}
|
||||
|
||||
if let topController = topMostController {
|
||||
//If it's iOS8 then we should do calculations according to portrait orientations. // (Bug ID: #64, #66)
|
||||
let interfaceOrientation = (IQ_IS_IOS8_OR_GREATER) ? UIInterfaceOrientation.Portrait : topController.interfaceOrientation
|
||||
|
||||
let _keyboardDistanceFromTextField = keyboardDistanceFromTextField
|
||||
// let _keyboardDistanceFromTextField = (_textFieldView.keyboardDistanceFromTextField == kIQUseDefaultKeyboardDistance)?_keyboardDistanceFromTextField:_textFieldView.keyboardDistanceFromTextField
|
||||
|
||||
// Adding Keyboard distance from textField.
|
||||
switch interfaceOrientation {
|
||||
case UIInterfaceOrientation.LandscapeLeft, UIInterfaceOrientation.LandscapeRight:
|
||||
_kbSize.width += _keyboardDistanceFromTextField
|
||||
case UIInterfaceOrientation.Portrait, UIInterfaceOrientation.PortraitUpsideDown:
|
||||
_kbSize.height += _keyboardDistanceFromTextField
|
||||
default: break
|
||||
}
|
||||
}
|
||||
|
||||
//If last restored keyboard size is different(any orientation accure), then refresh. otherwise not.
|
||||
if CGSizeEqualToSize(_kbSize, oldKBSize) == false {
|
||||
|
||||
@@ -1273,7 +1344,7 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
// if (_textFieldView == nil) return
|
||||
|
||||
// Boolean to know keyboard is showing/hiding
|
||||
_isKeyboardShowing = false
|
||||
_keyboardManagerFlags.isKeyboardShowing = false
|
||||
|
||||
let info : [NSObject : AnyObject]? = notification?.userInfo
|
||||
|
||||
@@ -1301,9 +1372,9 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
|
||||
// TODO: restore scrollView state
|
||||
// This is temporary solution. Have to implement the save and restore scrollView state
|
||||
var superScrollView = self._lastScrollView?.superviewOfClassType(UIScrollView) as? UIScrollView
|
||||
var superScrollView = lastScrollView
|
||||
|
||||
while let scrollView = superScrollView {
|
||||
while let scrollView = superScrollView.superviewOfClassType(UIScrollView) as? UIScrollView {
|
||||
|
||||
let contentSize = CGSizeMake(max(scrollView.contentSize.width, CGRectGetWidth(scrollView.frame)), max(scrollView.contentSize.height, CGRectGetHeight(scrollView.frame)))
|
||||
|
||||
@@ -1315,7 +1386,7 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
self._IQShowLog("Restoring \(scrollView._IQDescription()) contentOffset to : \(self._startingContentOffset)")
|
||||
}
|
||||
|
||||
superScrollView = superScrollView?.superviewOfClassType(UIScrollView) as? UIScrollView
|
||||
superScrollView = scrollView
|
||||
}
|
||||
}) { (finished) -> Void in }
|
||||
}
|
||||
@@ -1333,18 +1404,46 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
//Used UIViewAnimationOptionBeginFromCurrentState to minimize strange animations.
|
||||
UIView.animateWithDuration(_animationDuration, delay: 0, options: UIViewAnimationOptions.BeginFromCurrentState|_animationCurve, animations: { () -> Void in
|
||||
|
||||
self._IQShowLog("Restoring \(rootViewController._IQDescription()) frame to : \(self._topViewBeginRect)")
|
||||
var hasDoneTweakLayoutGuide = false
|
||||
|
||||
// Setting it's new frame
|
||||
rootViewController.view.frame = self._topViewBeginRect
|
||||
|
||||
//Animating content if needed (Bug ID: #204)
|
||||
if self.layoutIfNeededOnUpdate == true {
|
||||
//Animating content (Bug ID: #160)
|
||||
rootViewController.view.setNeedsLayout()
|
||||
rootViewController.view.layoutIfNeeded()
|
||||
if let viewController = self._textFieldView?.viewController() {
|
||||
|
||||
if let constraint = viewController.IQLayoutGuideConstraint {
|
||||
|
||||
var layoutGuide : UILayoutSupport?
|
||||
if let itemLayoutGuide = constraint.firstItem as? UILayoutSupport {
|
||||
layoutGuide = itemLayoutGuide
|
||||
} else if let itemLayoutGuide = constraint.secondItem as? UILayoutSupport {
|
||||
layoutGuide = itemLayoutGuide
|
||||
}
|
||||
|
||||
if let itemLayoutGuide : UILayoutSupport = layoutGuide {
|
||||
|
||||
if (itemLayoutGuide === viewController.topLayoutGuide || itemLayoutGuide === viewController.bottomLayoutGuide)
|
||||
{
|
||||
constraint.constant = self._layoutGuideConstraintInitialConstant
|
||||
rootViewController.view.setNeedsLayout()
|
||||
rootViewController.view.layoutIfNeeded()
|
||||
|
||||
hasDoneTweakLayoutGuide = true
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if hasDoneTweakLayoutGuide == false {
|
||||
self._IQShowLog("Restoring \(rootViewController._IQDescription()) frame to : \(self._topViewBeginRect)")
|
||||
|
||||
// Setting it's new frame
|
||||
rootViewController.view.frame = self._topViewBeginRect
|
||||
|
||||
//Animating content if needed (Bug ID: #204)
|
||||
if self.layoutIfNeededOnUpdate == true {
|
||||
//Animating content (Bug ID: #160)
|
||||
rootViewController.view.setNeedsLayout()
|
||||
rootViewController.view.layoutIfNeeded()
|
||||
}
|
||||
}
|
||||
}) { (finished) -> Void in }
|
||||
|
||||
_rootViewController = nil
|
||||
@@ -1362,7 +1461,6 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
_IQShowLog("****** \(__FUNCTION__) ended ******")
|
||||
}
|
||||
|
||||
|
||||
func keyboardDidHide(notification:NSNotification) {
|
||||
|
||||
_IQShowLog("****** \(__FUNCTION__) started ******")
|
||||
@@ -1405,7 +1503,7 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
|
||||
// Saving textFieldView current frame to use it with canAdjustTextView if textViewFrame has already not been changed.
|
||||
//Added _isTextFieldViewFrameChanged check. (Bug ID: #92)
|
||||
if _isTextFieldViewFrameChanged == false {
|
||||
if _keyboardManagerFlags.isTextFieldViewFrameChanged == false {
|
||||
if let textFieldView = _textFieldView {
|
||||
_textFieldViewIntialFrame = textFieldView.frame
|
||||
_IQShowLog("Saving \(textFieldView._IQDescription()) Initial frame : \(_textFieldViewIntialFrame)")
|
||||
@@ -1426,6 +1524,16 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
|
||||
}, completion: { (finished) -> Void in
|
||||
|
||||
//RestoringTextView before reloading inputViews
|
||||
if (self._keyboardManagerFlags.isTextFieldViewFrameChanged)
|
||||
{
|
||||
self._keyboardManagerFlags.isTextFieldViewFrameChanged = false;
|
||||
|
||||
if let textFieldView = self._textFieldView {
|
||||
textFieldView.frame = self._textFieldViewIntialFrame;
|
||||
}
|
||||
}
|
||||
|
||||
//On textView toolbar didn't appear on first time, so forcing textView to reload it's inputViews.
|
||||
self._textFieldView?.reloadInputViews()
|
||||
})
|
||||
@@ -1442,9 +1550,13 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
|
||||
_textFieldView?.window?.addGestureRecognizer(_tapGesture) // (Enhancement ID: #14)
|
||||
|
||||
if _isKeyboardShowing == false { // (Bug ID: #5)
|
||||
if _keyboardManagerFlags.isKeyboardShowing == false { // (Bug ID: #5)
|
||||
|
||||
// keyboard is not showing(At the beginning only). We should save rootViewRect.
|
||||
if let constant = _textFieldView?.viewController()?.IQLayoutGuideConstraint?.constant {
|
||||
_layoutGuideConstraintInitialConstant = constant
|
||||
}
|
||||
|
||||
_rootViewController = _textFieldView?.topMostController()
|
||||
if _rootViewController == nil {
|
||||
_rootViewController = keyWindow()?.topMostController()
|
||||
@@ -1496,9 +1608,9 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
_textFieldView?.window?.removeGestureRecognizer(_tapGesture)
|
||||
|
||||
// We check if there's a change in original frame or not.
|
||||
if _isTextFieldViewFrameChanged == true {
|
||||
if _keyboardManagerFlags.isTextFieldViewFrameChanged == true {
|
||||
UIView.animateWithDuration(_animationDuration, delay: 0, options: UIViewAnimationOptions.BeginFromCurrentState|_animationCurve, animations: { () -> Void in
|
||||
self._isTextFieldViewFrameChanged = false
|
||||
self._keyboardManagerFlags.isTextFieldViewFrameChanged = false
|
||||
|
||||
self._IQShowLog("Restoring \(self._textFieldView?._IQDescription()) frame to : \(self._textFieldViewIntialFrame)")
|
||||
|
||||
@@ -1518,7 +1630,7 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
if shouldFixTextViewClip {
|
||||
let textView = notification.object as! UITextView
|
||||
|
||||
let line = textView .caretRectForPosition(textView.selectedTextRange?.start)
|
||||
let line = textView.caretRectForPosition(textView.selectedTextRange?.start)
|
||||
|
||||
let overflow = CGRectGetMaxY(line) - (textView.contentOffset.y + CGRectGetHeight(textView.bounds) - textView.contentInset.bottom - textView.contentInset.top)
|
||||
|
||||
@@ -1537,7 +1649,6 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
///------------------------------------------
|
||||
/// MARK: Interface Orientation Notifications
|
||||
///------------------------------------------
|
||||
@@ -1548,11 +1659,11 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
_IQShowLog("****** \(__FUNCTION__) started ******")
|
||||
|
||||
//If textFieldViewInitialRect is saved then restore it.(UITextView case @canAdjustTextView)
|
||||
if _isTextFieldViewFrameChanged == true {
|
||||
if _keyboardManagerFlags.isTextFieldViewFrameChanged == true {
|
||||
if let textFieldView = _textFieldView {
|
||||
//Due to orientation callback we need to set it's original position.
|
||||
UIView.animateWithDuration(_animationDuration, delay: 0, options: (_animationCurve|UIViewAnimationOptions.BeginFromCurrentState), animations: { () -> Void in
|
||||
self._isTextFieldViewFrameChanged = false
|
||||
self._keyboardManagerFlags.isTextFieldViewFrameChanged = false
|
||||
|
||||
self._IQShowLog("Restoring \(textFieldView._IQDescription()) frame to : \(self._textFieldViewIntialFrame)")
|
||||
|
||||
@@ -1566,7 +1677,6 @@ class IQKeyboardManager: NSObject, UIGestureRecognizerDelegate {
|
||||
_IQShowLog("****** \(__FUNCTION__) ended ******")
|
||||
}
|
||||
|
||||
|
||||
///------------------
|
||||
/// MARK: AutoToolbar
|
||||
///------------------
|
||||
|
||||
@@ -29,8 +29,23 @@ class IQTextView : UITextView {
|
||||
|
||||
required init(coder aDecoder: NSCoder) {
|
||||
super.init(coder: aDecoder)
|
||||
NSNotificationCenter.defaultCenter().addObserver(self, selector: "refreshPlaceholder", name: UITextViewTextDidChangeNotification, object: self)
|
||||
}
|
||||
|
||||
override init(frame: CGRect, textContainer: NSTextContainer?) {
|
||||
super.init(frame: frame, textContainer: textContainer)
|
||||
NSNotificationCenter.defaultCenter().addObserver(self, selector: "refreshPlaceholder", name: UITextViewTextDidChangeNotification, object: self)
|
||||
}
|
||||
|
||||
override func awakeFromNib() {
|
||||
super.awakeFromNib()
|
||||
NSNotificationCenter.defaultCenter().addObserver(self, selector: "refreshPlaceholder", name: UITextViewTextDidChangeNotification, object: self)
|
||||
}
|
||||
|
||||
deinit {
|
||||
NSNotificationCenter.defaultCenter().removeObserver(self)
|
||||
}
|
||||
|
||||
private var placeholderLabel: UILabel?
|
||||
|
||||
/** @abstract To set textView's placeholder text. Default is ni. */
|
||||
|
||||
@@ -30,15 +30,16 @@ class IQTitleBarButtonItem: UIBarButtonItem {
|
||||
|
||||
didSet {
|
||||
if let unwrappedFont = font {
|
||||
titleLabel?.font = unwrappedFont
|
||||
_titleLabel?.font = unwrappedFont
|
||||
} else {
|
||||
titleLabel?.font = UIFont.boldSystemFontOfSize(12)
|
||||
_titleLabel?.font = UIFont.boldSystemFontOfSize(12)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private var titleLabel : UILabel?
|
||||
|
||||
private var _titleLabel : UILabel?
|
||||
private var _titleView : UIView?
|
||||
|
||||
override init() {
|
||||
super.init()
|
||||
}
|
||||
@@ -47,14 +48,19 @@ class IQTitleBarButtonItem: UIBarButtonItem {
|
||||
|
||||
super.init(title: nil, style: UIBarButtonItemStyle.Plain, target: nil, action: nil)
|
||||
|
||||
titleLabel = UILabel(frame: frame)
|
||||
titleLabel?.backgroundColor = UIColor.clearColor()
|
||||
titleLabel?.textAlignment = .Center
|
||||
titleLabel?.text = title
|
||||
titleLabel?.autoresizingMask = .FlexibleWidth
|
||||
_titleView = UIView(frame: frame)
|
||||
_titleView?.backgroundColor = UIColor.clearColor()
|
||||
_titleView?.autoresizingMask = .FlexibleWidth
|
||||
|
||||
_titleLabel = UILabel(frame: _titleView!.bounds)
|
||||
_titleLabel?.textColor = UIColor.lightGrayColor()
|
||||
_titleLabel?.backgroundColor = UIColor.clearColor()
|
||||
_titleLabel?.textAlignment = .Center
|
||||
_titleLabel?.text = title
|
||||
_titleLabel?.autoresizingMask = .FlexibleWidth
|
||||
font = UIFont.boldSystemFontOfSize(12.0)
|
||||
titleLabel?.font = self.font
|
||||
customView = titleLabel
|
||||
_titleLabel?.font = self.font
|
||||
customView = _titleLabel
|
||||
enabled = false
|
||||
}
|
||||
|
||||
|
||||
@@ -27,6 +27,14 @@ import UIKit
|
||||
/** @abstract IQToolbar for IQKeyboardManager. */
|
||||
class IQToolbar: UIToolbar , UIInputViewAudioFeedback {
|
||||
|
||||
override class func initialize() {
|
||||
|
||||
superclass()?.initialize()
|
||||
|
||||
self.appearance().barTintColor = nil
|
||||
self.appearance().backgroundColor = nil
|
||||
}
|
||||
|
||||
var titleFont : UIFont? {
|
||||
|
||||
didSet {
|
||||
@@ -62,7 +70,6 @@ class IQToolbar: UIToolbar , UIInputViewAudioFeedback {
|
||||
|
||||
sizeToFit()
|
||||
autoresizingMask = UIViewAutoresizing.FlexibleWidth
|
||||
|
||||
tintColor = UIColor .blackColor()
|
||||
}
|
||||
|
||||
@@ -71,7 +78,6 @@ class IQToolbar: UIToolbar , UIInputViewAudioFeedback {
|
||||
|
||||
sizeToFit()
|
||||
autoresizingMask = UIViewAutoresizing.FlexibleWidth | UIViewAutoresizing.FlexibleHeight
|
||||
|
||||
tintColor = UIColor .blackColor()
|
||||
}
|
||||
|
||||
@@ -84,11 +90,11 @@ class IQToolbar: UIToolbar , UIInputViewAudioFeedback {
|
||||
override var tintColor: UIColor! {
|
||||
|
||||
didSet {
|
||||
if items != nil {
|
||||
for item in items as! [UIBarButtonItem] {
|
||||
if let unwrappedItems = items {
|
||||
for item in unwrappedItems as! [UIBarButtonItem] {
|
||||
|
||||
if item is IQTitleBarButtonItem {
|
||||
(item as! IQTitleBarButtonItem).tintColor = tintColor
|
||||
item.tintColor = tintColor
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -25,6 +25,8 @@
|
||||
import Foundation
|
||||
import UIKit
|
||||
|
||||
private var kIQShouldHideTitle = "kIQShouldHideTitle"
|
||||
|
||||
/**
|
||||
UIView category methods to add IQToolbar on UIKeyboard.
|
||||
*/
|
||||
@@ -39,7 +41,7 @@ extension UIView {
|
||||
*/
|
||||
var shouldHideTitle: Bool? {
|
||||
get {
|
||||
let aValue: AnyObject? = objc_getAssociatedObject(self, "shouldHideTitle")
|
||||
let aValue: AnyObject? = objc_getAssociatedObject(self, &kIQShouldHideTitle)
|
||||
|
||||
if aValue == nil {
|
||||
return false
|
||||
@@ -48,7 +50,7 @@ extension UIView {
|
||||
}
|
||||
}
|
||||
set(newValue) {
|
||||
objc_setAssociatedObject(self, "shouldHideTitle", newValue, UInt(OBJC_ASSOCIATION_RETAIN_NONATOMIC))
|
||||
objc_setAssociatedObject(self, &kIQShouldHideTitle, newValue, UInt(OBJC_ASSOCIATION_RETAIN_NONATOMIC))
|
||||
}
|
||||
}
|
||||
|
||||
@@ -452,7 +454,7 @@ extension UIView {
|
||||
var items : [UIBarButtonItem] = []
|
||||
|
||||
// Create a cancel button to show on keyboard to resign it. Adding a selector to resign it.
|
||||
let cancelButton = IQBarButtonItem(title: leftButtonTitle, style: UIBarButtonItemStyle.Bordered, target: target, action: leftButtonAction)
|
||||
let cancelButton = IQBarButtonItem(title: leftButtonTitle, style: UIBarButtonItemStyle.Plain, target: target, action: leftButtonAction)
|
||||
items.append(cancelButton)
|
||||
|
||||
if let unwrappedTitleText = titleText {
|
||||
@@ -474,7 +476,7 @@ extension UIView {
|
||||
items.append(nilButton)
|
||||
|
||||
// Create a done button to show on keyboard to resign it. Adding a selector to resign it.
|
||||
let doneButton = IQBarButtonItem(title: rightButtonTitle, style: UIBarButtonItemStyle.Bordered, target: target, action: rightButtonAction)
|
||||
let doneButton = IQBarButtonItem(title: rightButtonTitle, style: UIBarButtonItemStyle.Plain, target: target, action: rightButtonAction)
|
||||
items.append(doneButton)
|
||||
|
||||
// Adding button to toolBar.
|
||||
@@ -686,7 +688,7 @@ extension UIView {
|
||||
var items : [UIBarButtonItem] = []
|
||||
|
||||
// Create a done button to show on keyboard to resign it. Adding a selector to resign it.
|
||||
let doneButton = IQBarButtonItem(title: rightButtonTitle, style: UIBarButtonItemStyle.Bordered, target: target, action: rightButtonAction)
|
||||
let doneButton = IQBarButtonItem(title: rightButtonTitle, style: UIBarButtonItemStyle.Plain, target: target, action: rightButtonAction)
|
||||
|
||||
let prev = IQBarButtonItem(image: UIImage(named: "IQKeyboardManager.bundle/IQButtonBarArrowLeft"), style: UIBarButtonItemStyle.Plain, target: target, action: previousAction)
|
||||
|
||||
|
||||
@@ -1,41 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="6214" systemVersion="14A314h" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" useTraitCollections="YES">
|
||||
<dependencies>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="6207"/>
|
||||
<capability name="Constraints with non-1.0 multipliers" minToolsVersion="5.1"/>
|
||||
</dependencies>
|
||||
<objects>
|
||||
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner"/>
|
||||
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
|
||||
<view contentMode="scaleToFill" id="iN0-l3-epB">
|
||||
<rect key="frame" x="0.0" y="0.0" width="480" height="480"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<subviews>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text=" Copyright (c) 2014 Iftekhar. All rights reserved." textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" minimumFontSize="9" translatesAutoresizingMaskIntoConstraints="NO" id="8ie-xW-0ye">
|
||||
<rect key="frame" x="20" y="439" width="441" height="21"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
||||
<color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
|
||||
<nil key="highlightedColor"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="IQKeyboardManager Swift" textAlignment="center" lineBreakMode="middleTruncation" baselineAdjustment="alignBaselines" minimumFontSize="18" translatesAutoresizingMaskIntoConstraints="NO" id="kId-c2-rCX">
|
||||
<rect key="frame" x="20" y="140" width="441" height="43"/>
|
||||
<fontDescription key="fontDescription" type="boldSystem" pointSize="36"/>
|
||||
<color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
|
||||
<nil key="highlightedColor"/>
|
||||
</label>
|
||||
</subviews>
|
||||
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
|
||||
<constraints>
|
||||
<constraint firstItem="kId-c2-rCX" firstAttribute="centerY" secondItem="iN0-l3-epB" secondAttribute="bottom" multiplier="1/3" constant="1" id="5cJ-9S-tgC"/>
|
||||
<constraint firstAttribute="centerX" secondItem="kId-c2-rCX" secondAttribute="centerX" id="Koa-jz-hwk"/>
|
||||
<constraint firstAttribute="bottom" secondItem="8ie-xW-0ye" secondAttribute="bottom" constant="20" id="Kzo-t9-V3l"/>
|
||||
<constraint firstItem="8ie-xW-0ye" firstAttribute="leading" secondItem="iN0-l3-epB" secondAttribute="leading" constant="20" symbolic="YES" id="MfP-vx-nX0"/>
|
||||
<constraint firstAttribute="centerX" secondItem="8ie-xW-0ye" secondAttribute="centerX" id="ZEH-qu-HZ9"/>
|
||||
<constraint firstItem="kId-c2-rCX" firstAttribute="leading" secondItem="iN0-l3-epB" secondAttribute="leading" constant="20" symbolic="YES" id="fvb-Df-36g"/>
|
||||
</constraints>
|
||||
<nil key="simulatedStatusBarMetrics"/>
|
||||
<freeformSimulatedSizeMetrics key="simulatedDestinationMetrics"/>
|
||||
<point key="canvasLocation" x="548" y="455"/>
|
||||
</view>
|
||||
</objects>
|
||||
</document>
|
||||
@@ -22,8 +22,6 @@
|
||||
<string>1</string>
|
||||
<key>LSRequiresIPhoneOS</key>
|
||||
<true/>
|
||||
<key>UILaunchStoryboardName</key>
|
||||
<string>LaunchScreen</string>
|
||||
<key>UIMainStoryboardFile</key>
|
||||
<string>MainSwift</string>
|
||||
<key>UIRequiredDeviceCapabilities</key>
|
||||
|
||||
@@ -1,18 +1,14 @@
|
||||
{\rtf1\ansi\ansicpg1252\cocoartf1343\cocoasubrtf140
|
||||
{\fonttbl\f0\fswiss\fcharset0 Helvetica;}
|
||||
{\rtf1\ansi\ansicpg1252\cocoartf1347\cocoasubrtf570
|
||||
{\fonttbl\f0\fswiss\fcharset0 Helvetica;\f1\fnil\fcharset0 Menlo-Regular;}
|
||||
{\colortbl;\red255\green255\blue255;}
|
||||
{\*\listtable{\list\listtemplateid1\listhybrid{\listlevel\levelnfc0\levelnfcn0\leveljc0\leveljcn0\levelfollow0\levelstartat1\levelspace360\levelindent0{\*\levelmarker \{decimal\}.}{\leveltext\leveltemplateid1\'02\'00.;}{\levelnumbers\'01;}\fi-360\li720\lin720 }{\listname ;}\listid1}
|
||||
{\list\listtemplateid2\listhybrid{\listlevel\levelnfc0\levelnfcn0\leveljc0\leveljcn0\levelfollow0\levelstartat1\levelspace360\levelindent0{\*\levelmarker \{decimal\}.}{\leveltext\leveltemplateid101\'02\'00.;}{\levelnumbers\'01;}\fi-360\li720\lin720 }{\listname ;}\listid2}}
|
||||
{\*\listoverridetable{\listoverride\listid1\listoverridecount0\ls1}{\listoverride\listid2\listoverridecount0\ls2}}
|
||||
\margl1440\margr1440\vieww9000\viewh8400\viewkind0
|
||||
\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\pardirnatural
|
||||
|
||||
\f0\b\fs24 \cf0 \
|
||||
\pard\tx220\tx720\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li720\fi-720\pardirnatural
|
||||
\ls1\ilvl0\cf0 {\listtext 1. }Need to Convert NSMutableSet to swift Array\
|
||||
\pard\tx220\tx720\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li720\fi-720\pardirnatural
|
||||
\ls2\ilvl0\cf0 {\listtext 2. }Need to convert NSArray to swift Array\
|
||||
\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\pardirnatural
|
||||
\cf0 \
|
||||
\
|
||||
\f0\fs24 \cf0 \
|
||||
1. Need to Convert NSMutableSet to swift Array\
|
||||
2. Need to convert NSArray to swift Array\
|
||||
3.
|
||||
\f1\fs26 setCustomDoneTarget on IQUIView+IQKeyboardToolbar.swift\
|
||||
4. Need to match IQUIView+IQKeyboardToolbar.swift with Objective-C Version\
|
||||
5. Debug Hierarchy on IQUIView+Hierarchy.swift\
|
||||
}
|
||||
@@ -93,7 +93,6 @@
|
||||
C0A392161B208F8300783FDD /* IQUIViewController+Additions.m in Sources */ = {isa = PBXBuildFile; fileRef = C0A392141B208F8300783FDD /* IQUIViewController+Additions.m */; };
|
||||
C0AB9307195F57BB00447049 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 9DC4CE2E18DAF77300DB2CB0 /* Main.storyboard */; };
|
||||
C0ACB10119CF104E0057B571 /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = C0ACB10019CF104E0057B571 /* Images.xcassets */; };
|
||||
C0ACB10419CF104F0057B571 /* LaunchScreen.xib in Resources */ = {isa = PBXBuildFile; fileRef = C0ACB10219CF104F0057B571 /* LaunchScreen.xib */; };
|
||||
C0B63BA01781FAB1008D3B64 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C0B63B9F1781FAB1008D3B64 /* UIKit.framework */; };
|
||||
C0B63BA21781FAB1008D3B64 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C0B63BA11781FAB1008D3B64 /* Foundation.framework */; };
|
||||
C0B63BA41781FAB1008D3B64 /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C0B63BA31781FAB1008D3B64 /* CoreGraphics.framework */; };
|
||||
@@ -112,6 +111,8 @@
|
||||
C0DDEB6C19FCD56300FAB29F /* IQToolbar.swift in Sources */ = {isa = PBXBuildFile; fileRef = C0DDEB5D19FCD56300FAB29F /* IQToolbar.swift */; };
|
||||
C0DDEB6D19FCD56300FAB29F /* IQUIView+IQKeyboardToolbar.swift in Sources */ = {isa = PBXBuildFile; fileRef = C0DDEB5E19FCD56300FAB29F /* IQUIView+IQKeyboardToolbar.swift */; };
|
||||
C0DDEB6E19FCD56300FAB29F /* IQKeyboardManager.bundle in Resources */ = {isa = PBXBuildFile; fileRef = C0DDEB6019FCD56300FAB29F /* IQKeyboardManager.bundle */; };
|
||||
C0E9FD191B7E01F400C62579 /* IQUITextFieldView+Additions.swift in Sources */ = {isa = PBXBuildFile; fileRef = C0E9FD171B7E01E500C62579 /* IQUITextFieldView+Additions.swift */; };
|
||||
C0E9FD1C1B7E021000C62579 /* IQUIViewController+Additions.swift in Sources */ = {isa = PBXBuildFile; fileRef = C0E9FD1A1B7E020E00C62579 /* IQUIViewController+Additions.swift */; };
|
||||
C0EC59D219D0C0B100997FFE /* TextFieldViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = C0EC59D119D0C0B100997FFE /* TextFieldViewController.swift */; };
|
||||
C0EC59D419D0C0C600997FFE /* ScrollViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = C0EC59D319D0C0C600997FFE /* ScrollViewController.swift */; };
|
||||
C0EC59D619D0C0D200997FFE /* WebViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = C0EC59D519D0C0D200997FFE /* WebViewController.swift */; };
|
||||
@@ -217,16 +218,15 @@
|
||||
C08A654C19DB18C700D255E2 /* ManualToolbarViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ManualToolbarViewController.m; sourceTree = "<group>"; };
|
||||
C08B91B719D7558800AF16E7 /* TextSelectionViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TextSelectionViewController.h; sourceTree = "<group>"; };
|
||||
C08B91B819D7558800AF16E7 /* TextSelectionViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TextSelectionViewController.m; sourceTree = "<group>"; };
|
||||
C08CE0BC1A5C5EAC00FD9273 /* Swift Pending.rtf */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.rtf; name = "Swift Pending.rtf"; path = "IQKeyboardManager Swift/Swift Pending.rtf"; sourceTree = "<group>"; };
|
||||
C08CE0BC1A5C5EAC00FD9273 /* Swift Pending.rtf */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.rtf; name = "Swift Pending.rtf"; path = "../IQKeyboardManager Swift/Swift Pending.rtf"; sourceTree = "<group>"; };
|
||||
C09576A719D811E00081DEB9 /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x.png"; sourceTree = "<group>"; };
|
||||
C0A392111B208F8300783FDD /* IQUITextFieldView+Additions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "IQUITextFieldView+Additions.h"; sourceTree = "<group>"; };
|
||||
C0A392121B208F8300783FDD /* IQUITextFieldView+Additions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "IQUITextFieldView+Additions.m"; sourceTree = "<group>"; };
|
||||
C0A392131B208F8300783FDD /* IQUIViewController+Additions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "IQUIViewController+Additions.h"; sourceTree = "<group>"; };
|
||||
C0A392141B208F8300783FDD /* IQUIViewController+Additions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "IQUIViewController+Additions.m"; sourceTree = "<group>"; };
|
||||
C0ACB0F519CF104B0057B571 /* IQKeyboardManager Swift.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "IQKeyboardManager Swift.app"; sourceTree = BUILT_PRODUCTS_DIR; };
|
||||
C0ACB0F819CF104D0057B571 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
|
||||
C0ACB0F819CF104D0057B571 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; name = Info.plist; path = "../IQKeyboardManager Swift/Info.plist"; sourceTree = "<group>"; };
|
||||
C0ACB10019CF104E0057B571 /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Images.xcassets; path = "../IQKeyboardManager Swift/Images.xcassets"; sourceTree = "<group>"; };
|
||||
C0ACB10319CF104F0057B571 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/LaunchScreen.xib; sourceTree = "<group>"; };
|
||||
C0B63B9B1781FAB1008D3B64 /* IQKeyboardManager.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = IQKeyboardManager.app; sourceTree = BUILT_PRODUCTS_DIR; };
|
||||
C0B63B9F1781FAB1008D3B64 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; };
|
||||
C0B63BA11781FAB1008D3B64 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
|
||||
@@ -238,7 +238,7 @@
|
||||
C0B63BAF1781FAB1008D3B64 /* AppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = "<group>"; };
|
||||
C0DDEB4E19FCD56300FAB29F /* IQNSArray+Sort.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = "IQNSArray+Sort.swift"; sourceTree = "<group>"; };
|
||||
C0DDEB4F19FCD56300FAB29F /* IQUIView+Hierarchy.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; lineEnding = 0; path = "IQUIView+Hierarchy.swift"; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.swift; };
|
||||
C0DDEB5019FCD56300FAB29F /* IQUIWindow+Hierarchy.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; lineEnding = 0; path = "IQUIWindow+Hierarchy.swift"; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.swift; };
|
||||
C0DDEB5019FCD56300FAB29F /* IQUIWindow+Hierarchy.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; lineEnding = 0; path = "IQUIWindow+Hierarchy.swift"; sourceTree = "<group>"; };
|
||||
C0DDEB5219FCD56300FAB29F /* IQKeyboardManagerConstants.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = IQKeyboardManagerConstants.swift; sourceTree = "<group>"; };
|
||||
C0DDEB5319FCD56300FAB29F /* IQKeyboardManagerConstantsInternal.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = IQKeyboardManagerConstantsInternal.swift; sourceTree = "<group>"; };
|
||||
C0DDEB5419FCD56300FAB29F /* IQKeyboardManager.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; lineEnding = 0; path = IQKeyboardManager.swift; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.swift; };
|
||||
@@ -247,8 +247,10 @@
|
||||
C0DDEB5B19FCD56300FAB29F /* IQBarButtonItem.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = IQBarButtonItem.swift; sourceTree = "<group>"; };
|
||||
C0DDEB5C19FCD56300FAB29F /* IQTitleBarButtonItem.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = IQTitleBarButtonItem.swift; sourceTree = "<group>"; };
|
||||
C0DDEB5D19FCD56300FAB29F /* IQToolbar.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = IQToolbar.swift; sourceTree = "<group>"; };
|
||||
C0DDEB5E19FCD56300FAB29F /* IQUIView+IQKeyboardToolbar.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; lineEnding = 0; path = "IQUIView+IQKeyboardToolbar.swift"; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.swift; };
|
||||
C0DDEB5E19FCD56300FAB29F /* IQUIView+IQKeyboardToolbar.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; lineEnding = 0; path = "IQUIView+IQKeyboardToolbar.swift"; sourceTree = "<group>"; };
|
||||
C0DDEB6019FCD56300FAB29F /* IQKeyboardManager.bundle */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.plug-in"; path = IQKeyboardManager.bundle; sourceTree = "<group>"; };
|
||||
C0E9FD171B7E01E500C62579 /* IQUITextFieldView+Additions.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = "IQUITextFieldView+Additions.swift"; sourceTree = "<group>"; };
|
||||
C0E9FD1A1B7E020E00C62579 /* IQUIViewController+Additions.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = "IQUIViewController+Additions.swift"; sourceTree = "<group>"; };
|
||||
C0EC59D119D0C0B100997FFE /* TextFieldViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = TextFieldViewController.swift; path = "IQKeyboardManager Swift/TextFieldViewController.swift"; sourceTree = "<group>"; };
|
||||
C0EC59D319D0C0C600997FFE /* ScrollViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = ScrollViewController.swift; path = "IQKeyboardManager Swift/ScrollViewController.swift"; sourceTree = "<group>"; };
|
||||
C0EC59D519D0C0D200997FFE /* WebViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = WebViewController.swift; path = "IQKeyboardManager Swift/WebViewController.swift"; sourceTree = "<group>"; };
|
||||
@@ -457,17 +459,6 @@
|
||||
path = Resources;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
C08549D519FAA92E00973573 /* Swift Demo */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
C08CE0BC1A5C5EAC00FD9273 /* Swift Pending.rtf */,
|
||||
C0DDEB4C19FCD56300FAB29F /* IQKeybordManagerSwift */,
|
||||
C0DD7E9F19D0A0AE007604CF /* KeyboardTextFieldDemoSwift */,
|
||||
C0ACB0F619CF104C0057B571 /* IQKeyboardManager Swift */,
|
||||
);
|
||||
name = "Swift Demo";
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
C0A25BD219D72AAA009E074D /* TableViewController Example */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
@@ -477,27 +468,10 @@
|
||||
name = "TableViewController Example";
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
C0ACB0F619CF104C0057B571 /* IQKeyboardManager Swift */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
C0ACB10219CF104F0057B571 /* LaunchScreen.xib */,
|
||||
C0ACB0F719CF104D0057B571 /* Supporting Files */,
|
||||
);
|
||||
path = "IQKeyboardManager Swift";
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
C0ACB0F719CF104D0057B571 /* Supporting Files */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
C0ACB0F819CF104D0057B571 /* Info.plist */,
|
||||
);
|
||||
name = "Supporting Files";
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
C0B63B901781FAB0008D3B64 = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
C08549D519FAA92E00973573 /* Swift Demo */,
|
||||
C0DDEB4C19FCD56300FAB29F /* IQKeybordManagerSwift */,
|
||||
C085498E19FAA91E00973573 /* IQKeyBoardManager */,
|
||||
C0B63BA51781FAB1008D3B64 /* KeyboardTextFieldDemo */,
|
||||
C0DE7A3019D49D3400B6A582 /* Resources */,
|
||||
@@ -535,41 +509,9 @@
|
||||
C0B63BA51781FAB1008D3B64 /* KeyboardTextFieldDemo */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
C05DD9FC1A591D2D00A6ECD4 /* IQDropDownTextField */,
|
||||
C0ACB10019CF104E0057B571 /* Images.xcassets */,
|
||||
C07E20C0185900BD001699A8 /* TextFieldViewController.h */,
|
||||
C07E20C1185900BD001699A8 /* TextFieldViewController.m */,
|
||||
C00EAA6B1858D5A500968DE2 /* ScrollViewController.h */,
|
||||
C07E20B41858FF54001699A8 /* ScrollViewController.m */,
|
||||
C07E20B918590085001699A8 /* WebViewController.h */,
|
||||
C07E20BA18590085001699A8 /* WebViewController.m */,
|
||||
C080A59018740EFF0088441B /* TextViewSpecialCaseViewController.h */,
|
||||
C080A59118740EFF0088441B /* TextViewSpecialCaseViewController.m */,
|
||||
53CF2B7D1903D02200E3FDEA /* NavigationBarViewController.h */,
|
||||
53CF2B7E1903D02200E3FDEA /* NavigationBarViewController.m */,
|
||||
9D03F06D18BDC19400F4970D /* SpecialCaseViewController.h */,
|
||||
9D03F06E18BDC19400F4970D /* SpecialCaseViewController.m */,
|
||||
9D8E5DAA18BC8E1D005695CF /* ViewController.h */,
|
||||
9D8E5DAB18BC8E1D005695CF /* ViewController.m */,
|
||||
C08B91B719D7558800AF16E7 /* TextSelectionViewController.h */,
|
||||
C08B91B819D7558800AF16E7 /* TextSelectionViewController.m */,
|
||||
C08A654B19DB18C700D255E2 /* ManualToolbarViewController.h */,
|
||||
C08A654C19DB18C700D255E2 /* ManualToolbarViewController.m */,
|
||||
C0F1193819EEDCD500708D17 /* BottomBlankSpaceViewController.h */,
|
||||
C0F1193919EEDCD500708D17 /* BottomBlankSpaceViewController.m */,
|
||||
C02790321A01404000FCB517 /* CollectionViewDemoController.h */,
|
||||
C02790331A01404000FCB517 /* CollectionViewDemoController.m */,
|
||||
DDAA29F01A320057002C0ED8 /* TableViewInContainerViewController.h */,
|
||||
DDAA29F11A320057002C0ED8 /* TableViewInContainerViewController.m */,
|
||||
1C2270101AE69224003A9D15 /* CustomViewController.h */,
|
||||
1C2270111AE69224003A9D15 /* CustomViewController.m */,
|
||||
1C22700D1AE68EEE003A9D15 /* CustomSubclassView.h */,
|
||||
1C22700E1AE68EEE003A9D15 /* CustomSubclassView.m */,
|
||||
C0A25BD219D72AAA009E074D /* TableViewController Example */,
|
||||
C06579C119D60AAF00DAA3EA /* Settings */,
|
||||
C0E9FD161B7DEEE800C62579 /* Swift */,
|
||||
C0E9FD151B7DEEC900C62579 /* Objective-C */,
|
||||
9DC4CE2E18DAF77300DB2CB0 /* Main.storyboard */,
|
||||
C0B63BAE1781FAB1008D3B64 /* AppDelegate.h */,
|
||||
C0B63BAF1781FAB1008D3B64 /* AppDelegate.m */,
|
||||
C0B63BA61781FAB1008D3B64 /* Supporting Files */,
|
||||
);
|
||||
path = KeyboardTextFieldDemo;
|
||||
@@ -612,6 +554,7 @@
|
||||
1C1ADFC71AE51F74007A73E3 /* Settings */,
|
||||
);
|
||||
name = KeyboardTextFieldDemoSwift;
|
||||
path = ..;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
C0DDEB4C19FCD56300FAB29F /* IQKeybordManagerSwift */ = {
|
||||
@@ -633,7 +576,9 @@
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
C0DDEB4E19FCD56300FAB29F /* IQNSArray+Sort.swift */,
|
||||
C0E9FD171B7E01E500C62579 /* IQUITextFieldView+Additions.swift */,
|
||||
C0DDEB4F19FCD56300FAB29F /* IQUIView+Hierarchy.swift */,
|
||||
C0E9FD1A1B7E020E00C62579 /* IQUIViewController+Additions.swift */,
|
||||
C0DDEB5019FCD56300FAB29F /* IQUIWindow+Hierarchy.swift */,
|
||||
);
|
||||
path = Categories;
|
||||
@@ -683,6 +628,57 @@
|
||||
name = Resources;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
C0E9FD151B7DEEC900C62579 /* Objective-C */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
C05DD9FC1A591D2D00A6ECD4 /* IQDropDownTextField */,
|
||||
C0ACB10019CF104E0057B571 /* Images.xcassets */,
|
||||
C07E20C0185900BD001699A8 /* TextFieldViewController.h */,
|
||||
C07E20C1185900BD001699A8 /* TextFieldViewController.m */,
|
||||
C00EAA6B1858D5A500968DE2 /* ScrollViewController.h */,
|
||||
C07E20B41858FF54001699A8 /* ScrollViewController.m */,
|
||||
C07E20B918590085001699A8 /* WebViewController.h */,
|
||||
C07E20BA18590085001699A8 /* WebViewController.m */,
|
||||
C080A59018740EFF0088441B /* TextViewSpecialCaseViewController.h */,
|
||||
C080A59118740EFF0088441B /* TextViewSpecialCaseViewController.m */,
|
||||
53CF2B7D1903D02200E3FDEA /* NavigationBarViewController.h */,
|
||||
53CF2B7E1903D02200E3FDEA /* NavigationBarViewController.m */,
|
||||
9D03F06D18BDC19400F4970D /* SpecialCaseViewController.h */,
|
||||
9D03F06E18BDC19400F4970D /* SpecialCaseViewController.m */,
|
||||
9D8E5DAA18BC8E1D005695CF /* ViewController.h */,
|
||||
9D8E5DAB18BC8E1D005695CF /* ViewController.m */,
|
||||
C08B91B719D7558800AF16E7 /* TextSelectionViewController.h */,
|
||||
C08B91B819D7558800AF16E7 /* TextSelectionViewController.m */,
|
||||
C08A654B19DB18C700D255E2 /* ManualToolbarViewController.h */,
|
||||
C08A654C19DB18C700D255E2 /* ManualToolbarViewController.m */,
|
||||
C0F1193819EEDCD500708D17 /* BottomBlankSpaceViewController.h */,
|
||||
C0F1193919EEDCD500708D17 /* BottomBlankSpaceViewController.m */,
|
||||
C02790321A01404000FCB517 /* CollectionViewDemoController.h */,
|
||||
C02790331A01404000FCB517 /* CollectionViewDemoController.m */,
|
||||
DDAA29F01A320057002C0ED8 /* TableViewInContainerViewController.h */,
|
||||
DDAA29F11A320057002C0ED8 /* TableViewInContainerViewController.m */,
|
||||
1C2270101AE69224003A9D15 /* CustomViewController.h */,
|
||||
1C2270111AE69224003A9D15 /* CustomViewController.m */,
|
||||
1C22700D1AE68EEE003A9D15 /* CustomSubclassView.h */,
|
||||
1C22700E1AE68EEE003A9D15 /* CustomSubclassView.m */,
|
||||
C0A25BD219D72AAA009E074D /* TableViewController Example */,
|
||||
C06579C119D60AAF00DAA3EA /* Settings */,
|
||||
C0B63BAE1781FAB1008D3B64 /* AppDelegate.h */,
|
||||
C0B63BAF1781FAB1008D3B64 /* AppDelegate.m */,
|
||||
);
|
||||
name = "Objective-C";
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
C0E9FD161B7DEEE800C62579 /* Swift */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
C08CE0BC1A5C5EAC00FD9273 /* Swift Pending.rtf */,
|
||||
C0ACB0F819CF104D0057B571 /* Info.plist */,
|
||||
C0DD7E9F19D0A0AE007604CF /* KeyboardTextFieldDemoSwift */,
|
||||
);
|
||||
name = Swift;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
/* End PBXGroup section */
|
||||
|
||||
/* Begin PBXHeadersBuildPhase section */
|
||||
@@ -820,7 +816,6 @@
|
||||
B53A8A301A4C2A3900951878 /* iTunesArtwork@2x in Resources */,
|
||||
C05C59411A4C7F110007BD8F /* IQKeyboardManagerScreenshot.png in Resources */,
|
||||
B53A8A331A4C2D7A00951878 /* icon.png in Resources */,
|
||||
C0ACB10419CF104F0057B571 /* LaunchScreen.xib in Resources */,
|
||||
C0ACB10119CF104E0057B571 /* Images.xcassets in Resources */,
|
||||
C0EC59DE19D0C11200997FFE /* MainSwift.storyboard in Resources */,
|
||||
);
|
||||
@@ -887,6 +882,7 @@
|
||||
C0EC59D219D0C0B100997FFE /* TextFieldViewController.swift in Sources */,
|
||||
C056E1F41AE41B0100F09472 /* AppDelegate.swift in Sources */,
|
||||
1C1ADFC31AE50E28007A73E3 /* CollectionViewDemoController.swift in Sources */,
|
||||
C0E9FD1C1B7E021000C62579 /* IQUIViewController+Additions.swift in Sources */,
|
||||
C0EC59D619D0C0D200997FFE /* WebViewController.swift in Sources */,
|
||||
C0DDEB6919FCD56300FAB29F /* IQTextView.swift in Sources */,
|
||||
1C1ADFC91AE51FB5007A73E3 /* ExampleTableViewController.swift in Sources */,
|
||||
@@ -909,6 +905,7 @@
|
||||
C0DDEB6219FCD56300FAB29F /* IQUIView+Hierarchy.swift in Sources */,
|
||||
C0DDEB6519FCD56300FAB29F /* IQKeyboardManagerConstantsInternal.swift in Sources */,
|
||||
1C1ADFBF1AE50D9B007A73E3 /* ManualToolbarViewController.swift in Sources */,
|
||||
C0E9FD191B7E01F400C62579 /* IQUITextFieldView+Additions.swift in Sources */,
|
||||
C0DDEB6119FCD56300FAB29F /* IQNSArray+Sort.swift in Sources */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
@@ -977,14 +974,6 @@
|
||||
name = Main.storyboard;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
C0ACB10219CF104F0057B571 /* LaunchScreen.xib */ = {
|
||||
isa = PBXVariantGroup;
|
||||
children = (
|
||||
C0ACB10319CF104F0057B571 /* Base */,
|
||||
);
|
||||
name = LaunchScreen.xib;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
C0B63BA81781FAB1008D3B64 /* InfoPlist.strings */ = {
|
||||
isa = PBXVariantGroup;
|
||||
children = (
|
||||
@@ -1050,6 +1039,7 @@
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
||||
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
|
||||
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
|
||||
CLANG_CXX_LIBRARY = "libc++";
|
||||
CLANG_ENABLE_MODULES = YES;
|
||||
@@ -1078,6 +1068,7 @@
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
||||
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
|
||||
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
|
||||
CLANG_CXX_LIBRARY = "libc++";
|
||||
CLANG_ENABLE_MODULES = YES;
|
||||
|
||||
Binary file not shown.
@@ -1,5 +1,5 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="7531" systemVersion="14D136" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" initialViewController="En3-R6-bks">
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="7531" systemVersion="14D131" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" initialViewController="En3-R6-bks">
|
||||
<dependencies>
|
||||
<deployment version="1536" identifier="iOS"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="7520"/>
|
||||
@@ -533,7 +533,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
<tableViewSection id="YTE-kI-p1t">
|
||||
<cells>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="none" accessoryType="disclosureIndicator" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" textLabel="JFS-sj-PKU" detailTextLabel="kSX-8R-3sG" style="IBUITableViewCellStyleSubtitle" id="sCs-hP-i8Y">
|
||||
<rect key="frame" x="0.0" y="0.0" width="320" height="44"/>
|
||||
<rect key="frame" x="0.0" y="64" width="320" height="44"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="sCs-hP-i8Y" id="rP5-Q3-kTU">
|
||||
<rect key="frame" x="0.0" y="0.0" width="287" height="43"/>
|
||||
@@ -562,7 +562,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
</connections>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="none" accessoryType="disclosureIndicator" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" textLabel="7en-HG-KdY" detailTextLabel="O5A-qp-Z36" style="IBUITableViewCellStyleSubtitle" id="nDf-ts-g11">
|
||||
<rect key="frame" x="0.0" y="44" width="320" height="44"/>
|
||||
<rect key="frame" x="0.0" y="108" width="320" height="44"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="nDf-ts-g11" id="D12-nZ-zzm">
|
||||
<rect key="frame" x="0.0" y="0.0" width="287" height="43"/>
|
||||
@@ -591,7 +591,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
</connections>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="none" accessoryType="disclosureIndicator" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" textLabel="oLv-wV-JEL" detailTextLabel="kMa-uD-bmh" style="IBUITableViewCellStyleSubtitle" id="ehJ-9W-rSw">
|
||||
<rect key="frame" x="0.0" y="88" width="320" height="44"/>
|
||||
<rect key="frame" x="0.0" y="152" width="320" height="44"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="ehJ-9W-rSw" id="9u0-PD-iNt">
|
||||
<rect key="frame" x="0.0" y="0.0" width="287" height="43"/>
|
||||
@@ -620,7 +620,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
</connections>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="none" accessoryType="disclosureIndicator" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" textLabel="eFV-Hu-yZu" detailTextLabel="pth-FB-7uz" style="IBUITableViewCellStyleSubtitle" id="4qQ-uH-3Mb">
|
||||
<rect key="frame" x="0.0" y="132" width="320" height="44"/>
|
||||
<rect key="frame" x="0.0" y="196" width="320" height="44"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="4qQ-uH-3Mb" id="nkj-yb-leT">
|
||||
<rect key="frame" x="0.0" y="0.0" width="287" height="43"/>
|
||||
@@ -649,7 +649,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
</connections>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="none" accessoryType="disclosureIndicator" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" textLabel="l7E-Mp-YYn" detailTextLabel="tKl-ae-U0U" style="IBUITableViewCellStyleSubtitle" id="Bmn-6r-9rN">
|
||||
<rect key="frame" x="0.0" y="176" width="320" height="44"/>
|
||||
<rect key="frame" x="0.0" y="240" width="320" height="44"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="Bmn-6r-9rN" id="XDb-SF-hhD">
|
||||
<rect key="frame" x="0.0" y="0.0" width="287" height="43"/>
|
||||
@@ -678,7 +678,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
</connections>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="none" accessoryType="disclosureIndicator" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" textLabel="TQC-dO-VET" detailTextLabel="uvf-Qo-FbG" style="IBUITableViewCellStyleSubtitle" id="XXU-fu-xxa">
|
||||
<rect key="frame" x="0.0" y="220" width="320" height="44"/>
|
||||
<rect key="frame" x="0.0" y="284" width="320" height="44"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="XXU-fu-xxa" id="BEW-5C-Cpw">
|
||||
<rect key="frame" x="0.0" y="0.0" width="287" height="43"/>
|
||||
@@ -707,7 +707,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
</connections>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="none" accessoryType="disclosureIndicator" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" textLabel="yh4-3c-1nA" detailTextLabel="hpe-jQ-iio" rowHeight="60" style="IBUITableViewCellStyleSubtitle" id="fqf-qq-b7t">
|
||||
<rect key="frame" x="0.0" y="264" width="320" height="60"/>
|
||||
<rect key="frame" x="0.0" y="328" width="320" height="60"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="fqf-qq-b7t" id="CGv-hv-qSn">
|
||||
<rect key="frame" x="0.0" y="0.0" width="287" height="59"/>
|
||||
@@ -736,7 +736,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
</connections>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="none" accessoryType="disclosureIndicator" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" textLabel="3Yx-sC-9GA" detailTextLabel="hkK-8e-u1P" rowHeight="60" style="IBUITableViewCellStyleSubtitle" id="NCc-Fh-tem">
|
||||
<rect key="frame" x="0.0" y="324" width="320" height="60"/>
|
||||
<rect key="frame" x="0.0" y="388" width="320" height="60"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="NCc-Fh-tem" id="oWa-2Y-OYx">
|
||||
<rect key="frame" x="0.0" y="0.0" width="287" height="59"/>
|
||||
@@ -765,7 +765,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
</connections>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="none" accessoryType="disclosureIndicator" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" textLabel="NXV-ww-IIT" detailTextLabel="UrJ-gz-Axr" rowHeight="60" style="IBUITableViewCellStyleSubtitle" id="mmm-pn-XIG">
|
||||
<rect key="frame" x="0.0" y="384" width="320" height="60"/>
|
||||
<rect key="frame" x="0.0" y="448" width="320" height="60"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="mmm-pn-XIG" id="qZC-7h-CV3">
|
||||
<rect key="frame" x="0.0" y="0.0" width="287" height="59"/>
|
||||
@@ -796,7 +796,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
</connections>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="none" accessoryType="disclosureIndicator" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" textLabel="KaL-S4-iSK" detailTextLabel="LJf-7V-3lw" rowHeight="88" style="IBUITableViewCellStyleSubtitle" id="SOF-b6-azo">
|
||||
<rect key="frame" x="0.0" y="444" width="320" height="88"/>
|
||||
<rect key="frame" x="0.0" y="508" width="320" height="88"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="SOF-b6-azo" id="g8Z-Dr-Qav">
|
||||
<rect key="frame" x="0.0" y="0.0" width="287" height="87"/>
|
||||
@@ -826,7 +826,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
</connections>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="none" accessoryType="disclosureIndicator" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" textLabel="Uae-6t-6Sj" detailTextLabel="58p-7P-t8z" style="IBUITableViewCellStyleSubtitle" id="bMd-Bf-n21">
|
||||
<rect key="frame" x="0.0" y="532" width="320" height="44"/>
|
||||
<rect key="frame" x="0.0" y="596" width="320" height="44"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="bMd-Bf-n21" id="pKj-nA-uRL">
|
||||
<rect key="frame" x="0.0" y="0.0" width="287" height="43"/>
|
||||
@@ -855,7 +855,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
</connections>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="none" accessoryType="disclosureIndicator" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" textLabel="bKO-gT-FVG" detailTextLabel="Fyc-dl-ydb" style="IBUITableViewCellStyleSubtitle" id="GbI-Bd-1Ey">
|
||||
<rect key="frame" x="0.0" y="576" width="320" height="44"/>
|
||||
<rect key="frame" x="0.0" y="640" width="320" height="44"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="GbI-Bd-1Ey" id="PHz-9f-kJ7">
|
||||
<rect key="frame" x="0.0" y="0.0" width="287" height="43"/>
|
||||
@@ -884,7 +884,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
</connections>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="none" accessoryType="disclosureIndicator" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" textLabel="UsR-Fv-SvT" detailTextLabel="gK5-Jo-5Kt" style="IBUITableViewCellStyleSubtitle" id="FfM-0m-gaT">
|
||||
<rect key="frame" x="0.0" y="620" width="320" height="44"/>
|
||||
<rect key="frame" x="0.0" y="684" width="320" height="44"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="FfM-0m-gaT" id="MkH-eY-2vg">
|
||||
<rect key="frame" x="0.0" y="0.0" width="287" height="43"/>
|
||||
@@ -913,7 +913,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
</connections>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="none" accessoryType="disclosureIndicator" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" textLabel="fC6-8C-VXq" detailTextLabel="Yrs-qJ-0g3" style="IBUITableViewCellStyleSubtitle" id="c5h-lH-evf">
|
||||
<rect key="frame" x="0.0" y="664" width="320" height="44"/>
|
||||
<rect key="frame" x="0.0" y="728" width="320" height="44"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="c5h-lH-evf" id="Zxn-YZ-CvY">
|
||||
<rect key="frame" x="0.0" y="0.0" width="287" height="43"/>
|
||||
@@ -1189,7 +1189,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
<tableViewSection id="t96-I2-xYK">
|
||||
<cells>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="blue" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" rowHeight="41" id="FaL-19-zky">
|
||||
<rect key="frame" x="0.0" y="0.0" width="320" height="41"/>
|
||||
<rect key="frame" x="0.0" y="64" width="320" height="41"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="FaL-19-zky" id="tTa-Og-6g2">
|
||||
<rect key="frame" x="0.0" y="0.0" width="320" height="40"/>
|
||||
@@ -1206,7 +1206,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="blue" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" rowHeight="350" id="Oe1-i6-nJZ">
|
||||
<rect key="frame" x="0.0" y="41" width="320" height="350"/>
|
||||
<rect key="frame" x="0.0" y="105" width="320" height="350"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="Oe1-i6-nJZ" id="2Oh-32-JDn">
|
||||
<rect key="frame" x="0.0" y="0.0" width="320" height="349"/>
|
||||
@@ -1224,7 +1224,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="blue" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" rowHeight="41" id="3lx-6h-twx">
|
||||
<rect key="frame" x="0.0" y="391" width="320" height="41"/>
|
||||
<rect key="frame" x="0.0" y="455" width="320" height="41"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="3lx-6h-twx" id="nH2-kY-d2t">
|
||||
<rect key="frame" x="0.0" y="0.0" width="320" height="40"/>
|
||||
@@ -1241,7 +1241,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="blue" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" rowHeight="350" id="Csd-T9-cQK">
|
||||
<rect key="frame" x="0.0" y="432" width="320" height="350"/>
|
||||
<rect key="frame" x="0.0" y="496" width="320" height="350"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="Csd-T9-cQK" id="40W-FL-aO3">
|
||||
<rect key="frame" x="0.0" y="0.0" width="320" height="349"/>
|
||||
@@ -1259,7 +1259,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="blue" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" rowHeight="41" id="SGZ-BU-Cc0">
|
||||
<rect key="frame" x="0.0" y="782" width="320" height="41"/>
|
||||
<rect key="frame" x="0.0" y="846" width="320" height="41"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="SGZ-BU-Cc0" id="Szn-af-4i0">
|
||||
<rect key="frame" x="0.0" y="0.0" width="320" height="40"/>
|
||||
@@ -1276,7 +1276,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="blue" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" rowHeight="350" id="Wfp-bY-ZWU">
|
||||
<rect key="frame" x="0.0" y="823" width="320" height="350"/>
|
||||
<rect key="frame" x="0.0" y="887" width="320" height="350"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="Wfp-bY-ZWU" id="b9R-dh-ePP">
|
||||
<rect key="frame" x="0.0" y="0.0" width="320" height="349"/>
|
||||
@@ -1294,7 +1294,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="blue" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" rowHeight="41" id="vvZ-c7-eBo">
|
||||
<rect key="frame" x="0.0" y="1173" width="320" height="41"/>
|
||||
<rect key="frame" x="0.0" y="1237" width="320" height="41"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="vvZ-c7-eBo" id="wTE-ag-Cbf">
|
||||
<rect key="frame" x="0.0" y="0.0" width="320" height="40"/>
|
||||
@@ -1311,7 +1311,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="blue" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" rowHeight="350" id="Ego-If-gyk">
|
||||
<rect key="frame" x="0.0" y="1214" width="320" height="350"/>
|
||||
<rect key="frame" x="0.0" y="1278" width="320" height="350"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="Ego-If-gyk" id="P4p-ss-iv2">
|
||||
<rect key="frame" x="0.0" y="0.0" width="320" height="349"/>
|
||||
@@ -1329,7 +1329,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="blue" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" rowHeight="41" id="VAE-Zy-WoN">
|
||||
<rect key="frame" x="0.0" y="1564" width="320" height="41"/>
|
||||
<rect key="frame" x="0.0" y="1628" width="320" height="41"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="VAE-Zy-WoN" id="xLf-mj-K4d">
|
||||
<rect key="frame" x="0.0" y="0.0" width="320" height="40"/>
|
||||
@@ -1346,7 +1346,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="blue" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" rowHeight="350" id="fZy-eQ-hXM">
|
||||
<rect key="frame" x="0.0" y="1605" width="320" height="350"/>
|
||||
<rect key="frame" x="0.0" y="1669" width="320" height="350"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="fZy-eQ-hXM" id="sFJ-zD-DrA">
|
||||
<rect key="frame" x="0.0" y="0.0" width="320" height="349"/>
|
||||
@@ -1364,7 +1364,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="blue" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" rowHeight="41" id="pwM-BD-F3E">
|
||||
<rect key="frame" x="0.0" y="1955" width="320" height="41"/>
|
||||
<rect key="frame" x="0.0" y="2019" width="320" height="41"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="pwM-BD-F3E" id="x38-ab-L3i">
|
||||
<rect key="frame" x="0.0" y="0.0" width="320" height="40"/>
|
||||
@@ -1381,7 +1381,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="blue" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" rowHeight="350" id="M69-7a-p9I">
|
||||
<rect key="frame" x="0.0" y="1996" width="320" height="350"/>
|
||||
<rect key="frame" x="0.0" y="2060" width="320" height="350"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="M69-7a-p9I" id="wTg-2o-j8b">
|
||||
<rect key="frame" x="0.0" y="0.0" width="320" height="349"/>
|
||||
@@ -1399,7 +1399,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="blue" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" rowHeight="41" id="Y5C-vW-9q2">
|
||||
<rect key="frame" x="0.0" y="2346" width="320" height="41"/>
|
||||
<rect key="frame" x="0.0" y="2410" width="320" height="41"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="Y5C-vW-9q2" id="LdN-dG-2Xo">
|
||||
<rect key="frame" x="0.0" y="0.0" width="320" height="40"/>
|
||||
@@ -1416,7 +1416,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="blue" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" rowHeight="350" id="kS4-wf-gdb">
|
||||
<rect key="frame" x="0.0" y="2387" width="320" height="350"/>
|
||||
<rect key="frame" x="0.0" y="2451" width="320" height="350"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="kS4-wf-gdb" id="X9y-jm-1sM">
|
||||
<rect key="frame" x="0.0" y="0.0" width="320" height="349"/>
|
||||
@@ -1434,7 +1434,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="blue" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" rowHeight="41" id="zP8-hL-yUz">
|
||||
<rect key="frame" x="0.0" y="2737" width="320" height="41"/>
|
||||
<rect key="frame" x="0.0" y="2801" width="320" height="41"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="zP8-hL-yUz" id="5ew-eq-OSY">
|
||||
<rect key="frame" x="0.0" y="0.0" width="320" height="40"/>
|
||||
@@ -1451,7 +1451,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/>
|
||||
</tableViewCell>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="blue" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" rowHeight="350" id="Dbj-Tr-RCC">
|
||||
<rect key="frame" x="0.0" y="2778" width="320" height="350"/>
|
||||
<rect key="frame" x="0.0" y="2842" width="320" height="350"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="Dbj-Tr-RCC" id="dEe-1n-imP">
|
||||
<rect key="frame" x="0.0" y="0.0" width="320" height="349"/>
|
||||
@@ -1573,7 +1573,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
</connections>
|
||||
</searchBar>
|
||||
<view contentMode="scaleToFill" id="SHK-82-xFg">
|
||||
<rect key="frame" x="10" y="161" width="305" height="269.99999963538619"/>
|
||||
<rect key="frame" x="10" y="161" width="305" height="269.9999992752185"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMinY="YES" heightSizable="YES" flexibleMaxY="YES"/>
|
||||
<subviews>
|
||||
<view contentMode="scaleToFill" id="k8L-Hj-hKb">
|
||||
@@ -1612,7 +1612,7 @@ textField.inputAcessoryView = [[UIView alloc] init];</string>
|
||||
<color key="backgroundColor" red="0.80000001192092896" green="1" blue="0.40000000596046448" alpha="1" colorSpace="calibratedRGB"/>
|
||||
</view>
|
||||
<view contentMode="scaleToFill" id="uYv-to-iCC">
|
||||
<rect key="frame" x="10" y="170" width="285" height="89.99999987378753"/>
|
||||
<rect key="frame" x="10" y="169.9999995261044" width="285" height="90"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMinY="YES" heightSizable="YES"/>
|
||||
<subviews>
|
||||
<textField opaque="NO" clipsSubviews="YES" tag="102" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="roundedRect" placeholder="TextField 4" minimumFontSize="17" id="yDj-sx-3pn">
|
||||
|
||||
Reference in New Issue
Block a user