ee76ea3ce7f33d7f95fed95722bd4635ff8b7b23
[mirrors/ShenYin.git] /
1 //
2 //  IQKeyboardToolbarConstants.swift
3 //  https://github.com/hackiftekhar/IQKeyboardToolbarManager
4 //  Copyright (c) 2013-24 Iftekhar Qurashi.
5 //
6 //  Permission is hereby granted, free of charge, to any person obtaining a copy
7 //  of this software and associated documentation files (the "Software"), to deal
8 //  in the Software without restriction, including without limitation the rights
9 //  to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10 //  copies of the Software, and to permit persons to whom the Software is
11 //  furnished to do so, subject to the following conditions:
12 //
13 //  The above copyright notice and this permission notice shall be included in
14 //  all copies or substantial portions of the Software.
15 //
16 //  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17 //  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18 //  FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19 //  AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20 //  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21 //  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
22 //  THE SOFTWARE.
23
24 import Foundation
25
26 // MARK: IQKeyboardToolbarManageBehavior
27
28 /**
29 `IQAutoToolbarBySubviews`
30 Creates Toolbar according to subview's hierarchy of textInputView's in view.
31
32 `IQAutoToolbarByTag`
33 Creates Toolbar according to tag property of textInputView's.
34
35 `IQAutoToolbarByPosition`
36 Creates Toolbar according to the y,x position of textInputView in it's superview coordinate.
37 */
38 @available(iOSApplicationExtension, unavailable)
39 @objc public enum IQKeyboardToolbarManageBehavior: Int {
40     case bySubviews
41     case byTag
42     case byPosition
43 }
44
45 @available(*, unavailable, renamed: "IQKeyboardToolbarManageBehavior")
46 @objc public enum IQAutoToolbarManageBehavior: Int {
47     case bySubviews
48     case byTag
49     case byPosition
50 }
51
52 /**
53  `IQPreviousNextDisplayModeDefault`
54  Show NextPrevious when there are more than 1 textInputView otherwise hide.
55
56  `IQPreviousNextDisplayModeAlwaysHide`
57  Do not show NextPrevious buttons in any case.
58  
59  `IQPreviousNextDisplayModeAlwaysShow`
60  Always show nextPrevious buttons,
61  if there are more than 1 textInputView then both buttons will be visible but will be shown as disabled.
62  */
63 @available(iOSApplicationExtension, unavailable)
64 @objc public enum IQPreviousNextDisplayMode: Int {
65     case `default`
66     case alwaysHide
67     case alwaysShow
68 }