105 Commits

Author SHA1 Message Date
Roman Podymov ceca40bb06 Nullability (#1091) 2023-06-29 10:17:03 -03:00
Martin Barreto 8335af6d83 Update README.md 2023-03-17 18:07:43 -03:00
Martin Barreto 6cf22d3cf2 Add files via upload 2023-03-17 18:05:55 -03:00
Enrique Galindo cd5d983b1a Create FUNDING.yml 2022-09-01 13:10:11 -03:00
Mathias Claassen 870afc5660 Version bump 4.3.0 (#1080) 2021-03-24 10:27:47 -03:00
Nick Reffitt ded97b8328 Add datePicker style property to XLFormDateCell (#1078)
Co-authored-by: Nick <nick@nicks-air.mynet>
2020-11-18 10:00:10 -03:00
Mathias Claassen 74bde2185b Fix Cocoapods source (#1077) 2020-10-12 09:22:50 -03:00
Mathias Claassen d299fe32cb Version bump 4.2.0 (#1076) 2020-10-09 10:59:04 -03:00
Kyle Hankinson 234a135f08 Fixes Carthage to master branch (#1075)
* + Fix for simulator issue/carthage build issue.

* + Headers public.

Co-authored-by: Kyle Hankinson <kyle.hankinson@gmail.com>
2020-10-09 09:13:04 -03:00
Eneko Alonso 0e5da84980 Add support for distribution via Swift Package Manager (SwiftPM) (#1073)
* Add Package.swift for distribution via SwiftPM

* Update publicHeadersPath

* Remove publicHeadersPath

* Flattened file structure

* Update project references

* Clean up

* Update README with instructions for installing via SwiftPM

* Fix typo

Co-authored-by: Mathias Claassen <mathiasclaassen7@gmail.com>

Co-authored-by: Mathias Claassen <mathiasclaassen7@gmail.com>
2020-09-23 09:31:38 -03:00
Mathias Claassen 3dd39ed7bc Version bump 4.1.0 (#1060) 2019-10-02 09:52:47 -03:00
Quintz Gábor 45d363fb0c iOS 13 dark mode support. (#1057) 2019-09-23 10:49:46 -03:00
Mathias Claassen 21f97ce9a6 Swift 5 updates in Examples and change Travis to use Xcode 11 (#1058) 2019-09-20 10:23:58 -03:00
mrcararia f2383b7903 Fix crash when .Nib is inside a framework bundle. (#1050) 2019-05-14 12:00:33 -03:00
Mathias Claassen 6ac31155f8 release 4.0.1 (#1049) 2019-04-15 11:07:06 -03:00
Liraz S 151003d8e5 Memory and stability fixes to XLForm (#1045)
* selectorCell display repair

Unable to display when value than apples first selectorOptions

* fixed crash

* fixed memory leaks

* Cell disappears while inline picker is open

* Fixes crash on update

* check object object equal

* codereview

* fixed memory leaks

* fixed memory leaks [2]

* updated logic

* fixed memory leaks

* fix for crash #1043

* fix for crash #1044

* fix for issue #1044

* fix for issue #1044

* fixed mistake

* fixed observation if lib uses in drawer controller

* fixed kvo crash

* reverted last fix

* cleanup

* fixed kvo

* fix for crash #1043

* reverted https://github.com/xmartlabs/XLForm/pull/1045#discussion_r255965033

* reverted #948

* fixed firstResponder logic

* codereview in Descriptors

* codereview
2019-03-25 12:20:16 -03:00
Mathias Claassen b5bdda8e80 Update Readme (#1046) 2019-03-14 13:40:30 -03:00
Bruno Agatte 81aca9c49c Update XLFormRowDescriptor.m to support <Class>.self for custom cells (#1041) 2019-01-08 10:59:18 -03:00
Ju d8ece1410d Fix crash when using swift custom cells with xib files (#1038) (#1040) 2019-01-07 15:57:31 -03:00
Nikita Razumnuy fdca5f7543 fix: can't update placeholder color using setNeedsDisplay in XLFormTextView (#1024) 2018-08-23 11:20:17 -03:00
Martin Barreto 204cad6045 update swift example 2017-10-26 14:36:33 -03:00
Martin Barreto e68b57cded update XLForm tests 2017-10-26 14:36:33 -03:00
Martin Barreto 0bc600d5a7 fix travis 2017-10-26 14:36:33 -03:00
pera c2d721f098 minor fixes 2017-10-26 14:36:33 -03:00
pera 2485332846 Updates README.md, CHANGELOG.md & podspec. 2017-10-26 14:36:33 -03:00
pera 20b661c41e - Adds support for Xcode9
- Deprecation of UIAlertView, UIActionSheet & UIPopoverController
2017-10-26 14:36:33 -03:00
MiMo42 1e2b5137d6 Fixed crash when trying to insert row in section at index 0 (#964) 2017-06-08 11:47:26 -03:00
Miguel Revetria 43abac5c3f Fixes #893, setting rowDescriptor to the serach result controller (#961) 2017-05-25 10:20:36 -03:00
MiMo42 77db6b9492 nullability warning fixed (#952) 2017-04-26 10:21:35 -03:00
Mathias Claassen 74b26c1e64 make properties of XLFormOptionsObject writable (#955) 2017-04-25 11:55:54 -03:00
Mathias Claassen 085cf31e52 Updated Readme Eureka introduction (#954) 2017-04-25 10:48:47 -03:00
FatalDizz 313e5d5d40 Added method to set a title for form errors (#951) 2017-04-19 11:46:34 -03:00
Mathias Claassen f7777d9d27 Add Header and Footer section to Readme FAQ (#942) 2017-04-05 09:46:52 -03:00
Mathias Claassen 578dea99dd Use the correct locale in date row (not only date picker) (#935) 2017-04-05 09:23:41 -03:00
Santiago Castro 1da30107dc Fix README headings due to GitHub change (#937)
GitHub changed its Markdown processor to stop supporting heading without spaces https://gist.github.com/vmarkovtsev/59cd7349d41cf804b9a8775388e681f8
2017-03-21 09:18:22 -03:00
Mathias Claassen 4674c3abaf Make moveRowAtIndexPath:toIndexPath: public in XLFormSectionDescriptor to allow to reorder rows programmatically. (#929) 2017-02-22 12:58:47 -03:00
Felix Dumit 5ca54fd949 Fix use of formatter in Info Cells (#916)
Adds example with infocell and bytecount formatter
2017-01-16 18:15:42 -03:00
Mathias Claassen e64e5b4885 update Travis file to use Xcode 8.2 (#920) 2017-01-12 10:24:37 -03:00
Mathias Claassen b28c902d73 release version 3.3.0 2016-11-17 11:10:10 -03:00
Mathias Claassen dc5f1e6dcd Merge pull request #895 from dvkch/master
Fix for #884
2016-11-03 11:33:16 -03:00
Stanislas Chevallier 55e440bc57 Fix: #884 by setting the UIDatePicker timeZone to GMT+0 when in countdown mode 2016-11-02 13:42:51 +01:00
Martin Barreto be2fb864be Update README.md 2016-10-21 18:14:17 -03:00
Mathias Claassen cdd498ebc7 Merge pull request #866 from xmartlabs/Swift3
Update Swift example to Swift 3 syntax
2016-10-20 14:46:21 -03:00
Mathias Claassen cd43abc3f0 Merge pull request #882 from kiancheong/OptionsRow-Deselect
OptionsRow-Deselect
2016-10-18 16:06:49 -03:00
kiancheong f1a83512d1 Prevents setting cell's accessoryType to UITableViewCellAccessoryNone if the rowDescriptor's required value is true.
This fixes the ability to deselect options when using XLFormRowDescriptorTypeSelectorPush.
2016-10-14 09:08:25 +08:00
Mathias Claassen 00ccf60895 Merge pull request #883 from kiancheong/bigsprocket-styling
bigsprocket-styling
2016-10-13 10:57:39 -03:00
kiancheong 27a172eb65 Synthesize cellConfigForSelector. 2016-10-11 19:31:45 +08:00
Kyle Davis e62404d24b remove unnecessary nil check 2016-10-11 12:57:16 +08:00
Kyle Davis d1aff91e63 Support styling of XLFormOptionViewController cells 2016-10-11 12:57:14 +08:00
Mathias Claassen a0a8cf793c Update Swift example to Swift 3 syntax 2016-09-15 13:33:38 -03:00
Mathias Claassen bb81e88572 Merge pull request #864 from choefele/master
Limit number of characters in XLFormTextFieldCell and XLFormTextViewCell
2016-09-07 10:31:50 -03:00
Claus Höfele 64ab7ccac0 Add property in XLFormTextViewCell to limit number of characters 2016-09-05 20:37:57 +02:00
Claus Höfele 9baeda1b0d Add property in XLFormTextFieldCell to limit number of characters
Implements #855
2016-09-05 18:52:23 +02:00
Mathias Claassen 6879f01230 Merge pull request #832 from xmartlabs/fix/constant
change XLFormUnspecifiedHeight constant to not collide with Automatic…
2016-07-22 11:34:30 -03:00
Mathias Claassen 50e9efe783 change XLFormUnspecifiedHeight constant to not collide with Automatic dimension 2016-07-22 11:34:01 -03:00
Mathias Claassen bf819ba0ed Merge pull request #831 from ablexie/master
Add locale property to date cell for inline cells
2016-07-22 11:26:50 -03:00
ablexie 087bbf089c datePicker.locale property public to developer,for example,
_birthdayRow = [XLFormRowDescriptor formRowDescriptorWithTag:kBirthdayTag rowType:XLFormRowDescriptorTypeDateInline title:@"Birthday"];
[_birthdayRow.cellConfig setObject:[[NSLocale alloc] initWithLocaleIdentifier:@"en"] forKey:@"locale"];
2016-07-21 10:29:17 +08:00
Mathias Claassen eac2f816d7 Merge pull request #819 from 3a4oT/master
Refactored '-(id)init..' to '- (instancetype)init...'
2016-07-07 11:23:43 -03:00
Mathias Claassen b19bf9bafc Merge pull request #817 from 3a4oT/patch-2
Update 'initializeForm' example.
2016-07-07 11:18:00 -03:00
Petro Rovenskyy ce869235bc Refactored '-(id)init' to '- (instancetype)init' 2016-07-04 21:50:17 +03:00
Petro Rovenskyy bb93c90c2d Update 'initializeForm' example.
Copy and paste the example of  ```initializeForm``` and feel the power of XLForm immediately. =)
2016-07-01 15:47:22 +03:00
Mathias Claassen 7b50e19cf6 Merge pull request #814 from 3a4oT/patch-1
Update pod badge
2016-06-30 10:12:56 -03:00
Petro Rovenskyy 8eefa8afd9 Update pod badge 2016-06-30 15:27:48 +03:00
Mathias Claassen ca53315145 Merge pull request #810 from jeanmartin/master
[fixes #452] respect the currentLocale when parsing decimal values
2016-06-28 09:44:14 -03:00
Jan Schwenzien c3263f7645 [fixes #452] respect the currentLocale when parsing decimal values 2016-06-27 22:04:51 +02:00
Mathias Claassen fbf800fc21 Merge pull request #806 from jimmyti/master
Fixed selector action sheet to use the row's value transformer
2016-06-24 09:54:33 -03:00
Jimmy Ti fbc08a7094 Remove the fix for suppressing "Empty snapshot" warnings when presenting action sheets 2016-06-23 23:10:57 +10:00
Jimmy Ti f1f8a21bf0 Updated code to actually use the optionTitle variable 2016-06-21 00:18:33 +10:00
Jimmy Ti 694c08beee Fixed selector action sheet to use the row's value transformer 2016-06-20 21:19:20 +10:00
Mathias Claassen c7d5708f16 update pod version 2016-06-16 10:34:54 -03:00
Mathias Claassen dd294cc709 Merge pull request #804 from xmartlabs/fix/multiEmpty
added count to empty check. Helpful to validate multiple selectors be…
2016-06-13 17:24:08 -03:00
Mathias Claassen cda0327def added count to empty check. Helpful to validate multiple selectors being empty 2016-06-13 17:23:44 -03:00
Mathias Claassen 9a2bdf1ca0 Merge pull request #797 from xmartlabs/fix/decimals
Fix decimal number formatting. closes #514
2016-06-02 13:46:49 -03:00
Mathias Claassen d8b67b5c21 Fix decimal number formatting. closes #514 2016-06-02 13:46:25 -03:00
Mathias Claassen f30fa9bb31 Merge pull request #796 from xmartlabs/feature/cellHeight
Added height property to XLFormRowDescriptor
2016-06-02 12:52:47 -03:00
Mathias Claassen 9b1e7d6d4e Added height property to XLFormRowDescriptor 2016-06-02 12:41:12 -03:00
Mathias Claassen fac9cefc2b Merge pull request #652 from droidlabs/custom-multiselect
Row with multiple selector should support custom controller
2016-06-02 11:14:23 -03:00
Mathias Claassen d202a40824 Merge pull request #794 from xmartlabs/readmeUpdate
updated readme with some comments. Fixes #771, fixes #727, fixes #696
2016-06-01 15:16:15 -03:00
Mathias Claassen d185e642e0 updated readme with some comments. Fixes #771, fixes #727, fixes #696 2016-06-01 15:15:35 -03:00
Mathias Claassen 743c5d289a Merge pull request #695 from realestate-com-au/hotfix/code-sign
Changed Release config to use iPhone Distribution code sign identity
2016-06-01 14:20:54 -03:00
Mathias Claassen de86c5e60e Merge pull request #306 from ziogaschr/add-support-NSFormatter
Add support for NSFormatter.
 closes #77 , closes #195 , closes #176 closes #64
2016-05-31 12:15:00 -03:00
Chris Ziogas f52c532fec Add support for NSFormatter 2016-05-31 17:57:18 +03:00
Mathias Claassen 274892dc95 Merge pull request #792 from xmartlabs/fix/validation
Do validation can be nullable. fixes #705
2016-05-31 11:54:29 -03:00
Mathias Claassen 09b28286de Do validation can be nullable. fixes #705 2016-05-31 11:54:06 -03:00
Mathias Claassen bbca57a2e6 Merge pull request #456 from conradwt/master
Update project README
2016-05-31 11:34:35 -03:00
Mathias Claassen d29275b780 Merge pull request #523 from MuscleRumble/appextensions
Fixed #357 by adding XL_APP_EXTENSIONS macro so that XLForm can be used in App Extensions
2016-05-31 11:30:01 -03:00
Mathias Claassen 11f54cee17 Merge pull request #686 from alejandrogarin/numberFormatter
Controlling formatting output when the rowType is XLFormRowDescriptorTypeNumber or XLFormRowDescriptorTypeDecimal
2016-05-31 11:16:24 -03:00
Mathias Claassen 418b3e4c96 Merge pull request #782 from kiancheong/UITextView-ShouldChange-Delegate
Added shouldChangeTextInRange delegate call for UITextView.
2016-05-31 11:03:13 -03:00
Mathias Claassen 6da2fc456c Merge pull request #791 from xmartlabs/fix/value2CellStyle
fix crash when using cell style Value2. closes #770
2016-05-30 17:25:09 -03:00
Mathias Claassen 52be3f3531 fix crash when using cell style Value2. closes #770 2016-05-30 17:14:13 -03:00
Mathias Claassen 5e00deb474 Merge pull request #790 from xmartlabs/fix/textFieldPercentage
Fix when the textFieldPercentage is applied. Closes #776
2016-05-30 16:46:37 -03:00
Mathias Claassen 2a8ebf2af5 Fix when the textFieldPercentage is applied. Closes #776 2016-05-30 16:46:09 -03:00
Mathias Claassen 5c716a665d Merge pull request #789 from mbjacks/master
fix crash when adding a validator to a copied row descriptor
2016-05-30 16:21:51 -03:00
Matt Jackson 60e67b9651 fix crash when adding a validator to a copied row descriptor 2016-05-27 14:20:56 -07:00
Mathias Claassen 6aac513398 Merge pull request #753 from jpmhouston/example-podfile
updated example podfile for cocoapods 1.0 compatibility
2016-05-24 16:58:11 -03:00
Mathias Claassen 0491752090 update pod spec for new release 2016-05-24 16:56:15 -03:00
kiancheong 51760a535a Added shouldChangeTextInRange delegate call for UITextView. 2016-05-11 11:13:17 +08:00
Pierre Houston 0d24f47f75 updated podfile for compatibility with cocoapods 1.0, did pod deintegrate on project to remove cruft
- fixes warnings on 'pod install': 'The dependency ... is not used in any concrete target'
2016-03-22 18:33:01 -07:00
Tobias Hagemann 756fdb914b Merge branch 'master' of https://github.com/xmartlabs/XLForm into appextensions 2016-01-16 11:29:29 +01:00
Iskander Haziev 3df413b0fa Row with multiple selector should support custom controller 2016-01-05 17:18:40 +03:00
Stephen Yao 97b79f1f93 Changed Release config to distribution profile for code signing
(cherry picked from commit c4d7f7c9ef5a3a5d6799a8ff6e6a34872ea4b7bd)
2016-01-04 14:35:35 +11:00
Alejandro Garin ba949c3697 check if self conform to protocol XLFormOptionObject before checking if the object is kind of class NSString or NSNumber. This allow better control in the formatted output if the object is a NSNumber 2015-12-28 15:00:44 -03:00
Tobias Hagemann e31c6db521 Merge branch 'master' of https://github.com/xmartlabs/XLForm into appextensions 2015-09-18 17:49:06 +02:00
Tobias Hagemann 15a4ce9d83 Fixed #357 by adding XL_APP_EXTENSIONS macro so that XLForm can be used in App Extensions 2015-08-25 16:41:56 +02:00
Conrad Taylor 5b136eb458 Enhance the copy for creating a form and add a section for Storyboard users. 2015-07-23 13:19:54 -07:00
141 changed files with 3308 additions and 2384 deletions
+13
View File
@@ -0,0 +1,13 @@
# These are supported funding model platforms
github: xmartlabs # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
patreon: # Replace with a single Patreon username
open_collective: # Replace with a single Open Collective username
ko_fi: # Replace with a single Ko-fi username
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
liberapay: # Replace with a single Liberapay username
issuehunt: # Replace with a single IssueHunt username
otechie: # Replace with a single Otechie username
lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry
custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
+2 -4
View File
@@ -19,7 +19,5 @@ DerivedData
#CocoaPods
Pods
Tests/Pods
Tests/Podfile.lock
Examples/Objective-C/Podfile.lock
Examples/Swift/Podfile.lock
Podfile.lock
*.xcworkspace
+3 -4
View File
@@ -1,8 +1,7 @@
language: objective-c
osx_image: xcode7.2
osx_image: xcode12
before_install:
- gem install cocoapods --no-rdoc --no-ri --no-document --quiet
- gem install xcpretty --no-rdoc --no-ri --no-document --quiet
- gem install cocoapods --quiet
- gem install xcpretty --quiet
- cd Tests && pod install && cd $TRAVIS_BUILD_DIR
script: rake test
+35 -3
View File
@@ -1,7 +1,39 @@
# Change Log
All notable changes to this project will be documented in this file.
### Latest:
### Version 4.3.0:
* Add datePicker style property to XLFormDateCell (#1078)
### Version 4.2.0:
* Support for Swift Package Manager (#1073)
* Fix Carthage build (#1075)
### Version 4.1.0:
* Fix crash when .Nib is inside a framework bundle. (#1050)
* iOS 13 dark mode support. (#1057)
* Updates for Swift 5 in Examples
### Version 4.0.1:
* Memory improvements and fixes.
* Other minor fixes
### Version 4.0.0:
* Adds support for Xcode 9.
* Deprecated UIAlertView, UIActionSheet, UIPopoverController.
* Bumped minimum iOS version to 9.0.
### Version 3.3.0:
* Added `cellConfigForSelector` to style XLFormOptionsViewController
* Added properties to **limit number of characters** in `XLFormTextFieldCell` and `XLFormTextViewCell`
* Minor fixes
### Version 3.2.0:
* Added XL_APP_EXTENSIONS macro to allow app extensions (@MuscleRumble #357)
* Added shouldChangeTextInRange delegate call for UITextView. (@kiancheong #782)
* Added support for NSFormatter (@ziogaschr, @fwhenin, @bhirt-bpl #306)
* Added `height` property to XLFormRowDescriptor to allow setting height of individual cells.
### Version 3.1.2:
* Update row in `cellForRowAtIndexPath` instead of `willDisplayCell`
* Added cancel action to image selector (by koenpunt)
* Other minor fixes
@@ -121,6 +153,6 @@ All notable changes to this project will be documented in this file.
* Added a convenience method to deselect a `XLFormRowDescriptor`. `-(void)deselectFormRow:(XLFormRowDescriptor *)row;`. [#33](https://github.com/xmartlabs/XLForm/issues/33 "#33").
### Version 1.0.0
### Version 1.0.0
* Initial release
* Initial release
@@ -57,6 +57,7 @@ NSString *const kCountDownTimer = @"countDownTimer";
// Date
row = [XLFormRowDescriptor formRowDescriptorWithTag:kDateInline rowType:XLFormRowDescriptorTypeDateInline title:@"Date"];
row.value = [NSDate new];
[row.cellConfigAtConfigure setObject:[NSLocale localeWithLocaleIdentifier:@"FR_fr" ] forKey:@"locale"];
[section addFormRow:row];
// Time
@@ -153,38 +154,13 @@ NSString *const kCountDownTimer = @"countDownTimer";
-(void)formRowDescriptorValueHasChanged:(XLFormRowDescriptor *)formRow oldValue:(id)oldValue newValue:(id)newValue
{
// super implementation must be called
[super formRowDescriptorValueHasChanged:formRow oldValue:oldValue newValue:newValue];
if([formRow.tag isEqualToString:kDatePicker])
{
#if __IPHONE_OS_VERSION_MAX_ALLOWED < 80000
UIAlertView *message = [[UIAlertView alloc] initWithTitle:@"DatePicker"
message:@"Value Has changed!"
delegate:nil
cancelButtonTitle:@"OK"
otherButtonTitles:nil];
[message show];
#else
if ([UIAlertController class]) {
UIAlertController * alertController = [UIAlertController alertControllerWithTitle:@"DatePicker"
message:@"Value Has changed!"
preferredStyle:UIAlertControllerStyleAlert];
[alertController addAction:[UIAlertAction actionWithTitle:@"OK"
style:UIAlertActionStyleDefault
handler:nil]];
[self presentViewController:alertController animated:YES completion:nil];
}
else{
UIAlertView *message = [[UIAlertView alloc] initWithTitle:@"DatePicker"
message:@"Value Has changed!"
delegate:nil
cancelButtonTitle:@"OK"
otherButtonTitles:nil];
[message show];
}
#endif
}
UIAlertController * alertController = [UIAlertController alertControllerWithTitle:@"DatePicker"
message:@"Value Has changed!"
preferredStyle:UIAlertControllerStyleAlert];
[alertController addAction:[UIAlertAction actionWithTitle:@"OK"
style:UIAlertActionStyleDefault
handler:nil]];
[self presentViewController:alertController animated:YES completion:nil];
}
@end
@@ -34,6 +34,7 @@
#import "CustomRowsViewController.h"
#import "AccessoryViewFormViewController.h"
#import "PredicateFormViewController.h"
#import "FormattersViewController.h"
NSString * const kTextFieldAndTextView = @"TextFieldAndTextView";
NSString * const kSelectors = @"Selectors";
@@ -46,6 +47,7 @@ NSString * const kMultivaluedOnlyReorder = @"MultivaluedOnlyReorder";
NSString * const kMultivaluedOnlyInsert = @"MultivaluedOnlyInsert";
NSString * const kMultivaluedOnlyDelete = @"MultivaluedOnlyDelete";
NSString * const kValidations= @"Validations";
NSString * const kFormatters = @"Formatters";
@interface ExamplesFormViewController ()
@@ -113,6 +115,11 @@ NSString * const kValidations= @"Validations";
row.action.viewControllerClass = [DatesFormViewController class];
[section addFormRow:row];
// NSFormatters
row = [XLFormRowDescriptor formRowDescriptorWithTag:kFormatters rowType:XLFormRowDescriptorTypeButton title:@"NSFormatter Support"];
row.action.viewControllerClass = [FormattersViewController class];
[section addFormRow:row];
// Others
row = [XLFormRowDescriptor formRowDescriptorWithTag:kOthes rowType:XLFormRowDescriptorTypeButton title:@"Other Rows"];
row.action.formSegueIdentifier = @"OthersFormViewControllerSegue";
@@ -0,0 +1,13 @@
//
// FormattersViewController.h
// XLForm
//
// Created by Freddy Henin on 12/29/14.
// Copyright (c) 2014 Xmartlabs. All rights reserved.
//
#import "XLFormViewController.h"
@interface FormattersViewController : XLFormViewController
@end
@@ -0,0 +1,120 @@
//
// FormattersViewController.m
// XLForm
//
// Created by Freddy Henin on 12/29/14.
// Copyright (c) 2014 Xmartlabs. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "XLForm.h"
#import "FormattersViewController.h"
#import <SHSPhoneComponent/SHSPhoneNumberFormatter+UserConfig.h>
// Simple little class to demonstraite currency formatting. Unfortunally we have to subclass
// NSNumberFormatter to work aroundn some long known rounding bugs with NSNumberFormatter
// http://stackoverflow.com/questions/12580162/nsstring-to-nsdate-conversion-issue
@interface CurrencyFormatter : NSNumberFormatter
@property (readonly, strong) NSDecimalNumberHandler *roundingBehavior;
@end
@implementation CurrencyFormatter
- (id) init
{
self = [super init];
if (self) {
[self setNumberStyle: NSNumberFormatterCurrencyStyle];
[self setGeneratesDecimalNumbers:YES];
NSUInteger currencyScale = [self maximumFractionDigits];
_roundingBehavior = [NSDecimalNumberHandler decimalNumberHandlerWithRoundingMode:NSRoundPlain scale:currencyScale raiseOnExactness:FALSE raiseOnOverflow:TRUE raiseOnUnderflow:TRUE raiseOnDivideByZero:TRUE];
}
return self;
}
//- (BOOL)getObjectValue:(id *)anObject forString:(NSString *)string errorDescription:(NSString **)error
//{
// NSDecimalNumber *number;
// BOOL success = [super getObjectValue:&number forString:string errorDescription:error];
//
// if (success) {
// *anObject = [number decimalNumberByRoundingAccordingToBehavior:_roundingBehavior];
// }
// else {
// *anObject = nil;
// }
//
// return success;
//}
@end
@interface FormattersViewController ()
@end
@implementation FormattersViewController
-(id)init
{
XLFormDescriptor * formDescriptor = [XLFormDescriptor formDescriptorWithTitle:@"Text Fields"];
XLFormSectionDescriptor * section;
XLFormRowDescriptor * row;
formDescriptor.assignFirstResponderOnShow = NO;
section = [XLFormSectionDescriptor formSection];
section.title = @"NSFormatter Support";
section.footerTitle = @"Rows can be configured to use the formatter as you type or to toggle on and off during for display/editing. You will most likely need custom NSFormatter objects to do on the fly formatting since NSNumberFormatter is pretty limited in this regard.";
[formDescriptor addFormSection:section];
// Phone
SHSPhoneNumberFormatter *formatter = [[SHSPhoneNumberFormatter alloc] init];
[formatter setDefaultOutputPattern:@"(###) ###-####" imagePath:nil];
row = [XLFormRowDescriptor formRowDescriptorWithTag:@"phone" rowType:XLFormRowDescriptorTypePhone title:@"US Phone"];
row.valueFormatter = formatter;
[row.cellConfigAtConfigure setObject:@(NSTextAlignmentRight) forKey:@"textField.textAlignment"];
row.useValueFormatterDuringInput = YES;
[section addFormRow:row];
// Currency
row = [XLFormRowDescriptor formRowDescriptorWithTag:@"currency" rowType:XLFormRowDescriptorTypeDecimal title:@"USD"];
CurrencyFormatter *numberFormatter = [[CurrencyFormatter alloc] init];
row.valueFormatter = numberFormatter;
row.value = [NSDecimalNumber numberWithDouble:9.95];
[row.cellConfigAtConfigure setObject:@(NSTextAlignmentRight) forKey:@"textField.textAlignment"];
[section addFormRow:row];
// Accounting
row = [XLFormRowDescriptor formRowDescriptorWithTag:@"percent" rowType:XLFormRowDescriptorTypeNumber title:@"Test Score"];
NSNumberFormatter *acctFormatter = [[NSNumberFormatter alloc] init];
[acctFormatter setNumberStyle:NSNumberFormatterPercentStyle];
row.valueFormatter = acctFormatter;
row.value = @(0.75);
[row.cellConfigAtConfigure setObject:@(NSTextAlignmentRight) forKey:@"textField.textAlignment"];
[section addFormRow:row];
row = [XLFormRowDescriptor formRowDescriptorWithTag:@"megabytes" rowType:XLFormRowDescriptorTypeInfo title:@"Megabytes"];
row.valueFormatter = [NSByteCountFormatter new];
row.value = @(1024);
[section addFormRow:row];
section = [XLFormSectionDescriptor formSection];
[formDescriptor addFormSection:section];
return [super initWithForm:formDescriptor];
}
@end
@@ -135,33 +135,13 @@ NSString *const kNotes = @"notes";
}
[self.tableView endEditing:YES];
#if __IPHONE_OS_VERSION_MAX_ALLOWED < 80000
UIAlertView *message = [[UIAlertView alloc] initWithTitle:NSLocalizedString(@"Valid Form", nil)
message:@"No errors found"
delegate:nil
cancelButtonTitle:NSLocalizedString(@"OK", nil)
otherButtonTitles:nil];
[message show];
#else
if ([UIAlertController class]){
UIAlertController * alertController = [UIAlertController alertControllerWithTitle:NSLocalizedString(@"Valid Form", nil)
message:@"No errors found"
preferredStyle:UIAlertControllerStyleAlert];
[alertController addAction:[UIAlertAction actionWithTitle:NSLocalizedString(@"OK", nil)
style:UIAlertActionStyleDefault
handler:nil]];
[self presentViewController:alertController animated:YES completion:nil];
}
else{
UIAlertView *message = [[UIAlertView alloc] initWithTitle:NSLocalizedString(@"Valid Form", nil)
message:@"No errors found"
delegate:nil
cancelButtonTitle:NSLocalizedString(@"OK", nil)
otherButtonTitles:nil];
[message show];
}
#endif
UIAlertController * alertController = [UIAlertController alertControllerWithTitle:NSLocalizedString(@"Valid Form", nil)
message:@"No errors found"
preferredStyle:UIAlertControllerStyleAlert];
[alertController addAction:[UIAlertAction actionWithTitle:NSLocalizedString(@"OK", nil)
style:UIAlertActionStyleDefault
handler:nil]];
[self presentViewController:alertController animated:YES completion:nil];
}
@end
@@ -25,7 +25,7 @@
#import "XLForm.h"
#import "SelectorsFormViewController.h"
#import "MultiValuedFormViewController.h"
#import "MultivaluedFormViewController.h"
@implementation MultivaluedFormViewController
@@ -85,95 +85,45 @@
-(void)addDidTouch:(UIBarButtonItem * __unused)sender
{
#if __IPHONE_OS_VERSION_MAX_ALLOWED < 80000
UIActionSheet * actionSheet = [[UIActionSheet alloc] initWithTitle:nil
delegate:self
cancelButtonTitle:NSLocalizedString(@"Cancel")
destructiveButtonTitle:@"Remove Last Section"
otherButtonTitles:@"Add a section at the end", self.form.isDisabled ? @"Enable Form" : @"Disable Form", nil];
[actionSheet showInView:self.view];
#else
if ([UIAlertController class]){
UIAlertController * alertController = [UIAlertController alertControllerWithTitle:nil
message:nil
preferredStyle:UIAlertControllerStyleActionSheet];
[alertController addAction:[UIAlertAction actionWithTitle:NSLocalizedString(@"Cancel", nil)
style:UIAlertActionStyleCancel
handler:nil]];
__weak __typeof(self)weakSelf = self;
[alertController addAction:[UIAlertAction actionWithTitle:@"Remove Last Section"
style:UIAlertActionStyleDestructive
handler:^(UIAlertAction *action) {
if (weakSelf.form.formSections.count > 0){
// remove last section
[weakSelf.form removeFormSectionAtIndex:(weakSelf.form.formSections.count - 1)];
}
}]];
[alertController addAction:[UIAlertAction actionWithTitle:@"Add a section at the end"
style:UIAlertActionStyleDefault
handler:^(UIAlertAction *action) {
// add a new section
XLFormSectionDescriptor * newSection = [XLFormSectionDescriptor formSectionWithTitle:[NSString stringWithFormat:@"Section created at %@", [NSDateFormatter localizedStringFromDate:[NSDate new] dateStyle:NSDateFormatterShortStyle timeStyle:NSDateFormatterShortStyle]] sectionOptions:XLFormSectionOptionCanInsert | XLFormSectionOptionCanDelete];
newSection.multivaluedTag = [NSString stringWithFormat:@"multivaluedPushSelector_%@", @(weakSelf.form.formSections.count)];
XLFormRowDescriptor * newRow = [XLFormRowDescriptor formRowDescriptorWithTag:nil rowType:XLFormRowDescriptorTypeSelectorPush title:@"Tap to select ;).."];
newRow.selectorOptions = @[@"Option 1", @"Option 2", @"Option 3"];
[newSection addFormRow:newRow];
[weakSelf.form addFormSection:newSection];
}]];
[alertController addAction:[UIAlertAction actionWithTitle:self.form.isDisabled ? @"Enable Form" : @"Disable Form"
style:UIAlertActionStyleDefault
handler:^(UIAlertAction *action) {
weakSelf.form.disabled = !weakSelf.form.disabled;
[weakSelf.tableView endEditing:YES];
[weakSelf.tableView reloadData];
}]];
[self presentViewController:alertController animated:YES completion:nil];
}
else{
UIActionSheet * actionSheet = [[UIActionSheet alloc] initWithTitle:nil
delegate:self
cancelButtonTitle:NSLocalizedString(@"Cancel", nil)
destructiveButtonTitle:@"Remove Last Section"
otherButtonTitles:@"Add a section at the end", self.form.isDisabled ? @"Enable Form" : @"Disable Form", nil];
[actionSheet showInView:self.view];
}
#endif
UIAlertController * alertController = [UIAlertController alertControllerWithTitle:nil
message:nil
preferredStyle:UIAlertControllerStyleActionSheet];
[alertController addAction:[UIAlertAction actionWithTitle:NSLocalizedString(@"Cancel", nil)
style:UIAlertActionStyleCancel
handler:nil]];
__weak __typeof(self)weakSelf = self;
[alertController addAction:[UIAlertAction actionWithTitle:@"Remove Last Section"
style:UIAlertActionStyleDestructive
handler:^(UIAlertAction *action) {
if (weakSelf.form.formSections.count > 0){
// remove last section
[weakSelf.form removeFormSectionAtIndex:(weakSelf.form.formSections.count - 1)];
}
}]];
[alertController addAction:[UIAlertAction actionWithTitle:@"Add a section at the end"
style:UIAlertActionStyleDefault
handler:^(UIAlertAction *action) {
// add a new section
XLFormSectionDescriptor * newSection = [XLFormSectionDescriptor formSectionWithTitle:[NSString stringWithFormat:@"Section created at %@", [NSDateFormatter localizedStringFromDate:[NSDate new] dateStyle:NSDateFormatterShortStyle timeStyle:NSDateFormatterShortStyle]] sectionOptions:XLFormSectionOptionCanInsert | XLFormSectionOptionCanDelete];
newSection.multivaluedTag = [NSString stringWithFormat:@"multivaluedPushSelector_%@", @(weakSelf.form.formSections.count)];
XLFormRowDescriptor * newRow = [XLFormRowDescriptor formRowDescriptorWithTag:nil rowType:XLFormRowDescriptorTypeSelectorPush title:@"Tap to select ;).."];
newRow.selectorOptions = @[@"Option 1", @"Option 2", @"Option 3"];
[newSection addFormRow:newRow];
[weakSelf.form addFormSection:newSection];
}]];
[alertController addAction:[UIAlertAction actionWithTitle:self.form.isDisabled ? @"Enable Form" : @"Disable Form"
style:UIAlertActionStyleDefault
handler:^(UIAlertAction *action) {
weakSelf.form.disabled = !weakSelf.form.disabled;
[weakSelf.tableView endEditing:YES];
[weakSelf.tableView reloadData];
}]];
[self presentViewController:alertController animated:YES completion:nil];
}
#if __IPHONE_OS_VERSION_MIN_REQUIRED < 80000
#pragma mark - UIActionSheetDelegate
- (void)actionSheet:(UIActionSheet *)actionSheet clickedButtonAtIndex:(NSInteger)buttonIndex
{
if ([actionSheet destructiveButtonIndex] == buttonIndex){
if (self.form.formSections.count > 0){
// remove last section
[self.form removeFormSectionAtIndex:(self.form.formSections.count - 1)];
}
}
else if ([[actionSheet buttonTitleAtIndex:buttonIndex] isEqualToString:@"Add a section at the end"]){
// add a new section
XLFormSectionDescriptor * newSection = [XLFormSectionDescriptor formSectionWithTitle:[NSString stringWithFormat:@"Section created at %@", [NSDateFormatter localizedStringFromDate:[NSDate new] dateStyle:NSDateFormatterShortStyle timeStyle:NSDateFormatterShortStyle]] sectionOptions:XLFormSectionOptionCanInsert | XLFormSectionOptionCanDelete];
newSection.multivaluedTag = [NSString stringWithFormat:@"multivaluedPushSelector_%@", @(self.form.formSections.count)];
XLFormRowDescriptor * newRow = [XLFormRowDescriptor formRowDescriptorWithTag:nil rowType:XLFormRowDescriptorTypeSelectorPush title:@"Tap to select ;).."];
newRow.selectorOptions = @[@"Option 1", @"Option 2", @"Option 3"];
[newSection addFormRow:newRow];
[self.form addFormSection:newSection];
}
else if (![[actionSheet buttonTitleAtIndex:buttonIndex] isEqualToString:NSLocalizedString(@"Cancel")]){
self.form.disabled = !self.form.disabled;
[self.tableView endEditing:YES];
[self.tableView reloadData];
}
}
#endif
@end
@@ -32,7 +32,7 @@
NSString *const kFormImageSelectorCellDefaultImage = @"defaultImage";
NSString *const kFormImageSelectorCellImageRequest = @"imageRequest";
@interface XLFormImageSelectorCell() <UIActionSheetDelegate, UINavigationControllerDelegate, UIImagePickerControllerDelegate>
@interface XLFormImageSelectorCell() <UINavigationControllerDelegate, UIImagePickerControllerDelegate>
@property (nonatomic) UIImage * defaultImage;
@property (nonatomic) NSURLRequest * imageRequest;
@@ -92,57 +92,36 @@ NSString *const kFormImageSelectorCellImageRequest = @"imageRequest";
-(void)formDescriptorCellDidSelectedWithFormController:(XLFormViewController *)controller
{
#if __IPHONE_OS_VERSION_MAX_ALLOWED < 80000
UIActionSheet *actionSheet = [[UIActionSheet alloc] initWithTitle:self.rowDescriptor.selectorTitle
delegate:self
cancelButtonTitle:NSLocalizedString(@"Cancel", nil)
destructiveButtonTitle:nil
otherButtonTitles:NSLocalizedString(@"XLFormImageSelectorCell_ChooseExistingPhoto", @"Choose Existing Photo"), NSLocalizedString(@"XLFormImageSelectorCell_TakePicture", @"Take a Picture"), nil];
actionSheet.tag = self.tag;
[actionSheet showInView:self.formViewController.view];
#else
if ([UIAlertController class]) {
UIAlertController * alertController = [UIAlertController alertControllerWithTitle:self.rowDescriptor.selectorTitle
message:nil
preferredStyle:UIAlertControllerStyleActionSheet];
[alertController addAction:[UIAlertAction actionWithTitle:NSLocalizedString(@"Cancel", nil)
style:UIAlertActionStyleCancel
handler:nil]];
__weak __typeof(self)weakSelf = self;
[alertController addAction:[UIAlertAction actionWithTitle:NSLocalizedString(@"XLFormImageSelectorCell_ChooseExistingPhoto", @"Choose Existing Photo")
style:UIAlertActionStyleDefault
handler:^(UIAlertAction *action) {
UIImagePickerController * imagePickerController = [[UIImagePickerController alloc] init];
imagePickerController.delegate = weakSelf;
imagePickerController.allowsEditing = YES;
imagePickerController.sourceType = UIImagePickerControllerSourceTypePhotoLibrary;
imagePickerController.mediaTypes = @[(NSString *)kUTTypeImage];
[weakSelf.formViewController presentViewController:imagePickerController animated:YES completion:nil];
}]];
[alertController addAction:[UIAlertAction actionWithTitle:NSLocalizedString(@"XLFormImageSelectorCell_TakePicture", @"Take a Picture")
style:UIAlertActionStyleDefault
handler:^(UIAlertAction *action) {
UIImagePickerController * imagePickerController = [[UIImagePickerController alloc] init];
imagePickerController.delegate = weakSelf;
imagePickerController.allowsEditing = YES;
imagePickerController.sourceType = UIImagePickerControllerSourceTypeCamera;
imagePickerController.mediaTypes = @[(NSString *)kUTTypeImage];
[weakSelf.formViewController presentViewController:imagePickerController animated:YES completion:nil];
}]];
[self.formViewController presentViewController:alertController animated:YES completion:nil];
}
else{
UIActionSheet *actionSheet = [[UIActionSheet alloc] initWithTitle:self.rowDescriptor.selectorTitle
delegate:self
cancelButtonTitle:NSLocalizedString(@"Cancel", nil)
destructiveButtonTitle:nil
otherButtonTitles:NSLocalizedString(@"XLFormImageSelectorCell_ChooseExistingPhoto", @"Choose Existing Photo"), NSLocalizedString(@"XLFormImageSelectorCell_TakePicture", @"Take a Picture"), nil];
actionSheet.tag = self.tag;
[actionSheet showInView:self.formViewController.view];
}
#endif
UIAlertController * alertController = [UIAlertController alertControllerWithTitle:self.rowDescriptor.selectorTitle
message:nil
preferredStyle:UIAlertControllerStyleActionSheet];
[alertController addAction:[UIAlertAction actionWithTitle:NSLocalizedString(@"Cancel", nil)
style:UIAlertActionStyleCancel
handler:nil]];
__weak __typeof(self)weakSelf = self;
[alertController addAction:[UIAlertAction actionWithTitle:NSLocalizedString(@"XLFormImageSelectorCell_ChooseExistingPhoto", @"Choose Existing Photo")
style:UIAlertActionStyleDefault
handler:^(UIAlertAction *action) {
UIImagePickerController * imagePickerController = [[UIImagePickerController alloc] init];
imagePickerController.delegate = weakSelf;
imagePickerController.allowsEditing = YES;
imagePickerController.sourceType = UIImagePickerControllerSourceTypePhotoLibrary;
imagePickerController.mediaTypes = @[(NSString *)kUTTypeImage];
[weakSelf.formViewController presentViewController:imagePickerController animated:YES completion:nil];
}]];
[alertController addAction:[UIAlertAction actionWithTitle:NSLocalizedString(@"XLFormImageSelectorCell_TakePicture", @"Take a Picture")
style:UIAlertActionStyleDefault
handler:^(UIAlertAction *action) {
UIImagePickerController * imagePickerController = [[UIImagePickerController alloc] init];
imagePickerController.delegate = weakSelf;
imagePickerController.allowsEditing = YES;
imagePickerController.sourceType = UIImagePickerControllerSourceTypeCamera;
imagePickerController.mediaTypes = @[(NSString *)kUTTypeImage];
[weakSelf.formViewController presentViewController:imagePickerController animated:YES completion:nil];
}]];
[self.formViewController presentViewController:alertController animated:YES completion:nil];
}
#pragma mark - LayoutConstraints
@@ -213,32 +192,6 @@ NSString *const kFormImageSelectorCellImageRequest = @"imageRequest";
[self.textLabel removeObserver:self forKeyPath:@"text"];
}
#if __IPHONE_OS_VERSION_MIN_REQUIRED < 80000
#pragma mark - UIActionSheetDelegate
- (void)actionSheet:(UIActionSheet * __unused)actionSheet clickedButtonAtIndex:(NSInteger)buttonIndex
{
UIImagePickerController * imagePickerController = [[UIImagePickerController alloc] init];
imagePickerController.delegate = self;
imagePickerController.allowsEditing = YES;
if (buttonIndex == 0){
imagePickerController.sourceType = UIImagePickerControllerSourceTypePhotoLibrary;
imagePickerController.mediaTypes = @[(NSString *)kUTTypeImage];
[self.formViewController presentViewController:imagePickerController animated:YES completion:nil];
}
else if (buttonIndex == 1){
imagePickerController.sourceType = UIImagePickerControllerSourceTypeCamera;
imagePickerController.mediaTypes = @[(NSString *)kUTTypeImage];
[self.formViewController presentViewController:imagePickerController animated:YES completion:nil];
}
}
#endif
#pragma mark - UIImagePickerControllerDelegate
- (void)imagePickerController:(UIImagePickerController *)picker didFinishPickingMediaWithInfo:(NSDictionary *)info
@@ -134,32 +134,13 @@ NSString *const kButtonWithStoryboardId = @"buttonWithStoryboardId";
__typeof(self) __weak weakSelf = self;
buttonLeftAlignedRow.action.formBlock = ^(XLFormRowDescriptor * sender){
if ([[sender.sectionDescriptor.formDescriptor formRowWithTag:kSwitchBool].value boolValue]){
#if __IPHONE_OS_VERSION_MAX_ALLOWED < 80000
UIAlertView *message = [[UIAlertView alloc] initWithTitle:NSLocalizedString(@"Switch is ON", nil)
message:@"Button has checked the switch value..."
delegate:weakSelf
cancelButtonTitle:NSLocalizedString(@"OK", nil)
otherButtonTitles:nil];
[message show];
#else
if ([UIAlertController class]) {
UIAlertController * alertController = [UIAlertController alertControllerWithTitle:NSLocalizedString(@"Switch is ON", nil)
message:@"Button has checked the switch value..."
preferredStyle:UIAlertControllerStyleAlert];
[alertController addAction:[UIAlertAction actionWithTitle:NSLocalizedString(@"OK", nil)
style:UIAlertActionStyleDefault
handler:nil]];
[self presentViewController:alertController animated:YES completion:nil];
}
else{
UIAlertView *message = [[UIAlertView alloc] initWithTitle:NSLocalizedString(@"Switch is ON", nil)
message:@"Button has checked the switch value..."
delegate:weakSelf
cancelButtonTitle:NSLocalizedString(@"OK", nil)
otherButtonTitles:nil];
[message show];
}
#endif
UIAlertController * alertController = [UIAlertController alertControllerWithTitle:NSLocalizedString(@"Switch is ON", nil)
message:@"Button has checked the switch value..."
preferredStyle:UIAlertControllerStyleAlert];
[alertController addAction:[UIAlertAction actionWithTitle:NSLocalizedString(@"OK", nil)
style:UIAlertActionStyleDefault
handler:nil]];
[self presentViewController:alertController animated:YES completion:nil];
}
[weakSelf deselectFormRow:sender];
};
@@ -196,33 +177,13 @@ NSString *const kButtonWithStoryboardId = @"buttonWithStoryboardId";
-(void)didTouchButton:(XLFormRowDescriptor *)sender
{
if ([[sender.sectionDescriptor.formDescriptor formRowWithTag:kSwitchBool].value boolValue]){
#if __IPHONE_OS_VERSION_MAX_ALLOWED < 80000
UIAlertView *message = [[UIAlertView alloc] initWithTitle:NSLocalizedString(@"Switch is ON", nil)
message:@"Button has checked the switch value..."
delegate:self
cancelButtonTitle:NSLocalizedString(@"OK", nil)
otherButtonTitles:nil];
[message show];
#else
if ([UIAlertController class]) {
UIAlertController * alertController = [UIAlertController alertControllerWithTitle:NSLocalizedString(@"Switch is ON", nil)
message:@"Button has checked the switch value..."
preferredStyle:UIAlertControllerStyleAlert];
[alertController addAction:[UIAlertAction actionWithTitle:NSLocalizedString(@"OK", nil)
style:UIAlertActionStyleDefault
handler:nil]];
[self presentViewController:alertController animated:YES completion:nil];
}
else{
UIAlertView *message = [[UIAlertView alloc] initWithTitle:NSLocalizedString(@"Switch is ON", nil)
message:@"Button has checked the switch value..."
delegate:self
cancelButtonTitle:NSLocalizedString(@"OK", nil)
otherButtonTitles:nil];
[message show];
}
#endif
UIAlertController * alertController = [UIAlertController alertControllerWithTitle:NSLocalizedString(@"Switch is ON", nil)
message:@"Button has checked the switch value..."
preferredStyle:UIAlertControllerStyleAlert];
[alertController addAction:[UIAlertAction actionWithTitle:NSLocalizedString(@"OK", nil)
style:UIAlertActionStyleDefault
handler:nil]];
[self presentViewController:alertController animated:YES completion:nil];
}
[self deselectFormRow:sender];
}
@@ -89,7 +89,7 @@
MKPinAnnotationView *pinAnnotationView = [[MKPinAnnotationView alloc] initWithAnnotation:annotation
reuseIdentifier:@"annotation"];
pinAnnotationView.pinColor = MKPinAnnotationColorRed;
pinAnnotationView.pinTintColor = [UIColor redColor];
pinAnnotationView.draggable = YES;
pinAnnotationView.animatesDrop = YES;
return pinAnnotationView;
@@ -26,9 +26,9 @@
#import "XLFormRowDescriptor.h"
#import "XLRemoteDataStoreController.h"
@interface UsersTableViewController : XLRemoteDataStoreController <XLFormRowDescriptorViewController, XLFormRowDescriptorPopoverViewController>
@interface UsersTableViewController : XLRemoteDataStoreController <XLFormRowDescriptorViewController>
@property BOOL isSearchResultsController;
@property NSLayoutConstraint *topConstraint;
@end
@end
@@ -124,7 +124,6 @@
@implementation UsersTableViewController
@synthesize rowDescriptor = _rowDescriptor;
@synthesize popoverController = __popoverController;
@synthesize searchController = _searchController;
@synthesize searchResultController = _searchResultController;
@@ -205,15 +204,16 @@ static NSString *const kCellIdentifier = @"CellIdentifier";
-(void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
{
NSDictionary *dataItem = [self.dataStore dataAtIndexPath:indexPath];
self.rowDescriptor.value = dataItem;
if (self.popoverController){
[self.popoverController dismissPopoverAnimated:YES];
[self.popoverController.delegate popoverControllerDidDismissPopover:self.popoverController];
}
else if ([self.parentViewController isKindOfClass:[UINavigationController class]]){
UIViewController *popoverController = self.presentedViewController;
if (popoverController && popoverController.modalPresentationStyle == UIModalPresentationPopover) {
[self dismissViewControllerAnimated:YES completion:nil];
} else if ([self.parentViewController isKindOfClass:[UINavigationController class]]) {
[self.navigationController popViewControllerAnimated:YES];
} else if ([self.presentingViewController isKindOfClass:[UsersTableViewController class]]) {
[[self.presentingViewController navigationController] popViewControllerAnimated:YES];
}
}
@@ -243,10 +243,12 @@ static NSString *const kCellIdentifier = @"CellIdentifier";
-(UsersTableViewController *)searchResultController
{
if (_searchResultController) return _searchResultController;
_searchResultController = [[UsersTableViewController alloc]init];
UsersTableViewController *usersViewController = [[UsersTableViewController alloc] init];
usersViewController.rowDescriptor = self.rowDescriptor;
_searchResultController = usersViewController;
_searchResultController.dataLoader.limit = 0; // no paging in search result
_searchResultController.isSearchResultsController = YES;
return _searchResultController;
}
@end
@end
@@ -1,8 +1,10 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="9059" systemVersion="15B42" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" initialViewController="p4n-1v-pzo">
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="14865.1" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" colorMatched="YES" initialViewController="p4n-1v-pzo">
<device id="retina6_1" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="9049"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14819.2"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<scenes>
<!--Navigation Controller-->
@@ -11,9 +13,8 @@
<navigationController automaticallyAdjustsScrollViewInsets="NO" id="p4n-1v-pzo" sceneMemberID="viewController">
<toolbarItems/>
<navigationBar key="navigationBar" contentMode="scaleToFill" id="SNt-hk-N3V">
<rect key="frame" x="0.0" y="0.0" width="320" height="44"/>
<rect key="frame" x="0.0" y="44" width="414" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<animations/>
</navigationBar>
<nil name="viewControllers"/>
<connections>
@@ -22,7 +23,7 @@
</navigationController>
<placeholder placeholderIdentifier="IBFirstResponder" id="jqF-cF-u4f" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="117" y="56"/>
<point key="canvasLocation" x="-3" y="38"/>
</scene>
<!--Others Form View Controller-->
<scene sceneID="dyJ-7m-RaD">
@@ -33,10 +34,9 @@
<viewControllerLayoutGuide type="bottom" id="HPb-Nx-E1G"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="wpr-wE-9nj">
<rect key="frame" x="0.0" y="64" width="320" height="504"/>
<rect key="frame" x="0.0" y="0.0" width="414" height="808"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<animations/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</view>
<extendedEdge key="edgesForExtendedLayout" bottom="YES"/>
<navigationItem key="navigationItem" id="Hf0-cB-ORN"/>
@@ -46,7 +46,7 @@
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="7YZ-ZR-X81" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="1533" y="-233"/>
<point key="canvasLocation" x="2221.739130434783" y="-156.02678571428569"/>
</scene>
<!--Native Event Form View Controller-->
<scene sceneID="EjT-rm-U3h">
@@ -57,17 +57,15 @@
<viewControllerLayoutGuide type="bottom" id="QuR-kY-o5R"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="tun-QW-CGC">
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
<rect key="frame" x="0.0" y="0.0" width="414" height="842"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<tableView clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" dataMode="prototypes" style="grouped" separatorStyle="default" rowHeight="44" sectionHeaderHeight="10" sectionFooterHeight="10" translatesAutoresizingMaskIntoConstraints="NO" id="JY7-WL-SnH">
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
<animations/>
<rect key="frame" x="0.0" y="0.0" width="414" height="808"/>
<color key="backgroundColor" cocoaTouchSystemColor="groupTableViewBackgroundColor"/>
</tableView>
</subviews>
<animations/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstItem="JY7-WL-SnH" firstAttribute="leading" secondItem="tun-QW-CGC" secondAttribute="leading" id="bSe-SV-rx6"/>
<constraint firstAttribute="trailing" secondItem="JY7-WL-SnH" secondAttribute="trailing" id="jLI-68-pSq"/>
@@ -82,7 +80,7 @@
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="zV0-mq-irv" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="1120" y="-635"/>
<point key="canvasLocation" x="1623.1884057971015" y="-425.22321428571428"/>
</scene>
<!--Examples-->
<scene sceneID="wf7-ha-lXx">
@@ -93,17 +91,15 @@
<viewControllerLayoutGuide type="bottom" id="0bE-2H-tqE"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="PO9-pF-A7O">
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
<rect key="frame" x="0.0" y="0.0" width="414" height="896"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<tableView clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" dataMode="prototypes" style="grouped" separatorStyle="default" rowHeight="44" sectionHeaderHeight="10" sectionFooterHeight="10" translatesAutoresizingMaskIntoConstraints="NO" id="Lxj-Sb-kC6">
<rect key="frame" x="0.0" y="64" width="320" height="504"/>
<animations/>
<rect key="frame" x="0.0" y="88" width="414" height="774"/>
<color key="backgroundColor" cocoaTouchSystemColor="groupTableViewBackgroundColor"/>
</tableView>
</subviews>
<animations/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstItem="Lxj-Sb-kC6" firstAttribute="top" secondItem="kOR-67-djF" secondAttribute="bottom" id="PT1-Xo-3Ql"/>
<constraint firstAttribute="trailing" secondItem="Lxj-Sb-kC6" secondAttribute="trailing" id="brq-yF-WM8"/>
@@ -125,7 +121,7 @@
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="1V5-DZ-WfF" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="527" y="56"/>
<point key="canvasLocation" x="763.768115942029" y="37.5"/>
</scene>
<!--Blog Example View Controller-->
<scene sceneID="Vn0-9y-5bc">
@@ -136,17 +132,16 @@
<viewControllerLayoutGuide type="bottom" id="scM-da-Sg0"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="hrV-fb-58s">
<rect key="frame" x="0.0" y="64" width="320" height="504"/>
<rect key="frame" x="0.0" y="0.0" width="414" height="808"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<animations/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</view>
<extendedEdge key="edgesForExtendedLayout" bottom="YES"/>
<navigationItem key="navigationItem" id="RJB-cz-SnF"/>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="Fvo-wr-5Ca" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="167" y="1151"/>
<point key="canvasLocation" x="242.0289855072464" y="770.75892857142856"/>
</scene>
<!--Validation Examples-->
<scene sceneID="z2I-Nk-y9W">
@@ -157,17 +152,15 @@
<viewControllerLayoutGuide type="bottom" id="xtJ-Wo-mhU"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="1Ol-Ra-Ysg">
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
<rect key="frame" x="0.0" y="0.0" width="414" height="896"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<tableView clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" dataMode="prototypes" style="grouped" separatorStyle="default" rowHeight="44" sectionHeaderHeight="10" sectionFooterHeight="10" translatesAutoresizingMaskIntoConstraints="NO" id="Fty-3j-BeF">
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
<animations/>
<rect key="frame" x="0.0" y="24" width="414" height="838"/>
<color key="backgroundColor" cocoaTouchSystemColor="groupTableViewBackgroundColor"/>
</tableView>
</subviews>
<animations/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstItem="xtJ-Wo-mhU" firstAttribute="top" secondItem="Fty-3j-BeF" secondAttribute="bottom" id="CbV-4f-RzP"/>
<constraint firstItem="Fty-3j-BeF" firstAttribute="top" secondItem="AG9-N9-2qp" secondAttribute="bottom" constant="-64" id="Pdw-VG-qcc"/>
@@ -184,7 +177,7 @@
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="VFT-Og-STO" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="566" y="938"/>
<point key="canvasLocation" x="820.28985507246387" y="628.125"/>
</scene>
<!--Predicate Form View Controller-->
<scene sceneID="a9p-C8-g8y">
@@ -195,17 +188,16 @@
<viewControllerLayoutGuide type="bottom" id="Lsg-dH-McH"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="6EZ-O7-FjX">
<rect key="frame" x="0.0" y="64" width="320" height="504"/>
<rect key="frame" x="0.0" y="0.0" width="414" height="808"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<animations/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</view>
<extendedEdge key="edgesForExtendedLayout" bottom="YES"/>
<navigationItem key="navigationItem" id="Lsd-xH-7IN"/>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="rZL-10-YZn" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="956" y="924"/>
<point key="canvasLocation" x="1385.5072463768117" y="618.75"/>
</scene>
<!--Selectors Form View Controller-->
<scene sceneID="KYK-TX-8rm">
@@ -216,10 +208,9 @@
<viewControllerLayoutGuide type="bottom" id="CTu-Y5-7Qw"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="bNj-SD-83w">
<rect key="frame" x="0.0" y="64" width="320" height="504"/>
<rect key="frame" x="0.0" y="0.0" width="414" height="808"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<animations/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</view>
<extendedEdge key="edgesForExtendedLayout" bottom="YES"/>
<navigationItem key="navigationItem" id="Buo-Af-6Q1"/>
@@ -229,7 +220,7 @@
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="8fu-YK-6qz" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="1346" y="533"/>
<point key="canvasLocation" x="1950.7246376811595" y="356.91964285714283"/>
</scene>
<!--Map View Controller-->
<scene sceneID="tAS-lK-35t">
@@ -240,17 +231,16 @@
<viewControllerLayoutGuide type="bottom" id="cgQ-Vs-ICN"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="JjC-E5-SyY">
<rect key="frame" x="0.0" y="64" width="320" height="504"/>
<rect key="frame" x="0.0" y="0.0" width="414" height="808"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<animations/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</view>
<extendedEdge key="edgesForExtendedLayout" bottom="YES"/>
<navigationItem key="navigationItem" id="BjG-Bq-0lD"/>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="LmS-YR-mFY" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="1789" y="533"/>
<point key="canvasLocation" x="2592.753623188406" y="356.91964285714283"/>
</scene>
<!--Native Event Navigation View Controller-->
<scene sceneID="mNb-be-ApA">
@@ -258,9 +248,8 @@
<navigationController automaticallyAdjustsScrollViewInsets="NO" id="K9D-4c-9eZ" customClass="NativeEventNavigationViewController" sceneMemberID="viewController">
<toolbarItems/>
<navigationBar key="navigationBar" contentMode="scaleToFill" id="fO3-V7-XXu">
<rect key="frame" x="0.0" y="0.0" width="320" height="44"/>
<rect key="frame" x="0.0" y="0.0" width="414" height="56"/>
<autoresizingMask key="autoresizingMask"/>
<animations/>
</navigationBar>
<nil name="viewControllers"/>
<connections>
@@ -269,7 +258,7 @@
</navigationController>
<placeholder placeholderIdentifier="IBFirstResponder" id="eqB-vl-BzH" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="586" y="-654"/>
<point key="canvasLocation" x="849.27536231884062" y="-437.94642857142856"/>
</scene>
<!--Basic Predicate View Controller-->
<scene sceneID="pD4-sm-x3a">
@@ -280,17 +269,16 @@
<viewControllerLayoutGuide type="bottom" id="2b4-gN-85p"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="NZg-t1-g19">
<rect key="frame" x="0.0" y="64" width="320" height="504"/>
<rect key="frame" x="0.0" y="0.0" width="414" height="808"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<animations/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</view>
<extendedEdge key="edgesForExtendedLayout" bottom="YES"/>
<navigationItem key="navigationItem" id="1lh-jZ-lIV"/>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="Tlw-q2-pcu" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="-159" y="1151"/>
<point key="canvasLocation" x="-230.43478260869566" y="770.75892857142856"/>
</scene>
<!--Users Table View Controller-->
<scene sceneID="lGi-0L-kUk">
@@ -301,17 +289,15 @@
<viewControllerLayoutGuide type="bottom" id="uVG-bI-IMr"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="sMH-hT-NCg">
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
<rect key="frame" x="0.0" y="0.0" width="414" height="896"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<tableView autoresizesSubviews="NO" clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" dataMode="prototypes" style="grouped" separatorStyle="default" rowHeight="44" sectionHeaderHeight="10" sectionFooterHeight="10" translatesAutoresizingMaskIntoConstraints="NO" id="fLo-Gu-rqr">
<rect key="frame" x="0.0" y="20" width="320" height="548"/>
<animations/>
<rect key="frame" x="0.0" y="44" width="414" height="818"/>
<color key="backgroundColor" cocoaTouchSystemColor="groupTableViewBackgroundColor"/>
</tableView>
</subviews>
<animations/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstItem="uVG-bI-IMr" firstAttribute="top" secondItem="fLo-Gu-rqr" secondAttribute="bottom" id="25A-HG-wek"/>
<constraint firstItem="fLo-Gu-rqr" firstAttribute="top" secondItem="at2-Ds-EcY" secondAttribute="bottom" id="3N4-a2-LLf"/>
@@ -326,7 +312,7 @@
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="flB-2M-8zS" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="1346" y="1178"/>
<point key="canvasLocation" x="1950.7246376811595" y="788.83928571428567"/>
</scene>
</scenes>
<inferredMetricsTieBreakers>
+5 -1
View File
@@ -1,5 +1,7 @@
source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '8.0'
platform :ios, '9.0'
target 'XLForm' do
pod 'XLForm', :path => '../../'
@@ -8,3 +10,5 @@ pod 'AFNetworking', '~> 2.0', :inhibit_warnings => true
pod 'XLData', :git => 'https://github.com/xmartlabs/XLData.git', :commit => '1f9019b56242a2019c7f7e11ec4ef823c397ebcf', :inhibit_warnings => true
pod 'JVFloatLabeledTextField', '1.0.2', :inhibit_warnings => true
pod 'AXRatingView', '1.0.3', :inhibit_warnings => true
pod 'SHSPhoneComponent'
end
+85
View File
@@ -0,0 +1,85 @@
PODS:
- AFNetworking (2.6.3):
- AFNetworking/NSURLConnection (= 2.6.3)
- AFNetworking/NSURLSession (= 2.6.3)
- AFNetworking/Reachability (= 2.6.3)
- AFNetworking/Security (= 2.6.3)
- AFNetworking/Serialization (= 2.6.3)
- AFNetworking/UIKit (= 2.6.3)
- AFNetworking/NSURLConnection (2.6.3):
- AFNetworking/Reachability
- AFNetworking/Security
- AFNetworking/Serialization
- AFNetworking/NSURLSession (2.6.3):
- AFNetworking/Reachability
- AFNetworking/Security
- AFNetworking/Serialization
- AFNetworking/Reachability (2.6.3)
- AFNetworking/Security (2.6.3)
- AFNetworking/Serialization (2.6.3)
- AFNetworking/UIKit (2.6.3):
- AFNetworking/NSURLConnection
- AFNetworking/NSURLSession
- AXRatingView (1.0.3)
- JVFloatLabeledTextField (1.0.2)
- SHSPhoneComponent (2.15)
- XLData (2.0.0):
- XLData/Core (= 2.0.0)
- XLData/CoreData (= 2.0.0)
- XLData/CoreRemote (= 2.0.0)
- XLData/DataStore (= 2.0.0)
- XLData/RemoteCoreData (= 2.0.0)
- XLData/RemoteDataStore (= 2.0.0)
- XLData/Core (2.0.0)
- XLData/CoreData (2.0.0):
- XLData/Core
- XLData/CoreRemote (2.0.0):
- AFNetworking (~> 2.0)
- XLData/DataStore (2.0.0):
- XLData/Core
- XLData/RemoteCoreData (2.0.0):
- XLData/CoreData
- XLData/CoreRemote
- XLData/RemoteDataStore (2.0.0):
- XLData/CoreRemote
- XLData/DataStore
- XLForm (4.3.0)
DEPENDENCIES:
- AFNetworking (~> 2.0)
- AXRatingView (= 1.0.3)
- JVFloatLabeledTextField (= 1.0.2)
- SHSPhoneComponent
- XLData (from `https://github.com/xmartlabs/XLData.git`, commit `1f9019b56242a2019c7f7e11ec4ef823c397ebcf`)
- XLForm (from `../../`)
SPEC REPOS:
https://github.com/CocoaPods/Specs.git:
- AFNetworking
- AXRatingView
- JVFloatLabeledTextField
- SHSPhoneComponent
EXTERNAL SOURCES:
XLData:
:commit: 1f9019b56242a2019c7f7e11ec4ef823c397ebcf
:git: https://github.com/xmartlabs/XLData.git
XLForm:
:path: "../../"
CHECKOUT OPTIONS:
XLData:
:commit: 1f9019b56242a2019c7f7e11ec4ef823c397ebcf
:git: https://github.com/xmartlabs/XLData.git
SPEC CHECKSUMS:
AFNetworking: cb8d14a848e831097108418f5d49217339d4eb60
AXRatingView: ccaadc1bbda99a4b7e1d556059482d2b933a9f4e
JVFloatLabeledTextField: 58a3a32cfb800e5b224f676987e7c13abf50a14d
SHSPhoneComponent: 4cec0653a150ad63cbc52b0c8b29ce2d3c9c26f0
XLData: df725c6179e2e0c80bf56a1ecad9afd169707a6d
XLForm: a439f9512078ed538e8335c8b06d3f3286bbfd37
PODFILE CHECKSUM: 64fbcd03a2c13762b2c18e3938cc8008807937c9
COCOAPODS: 1.11.3
@@ -33,7 +33,6 @@
28A85D5918E346C100E81A26 /* XLFormImageSelectorCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 28A85D5818E346C100E81A26 /* XLFormImageSelectorCell.m */; };
28DBB04118D76FDC00FB8A8B /* MultivaluedFormViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 28DBB04018D76FDC00FB8A8B /* MultivaluedFormViewController.m */; };
28F89F2E1AA4EA5600E90218 /* ValidationExamplesFormViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 28F89F2D1AA4EA5600E90218 /* ValidationExamplesFormViewController.m */; };
2CA9A3FC06E94345A2FDE415 /* libPods.a in Frameworks */ = {isa = PBXBuildFile; fileRef = F6DF43B7BBF44F72A4493E8E /* libPods.a */; };
3C0357F01AB0D82300200C8A /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 3C0357EF1AB0D82300200C8A /* Images.xcassets */; };
3C3B01D51AB741EF0027CD45 /* XLFormRatingCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 3C3B01D31AB741EF0027CD45 /* XLFormRatingCell.m */; };
3C3B01DA1AB7497D0027CD45 /* XLFormWeekDaysCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 3C3B01D81AB7497D0027CD45 /* XLFormWeekDaysCell.m */; };
@@ -41,6 +40,7 @@
3C3B01E21AB7499A0027CD45 /* XLRatingView.m in Sources */ = {isa = PBXBuildFile; fileRef = 3C3B01E01AB7499A0027CD45 /* XLRatingView.m */; };
3C3B01F01AB74BDC0027CD45 /* FloatLabeledTextFieldCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 3C3B01EF1AB74BDC0027CD45 /* FloatLabeledTextFieldCell.m */; };
3CDAFC7A1AB0AFA4000F75B6 /* CustomRowsViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 3CDAFC791AB0AFA4000F75B6 /* CustomRowsViewController.m */; };
5BB6B032D80344C9E7D956CD /* libPods-XLForm.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 19383D268EF8024CB33FCCA4 /* libPods-XLForm.a */; };
66B6266E1AE0055100007886 /* DateAndTimeValueTrasformer.m in Sources */ = {isa = PBXBuildFile; fileRef = 66B6266D1AE0055100007886 /* DateAndTimeValueTrasformer.m */; };
BF01E9281C21F0BB00BDE045 /* XLFormInlineSegmentedCell.m in Sources */ = {isa = PBXBuildFile; fileRef = BF01E9271C21F0BB00BDE045 /* XLFormInlineSegmentedCell.m */; };
BF9DB1D51AE0436600B985E7 /* BlogExampleViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = BF9DB1D21AE0436600B985E7 /* BlogExampleViewController.m */; };
@@ -49,9 +49,11 @@
BFE91AFB1AE159B200DE5231 /* BasicPredicateViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = BFE91AFA1AE159B200DE5231 /* BasicPredicateViewController.m */; };
D51B8B2C19126664008C0478 /* XLFormCustomCell.m in Sources */ = {isa = PBXBuildFile; fileRef = D51B8B2B19126664008C0478 /* XLFormCustomCell.m */; };
DEA6EF911B57D6CC000F4893 /* HTTPSessionManager.m in Sources */ = {isa = PBXBuildFile; fileRef = DEA6EF901B57D6CC000F4893 /* HTTPSessionManager.m */; };
DEB8235C1AD5529A00AF9FE2 /* FormattersViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = DEB8235B1AD5529A00AF9FE2 /* FormattersViewController.m */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
19383D268EF8024CB33FCCA4 /* libPods-XLForm.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-XLForm.a"; sourceTree = BUILT_PRODUCTS_DIR; };
281E5BE719538F4A006D93C5 /* CLLocationValueTrasformer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CLLocationValueTrasformer.h; path = Examples/Selectors/CustomSelectors/XLFormRowViewController/CLLocationValueTrasformer.h; sourceTree = "<group>"; };
281E5BE819538F4A006D93C5 /* CLLocationValueTrasformer.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CLLocationValueTrasformer.m; path = Examples/Selectors/CustomSelectors/XLFormRowViewController/CLLocationValueTrasformer.m; sourceTree = "<group>"; };
282EB27A1AB5FF33004A736F /* AccessoryViewFormViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AccessoryViewFormViewController.h; path = Examples/AccessoryViews/AccessoryViewFormViewController.h; sourceTree = "<group>"; };
@@ -111,10 +113,10 @@
3C3B01EF1AB74BDC0027CD45 /* FloatLabeledTextFieldCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = FloatLabeledTextFieldCell.m; path = Examples/CustomRows/FloatLabeledTextField/FloatLabeledTextFieldCell.m; sourceTree = "<group>"; };
3CDAFC781AB0AFA4000F75B6 /* CustomRowsViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CustomRowsViewController.h; path = Examples/CustomRows/CustomRowsViewController.h; sourceTree = "<group>"; };
3CDAFC791AB0AFA4000F75B6 /* CustomRowsViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CustomRowsViewController.m; path = Examples/CustomRows/CustomRowsViewController.m; sourceTree = "<group>"; };
5F6FC67A75254B60005DC716 /* Pods-XLForm.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-XLForm.debug.xcconfig"; path = "Pods/Target Support Files/Pods-XLForm/Pods-XLForm.debug.xcconfig"; sourceTree = "<group>"; };
66B6266C1AE0055100007886 /* DateAndTimeValueTrasformer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DateAndTimeValueTrasformer.h; path = Examples/Dates/DateAndTimeValueTrasformer.h; sourceTree = "<group>"; };
66B6266D1AE0055100007886 /* DateAndTimeValueTrasformer.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = DateAndTimeValueTrasformer.m; path = Examples/Dates/DateAndTimeValueTrasformer.m; sourceTree = "<group>"; };
7B0D2D6A86E2A41ED22E8A35 /* Pods.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = Pods.debug.xcconfig; path = "Pods/Target Support Files/Pods/Pods.debug.xcconfig"; sourceTree = "<group>"; };
976A33EE62A018A7257B4878 /* Pods.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = Pods.release.xcconfig; path = "Pods/Target Support Files/Pods/Pods.release.xcconfig"; sourceTree = "<group>"; };
B98C1213E7C714A861219C81 /* Pods-XLForm.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-XLForm.release.xcconfig"; path = "Pods/Target Support Files/Pods-XLForm/Pods-XLForm.release.xcconfig"; sourceTree = "<group>"; };
BF01E9261C21F0BB00BDE045 /* XLFormInlineSegmentedCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormInlineSegmentedCell.h; path = "Inline Segmented/XLFormInlineSegmentedCell.h"; sourceTree = "<group>"; };
BF01E9271C21F0BB00BDE045 /* XLFormInlineSegmentedCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormInlineSegmentedCell.m; path = "Inline Segmented/XLFormInlineSegmentedCell.m"; sourceTree = "<group>"; };
BF9DB1D11AE0436600B985E7 /* BlogExampleViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = BlogExampleViewController.h; path = Examples/PredicateExamples/BlogExampleViewController.h; sourceTree = SOURCE_ROOT; };
@@ -127,7 +129,8 @@
D51B8B2B19126664008C0478 /* XLFormCustomCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormCustomCell.m; path = Examples/Others/CustomCells/XLFormCustomCell.m; sourceTree = "<group>"; };
DEA6EF8F1B57D6CC000F4893 /* HTTPSessionManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = HTTPSessionManager.h; path = Examples/Selectors/HTTPSessionManager.h; sourceTree = "<group>"; };
DEA6EF901B57D6CC000F4893 /* HTTPSessionManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = HTTPSessionManager.m; path = Examples/Selectors/HTTPSessionManager.m; sourceTree = "<group>"; };
F6DF43B7BBF44F72A4493E8E /* libPods.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libPods.a; sourceTree = BUILT_PRODUCTS_DIR; };
DEB8235A1AD5529A00AF9FE2 /* FormattersViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FormattersViewController.h; sourceTree = "<group>"; };
DEB8235B1AD5529A00AF9FE2 /* FormattersViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = FormattersViewController.m; sourceTree = "<group>"; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
@@ -139,22 +142,13 @@
2850C5FE18D0F706002B7D0A /* CoreGraphics.framework in Frameworks */,
2850C60018D0F706002B7D0A /* UIKit.framework in Frameworks */,
2850C5FC18D0F706002B7D0A /* Foundation.framework in Frameworks */,
2CA9A3FC06E94345A2FDE415 /* libPods.a in Frameworks */,
5BB6B032D80344C9E7D956CD /* libPods-XLForm.a in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
15E61D225B0D27FAB51BDD90 /* Pods */ = {
isa = PBXGroup;
children = (
7B0D2D6A86E2A41ED22E8A35 /* Pods.debug.xcconfig */,
976A33EE62A018A7257B4878 /* Pods.release.xcconfig */,
);
name = Pods;
sourceTree = "<group>";
};
282C5EEF18D33C1800A5D47C /* Inputs */ = {
isa = PBXGroup;
children = (
@@ -261,7 +255,7 @@
2850C60118D0F706002B7D0A /* XLForm */,
2850C5FA18D0F706002B7D0A /* Frameworks */,
2850C5F918D0F706002B7D0A /* Products */,
15E61D225B0D27FAB51BDD90 /* Pods */,
B6478577DDCB0DDDD433C572 /* Pods */,
);
sourceTree = "<group>";
};
@@ -280,7 +274,7 @@
2850C5FB18D0F706002B7D0A /* Foundation.framework */,
2850C5FD18D0F706002B7D0A /* CoreGraphics.framework */,
2850C5FF18D0F706002B7D0A /* UIKit.framework */,
F6DF43B7BBF44F72A4493E8E /* libPods.a */,
19383D268EF8024CB33FCCA4 /* libPods-XLForm.a */,
);
name = Frameworks;
sourceTree = "<group>";
@@ -312,6 +306,7 @@
282EB2791AB5FD66004A736F /* AccessoryViews */,
3CDAFC741AB0AEE5000F75B6 /* CustomRows */,
28F89F2B1AA4E99500E90218 /* Validations */,
DEB823591AD5529A00AF9FE2 /* Formatters */,
283C6B7A1999BA1B00A5283D /* UICustomization */,
28A76624193251E500D69546 /* AppDelegate.m */,
28A8083C190D903D009D77F8 /* StoryboardExample */,
@@ -429,6 +424,15 @@
name = CustomRows;
sourceTree = "<group>";
};
B6478577DDCB0DDDD433C572 /* Pods */ = {
isa = PBXGroup;
children = (
5F6FC67A75254B60005DC716 /* Pods-XLForm.debug.xcconfig */,
B98C1213E7C714A861219C81 /* Pods-XLForm.release.xcconfig */,
);
name = Pods;
sourceTree = "<group>";
};
BF01E9251C21F02D00BDE045 /* Inline Segmented */ = {
isa = PBXGroup;
children = (
@@ -461,6 +465,16 @@
name = SessionManager;
sourceTree = "<group>";
};
DEB823591AD5529A00AF9FE2 /* Formatters */ = {
isa = PBXGroup;
children = (
DEB8235A1AD5529A00AF9FE2 /* FormattersViewController.h */,
DEB8235B1AD5529A00AF9FE2 /* FormattersViewController.m */,
);
name = Formatters;
path = Examples/Formatters;
sourceTree = "<group>";
};
/* End PBXGroup section */
/* Begin PBXNativeTarget section */
@@ -468,12 +482,11 @@
isa = PBXNativeTarget;
buildConfigurationList = 2850C62418D0F707002B7D0A /* Build configuration list for PBXNativeTarget "XLForm" */;
buildPhases = (
0EA9FCE3DA0D444498836D37 /* Check Pods Manifest.lock */,
EBE0335CCC7588D83B89A92A /* [CP] Check Pods Manifest.lock */,
2850C5F418D0F706002B7D0A /* Sources */,
2850C5F518D0F706002B7D0A /* Frameworks */,
2850C5F618D0F706002B7D0A /* Resources */,
CFE72E068B5F4D9BB45FB757 /* Copy Pods Resources */,
734CC62A7A974D37CC982576 /* Embed Pods Frameworks */,
DE3D12F5596780A66C6C3D4A /* [CP] Copy Pods Resources */,
);
buildRules = (
);
@@ -490,7 +503,7 @@
2850C5F018D0F706002B7D0A /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 0700;
LastUpgradeCheck = 1100;
ORGANIZATIONNAME = Xmartlabs;
};
buildConfigurationList = 2850C5F318D0F706002B7D0A /* Build configuration list for PBXProject "XLForm" */;
@@ -498,6 +511,7 @@
developmentRegion = English;
hasScannedForEncodings = 0;
knownRegions = (
English,
en,
);
mainGroup = 2850C5EF18D0F706002B7D0A;
@@ -528,49 +542,40 @@
/* End PBXResourcesBuildPhase section */
/* Begin PBXShellScriptBuildPhase section */
0EA9FCE3DA0D444498836D37 /* Check Pods Manifest.lock */ = {
DE3D12F5596780A66C6C3D4A /* [CP] Copy Pods Resources */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
"${PODS_ROOT}/Target Support Files/Pods-XLForm/Pods-XLForm-resources.sh",
"${PODS_ROOT}/../../../XLForm/XLForm.bundle",
);
name = "Check Pods Manifest.lock";
name = "[CP] Copy Pods Resources";
outputPaths = (
"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/XLForm.bundle",
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [[ $? != 0 ]] ; then\n cat << EOM\nerror: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\nEOM\n exit 1\nfi\n";
shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-XLForm/Pods-XLForm-resources.sh\"\n";
showEnvVarsInLog = 0;
};
734CC62A7A974D37CC982576 /* Embed Pods Frameworks */ = {
EBE0335CCC7588D83B89A92A /* [CP] Check Pods Manifest.lock */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
"${PODS_PODFILE_DIR_PATH}/Podfile.lock",
"${PODS_ROOT}/Manifest.lock",
);
name = "Embed Pods Frameworks";
name = "[CP] Check Pods Manifest.lock";
outputPaths = (
"$(DERIVED_FILE_DIR)/Pods-XLForm-checkManifestLockResult.txt",
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods/Pods-frameworks.sh\"\n";
showEnvVarsInLog = 0;
};
CFE72E068B5F4D9BB45FB757 /* Copy Pods Resources */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
);
name = "Copy Pods Resources";
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods/Pods-resources.sh\"\n";
shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n";
showEnvVarsInLog = 0;
};
/* End PBXShellScriptBuildPhase section */
@@ -606,6 +611,7 @@
BF01E9281C21F0BB00BDE045 /* XLFormInlineSegmentedCell.m in Sources */,
BF9DB1D61AE0436600B985E7 /* PredicateFormViewController.m in Sources */,
BFE91AFB1AE159B200DE5231 /* BasicPredicateViewController.m in Sources */,
DEB8235C1AD5529A00AF9FE2 /* FormattersViewController.m in Sources */,
2843EB5218D4CFC700F13E2B /* OthersFormViewController.m in Sources */,
2843EB4B18D496F600F13E2B /* SelectorsFormViewController.m in Sources */,
28468EA418EF41D300DBB015 /* InputsFormViewController.m in Sources */,
@@ -639,23 +645,37 @@
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
COPY_PHASE_STRIP = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
ENABLE_TESTABILITY = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_DYNAMIC_NO_PIC = NO;
GCC_NO_COMMON_BLOCKS = YES;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PREPROCESSOR_DEFINITIONS = (
"DEBUG=1",
@@ -668,7 +688,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
};
@@ -678,29 +698,43 @@
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
COPY_PHASE_STRIP = YES;
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_NO_COMMON_BLOCKS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
SDKROOT = iphoneos;
VALIDATE_PRODUCT = YES;
};
@@ -708,14 +742,14 @@
};
2850C62518D0F707002B7D0A /* Debug */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = 7B0D2D6A86E2A41ED22E8A35 /* Pods.debug.xcconfig */;
baseConfigurationReference = 5F6FC67A75254B60005DC716 /* Pods-XLForm.debug.xcconfig */;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "XLForm/XLForm-Prefix.pch";
INFOPLIST_FILE = "XLForm/XLForm-Info.plist";
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
PRODUCT_BUNDLE_IDENTIFIER = "com.xmartlabs.$(PRODUCT_NAME:rfc1034identifier)";
PRODUCT_NAME = "$(TARGET_NAME)";
TARGETED_DEVICE_FAMILY = "1,2";
@@ -725,14 +759,15 @@
};
2850C62618D0F707002B7D0A /* Release */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = 976A33EE62A018A7257B4878 /* Pods.release.xcconfig */;
baseConfigurationReference = B98C1213E7C714A861219C81 /* Pods-XLForm.release.xcconfig */;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution";
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "XLForm/XLForm-Prefix.pch";
INFOPLIST_FILE = "XLForm/XLForm-Info.plist";
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
PRODUCT_BUNDLE_IDENTIFIER = "com.xmartlabs.$(PRODUCT_NAME:rfc1034identifier)";
PRODUCT_NAME = "$(TARGET_NAME)";
TARGETED_DEVICE_FAMILY = "1,2";
@@ -1,5 +1,15 @@
{
"images" : [
{
"idiom" : "iphone",
"size" : "20x20",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "20x20",
"scale" : "3x"
},
{
"idiom" : "iphone",
"size" : "29x29",
@@ -48,6 +58,16 @@
"size" : "60x60",
"scale" : "3x"
},
{
"idiom" : "ipad",
"size" : "20x20",
"scale" : "1x"
},
{
"idiom" : "ipad",
"size" : "20x20",
"scale" : "2x"
},
{
"idiom" : "ipad",
"size" : "29x29",
@@ -101,8 +121,13 @@
"scale" : "2x"
},
{
"idiom" : "car",
"size" : "120x120",
"idiom" : "ipad",
"size" : "83.5x83.5",
"scale" : "2x"
},
{
"idiom" : "ios-marketing",
"size" : "1024x1024",
"scale" : "1x"
},
{
@@ -142,8 +167,15 @@
"size" : "44x44",
"idiom" : "watch",
"scale" : "2x",
"role" : "longLook",
"subtype" : "42mm"
"role" : "appLauncher",
"subtype" : "40mm"
},
{
"size" : "50x50",
"idiom" : "watch",
"scale" : "2x",
"role" : "appLauncher",
"subtype" : "44mm"
},
{
"size" : "86x86",
@@ -158,6 +190,30 @@
"scale" : "2x",
"role" : "quickLook",
"subtype" : "42mm"
},
{
"size" : "108x108",
"idiom" : "watch",
"scale" : "2x",
"role" : "quickLook",
"subtype" : "44mm"
},
{
"idiom" : "watch-marketing",
"size" : "1024x1024",
"scale" : "1x"
},
{
"idiom" : "car",
"size" : "120x120",
"scale" : "1x"
},
{
"size" : "44x44",
"idiom" : "watch",
"scale" : "2x",
"role" : "longLook",
"subtype" : "42mm"
}
],
"info" : {
+1 -1
View File
@@ -1,4 +1,4 @@
platform :ios, '8.0'
platform :ios, '9.0'
target 'SwiftExample' do
@@ -38,8 +38,8 @@
28D8326C1AEC177E009E3B3F /* ValidationExamplesFormViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 28D8326B1AEC177E009E3B3F /* ValidationExamplesFormViewController.swift */; };
28D8326F1AEC2D1B009E3B3F /* UICustomizationFormViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 28D8326E1AEC2D1B009E3B3F /* UICustomizationFormViewController.swift */; };
28F490221AAFBBC600C8E0CC /* DatesFormViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 28F490211AAFBBC600C8E0CC /* DatesFormViewController.swift */; };
649437BA8D5B7C59BBDB7B92 /* libPods-SwiftExample.a in Frameworks */ = {isa = PBXBuildFile; fileRef = E006C7F7FF8E967AA8661BC9 /* libPods-SwiftExample.a */; };
BF01E92B1C21FF2800BDE045 /* InlineSegmentedCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = BF01E92A1C21FF2800BDE045 /* InlineSegmentedCell.swift */; };
DD7B43598E698717584375E9 /* libPods-SwiftExample.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 9CFB9BA3A82D5F6FE7CCE5A5 /* libPods-SwiftExample.a */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
@@ -77,10 +77,10 @@
28D8326B1AEC177E009E3B3F /* ValidationExamplesFormViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ValidationExamplesFormViewController.swift; sourceTree = "<group>"; };
28D8326E1AEC2D1B009E3B3F /* UICustomizationFormViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = UICustomizationFormViewController.swift; sourceTree = "<group>"; };
28F490211AAFBBC600C8E0CC /* DatesFormViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; lineEnding = 0; path = DatesFormViewController.swift; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.swift; };
2EB9C638FC2450A0B9786D1E /* Pods-SwiftExample.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-SwiftExample.release.xcconfig"; path = "Pods/Target Support Files/Pods-SwiftExample/Pods-SwiftExample.release.xcconfig"; sourceTree = "<group>"; };
420D9BAB7B0D2AF9487DD060 /* Pods-SwiftExample.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-SwiftExample.debug.xcconfig"; path = "Pods/Target Support Files/Pods-SwiftExample/Pods-SwiftExample.debug.xcconfig"; sourceTree = "<group>"; };
9CFB9BA3A82D5F6FE7CCE5A5 /* libPods-SwiftExample.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-SwiftExample.a"; sourceTree = BUILT_PRODUCTS_DIR; };
BF01E92A1C21FF2800BDE045 /* InlineSegmentedCell.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = InlineSegmentedCell.swift; path = InlineSegmentedCell/InlineSegmentedCell.swift; sourceTree = "<group>"; };
CD0A6F89B9CD5843CA297E52 /* Pods-SwiftExample.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-SwiftExample.release.xcconfig"; path = "Pods/Target Support Files/Pods-SwiftExample/Pods-SwiftExample.release.xcconfig"; sourceTree = "<group>"; };
E006C7F7FF8E967AA8661BC9 /* libPods-SwiftExample.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-SwiftExample.a"; sourceTree = BUILT_PRODUCTS_DIR; };
F019783EE34BD17E2BA41467 /* Pods-SwiftExample.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-SwiftExample.debug.xcconfig"; path = "Pods/Target Support Files/Pods-SwiftExample/Pods-SwiftExample.debug.xcconfig"; sourceTree = "<group>"; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
@@ -88,7 +88,7 @@
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
DD7B43598E698717584375E9 /* libPods-SwiftExample.a in Frameworks */,
649437BA8D5B7C59BBDB7B92 /* libPods-SwiftExample.a in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -100,8 +100,8 @@
children = (
2847A6A01AAF2679000A2ABE /* SwiftExample */,
2847A69F1AAF2679000A2ABE /* Products */,
7A12A831117D9B4D152E0A51 /* Pods */,
402AE3EC1FACD058DCF0A2D3 /* Frameworks */,
E9F3DD7ACEF5AAF92FCE6E24 /* Pods */,
3D93F92C6A8B49B82B452B67 /* Frameworks */,
);
sourceTree = "<group>";
};
@@ -324,23 +324,14 @@
path = SwiftExample/Dates;
sourceTree = SOURCE_ROOT;
};
402AE3EC1FACD058DCF0A2D3 /* Frameworks */ = {
3D93F92C6A8B49B82B452B67 /* Frameworks */ = {
isa = PBXGroup;
children = (
9CFB9BA3A82D5F6FE7CCE5A5 /* libPods-SwiftExample.a */,
E006C7F7FF8E967AA8661BC9 /* libPods-SwiftExample.a */,
);
name = Frameworks;
sourceTree = "<group>";
};
7A12A831117D9B4D152E0A51 /* Pods */ = {
isa = PBXGroup;
children = (
420D9BAB7B0D2AF9487DD060 /* Pods-SwiftExample.debug.xcconfig */,
2EB9C638FC2450A0B9786D1E /* Pods-SwiftExample.release.xcconfig */,
);
name = Pods;
sourceTree = "<group>";
};
BF01E9291C21FEF700BDE045 /* Inline Segmented */ = {
isa = PBXGroup;
children = (
@@ -349,6 +340,15 @@
name = "Inline Segmented";
sourceTree = "<group>";
};
E9F3DD7ACEF5AAF92FCE6E24 /* Pods */ = {
isa = PBXGroup;
children = (
F019783EE34BD17E2BA41467 /* Pods-SwiftExample.debug.xcconfig */,
CD0A6F89B9CD5843CA297E52 /* Pods-SwiftExample.release.xcconfig */,
);
name = Pods;
sourceTree = "<group>";
};
/* End PBXGroup section */
/* Begin PBXNativeTarget section */
@@ -356,11 +356,11 @@
isa = PBXNativeTarget;
buildConfigurationList = 2847A6BD1AAF2679000A2ABE /* Build configuration list for PBXNativeTarget "SwiftExample" */;
buildPhases = (
21FCE00817B1AE1029F382A4 /* Check Pods Manifest.lock */,
89E8536C00EFF5D0377E1AE9 /* [CP] Check Pods Manifest.lock */,
2847A69A1AAF2679000A2ABE /* Sources */,
2847A69B1AAF2679000A2ABE /* Frameworks */,
2847A69C1AAF2679000A2ABE /* Resources */,
A0F2DA95250A4C3E69515D96 /* Copy Pods Resources */,
DC50100813F1902A0CFCE009 /* [CP] Copy Pods Resources */,
);
buildRules = (
);
@@ -379,17 +379,18 @@
attributes = {
LastSwiftMigration = 0700;
LastSwiftUpdateCheck = 0700;
LastUpgradeCheck = 0700;
LastUpgradeCheck = 1200;
ORGANIZATIONNAME = Xmartlabs;
TargetAttributes = {
2847A69D1AAF2679000A2ABE = {
CreatedOnToolsVersion = 6.2;
LastSwiftMigration = 1100;
};
};
};
buildConfigurationList = 2847A6991AAF2679000A2ABE /* Build configuration list for PBXProject "SwiftExample" */;
compatibilityVersion = "Xcode 3.2";
developmentRegion = English;
developmentRegion = en;
hasScannedForEncodings = 0;
knownRegions = (
en,
@@ -421,34 +422,40 @@
/* End PBXResourcesBuildPhase section */
/* Begin PBXShellScriptBuildPhase section */
21FCE00817B1AE1029F382A4 /* Check Pods Manifest.lock */ = {
89E8536C00EFF5D0377E1AE9 /* [CP] Check Pods Manifest.lock */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
"${PODS_PODFILE_DIR_PATH}/Podfile.lock",
"${PODS_ROOT}/Manifest.lock",
);
name = "Check Pods Manifest.lock";
name = "[CP] Check Pods Manifest.lock";
outputPaths = (
"$(DERIVED_FILE_DIR)/Pods-SwiftExample-checkManifestLockResult.txt",
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [[ $? != 0 ]] ; then\n cat << EOM\nerror: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\nEOM\n exit 1\nfi\n";
shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n";
showEnvVarsInLog = 0;
};
A0F2DA95250A4C3E69515D96 /* Copy Pods Resources */ = {
DC50100813F1902A0CFCE009 /* [CP] Copy Pods Resources */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
"${PODS_ROOT}/Target Support Files/Pods-SwiftExample/Pods-SwiftExample-resources.sh",
"${PODS_ROOT}/../../../XLForm/XLForm.bundle",
);
name = "Copy Pods Resources";
name = "[CP] Copy Pods Resources";
outputPaths = (
"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/XLForm.bundle",
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-SwiftExample/Pods-SwiftExample-resources.sh\"\n";
shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-SwiftExample/Pods-SwiftExample-resources.sh\"\n";
showEnvVarsInLog = 0;
};
/* End PBXShellScriptBuildPhase section */
@@ -495,17 +502,29 @@
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
@@ -514,6 +533,7 @@
ENABLE_TESTABILITY = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_DYNAMIC_NO_PIC = NO;
GCC_NO_COMMON_BLOCKS = YES;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PREPROCESSOR_DEFINITIONS = (
"DEBUG=1",
@@ -526,7 +546,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 8.4;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
@@ -539,17 +559,29 @@
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
@@ -557,15 +589,17 @@
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_NO_COMMON_BLOCKS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 8.4;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule";
TARGETED_DEVICE_FAMILY = "1,2";
VALIDATE_PRODUCT = YES;
};
@@ -573,7 +607,7 @@
};
2847A6BE1AAF2679000A2ABE /* Debug */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = 420D9BAB7B0D2AF9487DD060 /* Pods-SwiftExample.debug.xcconfig */;
baseConfigurationReference = F019783EE34BD17E2BA41467 /* Pods-SwiftExample.debug.xcconfig */;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
@@ -582,12 +616,14 @@
PRODUCT_BUNDLE_IDENTIFIER = "com.xmartlabs.$(PRODUCT_NAME:rfc1034identifier)";
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_OBJC_BRIDGING_HEADER = "SwiftExample/SwiftExample-Bridging-Header.h";
SWIFT_SWIFT3_OBJC_INFERENCE = Default;
SWIFT_VERSION = 5.0;
};
name = Debug;
};
2847A6BF1AAF2679000A2ABE /* Release */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = 2EB9C638FC2450A0B9786D1E /* Pods-SwiftExample.release.xcconfig */;
baseConfigurationReference = CD0A6F89B9CD5843CA297E52 /* Pods-SwiftExample.release.xcconfig */;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
@@ -596,6 +632,8 @@
PRODUCT_BUNDLE_IDENTIFIER = "com.xmartlabs.$(PRODUCT_NAME:rfc1034identifier)";
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_OBJC_BRIDGING_HEADER = "SwiftExample/SwiftExample-Bridging-Header.h";
SWIFT_SWIFT3_OBJC_INFERENCE = Default;
SWIFT_VERSION = 5.0;
};
name = Release;
};
@@ -28,7 +28,7 @@
class AccessoryViewFormViewController : XLFormViewController {
private struct Tags {
fileprivate struct Tags {
static let AccessoryViewRowNavigationEnabled = "RowNavigationEnabled"
static let AccessoryViewRowNavigationShowAccessoryView = "RowNavigationShowAccessoryView"
static let AccessoryViewRowNavigationStopDisableRow = "rowNavigationStopDisableRow"
@@ -44,7 +44,7 @@ class AccessoryViewFormViewController : XLFormViewController {
static let AccessoryViewNotes = "notes"
}
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: NSBundle?) {
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
initializeForm()
}
@@ -61,7 +61,7 @@ class AccessoryViewFormViewController : XLFormViewController {
var row : XLFormRowDescriptor
form = XLFormDescriptor(title: "Accessory View")
form.rowNavigationOptions = .Enabled
form.rowNavigationOptions = .enabled
// Configuration section
section = XLFormSectionDescriptor()
@@ -76,25 +76,25 @@ class AccessoryViewFormViewController : XLFormViewController {
// RowNavigationShowAccessoryView
row = XLFormRowDescriptor(tag: Tags.AccessoryViewRowNavigationShowAccessoryView, rowType:XLFormRowDescriptorTypeBooleanCheck, title:"Show input accessory row?")
row.value = form.rowNavigationOptions.contains(.Enabled)
row.value = form.rowNavigationOptions.contains(.enabled)
row.hidden = "$\(Tags.AccessoryViewRowNavigationEnabled) == 0"
section.addFormRow(row)
// RowNavigationStopDisableRow
row = XLFormRowDescriptor(tag: Tags.AccessoryViewRowNavigationStopDisableRow, rowType: XLFormRowDescriptorTypeBooleanCheck, title:"Stop when reach disabled row?")
row.value = form.rowNavigationOptions.contains(.StopDisableRow)
row.value = form.rowNavigationOptions.contains(.stopDisableRow)
row.hidden = "$\(Tags.AccessoryViewRowNavigationEnabled) == 0"
section.addFormRow(row)
// RowNavigationStopInlineRow
row = XLFormRowDescriptor(tag: Tags.AccessoryViewRowNavigationStopInlineRow, rowType: XLFormRowDescriptorTypeBooleanCheck, title: "Stop when reach inline row?")
row.value = form.rowNavigationOptions.contains(.StopInlineRow)
row.value = form.rowNavigationOptions.contains(.stopInlineRow)
row.hidden = "$\(Tags.AccessoryViewRowNavigationEnabled) == 0"
section.addFormRow(row)
// RowNavigationSkipCanNotBecomeFirstResponderRow
row = XLFormRowDescriptor(tag: Tags.AccessoryViewRowNavigationSkipCanNotBecomeFirstResponderRow, rowType:XLFormRowDescriptorTypeBooleanCheck, title:"Skip Can Not Become First Responder Row?")
row.value = form.rowNavigationOptions.contains(XLFormRowNavigationOptions.SkipCanNotBecomeFirstResponderRow)
row.value = form.rowNavigationOptions.contains(XLFormRowNavigationOptions.skipCanNotBecomeFirstResponderRow)
row.hidden = "$\(Tags.AccessoryViewRowNavigationEnabled) == 0"
section.addFormRow(row)
@@ -103,18 +103,18 @@ class AccessoryViewFormViewController : XLFormViewController {
// Name
row = XLFormRowDescriptor(tag: Tags.AccessoryViewName, rowType: XLFormRowDescriptorTypeText, title: "Name")
row.required = true
row.isRequired = true
section.addFormRow(row)
// Email
row = XLFormRowDescriptor(tag: Tags.AccessoryViewEmail, rowType: XLFormRowDescriptorTypeEmail, title: "Email")
// validate the email
row.addValidator(XLFormValidator.emailValidator())
row.addValidator(XLFormValidator.email())
section.addFormRow(row)
// Twitter
row = XLFormRowDescriptor(tag: Tags.AccessoryViewTwitter, rowType: XLFormRowDescriptorTypeTwitter, title: "Twitter")
row.disabled = NSNumber(bool: true)
row.disabled = NSNumber(value: true as Bool)
row.value = "@no_editable"
section.addFormRow(row)
@@ -125,7 +125,7 @@ class AccessoryViewFormViewController : XLFormViewController {
// Date
row = XLFormRowDescriptor(tag: Tags.AccessoryViewDate, rowType:XLFormRowDescriptorTypeDateInline, title:"Date Inline")
row.value = NSDate()
row.value = Date()
section.addFormRow(row)
@@ -152,43 +152,43 @@ class AccessoryViewFormViewController : XLFormViewController {
}
override func inputAccessoryViewForRowDescriptor(rowDescriptor: XLFormRowDescriptor!) -> UIView! {
if form.formRowWithTag(Tags.AccessoryViewRowNavigationShowAccessoryView)!.value!.boolValue == false {
override func inputAccessoryView(for rowDescriptor: XLFormRowDescriptor!) -> UIView! {
if (form.formRow(withTag: Tags.AccessoryViewRowNavigationShowAccessoryView)!.value! as AnyObject).boolValue == false {
return nil
}
return super.inputAccessoryViewForRowDescriptor(rowDescriptor)
return super.inputAccessoryView(for: rowDescriptor)
}
//MARK: XLFormDescriptorDelegate
override func formRowDescriptorValueHasChanged(formRow: XLFormRowDescriptor!, oldValue: AnyObject!, newValue: AnyObject!) {
override func formRowDescriptorValueHasChanged(_ formRow: XLFormRowDescriptor!, oldValue: Any!, newValue: Any!) {
super.formRowDescriptorValueHasChanged(formRow, oldValue: oldValue, newValue: newValue)
if formRow.tag == Tags.AccessoryViewRowNavigationStopDisableRow {
if formRow.value!.boolValue == true {
form.rowNavigationOptions = form.rowNavigationOptions.union(.StopDisableRow)
if (formRow.value! as AnyObject).boolValue == true {
form.rowNavigationOptions = form.rowNavigationOptions.union(.stopDisableRow)
}
else{
form.rowNavigationOptions = form.rowNavigationOptions.subtract(.StopDisableRow)
form.rowNavigationOptions = form.rowNavigationOptions.subtracting(.stopDisableRow)
}
}
else if formRow.tag == Tags.AccessoryViewRowNavigationStopInlineRow {
if formRow.value!.boolValue == true {
form.rowNavigationOptions = form.rowNavigationOptions.union(.StopInlineRow)
if (formRow.value! as AnyObject).boolValue == true {
form.rowNavigationOptions = form.rowNavigationOptions.union(.stopInlineRow)
}
else{
var options = form.rowNavigationOptions
options = options.subtract(XLFormRowNavigationOptions.StopInlineRow)
options = options.subtracting(XLFormRowNavigationOptions.stopInlineRow)
form.rowNavigationOptions = options
}
}
else if formRow.tag == Tags.AccessoryViewRowNavigationSkipCanNotBecomeFirstResponderRow {
if formRow.value!.boolValue == true {
form.rowNavigationOptions = form.rowNavigationOptions.union(.SkipCanNotBecomeFirstResponderRow)
if (formRow.value! as AnyObject).boolValue == true {
form.rowNavigationOptions = form.rowNavigationOptions.union(.skipCanNotBecomeFirstResponderRow)
}
else{
var options = form.rowNavigationOptions
options = options.subtract(.SkipCanNotBecomeFirstResponderRow)
options = options.subtracting(.skipCanNotBecomeFirstResponderRow)
form.rowNavigationOptions = options
}
}
+10 -10
View File
@@ -14,20 +14,20 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
var window: UIWindow?
func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: [NSObject: AnyObject]?) -> Bool {
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
// Declare custom rows
XLFormViewController.cellClassesForRowDescriptorTypes()[XLFormRowDescriptorTypeRate] = "XLFormRatingCell"
XLFormViewController.cellClassesForRowDescriptorTypes()[XLFormRowDescriptorTypeRate] = NSStringFromClass(XLFormRatingCell.self)
XLFormViewController.cellClassesForRowDescriptorTypes()[XLFormRowDescriptorTypeFloatLabeledTextField] = FloatLabeledTextFieldCell.self
XLFormViewController.cellClassesForRowDescriptorTypes()[XLFormRowDescriptorTypeWeekDays] = "XLFormWeekDaysCell"
XLFormViewController.cellClassesForRowDescriptorTypes()[XLFormRowDescriptorTypeWeekDays] = NSStringFromClass(XLFormWeekDaysCell.self)
XLFormViewController.cellClassesForRowDescriptorTypes()[XLFormRowDescriptorTypeSegmentedInline] = InlineSegmentedCell.self
XLFormViewController.cellClassesForRowDescriptorTypes()[XLFormRowDescriptorTypeSegmentedControl] = InlineSegmentedControl.self
XLFormViewController.inlineRowDescriptorTypesForRowDescriptorTypes()[XLFormRowDescriptorTypeSegmentedInline] = XLFormRowDescriptorTypeSegmentedControl
// Override point for customization after application launch.
self.window = UIWindow.init(frame: UIScreen.mainScreen().bounds)
self.window = UIWindow.init(frame: UIScreen.main.bounds)
// Override point for customization after application launch.
self.window!.backgroundColor = .whiteColor()
self.window!.backgroundColor = .white
// load the initial form form Storybiard
let storyboard = UIStoryboard.init(name:"iPhoneStoryboard", bundle:nil)
@@ -36,25 +36,25 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
return true
}
func applicationWillResignActive(application: UIApplication) {
func applicationWillResignActive(_ application: UIApplication) {
// Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state.
// Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game.
}
func applicationDidEnterBackground(application: UIApplication) {
func applicationDidEnterBackground(_ application: UIApplication) {
// Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later.
// If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits.
}
func applicationWillEnterForeground(application: UIApplication) {
func applicationWillEnterForeground(_ application: UIApplication) {
// Called as part of the transition from the background to the inactive state here you can undo many of the changes made on entering the background.
}
func applicationDidBecomeActive(application: UIApplication) {
func applicationDidBecomeActive(_ application: UIApplication) {
// Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface.
}
func applicationWillTerminate(application: UIApplication) {
func applicationWillTerminate(_ application: UIApplication) {
// Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:.
}
@@ -24,7 +24,7 @@
class CustomRowsViewController : XLFormViewController {
private struct Tags {
fileprivate struct Tags {
static let CustomRowFirstRatingTag = "CustomRowFirstRatingTag"
static let CustomRowSecondRatingTag = "CustomRowSecondRatingTag"
static let CustomRowFloatLabeledTextFieldTag = "CustomRowFloatLabeledTextFieldTag"
@@ -33,7 +33,7 @@ class CustomRowsViewController : XLFormViewController {
static let CustomRowInline = "CustomRowInline"
}
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: NSBundle?) {
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
self.initializeForm()
}
@@ -64,7 +64,7 @@ class CustomRowsViewController : XLFormViewController {
section.addFormRow(row)
// Section Float Labeled Text Field
section = XLFormSectionDescriptor.formSectionWithTitle("Float Labeled Text Field")
section = XLFormSectionDescriptor.formSection(withTitle: "Float Labeled Text Field")
form.addFormSection(section)
row = XLFormRowDescriptor(tag: Tags.CustomRowFloatLabeledTextFieldTag, rowType: XLFormRowDescriptorTypeFloatLabeledTextField, title: "Title")
@@ -77,23 +77,23 @@ class CustomRowsViewController : XLFormViewController {
section.addFormRow(row)
section = XLFormSectionDescriptor.formSectionWithTitle("Weekdays")
section = XLFormSectionDescriptor.formSection(withTitle: "Weekdays")
form.addFormSection(section)
// WeekDays
row = XLFormRowDescriptor(tag: Tags.CustomRowWeekdays, rowType: XLFormRowDescriptorTypeWeekDays)
row.value = [
XLFormWeekDaysCell.kWeekDay.Sunday.description(): false,
XLFormWeekDaysCell.kWeekDay.Monday.description(): true,
XLFormWeekDaysCell.kWeekDay.Tuesday.description(): true,
XLFormWeekDaysCell.kWeekDay.Wednesday.description(): false,
XLFormWeekDaysCell.kWeekDay.Thursday.description(): false,
XLFormWeekDaysCell.kWeekDay.Friday.description(): false,
XLFormWeekDaysCell.kWeekDay.Saturday.description(): false
XLFormWeekDaysCell.kWeekDay.sunday.description(): false,
XLFormWeekDaysCell.kWeekDay.monday.description(): true,
XLFormWeekDaysCell.kWeekDay.tuesday.description(): true,
XLFormWeekDaysCell.kWeekDay.wednesday.description(): false,
XLFormWeekDaysCell.kWeekDay.thursday.description(): false,
XLFormWeekDaysCell.kWeekDay.friday.description(): false,
XLFormWeekDaysCell.kWeekDay.saturday.description(): false
]
section.addFormRow(row)
section = XLFormSectionDescriptor.formSectionWithTitle("Custom inline row")
section = XLFormSectionDescriptor.formSection(withTitle: "Custom inline row")
form.addFormSection(section)
// Inline
@@ -35,9 +35,9 @@ class FloatLabeledTextFieldCell : XLFormBaseCell, UITextFieldDelegate {
lazy var floatLabeledTextField: JVFloatLabeledTextField = {
let result = JVFloatLabeledTextField(frame: CGRect.zero)
result.translatesAutoresizingMaskIntoConstraints = false
result.font = UIFont.systemFontOfSize(kFontSize)
result.floatingLabel.font = .boldSystemFontOfSize(kFontSize)
result.clearButtonMode = .WhileEditing
result.font = UIFont.systemFont(ofSize: FloatLabeledTextFieldCell.kFontSize)
result.floatingLabel.font = .boldSystemFont(ofSize: FloatLabeledTextFieldCell.kFontSize)
result.clearButtonMode = .whileEditing
return result
}()
@@ -45,7 +45,7 @@ class FloatLabeledTextFieldCell : XLFormBaseCell, UITextFieldDelegate {
override func configure() {
super.configure()
selectionStyle = .None
selectionStyle = .none
contentView.addSubview(self.floatLabeledTextField)
floatLabeledTextField.delegate = self
contentView.addConstraints(layoutConstraints())
@@ -54,15 +54,15 @@ class FloatLabeledTextFieldCell : XLFormBaseCell, UITextFieldDelegate {
override func update() {
super.update()
if let rowDescriptor = rowDescriptor {
floatLabeledTextField.attributedPlaceholder = NSAttributedString(string: rowDescriptor.title ?? "" , attributes: [NSForegroundColorAttributeName: UIColor.lightGrayColor()])
floatLabeledTextField.attributedPlaceholder = NSAttributedString(string: rowDescriptor.title ?? "" , attributes: [NSAttributedString.Key.foregroundColor: UIColor.lightGray])
if let value = rowDescriptor.value {
floatLabeledTextField.text = value.displayText()
floatLabeledTextField.text = (value as AnyObject).displayText()
}
else {
floatLabeledTextField.text = rowDescriptor.noValueDisplayText
}
floatLabeledTextField.enabled = !rowDescriptor.isDisabled()
floatLabeledTextField.floatingLabelTextColor = .lightGrayColor()
floatLabeledTextField.isEnabled = !rowDescriptor.isDisabled()
floatLabeledTextField.floatingLabelTextColor = .lightGray
floatLabeledTextField.alpha = rowDescriptor.isDisabled() ? 0.6 : 1.0
}
}
@@ -76,7 +76,7 @@ class FloatLabeledTextFieldCell : XLFormBaseCell, UITextFieldDelegate {
return self.floatLabeledTextField.becomeFirstResponder()
}
override static func formDescriptorCellHeightForRowDescriptor(rowDescriptor: XLFormRowDescriptor!) -> CGFloat {
override static func formDescriptorCellHeight(for rowDescriptor: XLFormRowDescriptor!) -> CGFloat {
return 55.0
}
@@ -86,12 +86,12 @@ class FloatLabeledTextFieldCell : XLFormBaseCell, UITextFieldDelegate {
func layoutConstraints() -> [NSLayoutConstraint]{
let views = ["floatLabeledTextField" : floatLabeledTextField]
let metrics = ["hMargin": 15.0, "vMargin": 8.0]
var result = NSLayoutConstraint.constraintsWithVisualFormat("H:|-(hMargin)-[floatLabeledTextField]-(hMargin)-|", options:.AlignAllCenterY, metrics:metrics, views:views)
result += NSLayoutConstraint.constraintsWithVisualFormat("V:|-(vMargin)-[floatLabeledTextField]-(vMargin)-|", options:.AlignAllCenterX, metrics:metrics, views:views)
var result = NSLayoutConstraint.constraints(withVisualFormat: "H:|-(hMargin)-[floatLabeledTextField]-(hMargin)-|", options:.alignAllCenterY, metrics:metrics, views:views)
result += NSLayoutConstraint.constraints(withVisualFormat: "V:|-(vMargin)-[floatLabeledTextField]-(vMargin)-|", options:.alignAllCenterX, metrics:metrics, views:views)
return result
}
func textFieldDidChange(textField : UITextField) {
func textFieldDidChange(_ textField : UITextField) {
if floatLabeledTextField == textField {
if let rowDescriptor = rowDescriptor, let text = self.floatLabeledTextField.text {
if text.isEmpty == false {
@@ -105,34 +105,34 @@ class FloatLabeledTextFieldCell : XLFormBaseCell, UITextFieldDelegate {
//Mark: UITextFieldDelegate
func textFieldShouldClear(textField: UITextField) -> Bool {
func textFieldShouldClear(_ textField: UITextField) -> Bool {
return self.formViewController().textFieldShouldClear(textField)
}
func textFieldShouldReturn(textField: UITextField) -> Bool {
func textFieldShouldReturn(_ textField: UITextField) -> Bool {
return self.formViewController().textFieldShouldReturn(textField)
}
func textFieldShouldBeginEditing(textField: UITextField) -> Bool {
func textFieldShouldBeginEditing(_ textField: UITextField) -> Bool {
return self.formViewController().textFieldShouldBeginEditing(textField)
}
func textFieldShouldEndEditing(textField: UITextField) -> Bool {
func textFieldShouldEndEditing(_ textField: UITextField) -> Bool {
return self.formViewController().textFieldShouldEndEditing(textField)
}
func textField(textField: UITextField, shouldChangeCharactersInRange range: NSRange, replacementString string: String) -> Bool {
return self.formViewController().textField(textField, shouldChangeCharactersInRange: range, replacementString: string)
func textField(_ textField: UITextField, shouldChangeCharactersIn range: NSRange, replacementString string: String) -> Bool {
return self.formViewController().textField(textField, shouldChangeCharactersIn: range, replacementString: string)
}
func textFieldDidBeginEditing(textField: UITextField) {
func textFieldDidBeginEditing(_ textField: UITextField) {
self.formViewController().textFieldDidBeginEditing(textField)
}
func textFieldDidEndEditing(textField: UITextField) {
func textFieldDidEndEditing(_ textField: UITextField) {
self.textFieldDidChange(textField)
self.formViewController().textFieldDidEndEditing(textField)
}
@@ -14,18 +14,18 @@ let XLFormRowDescriptorTypeSegmentedControl = "XLFormRowDescriptorTypeSegmentedC
class InlineSegmentedCell : XLFormBaseCell {
override func canBecomeFirstResponder() -> Bool {
override var canBecomeFirstResponder : Bool {
return true
}
override func becomeFirstResponder() -> Bool {
if isFirstResponder() {
if isFirstResponder {
return super.becomeFirstResponder()
}
let result = super.becomeFirstResponder()
if result {
let inlineRowDescriptor : XLFormRowDescriptor = XLFormRowDescriptor(tag: nil, rowType: XLFormViewController.inlineRowDescriptorTypesForRowDescriptorTypes()![rowDescriptor!.rowType] as! String)
let cell = inlineRowDescriptor.cellForFormController(formViewController())
let cell = inlineRowDescriptor.cell(forForm: formViewController())
let inlineCell = cell as? XLFormInlineRowDescriptorCell
inlineCell?.inlineRowDescriptor = rowDescriptor
rowDescriptor?.sectionDescriptor.addFormRow(inlineRowDescriptor, afterRow: rowDescriptor!)
@@ -35,13 +35,13 @@ class InlineSegmentedCell : XLFormBaseCell {
}
override func resignFirstResponder() -> Bool {
if isFirstResponder() {
if !isFirstResponder {
return super.resignFirstResponder()
}
let selectedRowPath : NSIndexPath = formViewController().form.indexPathOfFormRow(rowDescriptor!)!
let nextRowPath = NSIndexPath(forRow: selectedRowPath.row + 1, inSection: selectedRowPath.section)
let nextFormRow = formViewController().form.formRowAtIndex(nextRowPath)
let section : XLFormSectionDescriptor = formViewController().form.formSectionAtIndex(UInt(nextRowPath.section))!
let selectedRowPath : IndexPath = formViewController().form.indexPath(ofFormRow: rowDescriptor!)!
let nextRowPath = IndexPath(row: (selectedRowPath as NSIndexPath).row + 1, section: (selectedRowPath as NSIndexPath).section)
let nextFormRow = formViewController().form.formRow(atIndex: nextRowPath)
let section : XLFormSectionDescriptor = formViewController().form.formSection(at: UInt((nextRowPath as NSIndexPath).section))!
let result = super.resignFirstResponder()
if result {
section.removeFormRow(nextFormRow!)
@@ -56,8 +56,8 @@ class InlineSegmentedCell : XLFormBaseCell {
}
override func formDescriptorCellBecomeFirstResponder() -> Bool {
if isFirstResponder() {
resignFirstResponder()
if isFirstResponder {
_ = resignFirstResponder()
return false
}
return becomeFirstResponder()
@@ -65,20 +65,20 @@ class InlineSegmentedCell : XLFormBaseCell {
override func update() {
super.update()
accessoryType = .None
editingAccessoryType = .None
selectionStyle = .None
accessoryType = .none
editingAccessoryType = .none
selectionStyle = .none
textLabel?.text = rowDescriptor?.title
detailTextLabel?.text = valueDisplayText()
}
override func formDescriptorCellDidSelectedWithFormController(controller: XLFormViewController!) {
controller.tableView.deselectRowAtIndexPath(controller.form.indexPathOfFormRow(rowDescriptor!)!, animated: true)
override func formDescriptorCellDidSelected(withForm controller: XLFormViewController!) {
controller.tableView.deselectRow(at: controller.form.indexPath(ofFormRow: rowDescriptor!)!, animated: true)
}
func valueDisplayText() -> String? {
if let value = rowDescriptor?.value {
return value.displayText()
return (value as AnyObject).displayText()
}
return rowDescriptor?.noValueDisplayText
}
@@ -88,27 +88,27 @@ class InlineSegmentedControl : XLFormBaseCell, XLFormInlineRowDescriptorCell {
var inlineRowDescriptor : XLFormRowDescriptor?
lazy var segmentedControl : UISegmentedControl = {
return UISegmentedControl.autolayoutView() as! UISegmentedControl
return UISegmentedControl.autolayout()
}()
override func configure() {
super.configure()
selectionStyle = .None
selectionStyle = .none
contentView.addSubview(segmentedControl)
contentView.addConstraints(NSLayoutConstraint.constraintsWithVisualFormat("H:|-[segmentedControl]-|", options: .AlignAllCenterY, metrics: nil, views: ["segmentedControl": segmentedControl]))
segmentedControl.addTarget(self, action: "valueChanged", forControlEvents: .ValueChanged)
contentView.addConstraints(NSLayoutConstraint.constraints(withVisualFormat: "H:|-[segmentedControl]-|", options: .alignAllCenterY, metrics: nil, views: ["segmentedControl": segmentedControl]))
segmentedControl.addTarget(self, action: #selector(InlineSegmentedControl.valueChanged), for: .valueChanged)
}
override func update() {
super.update()
updateSegmentedControl()
segmentedControl.selectedSegmentIndex = selectedIndex()
segmentedControl.enabled = rowDescriptor?.isDisabled() == false
segmentedControl.isEnabled = rowDescriptor?.isDisabled() == false
}
//MARK: Actions
func valueChanged() {
@objc func valueChanged() {
inlineRowDescriptor!.value = inlineRowDescriptor!.selectorOptions![segmentedControl.selectedSegmentIndex]
formViewController().updateFormRow(inlineRowDescriptor)
}
@@ -118,27 +118,27 @@ class InlineSegmentedControl : XLFormBaseCell, XLFormInlineRowDescriptorCell {
func getItems() -> NSMutableArray {
let result = NSMutableArray()
for option in inlineRowDescriptor!.selectorOptions! {
result.addObject(option.displayText())
result.add((option as AnyObject).displayText() ?? "")
}
return result
}
func updateSegmentedControl() {
segmentedControl.removeAllSegments()
getItems().enumerateObjectsUsingBlock { [weak self] object, index, stop in
self?.segmentedControl.insertSegmentWithTitle(object.displayText(), atIndex: index, animated: false)
}
getItems().enumerateObjects({ [weak self] (object, index, stop) in
self?.segmentedControl.insertSegment(withTitle: (object as AnyObject).displayText(), at: index, animated: false)
})
}
func selectedIndex() -> Int {
let formRow = inlineRowDescriptor ?? rowDescriptor
if let value = formRow?.value {
if let value = formRow?.value as? NSObject {
for option in (formRow?.selectorOptions)! {
if option.valueData().isEqual(value.valueData()){
return formRow?.selectorOptions?.indexOf({ $0.isEqual(option) }) ?? -1
if ((option as! NSObject).valueData() as AnyObject) === (value.valueData() as AnyObject) {
return formRow?.selectorOptions?.firstIndex(where: { ($0 as! NSObject) == (option as! NSObject) } ) ?? -1
}
}
}
return -1
}
}
}
@@ -39,7 +39,7 @@ class XLRatingView : AXRatingView {
func customize() {
baseColor = UIColor(red: (205/255.0), green: (201/255.0), blue: (201/255.0), alpha: 1)
highlightColor = UIColor(red: (255/255.0), green: (215/255.0), blue: 0, alpha: 1)
markFont = UIFont.systemFontOfSize(23.0)
markFont = UIFont.systemFont(ofSize: 23.0)
stepInterval = 1.0
}
@@ -34,14 +34,14 @@ class XLFormRatingCell : XLFormBaseCell {
override func configure() {
super.configure()
selectionStyle = .None
ratingView.addTarget(self, action: "rateChanged:", forControlEvents:.ValueChanged)
selectionStyle = .none
ratingView.addTarget(self, action: #selector(XLFormRatingCell.rateChanged(_:)), for:.valueChanged)
}
override func update() {
super.update()
ratingView.value = rowDescriptor!.value!.floatValue
ratingView.value = (rowDescriptor!.value! as AnyObject).floatValue
rateTitle.text = rowDescriptor!.title
ratingView.alpha = rowDescriptor!.isDisabled() ? 0.6 : 1
rateTitle.alpha = rowDescriptor!.isDisabled() ? 0.6 : 1
@@ -49,7 +49,7 @@ class XLFormRatingCell : XLFormBaseCell {
//MARK: Events
func rateChanged(ratingView : XLRatingView){
@objc func rateChanged(_ ratingView : XLRatingView){
rowDescriptor!.value = ratingView.value
}
@@ -30,29 +30,29 @@ class XLFormWeekDaysCell : XLFormBaseCell {
enum kWeekDay: Int {
case
Sunday = 1,
Monday,
Tuesday,
Wednesday,
Thursday,
Friday,
Saturday
sunday = 1,
monday,
tuesday,
wednesday,
thursday,
friday,
saturday
func description() -> String {
switch self {
case .Sunday:
case .sunday:
return "Sunday"
case .Monday:
case .monday:
return "Monday"
case .Tuesday:
case .tuesday:
return "Tuesday"
case .Wednesday:
case .wednesday:
return "Wednesday"
case .Thursday:
case .thursday:
return "Thursday"
case .Friday:
case .friday:
return "Friday"
case .Saturday:
case .saturday:
return "Saturday"
}
}
@@ -60,13 +60,13 @@ class XLFormWeekDaysCell : XLFormBaseCell {
//Add Custom Functions
//Allows for iteration as needed (for in ...)
static let allValues = [Sunday,
Monday,
Tuesday,
Wednesday,
Thursday,
Friday,
Saturday]
static let allValues = [sunday,
monday,
tuesday,
wednesday,
thursday,
friday,
saturday]
}
@IBOutlet weak var sundayButton: UIButton!
@@ -81,7 +81,7 @@ class XLFormWeekDaysCell : XLFormBaseCell {
override func configure() {
super.configure()
selectionStyle = .None
selectionStyle = .none
configureButtons()
}
@@ -91,17 +91,17 @@ class XLFormWeekDaysCell : XLFormBaseCell {
updateButtons()
}
override static func formDescriptorCellHeightForRowDescriptor(rowDescriptor: XLFormRowDescriptor!) -> CGFloat {
override static func formDescriptorCellHeight(for rowDescriptor: XLFormRowDescriptor!) -> CGFloat {
return 60
}
//MARK: - Action
@IBAction func dayTapped(sender: UIButton) {
@IBAction func dayTapped(_ sender: UIButton) {
let day = getDayFormButton(sender)
sender.selected = !sender.selected
sender.isSelected = !sender.isSelected
var newValue = rowDescriptor!.value as! Dictionary<String, Bool>
newValue[day] = sender.selected
newValue[day] = sender.isSelected
rowDescriptor!.value = newValue
}
@@ -110,8 +110,8 @@ class XLFormWeekDaysCell : XLFormBaseCell {
func configureButtons() {
for subview in contentView.subviews {
if let button = subview as? UIButton {
button.setImage(UIImage(named: "uncheckedDay"), forState: .Normal)
button.setImage(UIImage(named: "checkedDay"), forState: .Selected)
button.setImage(UIImage(named: "uncheckedDay"), for: UIControl.State())
button.setImage(UIImage(named: "checkedDay"), for: .selected)
button.adjustsImageWhenHighlighted = false
imageTopTitleBottom(button)
}
@@ -120,15 +120,15 @@ class XLFormWeekDaysCell : XLFormBaseCell {
}
func updateButtons() {
var value = rowDescriptor!.value as! Dictionary<String, Bool>
let value = rowDescriptor!.value as! Dictionary<String, Bool>
sundayButton.selected = value[kWeekDay.Sunday.description()]!
mondayButton.selected = value[kWeekDay.Monday.description()]!
tuesdayButton.selected = value[kWeekDay.Tuesday.description()]!
wednesdayButton.selected = value[kWeekDay.Wednesday.description()]!
thursdayButton.selected = value[kWeekDay.Thursday.description()]!
fridayButton.selected = value[kWeekDay.Friday.description()]!
saturdayButton.selected = value[kWeekDay.Saturday.description()]!
sundayButton.isSelected = value[kWeekDay.sunday.description()]!
mondayButton.isSelected = value[kWeekDay.monday.description()]!
tuesdayButton.isSelected = value[kWeekDay.tuesday.description()]!
wednesdayButton.isSelected = value[kWeekDay.wednesday.description()]!
thursdayButton.isSelected = value[kWeekDay.thursday.description()]!
fridayButton.isSelected = value[kWeekDay.friday.description()]!
saturdayButton.isSelected = value[kWeekDay.saturday.description()]!
sundayButton.alpha = rowDescriptor!.isDisabled() ? 0.6 : 1
mondayButton.alpha = mondayButton.alpha
@@ -139,7 +139,7 @@ class XLFormWeekDaysCell : XLFormBaseCell {
saturdayButton.alpha = mondayButton.alpha
}
func imageTopTitleBottom(button: UIButton) {
func imageTopTitleBottom(_ button: UIButton) {
// the space between the image and text
let spacing : CGFloat = 3.0
@@ -150,26 +150,26 @@ class XLFormWeekDaysCell : XLFormBaseCell {
// raise the image and push it right so it appears centered
// above the text
let titleSize : CGSize = (button.titleLabel!.text! as NSString).sizeWithAttributes([NSFontAttributeName: button.titleLabel!.font])
button.imageEdgeInsets = UIEdgeInsetsMake(-(titleSize.height + spacing), 0.0, 0.0, -titleSize.width)
let titleSize : CGSize = (button.titleLabel!.text! as NSString).size(withAttributes: [NSAttributedString.Key.font: button.titleLabel!.font as Any])
button.imageEdgeInsets = UIEdgeInsets.init(top: -(titleSize.height + spacing), left: 0.0, bottom: 0.0, right: -titleSize.width)
}
func getDayFormButton(button: UIButton) -> String {
func getDayFormButton(_ button: UIButton) -> String {
switch button {
case sundayButton:
return kWeekDay.Sunday.description()
return kWeekDay.sunday.description()
case mondayButton:
return kWeekDay.Monday.description()
return kWeekDay.monday.description()
case tuesdayButton:
return kWeekDay.Tuesday.description()
return kWeekDay.tuesday.description()
case wednesdayButton:
return kWeekDay.Wednesday.description()
return kWeekDay.wednesday.description()
case thursdayButton:
return kWeekDay.Thursday.description()
return kWeekDay.thursday.description()
case fridayButton:
return kWeekDay.Friday.description()
return kWeekDay.friday.description()
default:
return kWeekDay.Saturday.description()
return kWeekDay.saturday.description()
}
}
@@ -28,12 +28,12 @@ import MapKit
class CustomSelectorsFormViewController : XLFormViewController {
private struct Tags {
fileprivate struct Tags {
static let SelectorMap = "selectorMap"
static let SelectorMapPopover = "selectorMapPopover"
}
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: NSBundle?) {
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
initializeForm()
}
@@ -51,7 +51,7 @@ class CustomSelectorsFormViewController : XLFormViewController {
form = XLFormDescriptor(title: "Custom Selectors")
section = XLFormSectionDescriptor.formSectionWithTitle("TextField Types")
section = XLFormSectionDescriptor.formSection(withTitle: "TextField Types")
section.footerTitle = "CustomSelectorsFormViewController.swift"
form.addFormSection(section)
@@ -62,7 +62,7 @@ class CustomSelectorsFormViewController : XLFormViewController {
row.value = CLLocation(latitude: -33, longitude: -56)
section.addFormRow(row)
if UIDevice.currentDevice().userInterfaceIdiom == .Pad {
if UIDevice.current.userInterfaceIdiom == .pad {
// Selector PopOver
row = XLFormRowDescriptor(tag: Tags.SelectorMapPopover, rowType: XLFormRowDescriptorTypeSelectorPopover, title: "Coordinate PopOver")
row.action.viewControllerClass = MapViewController.self
@@ -26,7 +26,7 @@
import MapKit
class CLLocationValueTrasformer : NSValueTransformer {
class CLLocationValueTrasformer : ValueTransformer {
override class func transformedValueClass() -> AnyClass {
return NSString.self
@@ -37,7 +37,7 @@ class CLLocationValueTrasformer : NSValueTransformer {
return false
}
override func transformedValue(value: AnyObject?) -> AnyObject? {
override func transformedValue(_ value: Any?) -> Any? {
if let valueData = value, let location = valueData as? CLLocation{
return String(format: "%0.4f, %0.4f", location.coordinate.latitude, location.coordinate.longitude)
}
@@ -42,11 +42,11 @@ class MapViewController : UIViewController, XLFormRowDescriptorViewController, M
var rowDescriptor: XLFormRowDescriptor?
lazy var mapView : MKMapView = { [unowned self] in
let mapView = MKMapView(frame: self.view.frame)
mapView.autoresizingMask = [UIViewAutoresizing.FlexibleHeight, UIViewAutoresizing.FlexibleWidth]
mapView.autoresizingMask = [UIView.AutoresizingMask.flexibleHeight, UIView.AutoresizingMask.flexibleWidth]
return mapView
}()
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: NSBundle?) {
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
}
@@ -60,7 +60,7 @@ class MapViewController : UIViewController, XLFormRowDescriptorViewController, M
view.addSubview(mapView)
mapView.delegate = self
if let value = rowDescriptor?.value as? CLLocation {
mapView.setCenterCoordinate(value.coordinate, animated: false)
mapView.setCenter(value.coordinate, animated: false)
title = String(format: "%0.4f, %0.4f", mapView.centerCoordinate.latitude, mapView.centerCoordinate.longitude)
let annotation = MapAnnotation()
annotation.coordinate = value.coordinate
@@ -70,18 +70,18 @@ class MapViewController : UIViewController, XLFormRowDescriptorViewController, M
//MARK - - MKMapViewDelegate
func mapView(mapView: MKMapView, viewForAnnotation annotation: MKAnnotation) -> MKAnnotationView? {
func mapView(_ mapView: MKMapView, viewFor annotation: MKAnnotation) -> MKAnnotationView? {
let pinAnnotationView = MKPinAnnotationView(annotation: annotation, reuseIdentifier: "annotation")
pinAnnotationView.pinColor = MKPinAnnotationColor.Red
pinAnnotationView.draggable = true
pinAnnotationView.pinTintColor = .red
pinAnnotationView.isDraggable = true
pinAnnotationView.animatesDrop = true
return pinAnnotationView
}
func mapView(mapView: MKMapView, annotationView view: MKAnnotationView, didChangeDragState newState: MKAnnotationViewDragState, fromOldState oldState: MKAnnotationViewDragState) {
if (newState == .Ending){
func mapView(_ mapView: MKMapView, annotationView view: MKAnnotationView, didChange newState: MKAnnotationView.DragState, fromOldState oldState: MKAnnotationView.DragState) {
if (newState == .ending){
if let rowDescriptor = rowDescriptor, let annotation = view.annotation {
rowDescriptor.value = CLLocation(latitude:annotation.coordinate.latitude, longitude:annotation.coordinate.longitude)
self.title = String(format: "%0.4f, %0.4f", annotation.coordinate.latitude, annotation.coordinate.longitude)
@@ -23,7 +23,7 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.
class DateValueTrasformer : NSValueTransformer {
class DateValueTrasformer : ValueTransformer {
override class func transformedValueClass() -> AnyClass {
return NSString.self
@@ -34,18 +34,18 @@ class DateValueTrasformer : NSValueTransformer {
return false
}
override func transformedValue(value: AnyObject?) -> AnyObject? {
if let date = value as? NSDate {
let dateFormatter = NSDateFormatter()
dateFormatter.dateStyle = .FullStyle
dateFormatter.timeStyle = .NoStyle
return dateFormatter.stringFromDate(date)
override func transformedValue(_ value: Any?) -> Any? {
if let date = value as? Date {
let dateFormatter = DateFormatter()
dateFormatter.dateStyle = .full
dateFormatter.timeStyle = .none
return dateFormatter.string(from: date)
}
return nil
}
}
class DateTimeValueTrasformer: NSValueTransformer {
class DateTimeValueTrasformer: ValueTransformer {
override class func transformedValueClass() -> AnyClass {
return NSString.self
@@ -56,12 +56,12 @@ class DateTimeValueTrasformer: NSValueTransformer {
return false
}
override func transformedValue(value: AnyObject?) -> AnyObject? {
if let date = value as? NSDate {
let dateFormatter = NSDateFormatter()
dateFormatter.dateStyle = .MediumStyle
dateFormatter.timeStyle = .ShortStyle
return dateFormatter.stringFromDate(date)
override func transformedValue(_ value: Any?) -> Any? {
if let date = value as? Date {
let dateFormatter = DateFormatter()
dateFormatter.dateStyle = .medium
dateFormatter.timeStyle = .short
return dateFormatter.string(from: date)
}
return nil
}
@@ -26,7 +26,7 @@
class DatesFormViewController: XLFormViewController {
private struct Tags {
fileprivate struct Tags {
static let DateInline = "dateInline"
static let TimeInline = "timeInline"
static let DateTimeInline = "dateTimeInline"
@@ -38,7 +38,7 @@ class DatesFormViewController: XLFormViewController {
static let CountDownTimer = "countDownTimer"
}
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: NSBundle?) {
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
initializeForm()
}
@@ -50,15 +50,15 @@ class DatesFormViewController: XLFormViewController {
override func viewDidLoad() {
super.viewDidLoad()
let barButton = UIBarButtonItem(title: "Disable", style: .Plain, target: self, action: "disableEnable:")
let barButton = UIBarButtonItem(title: "Disable", style: .plain, target: self, action: #selector(DatesFormViewController.disableEnable(_:)))
barButton.possibleTitles = Set(["Disable", "Enable"])
navigationItem.rightBarButtonItem = barButton
}
func disableEnable(button : UIBarButtonItem){
form.disabled = !form.disabled
button.title = form.disabled ? "Enable" : "Disable"
@objc func disableEnable(_ button : UIBarButtonItem){
form.isDisabled = !form.isDisabled
button.title = form.isDisabled ? "Enable" : "Disable"
tableView.endEditing(true)
tableView.reloadData()
}
@@ -70,78 +70,79 @@ class DatesFormViewController: XLFormViewController {
form = XLFormDescriptor(title: "Date & Time")
section = XLFormSectionDescriptor.formSectionWithTitle("Inline Dates")
section = XLFormSectionDescriptor.formSection(withTitle: "Inline Dates")
form.addFormSection(section)
// Date
row = XLFormRowDescriptor(tag: Tags.DateInline, rowType: XLFormRowDescriptorTypeDateInline, title:"Date")
row.value = NSDate()
row.value = Date()
row.cellConfigAtConfigure["locale"] = Locale(identifier: "FR_fr")
section.addFormRow(row)
// Time
row = XLFormRowDescriptor(tag: Tags.TimeInline, rowType: XLFormRowDescriptorTypeTimeInline, title: "Time")
row.value = NSDate()
row.value = Date()
section.addFormRow(row)
// DateTime
row = XLFormRowDescriptor(tag: Tags.DateTimeInline, rowType: XLFormRowDescriptorTypeDateTimeInline, title: "Date Time")
row.value = NSDate()
row.value = Date()
section.addFormRow(row)
// CountDownTimer
row = XLFormRowDescriptor(tag: Tags.CountDownTimerInline, rowType:XLFormRowDescriptorTypeCountDownTimerInline, title:"Countdown Timer")
row.value = NSDate()
row.value = Date()
section.addFormRow(row)
section = XLFormSectionDescriptor.formSectionWithTitle("Dates") //
section = XLFormSectionDescriptor.formSection(withTitle: "Dates") //
form.addFormSection(section)
// Date
row = XLFormRowDescriptor(tag: Tags.Date, rowType:XLFormRowDescriptorTypeDate, title:"Date")
row.value = NSDate()
row.cellConfigAtConfigure["minimumDate"] = NSDate()
row.cellConfigAtConfigure["maximumDate"] = NSDate(timeIntervalSinceNow: 60*60*24*3)
row.value = Date()
row.cellConfigAtConfigure["minimumDate"] = Date()
row.cellConfigAtConfigure["maximumDate"] = Date(timeIntervalSinceNow: 60*60*24*3)
section.addFormRow(row)
// Time
row = XLFormRowDescriptor(tag: Tags.Time, rowType: XLFormRowDescriptorTypeTime, title: "Time")
row.cellConfigAtConfigure["minuteInterval"] = 10
row.value = NSDate()
row.value = Date()
section.addFormRow(row)
// DateTime
row = XLFormRowDescriptor(tag: Tags.DateTime, rowType: XLFormRowDescriptorTypeDateTime, title: "Date Time")
row.value = NSDate()
row.value = Date()
section.addFormRow(row)
// CountDownTimer
row = XLFormRowDescriptor(tag: Tags.CountDownTimer, rowType: XLFormRowDescriptorTypeCountDownTimer, title: "Countdown Timer")
row.value = NSDate()
row.value = Date()
section.addFormRow(row)
section = XLFormSectionDescriptor.formSectionWithTitle("Disabled Dates")
section = XLFormSectionDescriptor.formSection(withTitle: "Disabled Dates")
section.footerTitle = "DatesFormViewController.swift"
form.addFormSection(section)
// Date
row = XLFormRowDescriptor(tag: nil, rowType: XLFormRowDescriptorTypeDate, title: "Date")
row.disabled = NSNumber(bool: true)
row.required = true
row.value = NSDate()
row.disabled = NSNumber(value: true as Bool)
row.isRequired = true
row.value = Date()
section.addFormRow(row)
section = XLFormSectionDescriptor.formSectionWithTitle("DatePicker")
section = XLFormSectionDescriptor.formSection(withTitle: "DatePicker")
form.addFormSection(section)
// DatePicker
row = XLFormRowDescriptor(tag: Tags.DatePicker, rowType:XLFormRowDescriptorTypeDatePicker)
row.cellConfigAtConfigure["datePicker.datePickerMode"] = UIDatePickerMode.Date.rawValue
row.value = NSDate()
row.cellConfigAtConfigure["datePicker.datePickerMode"] = UIDatePicker.Mode.date.rawValue
row.value = Date()
section.addFormRow(row)
@@ -150,12 +151,13 @@ class DatesFormViewController: XLFormViewController {
// MARK: - XLFormDescriptorDelegate
override func formRowDescriptorValueHasChanged(formRow: XLFormRowDescriptor!, oldValue: AnyObject!, newValue: AnyObject!) {
override func formRowDescriptorValueHasChanged(_ formRow: XLFormRowDescriptor!, oldValue: Any!, newValue: Any!) {
super.formRowDescriptorValueHasChanged(formRow, oldValue: oldValue, newValue: newValue)
if formRow.tag == Tags.DatePicker {
let alertView = UIAlertView(title: "DatePicker", message: "Value Has changed!", delegate: self, cancelButtonTitle: "OK")
alertView.show()
let alert = UIAlertController(title: "DatePicker", message: "Values has changed!", preferredStyle: .alert)
alert.addAction(UIAlertAction(title: "OK", style: .default, handler: nil))
present(alert, animated: true, completion: nil)
}
}
@@ -25,7 +25,7 @@
class DynamicSelectorsFormViewController : XLFormViewController {
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: NSBundle?) {
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
initializeForm()
}
@@ -42,7 +42,7 @@ class DynamicSelectorsFormViewController : XLFormViewController {
var row : XLFormRowDescriptor
// Basic Information
section = XLFormSectionDescriptor.formSectionWithTitle("Dynamic Selectors")
section = XLFormSectionDescriptor.formSection(withTitle: "Dynamic Selectors")
section.footerTitle = "DynamicSelectorsFormViewController.swift"
form.addFormSection(section)
@@ -51,7 +51,7 @@ class DynamicSelectorsFormViewController : XLFormViewController {
row.action.viewControllerClass = UsersTableViewController.self
section.addFormRow(row)
if UIDevice.currentDevice().userInterfaceIdiom == .Pad {
if UIDevice.current.userInterfaceIdiom == .pad {
// Selector PopOver
row = XLFormRowDescriptor(tag: "selectorUserPopover", rowType:XLFormRowDescriptorTypeSelectorPopover, title:"User Popover")
row.action.viewControllerClass = UsersTableViewController.self
@@ -38,11 +38,11 @@ class UserCell : UITableViewCell {
lazy var userName : UILabel = {
let tempUserName = UILabel()
tempUserName.translatesAutoresizingMaskIntoConstraints = false
tempUserName.font = UIFont.systemFontOfSize(15.0)
tempUserName.font = UIFont.systemFont(ofSize: 15.0)
return tempUserName
}()
override init(style: UITableViewCellStyle, reuseIdentifier: String?) {
override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
super.init(style: style, reuseIdentifier: reuseIdentifier)
// Initialization code
@@ -55,7 +55,7 @@ class UserCell : UITableViewCell {
fatalError("init(coder:) has not been implemented")
}
override func setSelected(selected: Bool, animated: Bool) {
override func setSelected(_ selected: Bool, animated: Bool) {
super.setSelected(selected, animated: animated)
}
@@ -63,11 +63,11 @@ class UserCell : UITableViewCell {
// MARK: - Layout Constraints
func layoutConstraints() -> [NSLayoutConstraint]{
let views = ["image": self.userImage, "name": self.userName ]
let views = ["image": self.userImage, "name": self.userName ] as [String : Any]
let metrics = [ "imgSize": 50.0, "margin": 12.0]
var result = NSLayoutConstraint.constraintsWithVisualFormat("H:|-(margin)-[image(imgSize)]-[name]", options:.AlignAllTop, metrics: metrics, views: views)
result += NSLayoutConstraint.constraintsWithVisualFormat("V:|-(margin)-[image(imgSize)]", options:NSLayoutFormatOptions(), metrics:metrics, views: views)
var result = NSLayoutConstraint.constraints(withVisualFormat: "H:|-(margin)-[image(imgSize)]-[name]", options:.alignAllTop, metrics: metrics, views: views)
result += NSLayoutConstraint.constraints(withVisualFormat: "V:|-(margin)-[image(imgSize)]", options:NSLayoutConstraint.FormatOptions(), metrics:metrics, views: views)
return result
}
@@ -91,9 +91,9 @@ class UsersJSONSerialization {
"{\"id\":4,\"name\":\"Montgomery Burns\",\"imageName\":\"Montgomery_Burns.png\"}," +
"{\"id\":5,\"name\":\"Ned Flanders\",\"imageName\":\"Ned_Flanders.png\"}," +
"{\"id\":6,\"name\":\"Otto Mann\",\"imageName\":\"Otto_Mann.png\"}]"
let jsonData = dataString.dataUsingEncoding(NSUTF8StringEncoding, allowLossyConversion: true)
let jsonData = dataString.data(using: String.Encoding.utf8, allowLossyConversion: true)
do {
let result = try NSJSONSerialization.JSONObjectWithData(jsonData!, options: NSJSONReadingOptions()) as! Array<AnyObject>
let result = try JSONSerialization.jsonObject(with: jsonData!, options: JSONSerialization.ReadingOptions()) as! Array<AnyObject>
return result
}
catch let error as NSError {
@@ -124,29 +124,25 @@ class User: NSObject, XLFormOptionObject {
func formDisplayText() -> String {
return self.userName
}
func formValue() -> AnyObject {
return self.userId
func formValue() -> Any {
return self.userId as Any
}
}
class UsersTableViewController : UITableViewController, XLFormRowDescriptorViewController, XLFormRowDescriptorPopoverViewController {
class UsersTableViewController : UITableViewController, XLFormRowDescriptorViewController {
var rowDescriptor : XLFormRowDescriptor?
var popoverController : UIPopoverController?
var userCell : UserCell?
private let kUserCellIdentifier = "UserCell"
fileprivate let kUserCellIdentifier = "UserCell"
override init(style: UITableViewStyle) {
override init(style: UITableView.Style) {
super.init(style: style);
}
override init(nibName nibNameOrNil: String!, bundle nibBundleOrNil: NSBundle!) {
override init(nibName nibNameOrNil: String!, bundle nibBundleOrNil: Bundle!) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
}
@@ -156,53 +152,53 @@ class UsersTableViewController : UITableViewController, XLFormRowDescriptorViewC
override func viewDidLoad() {
super.viewDidLoad()
tableView.registerClass(UserCell.self, forCellReuseIdentifier: kUserCellIdentifier)
tableView.register(UserCell.self, forCellReuseIdentifier: kUserCellIdentifier)
tableView.tableFooterView = UIView(frame: CGRect.zero)
}
// MARK: UITableViewDataSource
override func numberOfSectionsInTableView(tableView: UITableView) -> Int {
override func numberOfSections(in tableView: UITableView) -> Int {
return 1
}
override func tableView(tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
return UsersJSONSerialization.sharedInstance.userData!.count
}
override func tableView(tableView: UITableView, cellForRowAtIndexPath indexPath: NSIndexPath) -> UITableViewCell {
let cell: UserCell = tableView.dequeueReusableCellWithIdentifier(self.kUserCellIdentifier, forIndexPath: indexPath) as! UserCell
override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
let cell: UserCell = tableView.dequeueReusableCell(withIdentifier: self.kUserCellIdentifier, for: indexPath) as! UserCell
let usersData = UsersJSONSerialization.sharedInstance.userData! as! Array<Dictionary<String, AnyObject>>
let userData = usersData[indexPath.row] as Dictionary<String, AnyObject>
let userData = usersData[(indexPath as NSIndexPath).row] as Dictionary<String, AnyObject>
let userId = userData["id"] as! Int
cell.userName.text = userData["name"] as? String
cell.userImage.image = UIImage(named: (userData["imageName"] as? String)!)
if let value = rowDescriptor?.value {
cell.accessoryType = value.formValue().isEqual(userId) ? .Checkmark : .None
cell.accessoryType = ((value as? XLFormOptionObject)?.formValue() as? Int) == userId ? .checkmark : .none
}
return cell;
}
override func tableView(tableView: UITableView, heightForRowAtIndexPath indexPath: NSIndexPath) -> CGFloat {
override func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat {
return 73.0
}
//MARK: UITableViewDelegate
override func tableView(tableView: UITableView, didSelectRowAtIndexPath indexPath: NSIndexPath) {
override func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
let usersData = UsersJSONSerialization.sharedInstance.userData! as! Array<Dictionary<String, AnyObject>>
let userData = usersData[indexPath.row] as Dictionary<String, AnyObject>
let userData = usersData[(indexPath as NSIndexPath).row] as Dictionary<String, AnyObject>
let user = User(userId: (userData["id"] as! Int), userName: userData["name"] as! String, userImage: userData["imageName"] as! String)
self.rowDescriptor!.value = user;
if let porpOver = self.popoverController {
porpOver.dismissPopoverAnimated(true)
porpOver.delegate?.popoverControllerDidDismissPopover!(porpOver)
if let popOver = self.presentedViewController, popOver.modalPresentationStyle == .popover {
dismiss(animated: true, completion: nil)
}
else if parentViewController is UINavigationController {
navigationController?.popViewControllerAnimated(true)
else if parent is UINavigationController {
navigationController?.popViewController(animated: true)
}
}
@@ -28,7 +28,7 @@
class ExamplesFormViewController : XLFormViewController {
private struct Tags {
fileprivate struct Tags {
static let RealExample = "RealExamples"
static let TextFieldAndTextView = "TextFieldAndTextView"
static let Selectors = "Selectors"
@@ -46,7 +46,7 @@ class ExamplesFormViewController : XLFormViewController {
static let AccessoryView = "Accessory View"
}
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: NSBundle?) {
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
initializeForm()
}
@@ -66,7 +66,7 @@ class ExamplesFormViewController : XLFormViewController {
form = XLFormDescriptor()
section = XLFormSectionDescriptor.formSectionWithTitle("Real examples")
section = XLFormSectionDescriptor.formSection(withTitle: "Real examples")
form.addFormSection(section)
// NativeEventFormViewController
@@ -74,7 +74,7 @@ class ExamplesFormViewController : XLFormViewController {
row.action.formSegueIdentifier = "NativeEventNavigationViewControllerSegue"
section.addFormRow(row)
section = XLFormSectionDescriptor.formSectionWithTitle("This form is actually an example")
section = XLFormSectionDescriptor.formSection(withTitle: "This form is actually an example")
section.footerTitle = "ExamplesFormViewController.swift, Select an option to view another example"
form.addFormSection(section)
@@ -102,7 +102,7 @@ class ExamplesFormViewController : XLFormViewController {
section.addFormRow(row)
section = XLFormSectionDescriptor.formSectionWithTitle("Multivalued example")
section = XLFormSectionDescriptor.formSection(withTitle: "Multivalued example")
form.addFormSection(section)
@@ -123,14 +123,14 @@ class ExamplesFormViewController : XLFormViewController {
section.addFormRow(row)
section = XLFormSectionDescriptor.formSectionWithTitle("UI Customization")
section = XLFormSectionDescriptor.formSection(withTitle: "UI Customization")
form.addFormSection(section)
row = XLFormRowDescriptor(tag: Tags.UICusomization, rowType: XLFormRowDescriptorTypeButton, title:"UI Customization")
row.action.viewControllerClass = UICustomizationFormViewController.self
section.addFormRow(row)
section = XLFormSectionDescriptor.formSectionWithTitle("Custom Rows")
section = XLFormSectionDescriptor.formSection(withTitle: "Custom Rows")
form.addFormSection(section)
@@ -138,7 +138,7 @@ class ExamplesFormViewController : XLFormViewController {
row.action.viewControllerClass = CustomRowsViewController.self
section.addFormRow(row)
section = XLFormSectionDescriptor.formSectionWithTitle("Accessory View")
section = XLFormSectionDescriptor.formSection(withTitle: "Accessory View")
form.addFormSection(section)
row = XLFormRowDescriptor(tag: Tags.AccessoryView, rowType: XLFormRowDescriptorTypeButton, title:"Accessory Views")
@@ -146,7 +146,7 @@ class ExamplesFormViewController : XLFormViewController {
section.addFormRow(row)
section = XLFormSectionDescriptor.formSectionWithTitle("Validation Examples")
section = XLFormSectionDescriptor.formSection(withTitle: "Validation Examples")
form.addFormSection(section)
@@ -154,7 +154,7 @@ class ExamplesFormViewController : XLFormViewController {
row.action.formSegueIdentifier = "ValidationExamplesFormViewControllerSegue"
section.addFormRow(row)
section = XLFormSectionDescriptor.formSectionWithTitle("Using Predicates")
section = XLFormSectionDescriptor.formSection(withTitle: "Using Predicates")
form.addFormSection(section)
@@ -66,6 +66,11 @@
"idiom" : "ipad",
"filename" : "xl_appicon_152.png",
"scale" : "2x"
},
{
"idiom" : "ipad",
"size" : "83.5x83.5",
"scale" : "2x"
}
],
"info" : {
@@ -26,7 +26,7 @@
class InputsFormViewController : XLFormViewController {
private struct Tags {
fileprivate struct Tags {
static let Name = "name"
static let Email = "email"
static let Twitter = "twitter"
@@ -41,7 +41,7 @@ class InputsFormViewController : XLFormViewController {
static let Notes = "notes"
}
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: NSBundle?) {
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
initializeForm()
}
@@ -60,25 +60,25 @@ class InputsFormViewController : XLFormViewController {
form = XLFormDescriptor(title: "Text Fields")
form.assignFirstResponderOnShow = true
section = XLFormSectionDescriptor.formSectionWithTitle("TextField Types")
section = XLFormSectionDescriptor.formSection(withTitle: "TextField Types")
section.footerTitle = "This is a long text that will appear on section footer"
form.addFormSection(section)
// Name
row = XLFormRowDescriptor(tag: Tags.Name, rowType: XLFormRowDescriptorTypeText, title: "Name")
row.required = true
row.isRequired = true
section.addFormRow(row)
// Email
row = XLFormRowDescriptor(tag: Tags.Email, rowType: XLFormRowDescriptorTypeEmail, title: "Email")
// validate the email
row.addValidator(XLFormValidator.emailValidator())
row.addValidator(XLFormValidator.email())
section.addFormRow(row)
// Twitter
row = XLFormRowDescriptor(tag: Tags.Name, rowType: XLFormRowDescriptorTypeTwitter, title: "Twitter")
row.disabled = NSNumber(bool: true)
row.disabled = NSNumber(value: true as Bool)
row.value = "@no_editable"
section.addFormRow(row)
@@ -121,7 +121,7 @@ class InputsFormViewController : XLFormViewController {
section.addFormRow(row)
section = XLFormSectionDescriptor.formSectionWithTitle("TextView With Label Example")
section = XLFormSectionDescriptor.formSection(withTitle: "TextView With Label Example")
form.addFormSection(section)
row = XLFormRowDescriptor(tag: Tags.Number, rowType: XLFormRowDescriptorTypeTextView, title: "Notes")
@@ -134,10 +134,10 @@ class InputsFormViewController : XLFormViewController {
override func viewDidLoad()
{
super.viewDidLoad()
navigationItem.rightBarButtonItem = UIBarButtonItem(barButtonSystemItem: .Save, target: self, action: "savePressed:")
navigationItem.rightBarButtonItem = UIBarButtonItem(barButtonSystemItem: .save, target: self, action: #selector(InputsFormViewController.savePressed(_:)))
}
func savePressed(button: UIBarButtonItem)
@objc func savePressed(_ button: UIBarButtonItem)
{
let validationErrors : Array<NSError> = self.formValidationErrors() as! Array<NSError>
if (validationErrors.count > 0){
@@ -145,8 +145,11 @@ class InputsFormViewController : XLFormViewController {
return
}
self.tableView.endEditing(true)
let alertView = UIAlertView(title: "Valid Form", message: "No errors found", delegate: self, cancelButtonTitle: "OK")
alertView.show()
let alert = UIAlertController(title: "Valid Form", message: "No errors found!", preferredStyle: .alert)
alert.addAction(UIAlertAction(title: "OK", style: .default, handler: nil))
present(alert, animated: true, completion: nil)
}
}
@@ -31,7 +31,7 @@ class MultivaluedFormViewController : XLFormViewController {
initializeForm()
}
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: NSBundle?) {
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
initializeForm()
}
@@ -45,7 +45,7 @@ class MultivaluedFormViewController : XLFormViewController {
form = XLFormDescriptor(title: "Multivalued Examples")
// Multivalued section
section = XLFormSectionDescriptor.formSectionWithTitle("Multivalued TextField", sectionOptions:XLFormSectionOptions.CanReorder.union(.CanInsert).union(.CanDelete), sectionInsertMode:.Button)
section = XLFormSectionDescriptor.formSection(withTitle: "Multivalued TextField", sectionOptions:XLFormSectionOptions.canReorder.union(.canInsert).union(.canDelete), sectionInsertMode:.button)
section.multivaluedAddButton!.title = "Add New Tag"
section.footerTitle = "XLFormSectionInsertModeButton sectionType adds a 'Add Item' (Add New Tag) button row as last cell."
// set up the row template
@@ -56,7 +56,7 @@ class MultivaluedFormViewController : XLFormViewController {
form.addFormSection(section)
// Another Multivalued section
section = XLFormSectionDescriptor.formSectionWithTitle("Multivalued ActionSheet Selector example", sectionOptions:XLFormSectionOptions.CanInsert.union(.CanDelete))
section = XLFormSectionDescriptor.formSection(withTitle: "Multivalued ActionSheet Selector example", sectionOptions:XLFormSectionOptions.canInsert.union(.canDelete))
section.footerTitle = "XLFormSectionInsertModeLastRow sectionType adds a '+' icon inside last table view cell allowing us to add a new row."
form.addFormSection(section)
row = XLFormRowDescriptor(tag: nil, rowType: XLFormRowDescriptorTypeSelectorActionSheet, title: "Tap to select..")
@@ -65,7 +65,7 @@ class MultivaluedFormViewController : XLFormViewController {
// Another one
section = XLFormSectionDescriptor.formSectionWithTitle("Multivalued Push Selector example", sectionOptions: XLFormSectionOptions.CanInsert.union(.CanDelete).union(.CanReorder), sectionInsertMode: .Button)
section = XLFormSectionDescriptor.formSection(withTitle: "Multivalued Push Selector example", sectionOptions: XLFormSectionOptions.canInsert.union(.canDelete).union(.canReorder), sectionInsertMode: .button)
section.footerTitle = "MultivaluedFormViewController.swift"
form.addFormSection(section)
row = XLFormRowDescriptor(tag: nil, rowType: XLFormRowDescriptorTypeSelectorPush, title: "Tap to select )..")
@@ -78,47 +78,50 @@ class MultivaluedFormViewController : XLFormViewController {
override func viewDidLoad() {
super.viewDidLoad()
navigationItem.rightBarButtonItem = UIBarButtonItem(barButtonSystemItem: .Edit, target: self, action: "addDidTouch:")
navigationItem.rightBarButtonItem = UIBarButtonItem(barButtonSystemItem: .edit, target: self, action: #selector(MultivaluedFormViewController.addDidTouch(_:)))
}
//MARK: - Actions
func addDidTouch(sender: UIBarButtonItem) {
let actionSheet = UIActionSheet(title: nil, delegate: self, cancelButtonTitle: "Cancel", destructiveButtonTitle: "Remove Last Section", otherButtonTitles: "Add a section at the end", self.form!.disabled ? "Enable Form" : "Disable Form")
actionSheet.showInView(view)
}
//MARK: - UIActionSheetDelegate
override func actionSheet(actionSheet: UIActionSheet, clickedButtonAtIndex buttonIndex: Int) {
if actionSheet.destructiveButtonIndex == buttonIndex {
if form.formSections.count > 0 {
@objc func addDidTouch(_ sender: UIBarButtonItem) {
let actionSheet = UIAlertController(title: nil, message: nil, preferredStyle: .actionSheet)
let cancelAction = UIAlertAction(title: "Cancel", style: .cancel, handler: nil)
let removeAction = UIAlertAction(title: "Remove Last Section", style: .destructive, handler: { [weak self] alert in
guard let `self` = self else { return }
if self.form.formSections.count > 0 {
// remove last section
form.removeFormSectionAtIndex(UInt(form.formSections.count - 1))
self.form.removeFormSection(at: UInt(self.form.formSections.count - 1))
}
}
else if actionSheet.buttonTitleAtIndex(buttonIndex) == "Add a section at the end" {
// add a new section
// let dateString = NSDateFormatter.localizedStringFromDate(NSDate(), dateStyle: NSDateFormatterStyle.ShortStyle, timeStyle: NSDateFormatterStyle.ShortStyle)
let newSection = XLFormSectionDescriptor.formSectionWithTitle("Section created at \(NSDateFormatter.localizedStringFromDate(NSDate(), dateStyle: NSDateFormatterStyle.ShortStyle, timeStyle: NSDateFormatterStyle.ShortStyle))", sectionOptions:XLFormSectionOptions.CanInsert.union(.CanDelete))
})
let addSectionAction = UIAlertAction(title: "Add a section at the end", style: .default, handler: { [weak self] alert in
guard let `self` = self else { return }
let newSection = XLFormSectionDescriptor.formSection(withTitle: "Section created at \(DateFormatter.localizedString(from: Date(), dateStyle: DateFormatter.Style.short, timeStyle: DateFormatter.Style.short))", sectionOptions:XLFormSectionOptions.canInsert.union(.canDelete))
newSection.multivaluedTag = "multivaluedPushSelector_\(self.form.formSections.count)"
let newRow = XLFormRowDescriptor(tag: nil, rowType: XLFormRowDescriptorTypeSelectorPush, title: "Tap to select )..")
newRow.selectorOptions = ["Option 1", "Option 2", "Option 3"]
newSection.addFormRow(newRow)
form.addFormSection(newSection)
}
else {
form.disabled = !self.form.disabled
tableView.endEditing(true)
tableView.reloadData()
}
self.form.addFormSection(newSection)
})
let toggleAction = UIAlertAction(title: self.form!.isDisabled ? "Enable Form" : "Disable Form", style: .default, handler: { [weak self] alert in
guard let `self` = self else { return }
self.form.isDisabled = !self.form.isDisabled
self.tableView.endEditing(true)
self.tableView.reloadData()
})
actionSheet.addAction(addSectionAction)
actionSheet.addAction(removeAction)
actionSheet.addAction(cancelAction)
actionSheet.addAction(toggleAction)
present(actionSheet, animated: true, completion: nil)
}
}
class MultivaluedOnlyReorderViewController : XLFormViewController {
required init?(coder aDecoder: NSCoder) {
@@ -126,7 +129,7 @@ class MultivaluedOnlyReorderViewController : XLFormViewController {
self.initializeForm()
}
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: NSBundle?) {
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
self.initializeForm()
}
@@ -143,29 +146,31 @@ class MultivaluedOnlyReorderViewController : XLFormViewController {
form = XLFormDescriptor(title: "Only Reorder Examples")
// Multivalued Section with inline rows - section set up to support only reordering
section = XLFormSectionDescriptor.formSectionWithTitle("Reordering Inline Rows",
sectionOptions:.CanReorder)
section = XLFormSectionDescriptor.formSection(withTitle: "Reordering Inline Rows",
sectionOptions:.canReorder)
section.footerTitle = "XLFormRowDescriptorTypeDateInline row type"
form.addFormSection(section)
var idx = 0
for listItem in list {
let timeIntervalSinceNow = NSTimeInterval(secondsPerDay * ++idx)
idx += 1
let timeIntervalSinceNow = TimeInterval(secondsPerDay * idx)
row = XLFormRowDescriptor(tag: nil, rowType:XLFormRowDescriptorTypeDateInline, title: listItem)
row.value = NSDate(timeIntervalSinceNow:timeIntervalSinceNow)
row.value = Date(timeIntervalSinceNow:timeIntervalSinceNow)
section.addFormRow(row)
}
// Multivalued Section with common rows - section set up to support only reordering
section = XLFormSectionDescriptor.formSectionWithTitle("Reordering Rows", sectionOptions:.CanReorder)
section = XLFormSectionDescriptor.formSection(withTitle: "Reordering Rows", sectionOptions:.canReorder)
section.footerTitle = "XLFormRowDescriptorTypeInfo row type"
form.addFormSection(section)
idx = 0
for listItem in list {
let timeIntervalSinceNow = NSTimeInterval(secondsPerDay * ++idx)
idx += 1
let timeIntervalSinceNow = TimeInterval(secondsPerDay * idx)
row = XLFormRowDescriptor(tag: nil, rowType:XLFormRowDescriptorTypeInfo, title: listItem)
row.value = NSDateFormatter.localizedStringFromDate(NSDate(timeIntervalSinceNow:timeIntervalSinceNow), dateStyle: .MediumStyle, timeStyle: .NoStyle)
row.value = DateFormatter.localizedString(from: Date(timeIntervalSinceNow:timeIntervalSinceNow), dateStyle: .medium, timeStyle: .none)
section.addFormRow(row)
}
@@ -182,7 +187,7 @@ class MultivaluedOnlyInserViewController : XLFormViewController {
}
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: NSBundle?) {
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
self.initializeForm()
}
@@ -197,7 +202,7 @@ class MultivaluedOnlyInserViewController : XLFormViewController {
form = XLFormDescriptor(title: "Multivalued Only Insert")
section = XLFormSectionDescriptor.formSectionWithTitle("XLFormSectionInsertModeButton", sectionOptions:.CanInsert, sectionInsertMode:.Button)
section = XLFormSectionDescriptor.formSection(withTitle: "XLFormSectionInsertModeButton", sectionOptions:.canInsert, sectionInsertMode:.button)
form.addFormSection(section)
@@ -205,15 +210,15 @@ class MultivaluedOnlyInserViewController : XLFormViewController {
row.cellConfig["textField.placeholder"] = "Add a new tag"
section.multivaluedRowTemplate = row
section = XLFormSectionDescriptor.formSectionWithTitle("XLFormSectionInsertModeButton With Inline Cells", sectionOptions:.CanInsert, sectionInsertMode:.Button)
section = XLFormSectionDescriptor.formSection(withTitle: "XLFormSectionInsertModeButton With Inline Cells", sectionOptions:.canInsert, sectionInsertMode:.button)
row = XLFormRowDescriptor(tag: nil, rowType:XLFormRowDescriptorTypeDateInline)
row.value = NSDate()
row.value = Date()
row.title = "Date"
section.multivaluedRowTemplate = row
form.addFormSection(section)
section = XLFormSectionDescriptor.formSectionWithTitle("XLFormSectionInsertModeLastRow",
sectionOptions:.CanInsert, sectionInsertMode:.LastRow)
section = XLFormSectionDescriptor.formSection(withTitle: "XLFormSectionInsertModeLastRow",
sectionOptions:.canInsert, sectionInsertMode:.lastRow)
form.addFormSection(section)
for tag in nameList {
// add a row to the section, the row will be used to crete new rows.
@@ -233,19 +238,19 @@ class MultivaluedOnlyDeleteViewController : XLFormViewController {
initializeForm()
}
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: NSBundle?) {
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
initializeForm()
}
override func viewDidLoad() {
super.viewDidLoad()
navigationItem.rightBarButtonItem = UIBarButtonItem(title: "Editing", style: .Plain, target: self, action: "toggleEditing:")
navigationItem.rightBarButtonItem = UIBarButtonItem(title: "Editing", style: .plain, target: self, action: #selector(MultivaluedOnlyDeleteViewController.toggleEditing(_:)))
}
func toggleEditing(sender : UIBarButtonItem) {
tableView.setEditing(!tableView.editing, animated: true)
sender.title = tableView.editing ? "Editing" : "Not Editing"
@objc func toggleEditing(_ sender : UIBarButtonItem) {
tableView.setEditing(!tableView.isEditing, animated: true)
sender.title = tableView.isEditing ? "Editing" : "Not Editing"
}
func initializeForm() {
@@ -258,7 +263,7 @@ class MultivaluedOnlyDeleteViewController : XLFormViewController {
form = XLFormDescriptor(title: "Multivalued Only Delete")
section = XLFormSectionDescriptor.formSectionWithTitle("", sectionOptions:.CanDelete)
section = XLFormSectionDescriptor.formSection(withTitle: "", sectionOptions:.canDelete)
section.footerTitle = "you can swipe to delete when table.editing = NO (Not Editing)"
form.addFormSection(section)
@@ -271,7 +276,7 @@ class MultivaluedOnlyDeleteViewController : XLFormViewController {
}
// Multivalued Section with inline row.
section = XLFormSectionDescriptor.formSectionWithTitle("", sectionOptions:.CanDelete)
section = XLFormSectionDescriptor.formSection(withTitle: "", sectionOptions:.canDelete)
section.footerTitle = "you can swipe to delete when table.editing = NO (Not Editing)"
form.addFormSection(section)
@@ -27,7 +27,7 @@ let XLFormRowDescriptorTypeCustom = "XLFormRowDescriptorTypeCustom"
class XLFormCustomCell : XLFormBaseCell {
override init(style: UITableViewCellStyle, reuseIdentifier: String?) {
override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
super.init(style: style, reuseIdentifier: reuseIdentifier)
}
@@ -50,10 +50,10 @@ class XLFormCustomCell : XLFormBaseCell {
}
}
override func formDescriptorCellDidSelectedWithFormController(controller: XLFormViewController!) {
override func formDescriptorCellDidSelected(withForm controller: XLFormViewController!) {
// custom code here
// i.e new behaviour when cell has been selected
if let string = rowDescriptor?.value as? String where string == "Am a custom cell, select me!" {
if let string = rowDescriptor?.value as? String , string == "Am a custom cell, select me!" {
self.rowDescriptor?.value = string
}
else {
@@ -61,7 +61,7 @@ class XLFormCustomCell : XLFormBaseCell {
}
update()
controller.tableView.selectRowAtIndexPath(nil, animated: true, scrollPosition: .None)
controller.tableView.selectRow(at: nil, animated: true, scrollPosition: .none)
}
}
@@ -27,7 +27,7 @@ import MapKit
class OthersFormViewController : XLFormViewController {
private struct Tags {
fileprivate struct Tags {
static let SwitchBool = "switchBool"
static let SwitchCheck = "switchCheck"
static let StepCounter = "stepCounter"
@@ -46,12 +46,10 @@ class OthersFormViewController : XLFormViewController {
required init?(coder aDecoder: NSCoder) {
super.init(coder: aDecoder)
self.initializeForm()
}
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: NSBundle?) {
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
self.initializeForm()
}
@@ -63,7 +61,7 @@ class OthersFormViewController : XLFormViewController {
form = XLFormDescriptor(title: "Other Cells")
section = XLFormSectionDescriptor.formSectionWithTitle("Other Cells")
section = XLFormSectionDescriptor.formSection(withTitle: "Other Cells")
section.footerTitle = "OthersFormViewController.swift"
form.addFormSection(section)
@@ -81,6 +79,12 @@ class OthersFormViewController : XLFormViewController {
row.selectorOptions = ["Apple", "Orange", "Pear"]
row.value = "Pear"
section.addFormRow(row)
row = XLFormRowDescriptor(tag: Tags.SegmentedControl, rowType: XLFormRowDescriptorTypeSegmentedInline, title: "Fruits Inline")
row.selectorOptions = ["Apple", "Orange", "Pear"]
row.value = "Pear"
section.addFormRow(row)
// Slider
@@ -99,31 +103,33 @@ class OthersFormViewController : XLFormViewController {
// Info cell
row = XLFormRowDescriptor(tag: Tags.Info, rowType: XLFormRowDescriptorTypeInfo)
row.title = "Version"
row.value = NSBundle.mainBundle().infoDictionary!["CFBundleShortVersionString"]
row.value = Bundle.main.infoDictionary!["CFBundleShortVersionString"]
section.addFormRow(row)
section = XLFormSectionDescriptor.formSectionWithTitle("Buttons")
section = XLFormSectionDescriptor.formSection(withTitle: "Buttons")
section.footerTitle = "Blue buttons will show a message when Switch is ON"
form.addFormSection(section)
// Button
row = XLFormRowDescriptor(tag: Tags.Button, rowType: XLFormRowDescriptorTypeButton, title: "Button")
row.cellConfig["textLabel.textColor"] = UIColor(red: 0.0, green: 122.0/255.0, blue: 1.0, alpha: 1.0)
row.action.formSelector = "didTouchButton:"
row.action.formSelector = #selector(OthersFormViewController.didTouchButton(_:))
section.addFormRow(row)
// Left Button
row = XLFormRowDescriptor(tag: Tags.ButtonLeftAligned, rowType: XLFormRowDescriptorTypeButton, title: "Button with Block")
row.cellConfig["textLabel.textColor"] = UIColor(red: 0.0, green: 122.0/255.0, blue: 1.0, alpha: 1.0)
row.cellConfig["textLabel.textAlignment"] = NSTextAlignment.Left.rawValue
row.cellConfig["accessoryType"] = UITableViewCellAccessoryType.DisclosureIndicator.rawValue
row.cellConfig["textLabel.textAlignment"] = NSTextAlignment.left.rawValue
row.cellConfig["accessoryType"] = UITableViewCell.AccessoryType.disclosureIndicator.rawValue
row.action.formBlock = { [weak self] (sender: XLFormRowDescriptor!) -> Void in
let switchRow = sender.sectionDescriptor.formDescriptor!.formRowWithTag(Tags.SwitchBool)!
if let value = switchRow.value where value.boolValue == true {
let alertView = UIAlertView(title: "Switch is ON", message: "Button has checked the switch value...", delegate: self, cancelButtonTitle: "OK")
alertView.show()
let switchRow = sender.sectionDescriptor.formDescriptor!.formRow(withTag: Tags.SwitchBool)!
if let value = switchRow.value , (value as AnyObject).boolValue == true {
let alert = UIAlertController(title: "Switch is ON", message: "Button has checked the switch value...", preferredStyle: .alert)
alert.addAction(UIAlertAction(title: "OK", style: .default, handler: nil))
self?.present(alert, animated: true, completion: nil)
}
self?.deselectFormRow(sender)
}
@@ -160,26 +166,30 @@ class OthersFormViewController : XLFormViewController {
self.form = form
}
func didTouchButton(sender: XLFormRowDescriptor) {
if sender.sectionDescriptor.formDescriptor.formRowWithTag(Tags.SwitchBool)?.value?.boolValue == true{
let alertView = UIAlertView(title: "Switch is ON", message: "Button has checked the switch value...", delegate: self, cancelButtonTitle: "OK")
alertView.show()
@objc func didTouchButton(_ sender: XLFormRowDescriptor) {
if (sender.sectionDescriptor.formDescriptor.formRow(withTag: Tags.SwitchBool)?.value as AnyObject).boolValue == true{
let alert = UIAlertController(title: "Switch is ON", message: "Button has checked the switch value...", preferredStyle: .alert)
alert.addAction(UIAlertAction(title: "OK", style: .default, handler: nil))
present(alert, animated: true, completion: nil)
}
self.deselectFormRow(sender)
}
override func viewDidLoad() {
super.viewDidLoad()
let barButton = UIBarButtonItem(title: "Disable", style: .Plain, target: self, action: "disableEnable:")
initializeForm()
let barButton = UIBarButtonItem(title: "Disable", style: .plain, target: self, action: #selector(OthersFormViewController.disableEnable(_:)))
barButton.possibleTitles = Set(["Disable", "Enable"])
navigationItem.rightBarButtonItem = barButton
}
func disableEnable(button : UIBarButtonItem) {
form.disabled = !form.disabled
button.title = form.disabled ? "Enable" : "Disable"
@objc func disableEnable(_ button : UIBarButtonItem) {
form.isDisabled = !form.isDisabled
button.title = form.isDisabled ? "Enable" : "Disable"
tableView.endEditing(true)
tableView.reloadData()
}
@@ -26,7 +26,7 @@
class BasicPredicateViewController : XLFormViewController {
private struct Tags {
fileprivate struct Tags {
static let HideRow = "tag1"
static let HideSection = "tag2"
@@ -35,7 +35,7 @@ class BasicPredicateViewController : XLFormViewController {
}
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: NSBundle?) {
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
initializeForm()
}
@@ -25,7 +25,7 @@
class BlogExampleViewController : XLFormViewController {
private struct Tags {
fileprivate struct Tags {
static let Hobbies = "hobbies"
static let Sport = "sport"
static let Film = "films1"
@@ -33,7 +33,7 @@ class BlogExampleViewController : XLFormViewController {
static let Music = "music"
}
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: NSBundle?) {
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
initializeForm()
}
@@ -26,7 +26,7 @@
class PredicateFormViewController : XLFormViewController {
private struct Tags {
fileprivate struct Tags {
static let Text = "text"
static let Integer = "integer"
static let Switch = "switch"
@@ -34,7 +34,7 @@ class PredicateFormViewController : XLFormViewController {
static let Account = "account"
}
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: NSBundle?) {
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
initializeForm()
}
@@ -77,7 +77,7 @@ class PredicateFormViewController : XLFormViewController {
// Predicate Disabling
row = XLFormRowDescriptor(tag: Tags.Date, rowType: XLFormRowDescriptorTypeDateInline, title:"Disabled")
row.value = NSDate()
row.value = Date()
section.addFormRow(row)
row.disabled = NSPredicate(format: "$\(Tags.Text).value contains[c] 'disable' OR ($\(Tags.Integer).value between {18, 60}) OR ($\(Tags.Switch).value == 0)")
section.hidden = NSPredicate(format: "($\(Tags.Text).value contains[c] 'disable') AND ($\(Tags.Integer).value between {18, 60}) AND ($\(Tags.Switch).value == 0)")
@@ -99,9 +99,9 @@ class PredicateFormViewController : XLFormViewController {
row.onChangeBlock = { [weak self] oldValue, newValue, _ in
let noValue = "No Value"
let message = "Old value: \(oldValue ?? noValue), New value: \(newValue ?? noValue)"
let alertView = UIAlertController(title: "Account Field changed", message: message, preferredStyle: .ActionSheet)
alertView.addAction(UIAlertAction(title: "Cancel", style: .Cancel, handler: nil))
self?.navigationController?.presentViewController(alertView, animated: true, completion: nil)
let alertView = UIAlertController(title: "Account Field changed", message: message, preferredStyle: .actionSheet)
alertView.addAction(UIAlertAction(title: "Cancel", style: .cancel, handler: nil))
self?.navigationController?.present(alertView, animated: true, completion: nil)
}
self.form = form
@@ -31,7 +31,7 @@ class NativeEventFormViewController : XLFormViewController {
initializeForm()
}
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: NSBundle?) {
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
initializeForm()
}
@@ -50,7 +50,7 @@ class NativeEventFormViewController : XLFormViewController {
// Title
row = XLFormRowDescriptor(tag: "title", rowType: XLFormRowDescriptorTypeText)
row.cellConfigAtConfigure["textField.placeholder"] = "Title"
row.required = true
row.isRequired = true
section.addFormRow(row)
// Location
@@ -67,12 +67,12 @@ class NativeEventFormViewController : XLFormViewController {
// Starts
row = XLFormRowDescriptor(tag: "starts", rowType: XLFormRowDescriptorTypeDateTimeInline, title: "Starts")
row.value = NSDate(timeIntervalSinceNow: 60*60*24)
row.value = Date(timeIntervalSinceNow: 60*60*24)
section.addFormRow(row)
// Ends
row = XLFormRowDescriptor(tag: "ends", rowType: XLFormRowDescriptorTypeDateTimeInline, title: "Ends")
row.value = NSDate(timeIntervalSinceNow: 60*60*25)
row.value = Date(timeIntervalSinceNow: 60*60*25)
section.addFormRow(row)
section = XLFormSectionDescriptor.formSection()
@@ -82,12 +82,12 @@ class NativeEventFormViewController : XLFormViewController {
row = XLFormRowDescriptor(tag: "repeat", rowType:XLFormRowDescriptorTypeSelectorPush, title:"Repeat")
row.value = XLFormOptionsObject(value: 0, displayText: "Never")
row.selectorTitle = "Repeat"
row.selectorOptions = [XLFormOptionsObject(value: 0, displayText: "Never"),
XLFormOptionsObject(value: 1, displayText: "Every Day"),
XLFormOptionsObject(value: 2, displayText: "Every Week"),
XLFormOptionsObject(value: 3, displayText: "Every 2 Weeks"),
XLFormOptionsObject(value: 4, displayText: "Every Month"),
XLFormOptionsObject(value: 5, displayText: "Every Year")]
row.selectorOptions = [XLFormOptionsObject(value: 0, displayText: "Never")!,
XLFormOptionsObject(value: 1, displayText: "Every Day")!,
XLFormOptionsObject(value: 2, displayText: "Every Week")!,
XLFormOptionsObject(value: 3, displayText: "Every 2 Weeks")!,
XLFormOptionsObject(value: 4, displayText: "Every Month")!,
XLFormOptionsObject(value: 5, displayText: "Every Year")!]
section.addFormRow(row)
section = XLFormSectionDescriptor.formSection()
@@ -98,15 +98,15 @@ class NativeEventFormViewController : XLFormViewController {
row.value = XLFormOptionsObject(value: 0, displayText: "None")
row.selectorTitle = "Event Alert"
row.selectorOptions = [
XLFormOptionsObject(value: 0, displayText: "None"),
XLFormOptionsObject(value: 1, displayText: "At time of event"),
XLFormOptionsObject(value: 2, displayText: "5 minutes before"),
XLFormOptionsObject(value: 3, displayText: "15 minutes before"),
XLFormOptionsObject(value: 4, displayText: "30 minutes before"),
XLFormOptionsObject(value: 5, displayText: "1 hour before"),
XLFormOptionsObject(value: 6, displayText: "2 hours before"),
XLFormOptionsObject(value: 7, displayText: "1 day before"),
XLFormOptionsObject(value: 8, displayText: "2 days before")]
XLFormOptionsObject(value: 0, displayText: "None")!,
XLFormOptionsObject(value: 1, displayText: "At time of event")!,
XLFormOptionsObject(value: 2, displayText: "5 minutes before")!,
XLFormOptionsObject(value: 3, displayText: "15 minutes before")!,
XLFormOptionsObject(value: 4, displayText: "30 minutes before")!,
XLFormOptionsObject(value: 5, displayText: "1 hour before")!,
XLFormOptionsObject(value: 6, displayText: "2 hours before")!,
XLFormOptionsObject(value: 7, displayText: "1 day before")!,
XLFormOptionsObject(value: 8, displayText: "2 days before")!]
section.addFormRow(row)
@@ -117,8 +117,8 @@ class NativeEventFormViewController : XLFormViewController {
row = XLFormRowDescriptor(tag: "showAs", rowType:XLFormRowDescriptorTypeSelectorPush, title:"Show As")
row.value = XLFormOptionsObject(value: 0, displayText: "Busy")
row.selectorTitle = "Show As"
row.selectorOptions = [XLFormOptionsObject(value: 0, displayText:"Busy"),
XLFormOptionsObject(value: 1, displayText:"Free")]
row.selectorOptions = [XLFormOptionsObject(value: 0, displayText:"Busy")!,
XLFormOptionsObject(value: 1, displayText:"Free")!]
section.addFormRow(row)
section = XLFormSectionDescriptor.formSection()
@@ -139,83 +139,83 @@ class NativeEventFormViewController : XLFormViewController {
override func viewDidLoad(){
super.viewDidLoad()
navigationItem.leftBarButtonItem = UIBarButtonItem(barButtonSystemItem: .Cancel, target: self, action: "cancelPressed:")
navigationItem.rightBarButtonItem = UIBarButtonItem(barButtonSystemItem: .Save, target: self, action: "savePressed:")
navigationItem.leftBarButtonItem = UIBarButtonItem(barButtonSystemItem: .cancel, target: self, action: #selector(NativeEventFormViewController.cancelPressed(_:)))
navigationItem.rightBarButtonItem = UIBarButtonItem(barButtonSystemItem: .save, target: self, action: #selector(NativeEventFormViewController.savePressed(_:)))
}
// MARK: XLFormDescriptorDelegate
override func formRowDescriptorValueHasChanged(formRow: XLFormRowDescriptor!, oldValue: AnyObject!, newValue: AnyObject!) {
override func formRowDescriptorValueHasChanged(_ formRow: XLFormRowDescriptor!, oldValue: Any!, newValue: Any!) {
super.formRowDescriptorValueHasChanged(formRow, oldValue: oldValue, newValue: newValue)
if formRow.tag == "alert" {
if !formRow.value!.valueData().isEqual(0) && oldValue.valueData().isEqual(0) {
if !((formRow.value! as AnyObject).valueData() as AnyObject).isEqual(0) && ((oldValue as AnyObject).valueData() as AnyObject).isEqual(0) {
let newRow = formRow.copy() as! XLFormRowDescriptor
newRow.tag = "secondAlert"
newRow.title = "Second Alert"
form.addFormRow(newRow, afterRow:formRow)
}
else if !oldValue.valueData().isEqual(0) && newValue.valueData().isEqual(0) {
form.removeFormRowWithTag("secondAlert")
else if !((oldValue as AnyObject).valueData() as AnyObject).isEqual(0) && ((newValue as AnyObject).valueData() as AnyObject).isEqual(0) {
form.removeFormRow(withTag: "secondAlert")
}
}
else if formRow.tag == "all-day" {
let startDateDescriptor = form.formRowWithTag("starts")!
let endDateDescriptor = form.formRowWithTag("ends")!
let dateStartCell: XLFormDateCell = startDateDescriptor.cellForFormController(self) as! XLFormDateCell
let dateEndCell: XLFormDateCell = endDateDescriptor.cellForFormController(self) as! XLFormDateCell
if formRow.value!.valueData() as? Bool == true {
let startDateDescriptor = form.formRow(withTag: "starts")!
let endDateDescriptor = form.formRow(withTag: "ends")!
let dateStartCell: XLFormDateCell = startDateDescriptor.cell(forForm: self) as! XLFormDateCell
let dateEndCell: XLFormDateCell = endDateDescriptor.cell(forForm: self) as! XLFormDateCell
if (formRow.value! as AnyObject).valueData() as? Bool == true {
startDateDescriptor.valueTransformer = DateValueTrasformer.self
endDateDescriptor.valueTransformer = DateValueTrasformer.self
dateStartCell.formDatePickerMode = .Date
dateEndCell.formDatePickerMode = .Date
dateStartCell.formDatePickerMode = .date
dateEndCell.formDatePickerMode = .date
}
else{
startDateDescriptor.valueTransformer = DateTimeValueTrasformer.self
endDateDescriptor.valueTransformer = DateTimeValueTrasformer.self
dateStartCell.formDatePickerMode = .DateTime
dateEndCell.formDatePickerMode = .DateTime
dateStartCell.formDatePickerMode = .dateTime
dateEndCell.formDatePickerMode = .dateTime
}
updateFormRow(startDateDescriptor)
updateFormRow(endDateDescriptor)
}
else if formRow.tag == "starts" {
let startDateDescriptor = form.formRowWithTag("starts")!
let endDateDescriptor = form.formRowWithTag("ends")!
if startDateDescriptor.value!.compare(endDateDescriptor.value as! NSDate) == .OrderedDescending {
let startDateDescriptor = form.formRow(withTag: "starts")!
let endDateDescriptor = form.formRow(withTag: "ends")!
if (startDateDescriptor.value! as AnyObject).compare(endDateDescriptor.value as! Date) == .orderedDescending {
// startDateDescriptor is later than endDateDescriptor
endDateDescriptor.value = NSDate(timeInterval: 60*60*24, sinceDate: startDateDescriptor.value as! NSDate)
endDateDescriptor.cellConfig.removeObjectForKey("detailTextLabel.attributedText")
endDateDescriptor.value = Date(timeInterval: 60*60*24, since: startDateDescriptor.value as! Date)
endDateDescriptor.cellConfig.removeObject(forKey: "detailTextLabel.attributedText")
updateFormRow(endDateDescriptor)
}
}
else if formRow.tag == "ends" {
let startDateDescriptor = form.formRowWithTag("starts")!
let endDateDescriptor = form.formRowWithTag("ends")!
let dateEndCell = endDateDescriptor.cellForFormController(self) as! XLFormDateCell
if startDateDescriptor.value!.compare(endDateDescriptor.value as! NSDate) == .OrderedDescending {
let startDateDescriptor = form.formRow(withTag: "starts")!
let endDateDescriptor = form.formRow(withTag: "ends")!
let dateEndCell = endDateDescriptor.cell(forForm: self) as! XLFormDateCell
if (startDateDescriptor.value! as AnyObject).compare(endDateDescriptor.value as! Date) == .orderedDescending {
// startDateDescriptor is later than endDateDescriptor
dateEndCell.update()
let newDetailText = dateEndCell.detailTextLabel!.text!
let strikeThroughAttribute = [NSStrikethroughStyleAttributeName : NSUnderlineStyle.StyleSingle.rawValue]
let strikeThroughAttribute = [NSAttributedString.Key.strikethroughStyle : NSUnderlineStyle.single.rawValue]
let strikeThroughText = NSAttributedString(string: newDetailText, attributes: strikeThroughAttribute)
endDateDescriptor.cellConfig["detailTextLabel.attributedText"] = strikeThroughText
updateFormRow(endDateDescriptor)
}
else{
let endDateDescriptor = self.form.formRowWithTag("ends")!
endDateDescriptor.cellConfig.removeObjectForKey("detailTextLabel.attributedText")
let endDateDescriptor = self.form.formRow(withTag: "ends")!
endDateDescriptor.cellConfig.removeObject(forKey: "detailTextLabel.attributedText")
updateFormRow(endDateDescriptor)
}
}
}
func cancelPressed(button: UIBarButtonItem){
dismissViewControllerAnimated(true, completion: nil)
@objc func cancelPressed(_ button: UIBarButtonItem){
dismiss(animated: true, completion: nil)
}
func savePressed(button: UIBarButtonItem){
@objc func savePressed(_ button: UIBarButtonItem){
let validationErrors : Array<NSError> = formValidationErrors() as! Array<NSError>
if (validationErrors.count > 0){
showFormValidationError(validationErrors.first)
@@ -230,7 +230,7 @@ class NativeEventNavigationViewController : UINavigationController {
override func viewDidLoad(){
super.viewDidLoad()
view.tintColor = .redColor()
view.tintColor = .red
}
}
@@ -27,7 +27,7 @@ import MapKit
// Mark - NSValueTransformer
class NSArrayValueTrasformer : NSValueTransformer {
class NSArrayValueTrasformer : ValueTransformer {
override class func transformedValueClass() -> AnyClass {
return NSString.self
@@ -37,7 +37,7 @@ class NSArrayValueTrasformer : NSValueTransformer {
return false
}
override func transformedValue(value: AnyObject?) -> AnyObject? {
override func transformedValue(_ value: Any?) -> Any? {
if let arrayValue = value as? Array<AnyObject> {
return String(format: "%d Item%@", arrayValue.count, arrayValue.count > 1 ? "s" : "")
}
@@ -48,7 +48,7 @@ class NSArrayValueTrasformer : NSValueTransformer {
}
}
class ISOLanguageCodesValueTranformer : NSValueTransformer {
class ISOLanguageCodesValueTranformer : ValueTransformer {
override class func transformedValueClass() -> AnyClass {
return NSString.self
@@ -59,9 +59,9 @@ class ISOLanguageCodesValueTranformer : NSValueTransformer {
return false
}
override func transformedValue(value: AnyObject?) -> AnyObject? {
override func transformedValue(_ value: Any?) -> Any? {
if let stringValue = value as? String {
return NSLocale.currentLocale().displayNameForKey(NSLocaleLanguageCode, value: stringValue)
return (Locale.current as NSLocale).displayName(forKey: NSLocale.Key.languageCode, value: stringValue)
}
return nil
}
@@ -71,7 +71,7 @@ class ISOLanguageCodesValueTranformer : NSValueTransformer {
class SelectorsFormViewController : XLFormViewController {
private struct Tags {
fileprivate struct Tags {
static let Push = "selectorPush"
static let Popover = "selectorPopover"
static let ActionSheet = "selectorActionSheet"
@@ -90,7 +90,7 @@ class SelectorsFormViewController : XLFormViewController {
}
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: NSBundle?) {
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
initializeForm()
}
@@ -102,15 +102,15 @@ class SelectorsFormViewController : XLFormViewController {
override func viewDidLoad() {
super.viewDidLoad()
let barButton = UIBarButtonItem(title: "Disable", style: .Plain, target: self, action: "disableEnable:")
let barButton = UIBarButtonItem(title: "Disable", style: .plain, target: self, action: #selector(SelectorsFormViewController.disableEnable(_:)))
barButton.possibleTitles = Set(["Disable", "Enable"])
navigationItem.rightBarButtonItem = barButton
}
func disableEnable(button : UIBarButtonItem)
@objc func disableEnable(_ button : UIBarButtonItem)
{
form.disabled = !form.disabled
button.title = form.disabled ? "Enable" : "Disable"
form.isDisabled = !form.isDisabled
button.title = form.isDisabled ? "Enable" : "Disable"
tableView.endEditing(true)
tableView.reloadData()
}
@@ -122,25 +122,25 @@ class SelectorsFormViewController : XLFormViewController {
var row : XLFormRowDescriptor
form = XLFormDescriptor(title: "Selectors")
section = XLFormSectionDescriptor.formSectionWithTitle("Selectors")
section = XLFormSectionDescriptor.formSection(withTitle: "Selectors")
section.footerTitle = "SelectorsFormViewController.swift"
form.addFormSection(section)
// Selector Push
row = XLFormRowDescriptor(tag: Tags.Push, rowType:XLFormRowDescriptorTypeSelectorPush, title:"Push")
row.selectorOptions = [XLFormOptionsObject(value: 0, displayText: "Option 1"),
XLFormOptionsObject(value: 1, displayText:"Option 2"),
XLFormOptionsObject(value: 2, displayText:"Option 3"),
XLFormOptionsObject(value: 3, displayText:"Option 4"),
XLFormOptionsObject(value: 4, displayText:"Option 5")
row.selectorOptions = [XLFormOptionsObject(value: 0, displayText: "Option 1")!,
XLFormOptionsObject(value: 1, displayText:"Option 2")!,
XLFormOptionsObject(value: 2, displayText:"Option 3")!,
XLFormOptionsObject(value: 3, displayText:"Option 4")!,
XLFormOptionsObject(value: 4, displayText:"Option 5")!
]
row.value = XLFormOptionsObject(value: 1, displayText:"Option 2")
section.addFormRow(row)
// Selector Popover
if (UIDevice.currentDevice().userInterfaceIdiom == UIUserInterfaceIdiom.Pad){
if (UIDevice.current.userInterfaceIdiom == UIUserInterfaceIdiom.pad){
row = XLFormRowDescriptor(tag: Tags.Popover, rowType:XLFormRowDescriptorTypeSelectorPopover, title:"PopOver")
row.selectorOptions = ["Option 1", "Option 2", "Option 3", "Option 4", "Option 5", "Option 6"]
row.value = "Option 2"
@@ -169,7 +169,7 @@ class SelectorsFormViewController : XLFormViewController {
// --------- Fixed Controls
section = XLFormSectionDescriptor.formSectionWithTitle("Fixed Controls")
section = XLFormSectionDescriptor.formSection(withTitle: "Fixed Controls")
form.addFormSection(section)
row = XLFormRowDescriptor(tag: Tags.Picker, rowType:XLFormRowDescriptorTypePicker)
@@ -178,7 +178,7 @@ class SelectorsFormViewController : XLFormViewController {
section.addFormRow(row)
// --------- Inline Selectors
section = XLFormSectionDescriptor.formSectionWithTitle("Inline Selectors")
section = XLFormSectionDescriptor.formSection(withTitle: "Inline Selectors")
form.addFormSection(section)
row = XLFormRowDescriptor(tag: Tags.MultipleSelector, rowType:XLFormRowDescriptorTypeSelectorPickerViewInline, title:"Inline Picker View")
@@ -187,7 +187,7 @@ class SelectorsFormViewController : XLFormViewController {
section.addFormRow(row)
// --------- MultipleSelector
section = XLFormSectionDescriptor.formSectionWithTitle("Multiple Selectors")
section = XLFormSectionDescriptor.formSection(withTitle: "Multiple Selectors")
form.addFormSection(section)
row = XLFormRowDescriptor(tag: Tags.MultipleSelector, rowType:XLFormRowDescriptorTypeMultipleSelector, title:"Multiple Selector")
@@ -206,26 +206,26 @@ class SelectorsFormViewController : XLFormViewController {
// Language multiple selector
row = XLFormRowDescriptor(tag: Tags.MultipleSelector, rowType:XLFormRowDescriptorTypeMultipleSelector, title:"Multiple Selector")
row.selectorOptions = NSLocale.ISOLanguageCodes()
row.selectorOptions = Locale.isoLanguageCodes
row.selectorTitle = "Languages"
row.valueTransformer = ISOLanguageCodesValueTranformer.self
row.value = NSLocale.preferredLanguages()
row.value = Locale.preferredLanguages
section.addFormRow(row)
if UIDevice.currentDevice().userInterfaceIdiom == .Pad {
if UIDevice.current.userInterfaceIdiom == .pad {
// Language multiple selector popover
row = XLFormRowDescriptor(tag: Tags.MultipleSelectorPopover, rowType:XLFormRowDescriptorTypeMultipleSelectorPopover, title:"Multiple Selector PopOver")
row.selectorOptions = NSLocale.ISOLanguageCodes()
row.selectorOptions = Locale.isoLanguageCodes
row.valueTransformer = ISOLanguageCodesValueTranformer.self
row.value = NSLocale.preferredLanguages()
row.value = Locale.preferredLanguages
section.addFormRow(row)
}
// --------- Dynamic Selectors
section = XLFormSectionDescriptor.formSectionWithTitle("Dynamic Selectors")
section = XLFormSectionDescriptor.formSection(withTitle: "Dynamic Selectors")
form.addFormSection(section)
row = XLFormRowDescriptor(tag: Tags.DynamicSelectors, rowType:XLFormRowDescriptorTypeButton, title:"Dynamic Selectors")
@@ -235,7 +235,7 @@ class SelectorsFormViewController : XLFormViewController {
// --------- Custom Selectors
section = XLFormSectionDescriptor.formSectionWithTitle("Custom Selectors")
section = XLFormSectionDescriptor.formSection(withTitle: "Custom Selectors")
form.addFormSection(section)
row = XLFormRowDescriptor(tag: Tags.CustomSelectors, rowType:XLFormRowDescriptorTypeButton, title:"Custom Selectors")
@@ -244,7 +244,7 @@ class SelectorsFormViewController : XLFormViewController {
// --------- Selector definition types
section = XLFormSectionDescriptor.formSectionWithTitle("Selectors")
section = XLFormSectionDescriptor.formSection(withTitle: "Selectors")
form.addFormSection(section)
// selector with segue class
@@ -280,7 +280,7 @@ class SelectorsFormViewController : XLFormViewController {
}
override func storyboardForRow(formRow: XLFormRowDescriptor!) -> UIStoryboard! {
override func storyboard(forRow formRow: XLFormRowDescriptor!) -> UIStoryboard! {
return UIStoryboard(name: "iPhoneStoryboard", bundle:nil)
}
@@ -1,8 +1,10 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="9531" systemVersion="14F1021" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" initialViewController="p4n-1v-pzo">
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="14865.1" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" colorMatched="YES" initialViewController="p4n-1v-pzo">
<device id="retina6_1" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="9529"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14819.2"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<scenes>
<!--Navigation Controller-->
@@ -11,7 +13,7 @@
<navigationController automaticallyAdjustsScrollViewInsets="NO" id="p4n-1v-pzo" sceneMemberID="viewController">
<toolbarItems/>
<navigationBar key="navigationBar" contentMode="scaleToFill" id="SNt-hk-N3V">
<rect key="frame" x="0.0" y="0.0" width="320" height="44"/>
<rect key="frame" x="0.0" y="44" width="414" height="44"/>
<autoresizingMask key="autoresizingMask"/>
</navigationBar>
<nil name="viewControllers"/>
@@ -21,7 +23,7 @@
</navigationController>
<placeholder placeholderIdentifier="IBFirstResponder" id="jqF-cF-u4f" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="117" y="56"/>
<point key="canvasLocation" x="-107" y="43"/>
</scene>
<!--Others Form View Controller-->
<scene sceneID="dyJ-7m-RaD">
@@ -32,9 +34,9 @@
<viewControllerLayoutGuide type="bottom" id="HPb-Nx-E1G"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="wpr-wE-9nj">
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
<rect key="frame" x="0.0" y="0.0" width="414" height="896"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</view>
<navigationItem key="navigationItem" id="Hf0-cB-ORN"/>
<connections>
@@ -43,7 +45,7 @@
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="7YZ-ZR-X81" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="1533" y="-233"/>
<point key="canvasLocation" x="2221.739130434783" y="-156.02678571428569"/>
</scene>
<!--Native Event Form View Controller-->
<scene sceneID="EjT-rm-U3h">
@@ -54,15 +56,15 @@
<viewControllerLayoutGuide type="bottom" id="QuR-kY-o5R"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="tun-QW-CGC">
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
<rect key="frame" x="0.0" y="0.0" width="414" height="842"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<tableView clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" dataMode="prototypes" style="grouped" separatorStyle="default" rowHeight="44" sectionHeaderHeight="10" sectionFooterHeight="10" translatesAutoresizingMaskIntoConstraints="NO" id="JY7-WL-SnH">
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
<color key="backgroundColor" red="0.93725490196078431" green="0.93725490196078431" blue="0.95686274509803926" alpha="1" colorSpace="calibratedRGB"/>
<rect key="frame" x="0.0" y="0.0" width="414" height="808"/>
<color key="backgroundColor" red="0.93725490196078431" green="0.93725490196078431" blue="0.95686274509803926" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</tableView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstItem="JY7-WL-SnH" firstAttribute="leading" secondItem="tun-QW-CGC" secondAttribute="leading" id="bSe-SV-rx6"/>
<constraint firstAttribute="trailing" secondItem="JY7-WL-SnH" secondAttribute="trailing" id="jLI-68-pSq"/>
@@ -77,7 +79,7 @@
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="zV0-mq-irv" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="1120" y="-635"/>
<point key="canvasLocation" x="1623.1884057971015" y="-425.22321428571428"/>
</scene>
<!--Examples-->
<scene sceneID="wf7-ha-lXx">
@@ -88,20 +90,20 @@
<viewControllerLayoutGuide type="bottom" id="0bE-2H-tqE"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="PO9-pF-A7O">
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
<rect key="frame" x="0.0" y="0.0" width="414" height="896"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<tableView clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" dataMode="prototypes" style="grouped" separatorStyle="default" rowHeight="44" sectionHeaderHeight="10" sectionFooterHeight="10" translatesAutoresizingMaskIntoConstraints="NO" id="Lxj-Sb-kC6">
<rect key="frame" x="0.0" y="64" width="320" height="504"/>
<color key="backgroundColor" red="0.93725490196078431" green="0.93725490196078431" blue="0.95686274509803926" alpha="1" colorSpace="calibratedRGB"/>
<rect key="frame" x="0.0" y="88" width="414" height="774"/>
<color key="backgroundColor" red="0.93725490196078431" green="0.93725490196078431" blue="0.95686274509803926" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</tableView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstItem="Lxj-Sb-kC6" firstAttribute="top" secondItem="kOR-67-djF" secondAttribute="bottom" id="PT1-Xo-3Ql"/>
<constraint firstItem="Lxj-Sb-kC6" firstAttribute="top" secondItem="kOR-67-djF" secondAttribute="bottom" id="R5O-as-LEG"/>
<constraint firstAttribute="trailing" secondItem="Lxj-Sb-kC6" secondAttribute="trailing" id="brq-yF-WM8"/>
<constraint firstItem="Lxj-Sb-kC6" firstAttribute="leading" secondItem="PO9-pF-A7O" secondAttribute="leading" id="d73-kq-kX4"/>
<constraint firstItem="0bE-2H-tqE" firstAttribute="top" secondItem="Lxj-Sb-kC6" secondAttribute="bottom" id="ltM-g9-Dgm"/>
<constraint firstItem="0bE-2H-tqE" firstAttribute="top" secondItem="Lxj-Sb-kC6" secondAttribute="bottom" id="dMl-nD-Jm5"/>
</constraints>
</view>
<navigationItem key="navigationItem" title="Examples" id="sEr-D1-cU5"/>
@@ -118,7 +120,7 @@
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="1V5-DZ-WfF" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="527" y="56"/>
<point key="canvasLocation" x="763.768115942029" y="37.5"/>
</scene>
<!--Blog Example View Controller-->
<scene sceneID="Vn0-9y-5bc">
@@ -129,15 +131,15 @@
<viewControllerLayoutGuide type="bottom" id="scM-da-Sg0"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="hrV-fb-58s">
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
<rect key="frame" x="0.0" y="0.0" width="414" height="896"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</view>
<navigationItem key="navigationItem" id="RJB-cz-SnF"/>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="Fvo-wr-5Ca" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="167" y="1151"/>
<point key="canvasLocation" x="242.0289855072464" y="770.75892857142856"/>
</scene>
<!--Validation Examples-->
<scene sceneID="z2I-Nk-y9W">
@@ -148,15 +150,15 @@
<viewControllerLayoutGuide type="bottom" id="xtJ-Wo-mhU"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="1Ol-Ra-Ysg">
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
<rect key="frame" x="0.0" y="0.0" width="414" height="896"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<tableView clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" dataMode="prototypes" style="grouped" separatorStyle="default" rowHeight="44" sectionHeaderHeight="10" sectionFooterHeight="10" translatesAutoresizingMaskIntoConstraints="NO" id="Fty-3j-BeF">
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
<color key="backgroundColor" red="0.93725490196078431" green="0.93725490196078431" blue="0.95686274509803926" alpha="1" colorSpace="calibratedRGB"/>
<rect key="frame" x="0.0" y="24" width="414" height="838"/>
<color key="backgroundColor" red="0.93725490196078431" green="0.93725490196078431" blue="0.95686274509803926" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</tableView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstItem="xtJ-Wo-mhU" firstAttribute="top" secondItem="Fty-3j-BeF" secondAttribute="bottom" id="CbV-4f-RzP"/>
<constraint firstItem="Fty-3j-BeF" firstAttribute="top" secondItem="AG9-N9-2qp" secondAttribute="bottom" constant="-64" id="Pdw-VG-qcc"/>
@@ -173,7 +175,7 @@
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="VFT-Og-STO" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="566" y="938"/>
<point key="canvasLocation" x="820.28985507246387" y="628.125"/>
</scene>
<!--Predicate Form View Controller-->
<scene sceneID="a9p-C8-g8y">
@@ -184,15 +186,15 @@
<viewControllerLayoutGuide type="bottom" id="Lsg-dH-McH"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="6EZ-O7-FjX">
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
<rect key="frame" x="0.0" y="0.0" width="414" height="896"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</view>
<navigationItem key="navigationItem" id="Lsd-xH-7IN"/>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="rZL-10-YZn" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="956" y="924"/>
<point key="canvasLocation" x="1385.5072463768117" y="618.75"/>
</scene>
<!--Selectors Form View Controller-->
<scene sceneID="KYK-TX-8rm">
@@ -203,9 +205,9 @@
<viewControllerLayoutGuide type="bottom" id="CTu-Y5-7Qw"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="bNj-SD-83w">
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
<rect key="frame" x="0.0" y="0.0" width="414" height="896"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</view>
<navigationItem key="navigationItem" id="Buo-Af-6Q1"/>
<connections>
@@ -214,7 +216,7 @@
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="8fu-YK-6qz" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="1346" y="533"/>
<point key="canvasLocation" x="1950.7246376811595" y="356.91964285714283"/>
</scene>
<!--Map View Controller-->
<scene sceneID="tAS-lK-35t">
@@ -225,15 +227,15 @@
<viewControllerLayoutGuide type="bottom" id="cgQ-Vs-ICN"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="JjC-E5-SyY">
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
<rect key="frame" x="0.0" y="0.0" width="414" height="896"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</view>
<navigationItem key="navigationItem" id="BjG-Bq-0lD"/>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="LmS-YR-mFY" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="1789" y="533"/>
<point key="canvasLocation" x="2592.753623188406" y="356.91964285714283"/>
</scene>
<!--Native Event Navigation View Controller-->
<scene sceneID="mNb-be-ApA">
@@ -241,7 +243,7 @@
<navigationController automaticallyAdjustsScrollViewInsets="NO" id="K9D-4c-9eZ" customClass="NativeEventNavigationViewController" customModule="SwiftExample" customModuleProvider="target" sceneMemberID="viewController">
<toolbarItems/>
<navigationBar key="navigationBar" contentMode="scaleToFill" id="fO3-V7-XXu">
<rect key="frame" x="0.0" y="0.0" width="320" height="44"/>
<rect key="frame" x="0.0" y="0.0" width="414" height="56"/>
<autoresizingMask key="autoresizingMask"/>
</navigationBar>
<nil name="viewControllers"/>
@@ -251,7 +253,7 @@
</navigationController>
<placeholder placeholderIdentifier="IBFirstResponder" id="eqB-vl-BzH" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="588" y="-635"/>
<point key="canvasLocation" x="852.17391304347836" y="-425.22321428571428"/>
</scene>
<!--Basic Predicate View Controller-->
<scene sceneID="pD4-sm-x3a">
@@ -262,15 +264,15 @@
<viewControllerLayoutGuide type="bottom" id="2b4-gN-85p"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="NZg-t1-g19">
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
<rect key="frame" x="0.0" y="0.0" width="414" height="896"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</view>
<navigationItem key="navigationItem" id="1lh-jZ-lIV"/>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="Tlw-q2-pcu" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="-159" y="1151"/>
<point key="canvasLocation" x="-230.43478260869566" y="770.75892857142856"/>
</scene>
</scenes>
<inferredMetricsTieBreakers>
@@ -25,13 +25,13 @@
class UICustomizationFormViewController : XLFormViewController {
private struct Tags {
fileprivate struct Tags {
static let Name = "Name"
static let Button = "Button"
}
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: NSBundle?) {
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
self.initializeForm()
}
@@ -55,15 +55,15 @@ class UICustomizationFormViewController : XLFormViewController {
// Name
row = XLFormRowDescriptor(tag: Tags.Name, rowType: XLFormRowDescriptorTypeText, title:"Name")
// change the background color
row.cellConfigAtConfigure["backgroundColor"] = UIColor.greenColor()
row.cellConfigAtConfigure["backgroundColor"] = UIColor.green
// font
row.cellConfig["textLabel.font"] = UIFont.systemFontOfSize(30)
row.cellConfig["textLabel.font"] = UIFont.systemFont(ofSize: 30)
// background color
row.cellConfig["textField.backgroundColor"] = UIColor.grayColor()
row.cellConfig["textField.backgroundColor"] = UIColor.gray
// font
row.cellConfig["textField.font"] = UIFont.systemFontOfSize(25)
row.cellConfig["textField.font"] = UIFont.systemFont(ofSize: 25)
// alignment
row.cellConfig["textField.textAlignment"] = NSTextAlignment.Right.rawValue
row.cellConfig["textField.textAlignment"] = NSTextAlignment.right.rawValue
section.addFormRow(row)
@@ -73,23 +73,23 @@ class UICustomizationFormViewController : XLFormViewController {
//Button
row = XLFormRowDescriptor(tag: Tags.Button, rowType: XLFormRowDescriptorTypeButton, title:"Button")
row.cellConfigAtConfigure["backgroundColor"] = UIColor.purpleColor()
row.cellConfig["textLabel.color"] = UIColor.whiteColor()
row.cellConfig["textLabel.font"] = UIFont.systemFontOfSize(40)
row.cellConfigAtConfigure["backgroundColor"] = UIColor.purple
row.cellConfig["textLabel.color"] = UIColor.white
row.cellConfig["textLabel.font"] = UIFont.systemFont(ofSize: 40)
section.addFormRow(row)
self.form = form
}
override func tableView(tableView: UITableView, heightForRowAtIndexPath indexPath: NSIndexPath) -> CGFloat {
override func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat {
// change cell height of a particular cell
if form.formRowAtIndex(indexPath)?.tag == "Name" {
if form.formRow(atIndex: indexPath)?.tag == "Name" {
return 60.0
}
else if form.formRowAtIndex(indexPath)?.tag == "Button" {
else if form.formRow(atIndex: indexPath)?.tag == "Button" {
return 100.0
}
return super.tableView(tableView, heightForRowAtIndexPath: indexPath)
return super.tableView(tableView, heightForRowAt: indexPath)
}
}
@@ -26,7 +26,7 @@
class ValidationExamplesFormViewController : XLFormViewController {
private struct Tags {
fileprivate struct Tags {
static let ValidationName = "Name"
static let ValidationEmail = "Email"
static let ValidationPassword = "Password"
@@ -34,7 +34,7 @@ class ValidationExamplesFormViewController : XLFormViewController {
}
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: NSBundle?) {
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
initializeForm()
}
@@ -60,8 +60,8 @@ class ValidationExamplesFormViewController : XLFormViewController {
// Name
row = XLFormRowDescriptor(tag: Tags.ValidationName, rowType: XLFormRowDescriptorTypeText, title:"Name")
row.cellConfigAtConfigure["textField.placeholder"] = "Required..."
row.cellConfigAtConfigure["textField.textAlignment"] = NSTextAlignment.Right.rawValue
row.required = true
row.cellConfigAtConfigure["textField.textAlignment"] = NSTextAlignment.right.rawValue
row.isRequired = true
row.value = "Martin"
section.addFormRow(row)
@@ -71,10 +71,10 @@ class ValidationExamplesFormViewController : XLFormViewController {
// Email
row = XLFormRowDescriptor(tag: Tags.ValidationEmail, rowType: XLFormRowDescriptorTypeText, title:"Email")
row.cellConfigAtConfigure["textField.textAlignment"] = NSTextAlignment.Right.rawValue
row.required = false
row.cellConfigAtConfigure["textField.textAlignment"] = NSTextAlignment.right.rawValue
row.isRequired = false
row.value = "not valid email"
row.addValidator(XLFormValidator.emailValidator())
row.addValidator(XLFormValidator.email())
section.addFormRow(row)
@@ -86,8 +86,8 @@ class ValidationExamplesFormViewController : XLFormViewController {
// Password
row = XLFormRowDescriptor(tag: Tags.ValidationPassword, rowType: XLFormRowDescriptorTypePassword, title:"Password")
row.cellConfigAtConfigure["textField.placeholder"] = "Required..."
row.cellConfigAtConfigure["textField.textAlignment"] = NSTextAlignment.Right.rawValue
row.required = true
row.cellConfigAtConfigure["textField.textAlignment"] = NSTextAlignment.right.rawValue
row.isRequired = true
row.addValidator(XLFormRegexValidator(msg: "At least 6, max 32 characters", andRegexString: "^(?=.*\\d)(?=.*[A-Za-z]).{6,32}$"))
section.addFormRow(row)
@@ -100,8 +100,8 @@ class ValidationExamplesFormViewController : XLFormViewController {
// Integer
row = XLFormRowDescriptor(tag: Tags.ValidationInteger, rowType:XLFormRowDescriptorTypeInteger, title:"Integer")
row.cellConfigAtConfigure["textField.placeholder"] = "Required..."
row.cellConfigAtConfigure["textField.textAlignment"] = NSTextAlignment.Right.rawValue
row.required = true
row.cellConfigAtConfigure["textField.textAlignment"] = NSTextAlignment.right.rawValue
row.isRequired = true
row.addValidator(XLFormRegexValidator(msg: "greater than 50 and less than 100", andRegexString: "^([5-9][0-9]|100)$"))
section.addFormRow(row)
@@ -111,30 +111,30 @@ class ValidationExamplesFormViewController : XLFormViewController {
override func viewDidLoad() {
super.viewDidLoad()
navigationItem.rightBarButtonItem?.target = self
navigationItem.rightBarButtonItem?.action = "validateForm:"
navigationItem.rightBarButtonItem?.action = #selector(ValidationExamplesFormViewController.validateForm(_:))
}
//MARK: Actions
func validateForm(buttonItem: UIBarButtonItem) {
@objc func validateForm(_ buttonItem: UIBarButtonItem) {
let array = formValidationErrors()
for errorItem in array {
for errorItem in array! {
let error = errorItem as! NSError
let validationStatus : XLFormValidationStatus = error.userInfo[XLValidationStatusErrorKey] as! XLFormValidationStatus
if validationStatus.rowDescriptor!.tag == Tags.ValidationName {
if let rowDescriptor = validationStatus.rowDescriptor, let indexPath = form.indexPathOfFormRow(rowDescriptor), let cell = tableView.cellForRowAtIndexPath(indexPath) {
cell.backgroundColor = .orangeColor()
UIView.animateWithDuration(0.3, animations: { () -> Void in
cell.backgroundColor = .whiteColor()
if let rowDescriptor = validationStatus.rowDescriptor, let indexPath = form.indexPath(ofFormRow: rowDescriptor), let cell = tableView.cellForRow(at: indexPath) {
cell.backgroundColor = .orange
UIView.animate(withDuration: 0.3, animations: { () -> Void in
cell.backgroundColor = .white
})
}
}
else if validationStatus.rowDescriptor!.tag == Tags.ValidationEmail ||
validationStatus.rowDescriptor!.tag == Tags.ValidationPassword ||
validationStatus.rowDescriptor!.tag == Tags.ValidationInteger {
if let rowDescriptor = validationStatus.rowDescriptor, let indexPath = form.indexPathOfFormRow(rowDescriptor), let cell = tableView.cellForRowAtIndexPath(indexPath) {
if let rowDescriptor = validationStatus.rowDescriptor, let indexPath = form.indexPath(ofFormRow: rowDescriptor), let cell = tableView.cellForRow(at: indexPath) {
self.animateCell(cell)
}
}
@@ -144,14 +144,14 @@ class ValidationExamplesFormViewController : XLFormViewController {
//MARK: - Helperph
func animateCell(cell: UITableViewCell) {
func animateCell(_ cell: UITableViewCell) {
let animation = CAKeyframeAnimation()
animation.keyPath = "position.x"
animation.values = [0, 20, -20, 10, 0]
animation.keyTimes = [0, (1 / 6.0), (3 / 6.0), (5 / 6.0), 1]
animation.keyTimes = [0, NSNumber(value: 1 / 6.0), NSNumber(value: 3 / 6.0), NSNumber(value: 5 / 6.0), 1]
animation.duration = 0.3
animation.timingFunction = CAMediaTimingFunction(name: kCAMediaTimingFunctionEaseOut)
animation.additive = true
cell.layer.addAnimation(animation, forKey: "shake")
animation.timingFunction = CAMediaTimingFunction(name: CAMediaTimingFunctionName.easeOut)
animation.isAdditive = true
cell.layer.add(animation, forKey: "shake")
}
}
+21
View File
@@ -0,0 +1,21 @@
// swift-tools-version:5.2
import PackageDescription
let package = Package(
name: "XLForm",
platforms: [
.iOS(.v9)
],
products: [
.library(name: "XLForm", targets: ["XLForm"])
],
dependencies: [],
targets: [
.target(
name: "XLForm",
dependencies: [],
path: "XLForm",
publicHeadersPath: "XL"
)
]
)
+226 -67
View File
@@ -1,12 +1,11 @@
XLForm
---------------
By [XMARTLABS](http://xmartlabs.com).
![XLForm](https://raw.githubusercontent.com/xmartlabs/XLForm/master/XLForm.png)
[![Build Status](https://travis-ci.org/xmartlabs/XLForm.svg?branch=master)](https://travis-ci.org/xmartlabs/XLForm)
[![license](https://img.shields.io/badge/pod-3.1.1-blue.svg)](https://github.com/xmartlabs/XLForm/releases)
<a href="https://cocoapods.org/pods/XLForm"><img src="https://img.shields.io/cocoapods/v/XLForm.svg" alt="CocoaPods compatible" /></a>
**If you are looking for Swift 2 native implementation we have recently created [Eureka], a complete re-design of XLForm in Swift 2.** *Do not panic, We will continue maintaining and improving XLForm, obj-c rocks!!*
**If you are working in Swift then you should have a look at [Eureka], a complete re-design of XLForm in Swift and with more features.**
We are not implementing any new features for XLForm anymore. However, if a critical issue arises we will fix it.
Purpose
--------------
@@ -15,7 +14,7 @@ XLForm is the most flexible and powerful iOS library to create dynamic table-vie
XLForm provides a very powerful DSL (Domain Specific Language) used to create a form. It keeps track of this specification on runtime, updating the UI on the fly.
#####Let's see the iOS Calendar Event Form created using XLForm
##### Let's see the iOS Calendar Event Form created using XLForm
![Screenshot of native Calendar Event Example](Examples/Objective-C/Examples/RealExamples/XLForm.gif)
@@ -38,8 +37,75 @@ What XLForm does
How to create a form
-----------------------------
## How to create a form
#### Create an instance of XLFormViewController
##### Swift
```swift
class CalendarEventFormViewController : XLFormViewController {
required init(coder aDecoder: NSCoder) {
super.init(coder: aDecoder)
self.initializeForm()
}
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: NSBundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
self.initializeForm()
}
func initializeForm() {
// Implementation details covered in the next section.
}
}
```
##### Objective-C
```objc
#import "XLFormViewController.h"
@interface CalendarEventFormViewController: XLFormViewController
@end
```
```objc
@interface ExamplesFormViewController ()
@end
@implementation ExamplesFormViewController
- (instancetype)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil {
self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
if (self){
[self initializeForm];
}
return self;
}
- (id)initWithCoder:(NSCoder *)aDecoder {
self = [super initWithCoder:aDecoder];
if (self){
[self initializeForm];
}
return self;
}
- (void)initializeForm {
// Implementation details covered in the next section.
}
@end
```
##### Implementing the initializeForm method
To create a form we should declare it through a `XLFormDescriptor` instance and assign it to a `XLFormViewController` instance. As we said XLForm works based on a DSL that hides complex and boilerplate stuff without losing the power and flexibility of hand-made forms.
@@ -51,50 +117,58 @@ To define a form we use 3 classes:
A form definition is a `XLFormDescriptor` instance that contains one or more sections (`XLFormSectionDescriptor` instances) and each section contains several rows (`XLFormRowDescriptor` instance). As you may have noticed the DSL structure is analog to the structure of a `UITableView` (Table -->> Sections -- >> Rows). The resulting table-view form's structure (sections and rows order) mirrors the definition's structure.
#####Let's see part of the iOS Calendar Event Form definition.
##### Let's see an example implementation of initializeForm to define the iOS Calendar Event Form
```objc
XLFormDescriptor * form;
XLFormSectionDescriptor * section;
XLFormRowDescriptor * row;
- (void)initializeForm {
XLFormDescriptor * form;
XLFormSectionDescriptor * section;
XLFormRowDescriptor * row;
form = [XLFormDescriptor formDescriptorWithTitle:@"Add Event"];
form = [XLFormDescriptor formDescriptorWithTitle:@"Add Event"];
// First section
section = [XLFormSectionDescriptor formSection];
[form addFormSection:section];
// First section
section = [XLFormSectionDescriptor formSection];
[form addFormSection:section];
// Title
row = [XLFormRowDescriptor formRowDescriptorWithTag:@"title" rowType:XLFormRowDescriptorTypeText];
[row.cellConfigAtConfigure setObject:@"Title" forKey:@"textField.placeholder"];
[section addFormRow:row];
// Title
row = [XLFormRowDescriptor formRowDescriptorWithTag:@"title" rowType:XLFormRowDescriptorTypeText];
[row.cellConfigAtConfigure setObject:@"Title" forKey:@"textField.placeholder"];
[section addFormRow:row];
// Location
row = [XLFormRowDescriptor formRowDescriptorWithTag:@"location" rowType:XLFormRowDescriptorTypeText];
[row.cellConfigAtConfigure setObject:@"Location" forKey:@"textField.placeholder"];
[section addFormRow:row];
// Location
row = [XLFormRowDescriptor formRowDescriptorWithTag:@"location" rowType:XLFormRowDescriptorTypeText];
[row.cellConfigAtConfigure setObject:@"Location" forKey:@"textField.placeholder"];
[section addFormRow:row];
// Second Section
section = [XLFormSectionDescriptor formSection];
[form addFormSection:section];
// Second Section
section = [XLFormSectionDescriptor formSection];
[form addFormSection:section];
// All-day
row = [XLFormRowDescriptor formRowDescriptorWithTag:@"all-day" rowType:XLFormRowDescriptorTypeBooleanSwitch title:@"All-day"];
[section addFormRow:row];
// All-day
row = [XLFormRowDescriptor formRowDescriptorWithTag:@"all-day" rowType:XLFormRowDescriptorTypeBooleanSwitch title:@"All-day"];
[section addFormRow:row];
// Starts
row = [XLFormRowDescriptor formRowDescriptorWithTag:@"starts" rowType:XLFormRowDescriptorTypeDateTimeInline title:@"Starts"];
row.value = [NSDate dateWithTimeIntervalSinceNow:60*60*24];
[section addFormRow:row];
// Starts
row = [XLFormRowDescriptor formRowDescriptorWithTag:@"starts" rowType:XLFormRowDescriptorTypeDateTimeInline title:@"Starts"];
row.value = [NSDate dateWithTimeIntervalSinceNow:60*60*24];
[section addFormRow:row];
self.form = form;
}
```
XLForm will load the table-view form from the previously explained definition. The most interesting part is that it will update the table-view form based on the form definition modifications.
That means that we are able to make changes on the table-view form adding or removing section definitions or row definitions to the form definition on runtime and you will never need to care again about `NSIndexPath`, `UITableViewDelegate`, `UITableViewDataSource` or other complexities.
**To see more complex form definitions take a look at the example application in the Examples folder of this repository. You can also run the examples on your own device if you wish.** XLForm **has no** dependencies over other pods, anyway the examples project makes use of some cocoapods to show advanced XLForm features.
## Using XLForm with Storyboards
* Perform the steps from **How to create a form**
* In Interface Builder (IB), drag-and-drop a **UIViewController** onto the Storyboard
* Associate your custom form class to the **UIViewController** using the **Identity Inspector**
How to run XLForm examples
---------------------------------
@@ -107,7 +181,7 @@ How to run XLForm examples
Rows
---------------------
####Input Rows
#### Input Rows
![Screenshot of Input Examples](Examples/Objective-C/Examples/Inputs/XLForm-Inputs.gif)
@@ -178,7 +252,7 @@ Will be represented by a `UITextView` with `UITextAutocorrectionTypeDefault`, `U
####Selector Rows
#### Selector Rows
Selector rows allow us to select a value or values from a list. XLForm supports 8 types of selectors out of the box:
@@ -245,7 +319,7 @@ This is the protocol declaration:
```
####Date & Time Rows
#### Date & Time Rows
XLForms supports 3 types of dates: `Date`, `DateTime` , `Time` and `Countdown Timer` and it's able to present the `UIDatePicker` control in 2 different ways, inline and non-inline.
@@ -352,7 +426,7 @@ section.addFormRow(row)
self.form = form;
```
####Boolean Rows
#### Boolean Rows
XLForms supports 2 types of boolean controls:
@@ -370,9 +444,9 @@ static NSString *const XLFormRowDescriptorTypeBooleanSwitch = @"booleanSwitch";
We can also simulate other types of Boolean rows using any of the Selector Row Types introduced in the [Selector Rows section](#selector-rows).
####Other Rows
#### Other Rows
#####Stepper
##### Stepper
XLForms supports counting using UIStepper control:
@@ -394,7 +468,7 @@ You can set the stepper paramaters easily:
[row.cellConfigAtConfigure setObject:@100 forKey:@"stepControl.maximumValue"];
```
#####Slider
##### Slider
XLForms supports counting using UISlider control:
@@ -415,11 +489,11 @@ You can adjust the slider for your own interests very easily:
Set `steps` to `@(0)` to disable the steps functionality.
#####Info
##### Info
Sometimes our apps needs to show data that are not editable. XLForm provides us with `XLFormRowDescriptorTypeInfo` row type to display not editable info. An example of usage would be showing the app version in the settings part of an app.
Sometimes our apps needs to show data that are not editable. XLForm provides us with `XLFormRowDescriptorTypeInfo` row type to display not editable info. An example of usage would be showing the app version in the settings part of an app.
#####Button
##### Button
Apart from data entry rows, not editable rows and selectors, XLForm has a button row `XLFormRowDescriptorTypeButton` that allows us to do any action when selected. It can be configured using a block (clousure), a selector, a segue identifier, segue class or specifing a view controller to be presented. ViewController specification could be done by setting up the view controller class, the view controller storyboard Id or a nib name. Nib name must match view controller class name.
@@ -427,7 +501,7 @@ Apart from data entry rows, not editable rows and selectors, XLForm has a button
Multivalued Sections (Insert, Delete, Reorder rows)
------------------------
Any `XLFormSectionDescriptor` object can be set up to support row insertion, deletion or reodering. It is possible to enable only one of these modes, a combination or all together.
Any `XLFormSectionDescriptor` object can be set up to support row insertion, deletion or reodering. It is possible to enable only one of these modes, a combination or all together.
A multivalued section is just a section that support either of these modes.
The most interesting part of multivalued `XLFormSectionDescriptor` is that it supports all the types of rows that were shown on the [*Rows*](#rows "Rows") section as well as custom rows.
@@ -591,7 +665,7 @@ row.action.viewControllerClass = [MapViewController class];
// or
//row.action.viewControllerNibName = @"MapViewControllerNibName";
// Set up a NSValueTransformer to convert CLLocation to NSString, it's used to show the select value description (text).
// Set up a NSValueTransformer to convert CLLocation to NSString, it's used to show the select value description (text).
row.valueTransformer = [CLLocationValueTrasformer class];
// Set up the default value
row.value = [[CLLocation alloc] initWithLatitude:-33 longitude:-56];
@@ -615,6 +689,8 @@ XLForm sets up `rowDescriptor` property using the `XLFormRowDescriptor` instance
The developer is responsible for update its views with the `rowDescriptor` value as well as set the selected value to `rowDescriptor` from within the custom selector view controller.
> Note: the properties `viewControllerClass`, `viewControllerNibName` or `viewControllerStoryboardId` are mutually exclusive and are used by `XLFormButtonCell` and `XLFormSelectorCell`. If you create a custom cell then you are responsible for using them.
#### Another example
@@ -690,7 +766,7 @@ For instance if we want to show or hide a row depending on the value of another
Make a row or section invisible depending on other rows values
--------------------------------
###Summary
### Summary
XLForm allows you to define dependencies between rows so that if the value of one row is changed, the behaviour of another one changes automatically. For example, you might have a form where you question the user if he/she has pets. If the answer is 'yes' you might want to ask how their names are.
So you can make a row invisible and visible again based on the values of other rows. The same happens with sections.
@@ -700,7 +776,7 @@ Take a look at the following example:
Of course, you could also do this manually by observing the value of some rows and deleting and adding rows accordingly, but that would be a lot of work which is already done.
###How it works
### How it works
To make the appearance and disappearance of rows and sections automatic, there is a property in each descriptor:
@@ -789,6 +865,7 @@ You may want to set up another properties of the `UITableViewCell`. To set up an
You just have to add the properties to `cellConfig` or `cellConfigAtConfigure` dictionary property of `XLFormRowDescriptor`.
The main difference between `cellConfig` and `cellConfigAtConfigure` is the time when the property is set up. `cellConfig` properties are set up each time a cell is about to be displayed. `cellConfigAtConfigure`, on the other hand, set up the property just after the init method of the cell is called and only one time.
Since version 3.3.0 you can also use `cellConfigForSelector` to configure how the cells of the `XLFormOptionsViewController` look like when it is shown for a selector row.
For instance if you want to set up the placeholder you can do the following:
@@ -804,7 +881,7 @@ Let's see how to change the color of the cell label:
```objc
row = [XLFormRowDescriptor formRowDescriptorWithTag:@"title" rowType:XLFormRowDescriptorTypeText];
[row.cellConfigAtConfigure setObject:[UIColor redColor] forKey:@"textLabel.textColor"];
[row.cellConfig setObject:[UIColor redColor] forKey:@"textLabel.textColor"];
[section addFormRow:row];
```
@@ -819,6 +896,25 @@ section.addFormRow(row)
FAQ
-------
#### How to customize the header and/or footer of a section
For this you should use the UITableViewDelegate methods in your XLFormViewController.
This means you should implement one or both of these:
```objc
-(UIView *)tableView:(UITableView *)tableView viewForHeaderInSection:(NSInteger)section
-(UIView *)tableView:(UITableView *)tableView viewForFooterInSection:(NSInteger)section
```
Also you might want to implement the following methods to specify the height for these views:
```objc
-(CGFloat)tableView:(UITableView *)tableView heightForHeaderInSection:(NSInteger)section
-(CGFloat)tableView:(UITableView *)tableView heightForFooterInSection:(NSInteger)section
```
#### How to assign the first responder on form appearance
Assign the first responder when the form is shown is as simple as setting the property `assignFirstResponderOnShow` to `YES`. By default the value of the property is `NO`.
@@ -930,7 +1026,7 @@ row.cellConfig.setObject(UIFont(name: "AppleSDGothicNeo-Regular", size: 17)!, fo
For further details, please take a look at [UICustomizationFormViewController.m](/Examples/Objective-C/Examples/UICustomization/UICustomizationFormViewController.m) example.
####How to set min/max for date cells?
#### How to set min/max for date cells?
Each XLFormDateCell has a `minimumDate` and a `maximumDate` property. To set a datetime row to be a value in the next three days you would do as follows:
@@ -999,26 +1095,64 @@ This is how you can set them:
[row.cellConfigAtConfigure setObject:@(UIReturnKeyGo) forKey:@"nextReturnKeyType"];
```
#### How to change the height of one cell
If you want to change the height for all cells of one class you should subclass that cell and override the class method `formDescriptorCellHeightForRowDescriptor`.
If you want to change the height of one individual cell then you can set that height to the `height` property of XLFormRowDescripto like this:
```
XLFormRowDescriptor* row = ...
row.height = 55;
```
#### How to change the appearance of the cells of a selector view controller (XLFormOptionsViewController)
To change the appearance of the cells of a XLFormOptionsViewController you can use the `cellConfigForSelector` property on the row descriptor.
Example:
```
[row.cellConfigForSelector setObject:[UIColor redColor] forKey:@"textLabel.textColor"];
```
#### How to limit the characters of a XLFormTextFieldCell or a XLFormTextViewCell
You can make this happen using the `textFieldMaxNumberOfCharacters` and the `textViewMaxNumberOfCharacters` respectively.
```
[row.cellConfigAtConfigure setObject:@(20) forKey:@"textViewMaxNumberOfCharacters"];
```
Installation
--------------------------
## Swift Package Manager
Starting with Xcode 11, Swift Package Manager is the recommended and preferred way for installing dependencies in Xcode projects. Installing dependencies via SwiftPM does not require the application nor dependencies to be written in Swift.
To add XLForm to your project using SwiftPM follow these steps:
1. Open your project in Xcode
1. In the main menu, select File -> Swift Packages -> Add Package Dependency...
1. In the window, enter the package url https://github.com/xmartlabs/XLForm
1. Configure the version to be used
To use XLForm in your code, import the module or header files as needed:
```objc
#import "XLForm.h" // Obj-c
```
```swift
import XLForm // Swift
```
## CocoaPods
1. Add the following line in the project's Podfile file:
`pod 'XLForm', '~> 3.0'`.
`pod 'XLForm', '~> 4.3'`.
2. Run the command `pod install` from the Podfile folder directory.
XLForm **has no** dependencies over other pods.
## Carthage
In your `Cartfile` add:
```
github "xmartlabs/XLForm" ~> 3.0
```
### How to use master branch
#### How to use master branch
Often master branch contains most recent features and latest fixes. On the other hand this features was not fully tested and changes on master may occur at any time. For the previous reasons I stongly recommend to fork the repository and manage the updates from master on your own making the proper pull on demand.
@@ -1029,7 +1163,7 @@ To use xmartlabs master branch.....
You can replace the repository URL for your forked version url if you wish.
### How to use XLForm in Swift files
#### How to use XLForm in Swift files
If you have installed XLForm with cocoapods and have set `use_frameworks!` in your Podfile, you can add `import XLForm` to any Swift file.
@@ -1037,18 +1171,43 @@ If you are using cocoapods but have not set `use_frameworks!` in your Podfile, a
For further details on how to create and configure the bridging header file visit [*Importing Objective-C into Swift*](https://developer.apple.com/library/ios/documentation/Swift/Conceptual/BuildingCocoaApps/MixandMatch.html "Importing Objective-C into Swift").
## Carthage
In your `Cartfile` add:
```
github "xmartlabs/XLForm" ~> 4.2
```
## Using git submodules
* Clone XLForm as a git [submodule](http://git-scm.com/docs/git-submodule) by running the following command from your project root git folder.
```bash
$ git submodule add https://github.com/xmartlabs/XLForm.git
```
* Open XLForm folder that was created by the previous git submodule command and drag the XLForm.xcodeproj into the Project Navigator of your application's Xcode project.
* Select the XLForm.xcodeproj in the Project Navigator and verify the deployment target matches with your application deployment target.
* Select your project in the Xcode Navigation and then select your application target from the sidebar. Next select the "General" tab and click on the + button under the "Embedded Binaries" section.
* Select `XLForm.framework` and we are done!
Requirements
-----------------------------
* ARC
* iOS 7.0 and above
* XCode 6.3+
* iOS 9.0 and above
* Xcode 9.0+ (11.0+ for installation via Swift Package Manager)
Release Notes
--------------
Have a look at the [CHANGELOG](https://github.com/xmartlabs/XLForm/CHANGELOG.md)
Have a look at the [CHANGELOG](https://github.com/xmartlabs/XLForm/blob/master/CHANGELOG.md)
Author
-----------------
+2 -2
View File
@@ -3,7 +3,7 @@ include FileUtils::Verbose
namespace :test do
desc "Run the XLForm Tests"
task :ios do
run_tests('XLForm Tests', 'iphonesimulator9.2')
run_tests('XLForm Tests', 'iphonesimulator')
tests_failed unless $?.success?
end
end
@@ -17,7 +17,7 @@ task :default => 'test'
private
def run_tests(scheme, sdk)
sh("xcodebuild -workspace 'Tests/XLForm Tests.xcworkspace' -scheme '#{scheme}' -sdk '#{sdk}' -destination 'name=iPhone 6' -configuration Release clean test | xcpretty -c ; exit ${PIPESTATUS[0]}") rescue nil
sh("xcodebuild -workspace 'Tests/XLForm Tests.xcworkspace' -scheme '#{scheme}' -sdk '#{sdk}' -destination 'OS=14.0,name=iPhone 11' -configuration Release clean test | xcpretty -c ; exit ${PIPESTATUS[0]}") rescue nil
end
def tests_failed
+4 -3
View File
@@ -1,9 +1,10 @@
source 'https://github.com/CocoaPods/Specs.git'
source 'https://cdn.cocoapods.org/'
project 'XLForm Tests'
inhibit_all_warnings!
platform :ios, '7.0'
platform :ios, '9.0'
target 'XLForm Tests' do
pod 'Expecta', '~> 0.3.0'
pod 'Expecta', '~> 1.0'
pod 'XLForm', :path => '../'
end
+94 -51
View File
@@ -7,19 +7,22 @@
objects = {
/* Begin PBXBuildFile section */
17538872B9BB29167787CF50 /* libPods-XLForm Tests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = E68572C5C8328F0F177BBCA1 /* libPods-XLForm Tests.a */; };
03885A911D7DD3BD00CC183A /* XLTestTextFieldProperties.m in Sources */ = {isa = PBXBuildFile; fileRef = 03885A901D7DD3BD00CC183A /* XLTestTextFieldProperties.m */; };
28657A3E1990879200CE8180 /* XCTest.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 28657A3D1990879200CE8180 /* XCTest.framework */; };
28657A401990879200CE8180 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 28657A3F1990879200CE8180 /* Foundation.framework */; };
28657A421990879200CE8180 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 28657A411990879200CE8180 /* UIKit.framework */; };
28657A481990879200CE8180 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 28657A461990879200CE8180 /* InfoPlist.strings */; };
28657A5219914F9700CE8180 /* XLTestCase.m in Sources */ = {isa = PBXBuildFile; fileRef = 28657A5119914F9700CE8180 /* XLTestCase.m */; };
28657A54199154EE00CE8180 /* XLFormValidatorsTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 28657A53199154EE00CE8180 /* XLFormValidatorsTests.m */; };
39585558ED414BFBE6FFB93C /* libPods-XLForm Tests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 8189C74AF1BF64FDF4D14AE3 /* libPods-XLForm Tests.a */; };
3C5B9B7A1AC0BA33000AF1BA /* XLFormExampleTest.m in Sources */ = {isa = PBXBuildFile; fileRef = 3C5B9B791AC0BA33000AF1BA /* XLFormExampleTest.m */; };
3C9817861AC30616003F6ABD /* UITextField+Test.m in Sources */ = {isa = PBXBuildFile; fileRef = 3C9817851AC30616003F6ABD /* UITextField+Test.m */; };
6233D65F1D7DF022000E7716 /* XLTestTextViewProperties.m in Sources */ = {isa = PBXBuildFile; fileRef = 6233D65E1D7DF022000E7716 /* XLTestTextViewProperties.m */; };
BFD111841AD8323900943D23 /* XLTestHideAndShow.m in Sources */ = {isa = PBXBuildFile; fileRef = BFD111831AD8323900943D23 /* XLTestHideAndShow.m */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
03885A901D7DD3BD00CC183A /* XLTestTextFieldProperties.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLTestTextFieldProperties.m; path = Test/XLTestTextFieldProperties.m; sourceTree = "<group>"; };
28657A3A1990879200CE8180 /* XLForm Tests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "XLForm Tests.xctest"; sourceTree = BUILT_PRODUCTS_DIR; };
28657A3D1990879200CE8180 /* XCTest.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = XCTest.framework; path = Library/Frameworks/XCTest.framework; sourceTree = DEVELOPER_DIR; };
28657A3F1990879200CE8180 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = Library/Frameworks/Foundation.framework; sourceTree = DEVELOPER_DIR; };
@@ -30,16 +33,14 @@
28657A5019914F9700CE8180 /* XLTestCase.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLTestCase.h; path = Test/XLTestCase.h; sourceTree = "<group>"; };
28657A5119914F9700CE8180 /* XLTestCase.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLTestCase.m; path = Test/XLTestCase.m; sourceTree = "<group>"; };
28657A53199154EE00CE8180 /* XLFormValidatorsTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormValidatorsTests.m; path = Test/XLFormValidatorsTests.m; sourceTree = "<group>"; };
35038A584FCFD0693D23F189 /* Pods-XLForm Tests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-XLForm Tests.debug.xcconfig"; path = "Pods/Target Support Files/Pods-XLForm Tests/Pods-XLForm Tests.debug.xcconfig"; sourceTree = "<group>"; };
3BE0FA85B15844909EF36AB4 /* Pods-XLForm Tests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-XLForm Tests.release.xcconfig"; path = "Pods/Target Support Files/Pods-XLForm Tests/Pods-XLForm Tests.release.xcconfig"; sourceTree = "<group>"; };
3C5B9B791AC0BA33000AF1BA /* XLFormExampleTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormExampleTest.m; path = Test/XLFormExampleTest.m; sourceTree = "<group>"; };
3C9817841AC30616003F6ABD /* UITextField+Test.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "UITextField+Test.h"; path = "Helpers/UITextField+Test.h"; sourceTree = "<group>"; };
3C9817851AC30616003F6ABD /* UITextField+Test.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = "UITextField+Test.m"; path = "Helpers/UITextField+Test.m"; sourceTree = "<group>"; };
8ADC094C94CA7ABBB8134573 /* Pods.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = Pods.release.xcconfig; path = "Pods/Target Support Files/Pods/Pods.release.xcconfig"; sourceTree = "<group>"; };
6233D65E1D7DF022000E7716 /* XLTestTextViewProperties.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLTestTextViewProperties.m; path = Test/XLTestTextViewProperties.m; sourceTree = "<group>"; };
8189C74AF1BF64FDF4D14AE3 /* libPods-XLForm Tests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-XLForm Tests.a"; sourceTree = BUILT_PRODUCTS_DIR; };
BFD111831AD8323900943D23 /* XLTestHideAndShow.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLTestHideAndShow.m; path = Test/XLTestHideAndShow.m; sourceTree = "<group>"; };
C6B20EA1A9D9591335BEE81F /* Pods.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = Pods.debug.xcconfig; path = "Pods/Target Support Files/Pods/Pods.debug.xcconfig"; sourceTree = "<group>"; };
CEC7E8601D7342BFAF4C4060 /* libPods.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libPods.a; sourceTree = BUILT_PRODUCTS_DIR; };
E68572C5C8328F0F177BBCA1 /* libPods-XLForm Tests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-XLForm Tests.a"; sourceTree = BUILT_PRODUCTS_DIR; };
D5A9B3DB06904B24F1A8EA24 /* Pods-XLForm Tests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-XLForm Tests.release.xcconfig"; path = "Pods/Target Support Files/Pods-XLForm Tests/Pods-XLForm Tests.release.xcconfig"; sourceTree = "<group>"; };
F9D7EFDB6BD5884E5923B6AC /* Pods-XLForm Tests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-XLForm Tests.debug.xcconfig"; path = "Pods/Target Support Files/Pods-XLForm Tests/Pods-XLForm Tests.debug.xcconfig"; sourceTree = "<group>"; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
@@ -50,20 +51,29 @@
28657A3E1990879200CE8180 /* XCTest.framework in Frameworks */,
28657A421990879200CE8180 /* UIKit.framework in Frameworks */,
28657A401990879200CE8180 /* Foundation.framework in Frameworks */,
17538872B9BB29167787CF50 /* libPods-XLForm Tests.a in Frameworks */,
39585558ED414BFBE6FFB93C /* libPods-XLForm Tests.a in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
142BA587E51B2D88244F04F1 /* Pods */ = {
isa = PBXGroup;
children = (
F9D7EFDB6BD5884E5923B6AC /* Pods-XLForm Tests.debug.xcconfig */,
D5A9B3DB06904B24F1A8EA24 /* Pods-XLForm Tests.release.xcconfig */,
);
name = Pods;
sourceTree = "<group>";
};
28657A2F19907FBE00CE8180 = {
isa = PBXGroup;
children = (
28657A431990879200CE8180 /* XLForm Tests */,
28657A3C1990879200CE8180 /* Frameworks */,
28657A3B1990879200CE8180 /* Products */,
52B313F2682BC45F8E9E8132 /* Pods */,
142BA587E51B2D88244F04F1 /* Pods */,
);
sourceTree = "<group>";
};
@@ -81,8 +91,7 @@
28657A3D1990879200CE8180 /* XCTest.framework */,
28657A3F1990879200CE8180 /* Foundation.framework */,
28657A411990879200CE8180 /* UIKit.framework */,
CEC7E8601D7342BFAF4C4060 /* libPods.a */,
E68572C5C8328F0F177BBCA1 /* libPods-XLForm Tests.a */,
8189C74AF1BF64FDF4D14AE3 /* libPods-XLForm Tests.a */,
);
name = Frameworks;
sourceTree = "<group>";
@@ -115,6 +124,8 @@
28657A5019914F9700CE8180 /* XLTestCase.h */,
28657A5119914F9700CE8180 /* XLTestCase.m */,
28657A53199154EE00CE8180 /* XLFormValidatorsTests.m */,
03885A901D7DD3BD00CC183A /* XLTestTextFieldProperties.m */,
6233D65E1D7DF022000E7716 /* XLTestTextViewProperties.m */,
);
name = Tests;
sourceTree = "<group>";
@@ -128,17 +139,6 @@
name = Helpers;
sourceTree = "<group>";
};
52B313F2682BC45F8E9E8132 /* Pods */ = {
isa = PBXGroup;
children = (
C6B20EA1A9D9591335BEE81F /* Pods.debug.xcconfig */,
8ADC094C94CA7ABBB8134573 /* Pods.release.xcconfig */,
35038A584FCFD0693D23F189 /* Pods-XLForm Tests.debug.xcconfig */,
3BE0FA85B15844909EF36AB4 /* Pods-XLForm Tests.release.xcconfig */,
);
name = Pods;
sourceTree = "<group>";
};
/* End PBXGroup section */
/* Begin PBXNativeTarget section */
@@ -146,12 +146,11 @@
isa = PBXNativeTarget;
buildConfigurationList = 28657A4C1990879200CE8180 /* Build configuration list for PBXNativeTarget "XLForm Tests" */;
buildPhases = (
6B058765CC1143829C6943B9 /* 📦 Check Pods Manifest.lock */,
29CB07B4E0344AEB95FE5406 /* [CP] Check Pods Manifest.lock */,
28657A361990879200CE8180 /* Sources */,
28657A371990879200CE8180 /* Frameworks */,
28657A381990879200CE8180 /* Resources */,
3E5FCF05A57F40C6AF367F6D /* 📦 Copy Pods Resources */,
6A2C507B76209618EDA57426 /* 📦 Embed Pods Frameworks */,
7E96395A3A94BDD9487AE471 /* [CP] Copy Pods Resources */,
);
buildRules = (
);
@@ -168,7 +167,7 @@
28657A3019907FBE00CE8180 /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 0610;
LastUpgradeCheck = 0900;
};
buildConfigurationList = 28657A3319907FBE00CE8180 /* Build configuration list for PBXProject "XLForm Tests" */;
compatibilityVersion = "Xcode 3.2";
@@ -199,49 +198,40 @@
/* End PBXResourcesBuildPhase section */
/* Begin PBXShellScriptBuildPhase section */
3E5FCF05A57F40C6AF367F6D /* 📦 Copy Pods Resources */ = {
29CB07B4E0344AEB95FE5406 /* [CP] Check Pods Manifest.lock */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
"${PODS_PODFILE_DIR_PATH}/Podfile.lock",
"${PODS_ROOT}/Manifest.lock",
);
name = "📦 Copy Pods Resources";
name = "[CP] Check Pods Manifest.lock";
outputPaths = (
"$(DERIVED_FILE_DIR)/Pods-XLForm Tests-checkManifestLockResult.txt",
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-XLForm Tests/Pods-XLForm Tests-resources.sh\"\n";
shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n";
showEnvVarsInLog = 0;
};
6A2C507B76209618EDA57426 /* 📦 Embed Pods Frameworks */ = {
7E96395A3A94BDD9487AE471 /* [CP] Copy Pods Resources */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
"${PODS_ROOT}/Target Support Files/Pods-XLForm Tests/Pods-XLForm Tests-resources.sh",
"${PODS_ROOT}/../../XLForm/XLForm.bundle",
);
name = "📦 Embed Pods Frameworks";
name = "[CP] Copy Pods Resources";
outputPaths = (
"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/XLForm.bundle",
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-XLForm Tests/Pods-XLForm Tests-frameworks.sh\"\n";
showEnvVarsInLog = 0;
};
6B058765CC1143829C6943B9 /* 📦 Check Pods Manifest.lock */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
);
name = "📦 Check Pods Manifest.lock";
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [[ $? != 0 ]] ; then\n cat << EOM\nerror: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\nEOM\n exit 1\nfi\n";
shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-XLForm Tests/Pods-XLForm Tests-resources.sh\"\n";
showEnvVarsInLog = 0;
};
/* End PBXShellScriptBuildPhase section */
@@ -253,7 +243,9 @@
files = (
28657A54199154EE00CE8180 /* XLFormValidatorsTests.m in Sources */,
28657A5219914F9700CE8180 /* XLTestCase.m in Sources */,
03885A911D7DD3BD00CC183A /* XLTestTextFieldProperties.m in Sources */,
BFD111841AD8323900943D23 /* XLTestHideAndShow.m in Sources */,
6233D65F1D7DF022000E7716 /* XLTestTextViewProperties.m in Sources */,
3C5B9B7A1AC0BA33000AF1BA /* XLFormExampleTest.m in Sources */,
3C9817861AC30616003F6ABD /* UITextField+Test.m in Sources */,
);
@@ -276,6 +268,31 @@
28657A3419907FBE00CE8180 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
ENABLE_STRICT_OBJC_MSGSEND = YES;
ENABLE_TESTABILITY = YES;
GCC_NO_COMMON_BLOCKS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
ONLY_ACTIVE_ARCH = YES;
};
name = Debug;
@@ -283,12 +300,36 @@
28657A3519907FBE00CE8180 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
ENABLE_STRICT_OBJC_MSGSEND = YES;
GCC_NO_COMMON_BLOCKS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
};
name = Release;
};
28657A4D1990879200CE8180 /* Debug */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = 35038A584FCFD0693D23F189 /* Pods-XLForm Tests.debug.xcconfig */;
baseConfigurationReference = F9D7EFDB6BD5884E5923B6AC /* Pods-XLForm Tests.debug.xcconfig */;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
@@ -326,9 +367,10 @@
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
INFOPLIST_FILE = "XLForm Tests/XLForm Tests-Info.plist";
IPHONEOS_DEPLOYMENT_TARGET = 7.1;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
LIBRARY_SEARCH_PATHS = "$(inherited)";
ONLY_ACTIVE_ARCH = YES;
PRODUCT_BUNDLE_IDENTIFIER = "com.xmartlabs.${PRODUCT_NAME:rfc1034identifier}";
PRODUCT_NAME = "$(TARGET_NAME)";
SDKROOT = iphoneos;
WRAPPER_EXTENSION = xctest;
@@ -337,7 +379,7 @@
};
28657A4E1990879200CE8180 /* Release */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = 3BE0FA85B15844909EF36AB4 /* Pods-XLForm Tests.release.xcconfig */;
baseConfigurationReference = D5A9B3DB06904B24F1A8EA24 /* Pods-XLForm Tests.release.xcconfig */;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
@@ -369,8 +411,9 @@
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
INFOPLIST_FILE = "XLForm Tests/XLForm Tests-Info.plist";
IPHONEOS_DEPLOYMENT_TARGET = 7.1;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
LIBRARY_SEARCH_PATHS = "$(inherited)";
PRODUCT_BUNDLE_IDENTIFIER = "com.xmartlabs.${PRODUCT_NAME:rfc1034identifier}";
PRODUCT_NAME = "$(TARGET_NAME)";
SDKROOT = iphoneos;
VALIDATE_PRODUCT = YES;
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0610"
LastUpgradeVersion = "0900"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
@@ -23,10 +23,11 @@
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
buildConfiguration = "Debug">
language = ""
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
<TestableReference
skipped = "NO">
@@ -39,15 +40,19 @@
</BuildableReference>
</TestableReference>
</Testables>
<AdditionalOptions>
</AdditionalOptions>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
language = ""
launchStyle = "0"
useCustomWorkingDirectory = "NO"
buildConfiguration = "Debug"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
<MacroExpansion>
<BuildableReference
@@ -62,10 +67,10 @@
</AdditionalOptions>
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
buildConfiguration = "Release"
debugDocumentVersioning = "YES">
</ProfileAction>
<AnalyzeAction
@@ -0,0 +1,66 @@
//
// XLTestTextFieldProperties.m
// XLForm Tests
//
// Created by Claus on 9/5/16.
//
//
#import "XLTestCase.h"
#import <XLForm/XLFormTextFieldCell.h>
#import <UIKit/UIKit.h>
@interface XLTestTextFieldProperties : XLTestCase
@end
@implementation XLTestTextFieldProperties
- (void)testPropertiesGetSet
{
// Get the tableView
UITableView * tableView = self.formController.tableView;
UITableViewCell * cell = [self.formController tableView:tableView cellForRowAtIndexPath:[NSIndexPath indexPathForRow:0 inSection:0]];
// Check if the cell contains the correct properties
expect(cell).to.beKindOf([XLFormTextFieldCell class]);
XLFormTextFieldCell * textFieldCell = (XLFormTextFieldCell *)cell;
expect(textFieldCell.textFieldLengthPercentage).to.equal(0.3);
expect(textFieldCell.textFieldMaxNumberOfCharacters).to.equal(10);
}
- (void)testMaxNumbersOfCharacters
{
// Get the tableView
UITableView * tableView = self.formController.tableView;
UITableViewCell * cell = [self.formController tableView:tableView cellForRowAtIndexPath:[NSIndexPath indexPathForRow:0 inSection:0]];
expect(cell).to.beKindOf([XLFormTextFieldCell class]);
XLFormTextFieldCell * textFieldCell = (XLFormTextFieldCell *)cell;
// Check if range check works
expect(cell).to.conformTo(@protocol(UITextFieldDelegate));
id<UITextFieldDelegate> textFieldDelegate = (id<UITextFieldDelegate>)cell;
NSRange range = NSMakeRange(0, 0);
expect([textFieldDelegate textField:textFieldCell.textField shouldChangeCharactersInRange:range replacementString:@"123"]).to.beTruthy();
expect([textFieldDelegate textField:textFieldCell.textField shouldChangeCharactersInRange:range replacementString:@"1234567890"]).to.beTruthy();
expect([textFieldDelegate textField:textFieldCell.textField shouldChangeCharactersInRange:range replacementString:@"12345678901"]).to.beFalsy();
}
#pragma mark - Build Form
-(void)buildForm
{
XLFormDescriptor * form = [XLFormDescriptor formDescriptor];
XLFormSectionDescriptor * section = [XLFormSectionDescriptor formSection];
[form addFormSection:section];
XLFormRowDescriptor * row = [XLFormRowDescriptor formRowDescriptorWithTag:nil rowType:XLFormRowDescriptorTypeText];
[row.cellConfigAtConfigure setObject:@(0.3) forKey:XLFormTextFieldLengthPercentage];
[row.cellConfigAtConfigure setObject:@(10) forKey:XLFormTextFieldMaxNumberOfCharacters];
[section addFormRow:row];
self.formController.form = form;
}
@end
@@ -0,0 +1,66 @@
//
// XLTestTextViewProperties.m
// XLForm Tests
//
// Created by Claus on 9/5/16.
//
//
#import "XLTestCase.h"
#import <XLForm/XLFormTextViewCell.h>
#import <UIKit/UIKit.h>
@interface XLTestTextViewProperties : XLTestCase
@end
@implementation XLTestTextViewProperties
- (void)testPropertiesGetSet
{
// Get the tableView
UITableView * tableView = self.formController.tableView;
UITableViewCell * cell = [self.formController tableView:tableView cellForRowAtIndexPath:[NSIndexPath indexPathForRow:0 inSection:0]];
// Check if the cell contains the correct properties
expect(cell).to.beKindOf([XLFormTextViewCell class]);
XLFormTextViewCell * textViewCell = (XLFormTextViewCell *)cell;
expect(textViewCell.textViewLengthPercentage).to.equal(0.3);
expect(textViewCell.textViewMaxNumberOfCharacters).to.equal(10);
}
- (void)testMaxNumbersOfCharacters
{
// Get the tableView
UITableView * tableView = self.formController.tableView;
UITableViewCell * cell = [self.formController tableView:tableView cellForRowAtIndexPath:[NSIndexPath indexPathForRow:0 inSection:0]];
expect(cell).to.beKindOf([XLFormTextViewCell class]);
XLFormTextViewCell * textViewCell = (XLFormTextViewCell *)cell;
// Check if range check works
expect(cell).to.conformTo(@protocol(UITextViewDelegate));
id<UITextViewDelegate> textFieldDelegate = (id<UITextViewDelegate>)cell;
NSRange range = NSMakeRange(0, 0);
expect([textFieldDelegate textView:textViewCell.textView shouldChangeTextInRange:range replacementText:@"123"]).to.beTruthy();
expect([textFieldDelegate textView:textViewCell.textView shouldChangeTextInRange:range replacementText:@"1234567890"]).to.beTruthy();
expect([textFieldDelegate textView:textViewCell.textView shouldChangeTextInRange:range replacementText:@"12345678901"]).to.beFalsy();
}
#pragma mark - Build Form
-(void)buildForm
{
XLFormDescriptor * form = [XLFormDescriptor formDescriptor];
XLFormSectionDescriptor * section = [XLFormSectionDescriptor formSection];
[form addFormSection:section];
XLFormRowDescriptor * row = [XLFormRowDescriptor formRowDescriptorWithTag:nil rowType:XLFormRowDescriptorTypeTextView];
[row.cellConfigAtConfigure setObject:@(0.3) forKey:XLFormTextViewLengthPercentage];
[row.cellConfigAtConfigure setObject:@(10) forKey:XLFormTextViewMaxNumberOfCharacters];
[section addFormRow:row];
self.formController.form = form;
}
@end
+1 -1
View File
@@ -7,7 +7,7 @@
<key>CFBundleExecutable</key>
<string>${EXECUTABLE_NAME}</string>
<key>CFBundleIdentifier</key>
<string>com.xmartlabs.${PRODUCT_NAME:rfc1034identifier}</string>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundlePackageType</key>
BIN
View File
Binary file not shown.

After

Width:  |  Height:  |  Size: 23 KiB

+2 -2
View File
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = 'XLForm'
s.version = '3.1.1'
s.version = '4.3.0'
s.license = { :type => 'MIT' }
s.summary = 'XLForm is the most flexible and powerful iOS library to create dynamic table-view forms.'
s.description = <<-DESC
@@ -11,7 +11,7 @@ Pod::Spec.new do |s|
s.source = { :git => 'https://github.com/xmartlabs/XLForm.git', :tag => s.version }
s.source_files = 'XLForm/XL/**/*.{h,m}'
s.requires_arc = true
s.ios.deployment_target = '7.0'
s.ios.deployment_target = '9.0'
s.ios.frameworks = 'UIKit', 'Foundation', 'CoreGraphics'
s.resource = 'XLForm/XLForm.bundle'
end
+340 -310
View File
@@ -7,164 +7,164 @@
objects = {
/* Begin PBXBuildFile section */
6442F6501C1FC3AA00C9152F /* XLFormImageCell.h in Headers */ = {isa = PBXBuildFile; fileRef = 6442F64E1C1FC3AA00C9152F /* XLFormImageCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
6442F6511C1FC3AA00C9152F /* XLFormImageCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 6442F64F1C1FC3AA00C9152F /* XLFormImageCell.m */; };
E267FD7C1BE804E200F86B42 /* XLFormBaseCell.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD2C1BE804E200F86B42 /* XLFormBaseCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FD7D1BE804E200F86B42 /* XLFormBaseCell.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD2D1BE804E200F86B42 /* XLFormBaseCell.m */; };
E267FD7E1BE804E200F86B42 /* XLFormButtonCell.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD2E1BE804E200F86B42 /* XLFormButtonCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FD7F1BE804E200F86B42 /* XLFormButtonCell.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD2F1BE804E200F86B42 /* XLFormButtonCell.m */; };
E267FD801BE804E200F86B42 /* XLFormCheckCell.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD301BE804E200F86B42 /* XLFormCheckCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FD811BE804E200F86B42 /* XLFormCheckCell.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD311BE804E200F86B42 /* XLFormCheckCell.m */; };
E267FD821BE804E200F86B42 /* XLFormDateCell.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD321BE804E200F86B42 /* XLFormDateCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FD831BE804E200F86B42 /* XLFormDateCell.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD331BE804E200F86B42 /* XLFormDateCell.m */; };
E267FD841BE804E200F86B42 /* XLFormDatePickerCell.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD341BE804E200F86B42 /* XLFormDatePickerCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FD851BE804E200F86B42 /* XLFormDatePickerCell.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD351BE804E200F86B42 /* XLFormDatePickerCell.m */; };
E267FD861BE804E200F86B42 /* XLFormDescriptorCell.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD361BE804E200F86B42 /* XLFormDescriptorCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FD871BE804E200F86B42 /* XLFormInlineRowDescriptorCell.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD371BE804E200F86B42 /* XLFormInlineRowDescriptorCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FD881BE804E200F86B42 /* XLFormInlineSelectorCell.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD381BE804E200F86B42 /* XLFormInlineSelectorCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FD891BE804E200F86B42 /* XLFormInlineSelectorCell.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD391BE804E200F86B42 /* XLFormInlineSelectorCell.m */; };
E267FD8A1BE804E200F86B42 /* XLFormLeftRightSelectorCell.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD3A1BE804E200F86B42 /* XLFormLeftRightSelectorCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FD8B1BE804E200F86B42 /* XLFormLeftRightSelectorCell.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD3B1BE804E200F86B42 /* XLFormLeftRightSelectorCell.m */; };
E267FD8C1BE804E200F86B42 /* XLFormPickerCell.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD3C1BE804E200F86B42 /* XLFormPickerCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FD8D1BE804E200F86B42 /* XLFormPickerCell.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD3D1BE804E200F86B42 /* XLFormPickerCell.m */; };
E267FD8E1BE804E200F86B42 /* XLFormSegmentedCell.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD3E1BE804E200F86B42 /* XLFormSegmentedCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FD8F1BE804E200F86B42 /* XLFormSegmentedCell.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD3F1BE804E200F86B42 /* XLFormSegmentedCell.m */; };
E267FD901BE804E200F86B42 /* XLFormSelectorCell.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD401BE804E200F86B42 /* XLFormSelectorCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FD911BE804E200F86B42 /* XLFormSelectorCell.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD411BE804E200F86B42 /* XLFormSelectorCell.m */; };
E267FD921BE804E200F86B42 /* XLFormSliderCell.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD421BE804E200F86B42 /* XLFormSliderCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FD931BE804E200F86B42 /* XLFormSliderCell.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD431BE804E200F86B42 /* XLFormSliderCell.m */; };
E267FD941BE804E200F86B42 /* XLFormStepCounterCell.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD441BE804E200F86B42 /* XLFormStepCounterCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FD951BE804E200F86B42 /* XLFormStepCounterCell.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD451BE804E200F86B42 /* XLFormStepCounterCell.m */; };
E267FD961BE804E200F86B42 /* XLFormSwitchCell.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD461BE804E200F86B42 /* XLFormSwitchCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FD971BE804E200F86B42 /* XLFormSwitchCell.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD471BE804E200F86B42 /* XLFormSwitchCell.m */; };
E267FD981BE804E200F86B42 /* XLFormTextFieldCell.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD481BE804E200F86B42 /* XLFormTextFieldCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FD991BE804E200F86B42 /* XLFormTextFieldCell.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD491BE804E200F86B42 /* XLFormTextFieldCell.m */; };
E267FD9A1BE804E200F86B42 /* XLFormTextViewCell.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD4A1BE804E200F86B42 /* XLFormTextViewCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FD9B1BE804E200F86B42 /* XLFormTextViewCell.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD4B1BE804E200F86B42 /* XLFormTextViewCell.m */; };
E267FD9C1BE804E200F86B42 /* XLFormOptionsObject.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD4D1BE804E200F86B42 /* XLFormOptionsObject.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FD9D1BE804E200F86B42 /* XLFormOptionsObject.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD4E1BE804E200F86B42 /* XLFormOptionsObject.m */; };
E267FD9E1BE804E200F86B42 /* XLFormOptionsViewController.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD4F1BE804E200F86B42 /* XLFormOptionsViewController.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FD9F1BE804E200F86B42 /* XLFormOptionsViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD501BE804E200F86B42 /* XLFormOptionsViewController.m */; };
E267FDA01BE804E200F86B42 /* XLFormRowDescriptorViewController.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD511BE804E200F86B42 /* XLFormRowDescriptorViewController.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FDA11BE804E200F86B42 /* XLFormViewController.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD521BE804E200F86B42 /* XLFormViewController.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FDA21BE804E200F86B42 /* XLFormViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD531BE804E200F86B42 /* XLFormViewController.m */; };
E267FDA31BE804E200F86B42 /* XLFormDescriptor.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD551BE804E200F86B42 /* XLFormDescriptor.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FDA41BE804E200F86B42 /* XLFormDescriptor.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD561BE804E200F86B42 /* XLFormDescriptor.m */; };
E267FDA51BE804E200F86B42 /* XLFormDescriptorDelegate.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD571BE804E200F86B42 /* XLFormDescriptorDelegate.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FDA61BE804E200F86B42 /* XLFormRowDescriptor.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD581BE804E200F86B42 /* XLFormRowDescriptor.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FDA71BE804E200F86B42 /* XLFormRowDescriptor.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD591BE804E200F86B42 /* XLFormRowDescriptor.m */; };
E267FDA81BE804E200F86B42 /* XLFormSectionDescriptor.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD5A1BE804E200F86B42 /* XLFormSectionDescriptor.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FDA91BE804E200F86B42 /* XLFormSectionDescriptor.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD5B1BE804E200F86B42 /* XLFormSectionDescriptor.m */; };
E267FDAA1BE804E200F86B42 /* NSArray+XLFormAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD5D1BE804E200F86B42 /* NSArray+XLFormAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FDAB1BE804E200F86B42 /* NSArray+XLFormAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD5E1BE804E200F86B42 /* NSArray+XLFormAdditions.m */; };
E267FDAC1BE804E200F86B42 /* NSExpression+XLFormAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD5F1BE804E200F86B42 /* NSExpression+XLFormAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FDAD1BE804E200F86B42 /* NSExpression+XLFormAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD601BE804E200F86B42 /* NSExpression+XLFormAdditions.m */; };
E267FDAE1BE804E200F86B42 /* NSObject+XLFormAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD611BE804E200F86B42 /* NSObject+XLFormAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FDAF1BE804E200F86B42 /* NSObject+XLFormAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD621BE804E200F86B42 /* NSObject+XLFormAdditions.m */; };
E267FDB01BE804E200F86B42 /* NSPredicate+XLFormAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD631BE804E200F86B42 /* NSPredicate+XLFormAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FDB11BE804E200F86B42 /* NSPredicate+XLFormAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD641BE804E200F86B42 /* NSPredicate+XLFormAdditions.m */; };
E267FDB21BE804E200F86B42 /* NSString+XLFormAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD651BE804E200F86B42 /* NSString+XLFormAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FDB31BE804E200F86B42 /* NSString+XLFormAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD661BE804E200F86B42 /* NSString+XLFormAdditions.m */; };
E267FDB41BE804E200F86B42 /* UIView+XLFormAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD671BE804E200F86B42 /* UIView+XLFormAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FDB51BE804E200F86B42 /* UIView+XLFormAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD681BE804E200F86B42 /* UIView+XLFormAdditions.m */; };
E267FDB61BE804E200F86B42 /* XLFormRightDetailCell.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD6A1BE804E200F86B42 /* XLFormRightDetailCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FDB71BE804E200F86B42 /* XLFormRightDetailCell.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD6B1BE804E200F86B42 /* XLFormRightDetailCell.m */; };
E267FDB81BE804E200F86B42 /* XLFormRightImageButton.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD6C1BE804E200F86B42 /* XLFormRightImageButton.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FDB91BE804E200F86B42 /* XLFormRightImageButton.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD6D1BE804E200F86B42 /* XLFormRightImageButton.m */; };
E267FDBA1BE804E200F86B42 /* XLFormRowNavigationAccessoryView.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD6E1BE804E200F86B42 /* XLFormRowNavigationAccessoryView.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FDBB1BE804E200F86B42 /* XLFormRowNavigationAccessoryView.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD6F1BE804E200F86B42 /* XLFormRowNavigationAccessoryView.m */; };
E267FDBC1BE804E200F86B42 /* XLFormTextView.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD701BE804E200F86B42 /* XLFormTextView.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FDBD1BE804E200F86B42 /* XLFormTextView.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD711BE804E200F86B42 /* XLFormTextView.m */; };
E267FDBE1BE804E200F86B42 /* XLFormRegexValidator.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD731BE804E200F86B42 /* XLFormRegexValidator.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FDBF1BE804E200F86B42 /* XLFormRegexValidator.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD741BE804E200F86B42 /* XLFormRegexValidator.m */; };
E267FDC01BE804E200F86B42 /* XLFormValidationStatus.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD751BE804E200F86B42 /* XLFormValidationStatus.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FDC11BE804E200F86B42 /* XLFormValidationStatus.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD761BE804E200F86B42 /* XLFormValidationStatus.m */; };
E267FDC21BE804E200F86B42 /* XLFormValidator.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD771BE804E200F86B42 /* XLFormValidator.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FDC31BE804E200F86B42 /* XLFormValidator.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD781BE804E200F86B42 /* XLFormValidator.m */; };
E267FDC41BE804E200F86B42 /* XLFormValidatorProtocol.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD791BE804E200F86B42 /* XLFormValidatorProtocol.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695192513CEFF0059594E /* XLFormBaseCell.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695072513CEFC0059594E /* XLFormBaseCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C26951A2513CEFF0059594E /* XLFormCheckCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C2695082513CEFC0059594E /* XLFormCheckCell.m */; };
9C26951B2513CEFF0059594E /* XLFormDatePickerCell.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695092513CEFC0059594E /* XLFormDatePickerCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C26951C2513CEFF0059594E /* XLFormButtonCell.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C26950A2513CEFC0059594E /* XLFormButtonCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C26951D2513CEFF0059594E /* XLFormButtonCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C26950B2513CEFC0059594E /* XLFormButtonCell.m */; };
9C26951E2513CEFF0059594E /* XLFormInlineSelectorCell.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C26950C2513CEFC0059594E /* XLFormInlineSelectorCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C26951F2513CEFF0059594E /* XLFormDatePickerCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C26950D2513CEFD0059594E /* XLFormDatePickerCell.m */; };
9C2695202513CEFF0059594E /* XLFormCheckCell.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C26950E2513CEFD0059594E /* XLFormCheckCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695212513CEFF0059594E /* XLFormImageCell.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C26950F2513CEFD0059594E /* XLFormImageCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695222513CEFF0059594E /* XLFormLeftRightSelectorCell.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695102513CEFD0059594E /* XLFormLeftRightSelectorCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695232513CEFF0059594E /* XLFormLeftRightSelectorCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C2695112513CEFE0059594E /* XLFormLeftRightSelectorCell.m */; };
9C2695242513CEFF0059594E /* XLFormInlineRowDescriptorCell.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695122513CEFE0059594E /* XLFormInlineRowDescriptorCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695252513CEFF0059594E /* XLFormDateCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C2695132513CEFE0059594E /* XLFormDateCell.m */; };
9C2695262513CEFF0059594E /* XLFormInlineSelectorCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C2695142513CEFE0059594E /* XLFormInlineSelectorCell.m */; };
9C2695272513CEFF0059594E /* XLFormBaseCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C2695152513CEFE0059594E /* XLFormBaseCell.m */; };
9C2695282513CEFF0059594E /* XLFormDescriptorCell.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695162513CEFE0059594E /* XLFormDescriptorCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695292513CEFF0059594E /* XLFormImageCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C2695172513CEFE0059594E /* XLFormImageCell.m */; };
9C26952A2513CEFF0059594E /* XLFormDateCell.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695182513CEFF0059594E /* XLFormDateCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C26953B2513CFA70059594E /* XLFormStepCounterCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C26952B2513CFA60059594E /* XLFormStepCounterCell.m */; };
9C26953C2513CFA70059594E /* XLFormPickerCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C26952C2513CFA60059594E /* XLFormPickerCell.m */; };
9C26953D2513CFA70059594E /* XLFormSliderCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C26952D2513CFA60059594E /* XLFormSliderCell.m */; };
9C26953E2513CFA70059594E /* XLFormSelectorCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C26952E2513CFA60059594E /* XLFormSelectorCell.m */; };
9C26953F2513CFA70059594E /* XLFormTextViewCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C26952F2513CFA60059594E /* XLFormTextViewCell.m */; };
9C2695402513CFA70059594E /* XLFormTextFieldCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C2695302513CFA60059594E /* XLFormTextFieldCell.m */; };
9C2695412513CFA70059594E /* XLFormStepCounterCell.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695312513CFA60059594E /* XLFormStepCounterCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695422513CFA70059594E /* XLFormTextFieldCell.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695322513CFA60059594E /* XLFormTextFieldCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695432513CFA70059594E /* XLFormSliderCell.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695332513CFA60059594E /* XLFormSliderCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695442513CFA70059594E /* XLFormTextViewCell.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695342513CFA60059594E /* XLFormTextViewCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695452513CFA70059594E /* XLFormSegmentedCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C2695352513CFA70059594E /* XLFormSegmentedCell.m */; };
9C2695462513CFA70059594E /* XLFormPickerCell.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695362513CFA70059594E /* XLFormPickerCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695472513CFA70059594E /* XLFormSwitchCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C2695372513CFA70059594E /* XLFormSwitchCell.m */; };
9C2695482513CFA70059594E /* XLFormSwitchCell.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695382513CFA70059594E /* XLFormSwitchCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695492513CFA70059594E /* XLFormSegmentedCell.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695392513CFA70059594E /* XLFormSegmentedCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C26954A2513CFA70059594E /* XLFormSelectorCell.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C26953A2513CFA70059594E /* XLFormSelectorCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695522513CFF50059594E /* XLFormViewController.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C26954B2513CFF50059594E /* XLFormViewController.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695532513CFF50059594E /* XLFormViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C26954C2513CFF50059594E /* XLFormViewController.m */; };
9C2695542513CFF50059594E /* XLFormRowDescriptorViewController.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C26954D2513CFF50059594E /* XLFormRowDescriptorViewController.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695552513CFF50059594E /* XLFormOptionsObject.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C26954E2513CFF50059594E /* XLFormOptionsObject.m */; };
9C2695562513CFF50059594E /* XLFormOptionsViewController.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C26954F2513CFF50059594E /* XLFormOptionsViewController.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695572513CFF50059594E /* XLFormOptionsObject.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695502513CFF50059594E /* XLFormOptionsObject.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695582513CFF50059594E /* XLFormOptionsViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C2695512513CFF50059594E /* XLFormOptionsViewController.m */; };
9C2695602513D0230059594E /* XLFormDescriptorDelegate.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695592513D0230059594E /* XLFormDescriptorDelegate.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695612513D0230059594E /* XLFormRowDescriptor.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C26955A2513D0230059594E /* XLFormRowDescriptor.m */; };
9C2695622513D0230059594E /* XLFormSectionDescriptor.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C26955B2513D0230059594E /* XLFormSectionDescriptor.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695632513D0230059594E /* XLFormRowDescriptor.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C26955C2513D0230059594E /* XLFormRowDescriptor.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695642513D0230059594E /* XLFormDescriptor.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C26955D2513D0230059594E /* XLFormDescriptor.m */; };
9C2695652513D0230059594E /* XLFormSectionDescriptor.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C26955E2513D0230059594E /* XLFormSectionDescriptor.m */; };
9C2695662513D0230059594E /* XLFormDescriptor.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C26955F2513D0230059594E /* XLFormDescriptor.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695732513D0520059594E /* NSArray+XLFormAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695672513D0510059594E /* NSArray+XLFormAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695742513D0520059594E /* NSString+XLFormAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C2695682513D0510059594E /* NSString+XLFormAdditions.m */; };
9C2695752513D0520059594E /* NSExpression+XLFormAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695692513D0510059594E /* NSExpression+XLFormAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695762513D0520059594E /* NSObject+XLFormAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C26956A2513D0510059594E /* NSObject+XLFormAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695772513D0520059594E /* NSPredicate+XLFormAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C26956B2513D0510059594E /* NSPredicate+XLFormAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695782513D0520059594E /* UIView+XLFormAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C26956C2513D0510059594E /* UIView+XLFormAdditions.m */; };
9C2695792513D0520059594E /* NSArray+XLFormAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C26956D2513D0510059594E /* NSArray+XLFormAdditions.m */; };
9C26957A2513D0520059594E /* NSExpression+XLFormAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C26956E2513D0510059594E /* NSExpression+XLFormAdditions.m */; };
9C26957B2513D0520059594E /* NSPredicate+XLFormAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C26956F2513D0510059594E /* NSPredicate+XLFormAdditions.m */; };
9C26957C2513D0520059594E /* UIView+XLFormAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695702513D0510059594E /* UIView+XLFormAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C26957D2513D0520059594E /* NSObject+XLFormAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C2695712513D0510059594E /* NSObject+XLFormAdditions.m */; };
9C26957E2513D0520059594E /* NSString+XLFormAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695722513D0520059594E /* NSString+XLFormAdditions.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695872513D0960059594E /* XLFormRightImageButton.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C26957F2513D0950059594E /* XLFormRightImageButton.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695882513D0960059594E /* XLFormRightDetailCell.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695802513D0950059594E /* XLFormRightDetailCell.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695892513D0960059594E /* XLFormTextView.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695812513D0950059594E /* XLFormTextView.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C26958A2513D0960059594E /* XLFormRowNavigationAccessoryView.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C2695822513D0950059594E /* XLFormRowNavigationAccessoryView.m */; };
9C26958B2513D0960059594E /* XLFormTextView.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C2695832513D0950059594E /* XLFormTextView.m */; };
9C26958C2513D0960059594E /* XLFormRowNavigationAccessoryView.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695842513D0950059594E /* XLFormRowNavigationAccessoryView.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C26958D2513D0960059594E /* XLFormRightImageButton.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C2695852513D0950059594E /* XLFormRightImageButton.m */; };
9C26958E2513D0960059594E /* XLFormRightDetailCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C2695862513D0960059594E /* XLFormRightDetailCell.m */; };
9C2695962513D0D00059594E /* XLFormValidationStatus.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C26958F2513D0CF0059594E /* XLFormValidationStatus.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695972513D0D00059594E /* XLFormValidationStatus.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C2695902513D0CF0059594E /* XLFormValidationStatus.m */; };
9C2695982513D0D00059594E /* XLFormValidator.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695912513D0CF0059594E /* XLFormValidator.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C2695992513D0D00059594E /* XLFormRegexValidator.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695922513D0CF0059594E /* XLFormRegexValidator.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C26959A2513D0D00059594E /* XLFormRegexValidator.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C2695932513D0D00059594E /* XLFormRegexValidator.m */; };
9C26959B2513D0D00059594E /* XLFormValidatorProtocol.h in Headers */ = {isa = PBXBuildFile; fileRef = 9C2695942513D0D00059594E /* XLFormValidatorProtocol.h */; settings = {ATTRIBUTES = (Public, ); }; };
9C26959C2513D0D00059594E /* XLFormValidator.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C2695952513D0D00059594E /* XLFormValidator.m */; };
E267FDC51BE804E200F86B42 /* XLForm.h in Headers */ = {isa = PBXBuildFile; fileRef = E267FD7A1BE804E200F86B42 /* XLForm.h */; settings = {ATTRIBUTES = (Public, ); }; };
E267FDC61BE804E200F86B42 /* XLForm.m in Sources */ = {isa = PBXBuildFile; fileRef = E267FD7B1BE804E200F86B42 /* XLForm.m */; };
E267FDC81BE806D000F86B42 /* XLForm.bundle in Resources */ = {isa = PBXBuildFile; fileRef = E267FDC71BE806D000F86B42 /* XLForm.bundle */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
6442F64E1C1FC3AA00C9152F /* XLFormImageCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormImageCell.h; sourceTree = "<group>"; };
6442F64F1C1FC3AA00C9152F /* XLFormImageCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormImageCell.m; sourceTree = "<group>"; };
9C2695072513CEFC0059594E /* XLFormBaseCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormBaseCell.h; path = XLForm/XL/XLFormBaseCell.h; sourceTree = SOURCE_ROOT; };
9C2695082513CEFC0059594E /* XLFormCheckCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormCheckCell.m; path = XLForm/XL/XLFormCheckCell.m; sourceTree = SOURCE_ROOT; };
9C2695092513CEFC0059594E /* XLFormDatePickerCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormDatePickerCell.h; path = XLForm/XL/XLFormDatePickerCell.h; sourceTree = SOURCE_ROOT; };
9C26950A2513CEFC0059594E /* XLFormButtonCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormButtonCell.h; path = XLForm/XL/XLFormButtonCell.h; sourceTree = SOURCE_ROOT; };
9C26950B2513CEFC0059594E /* XLFormButtonCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormButtonCell.m; path = XLForm/XL/XLFormButtonCell.m; sourceTree = SOURCE_ROOT; };
9C26950C2513CEFC0059594E /* XLFormInlineSelectorCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormInlineSelectorCell.h; path = XLForm/XL/XLFormInlineSelectorCell.h; sourceTree = SOURCE_ROOT; };
9C26950D2513CEFD0059594E /* XLFormDatePickerCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormDatePickerCell.m; path = XLForm/XL/XLFormDatePickerCell.m; sourceTree = SOURCE_ROOT; };
9C26950E2513CEFD0059594E /* XLFormCheckCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormCheckCell.h; path = XLForm/XL/XLFormCheckCell.h; sourceTree = SOURCE_ROOT; };
9C26950F2513CEFD0059594E /* XLFormImageCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormImageCell.h; path = XLForm/XL/XLFormImageCell.h; sourceTree = SOURCE_ROOT; };
9C2695102513CEFD0059594E /* XLFormLeftRightSelectorCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormLeftRightSelectorCell.h; path = XLForm/XL/XLFormLeftRightSelectorCell.h; sourceTree = SOURCE_ROOT; };
9C2695112513CEFE0059594E /* XLFormLeftRightSelectorCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormLeftRightSelectorCell.m; path = XLForm/XL/XLFormLeftRightSelectorCell.m; sourceTree = SOURCE_ROOT; };
9C2695122513CEFE0059594E /* XLFormInlineRowDescriptorCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormInlineRowDescriptorCell.h; path = XLForm/XL/XLFormInlineRowDescriptorCell.h; sourceTree = SOURCE_ROOT; };
9C2695132513CEFE0059594E /* XLFormDateCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormDateCell.m; path = XLForm/XL/XLFormDateCell.m; sourceTree = SOURCE_ROOT; };
9C2695142513CEFE0059594E /* XLFormInlineSelectorCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormInlineSelectorCell.m; path = XLForm/XL/XLFormInlineSelectorCell.m; sourceTree = SOURCE_ROOT; };
9C2695152513CEFE0059594E /* XLFormBaseCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormBaseCell.m; path = XLForm/XL/XLFormBaseCell.m; sourceTree = SOURCE_ROOT; };
9C2695162513CEFE0059594E /* XLFormDescriptorCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormDescriptorCell.h; path = XLForm/XL/XLFormDescriptorCell.h; sourceTree = SOURCE_ROOT; };
9C2695172513CEFE0059594E /* XLFormImageCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormImageCell.m; path = XLForm/XL/XLFormImageCell.m; sourceTree = SOURCE_ROOT; };
9C2695182513CEFF0059594E /* XLFormDateCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormDateCell.h; path = XLForm/XL/XLFormDateCell.h; sourceTree = SOURCE_ROOT; };
9C26952B2513CFA60059594E /* XLFormStepCounterCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormStepCounterCell.m; path = XL/XLFormStepCounterCell.m; sourceTree = "<group>"; };
9C26952C2513CFA60059594E /* XLFormPickerCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormPickerCell.m; path = XL/XLFormPickerCell.m; sourceTree = "<group>"; };
9C26952D2513CFA60059594E /* XLFormSliderCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormSliderCell.m; path = XL/XLFormSliderCell.m; sourceTree = "<group>"; };
9C26952E2513CFA60059594E /* XLFormSelectorCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormSelectorCell.m; path = XL/XLFormSelectorCell.m; sourceTree = "<group>"; };
9C26952F2513CFA60059594E /* XLFormTextViewCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormTextViewCell.m; path = XL/XLFormTextViewCell.m; sourceTree = "<group>"; };
9C2695302513CFA60059594E /* XLFormTextFieldCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormTextFieldCell.m; path = XL/XLFormTextFieldCell.m; sourceTree = "<group>"; };
9C2695312513CFA60059594E /* XLFormStepCounterCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormStepCounterCell.h; path = XL/XLFormStepCounterCell.h; sourceTree = "<group>"; };
9C2695322513CFA60059594E /* XLFormTextFieldCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormTextFieldCell.h; path = XL/XLFormTextFieldCell.h; sourceTree = "<group>"; };
9C2695332513CFA60059594E /* XLFormSliderCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormSliderCell.h; path = XL/XLFormSliderCell.h; sourceTree = "<group>"; };
9C2695342513CFA60059594E /* XLFormTextViewCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormTextViewCell.h; path = XL/XLFormTextViewCell.h; sourceTree = "<group>"; };
9C2695352513CFA70059594E /* XLFormSegmentedCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormSegmentedCell.m; path = XL/XLFormSegmentedCell.m; sourceTree = "<group>"; };
9C2695362513CFA70059594E /* XLFormPickerCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormPickerCell.h; path = XL/XLFormPickerCell.h; sourceTree = "<group>"; };
9C2695372513CFA70059594E /* XLFormSwitchCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormSwitchCell.m; path = XL/XLFormSwitchCell.m; sourceTree = "<group>"; };
9C2695382513CFA70059594E /* XLFormSwitchCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormSwitchCell.h; path = XL/XLFormSwitchCell.h; sourceTree = "<group>"; };
9C2695392513CFA70059594E /* XLFormSegmentedCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormSegmentedCell.h; path = XL/XLFormSegmentedCell.h; sourceTree = "<group>"; };
9C26953A2513CFA70059594E /* XLFormSelectorCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormSelectorCell.h; path = XL/XLFormSelectorCell.h; sourceTree = "<group>"; };
9C26954B2513CFF50059594E /* XLFormViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormViewController.h; path = XL/XLFormViewController.h; sourceTree = "<group>"; };
9C26954C2513CFF50059594E /* XLFormViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormViewController.m; path = XL/XLFormViewController.m; sourceTree = "<group>"; };
9C26954D2513CFF50059594E /* XLFormRowDescriptorViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormRowDescriptorViewController.h; path = XL/XLFormRowDescriptorViewController.h; sourceTree = "<group>"; };
9C26954E2513CFF50059594E /* XLFormOptionsObject.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormOptionsObject.m; path = XL/XLFormOptionsObject.m; sourceTree = "<group>"; };
9C26954F2513CFF50059594E /* XLFormOptionsViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormOptionsViewController.h; path = XL/XLFormOptionsViewController.h; sourceTree = "<group>"; };
9C2695502513CFF50059594E /* XLFormOptionsObject.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormOptionsObject.h; path = XL/XLFormOptionsObject.h; sourceTree = "<group>"; };
9C2695512513CFF50059594E /* XLFormOptionsViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormOptionsViewController.m; path = XL/XLFormOptionsViewController.m; sourceTree = "<group>"; };
9C2695592513D0230059594E /* XLFormDescriptorDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormDescriptorDelegate.h; path = XL/XLFormDescriptorDelegate.h; sourceTree = "<group>"; };
9C26955A2513D0230059594E /* XLFormRowDescriptor.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormRowDescriptor.m; path = XL/XLFormRowDescriptor.m; sourceTree = "<group>"; };
9C26955B2513D0230059594E /* XLFormSectionDescriptor.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormSectionDescriptor.h; path = XL/XLFormSectionDescriptor.h; sourceTree = "<group>"; };
9C26955C2513D0230059594E /* XLFormRowDescriptor.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormRowDescriptor.h; path = XL/XLFormRowDescriptor.h; sourceTree = "<group>"; };
9C26955D2513D0230059594E /* XLFormDescriptor.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormDescriptor.m; path = XL/XLFormDescriptor.m; sourceTree = "<group>"; };
9C26955E2513D0230059594E /* XLFormSectionDescriptor.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormSectionDescriptor.m; path = XL/XLFormSectionDescriptor.m; sourceTree = "<group>"; };
9C26955F2513D0230059594E /* XLFormDescriptor.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormDescriptor.h; path = XL/XLFormDescriptor.h; sourceTree = "<group>"; };
9C2695672513D0510059594E /* NSArray+XLFormAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "NSArray+XLFormAdditions.h"; path = "XL/NSArray+XLFormAdditions.h"; sourceTree = "<group>"; };
9C2695682513D0510059594E /* NSString+XLFormAdditions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = "NSString+XLFormAdditions.m"; path = "XL/NSString+XLFormAdditions.m"; sourceTree = "<group>"; };
9C2695692513D0510059594E /* NSExpression+XLFormAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "NSExpression+XLFormAdditions.h"; path = "XL/NSExpression+XLFormAdditions.h"; sourceTree = "<group>"; };
9C26956A2513D0510059594E /* NSObject+XLFormAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "NSObject+XLFormAdditions.h"; path = "XL/NSObject+XLFormAdditions.h"; sourceTree = "<group>"; };
9C26956B2513D0510059594E /* NSPredicate+XLFormAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "NSPredicate+XLFormAdditions.h"; path = "XL/NSPredicate+XLFormAdditions.h"; sourceTree = "<group>"; };
9C26956C2513D0510059594E /* UIView+XLFormAdditions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = "UIView+XLFormAdditions.m"; path = "XL/UIView+XLFormAdditions.m"; sourceTree = "<group>"; };
9C26956D2513D0510059594E /* NSArray+XLFormAdditions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = "NSArray+XLFormAdditions.m"; path = "XL/NSArray+XLFormAdditions.m"; sourceTree = "<group>"; };
9C26956E2513D0510059594E /* NSExpression+XLFormAdditions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = "NSExpression+XLFormAdditions.m"; path = "XL/NSExpression+XLFormAdditions.m"; sourceTree = "<group>"; };
9C26956F2513D0510059594E /* NSPredicate+XLFormAdditions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = "NSPredicate+XLFormAdditions.m"; path = "XL/NSPredicate+XLFormAdditions.m"; sourceTree = "<group>"; };
9C2695702513D0510059594E /* UIView+XLFormAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "UIView+XLFormAdditions.h"; path = "XL/UIView+XLFormAdditions.h"; sourceTree = "<group>"; };
9C2695712513D0510059594E /* NSObject+XLFormAdditions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = "NSObject+XLFormAdditions.m"; path = "XL/NSObject+XLFormAdditions.m"; sourceTree = "<group>"; };
9C2695722513D0520059594E /* NSString+XLFormAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "NSString+XLFormAdditions.h"; path = "XL/NSString+XLFormAdditions.h"; sourceTree = "<group>"; };
9C26957F2513D0950059594E /* XLFormRightImageButton.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormRightImageButton.h; path = XL/XLFormRightImageButton.h; sourceTree = "<group>"; };
9C2695802513D0950059594E /* XLFormRightDetailCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormRightDetailCell.h; path = XL/XLFormRightDetailCell.h; sourceTree = "<group>"; };
9C2695812513D0950059594E /* XLFormTextView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormTextView.h; path = XL/XLFormTextView.h; sourceTree = "<group>"; };
9C2695822513D0950059594E /* XLFormRowNavigationAccessoryView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormRowNavigationAccessoryView.m; path = XL/XLFormRowNavigationAccessoryView.m; sourceTree = "<group>"; };
9C2695832513D0950059594E /* XLFormTextView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormTextView.m; path = XL/XLFormTextView.m; sourceTree = "<group>"; };
9C2695842513D0950059594E /* XLFormRowNavigationAccessoryView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormRowNavigationAccessoryView.h; path = XL/XLFormRowNavigationAccessoryView.h; sourceTree = "<group>"; };
9C2695852513D0950059594E /* XLFormRightImageButton.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormRightImageButton.m; path = XL/XLFormRightImageButton.m; sourceTree = "<group>"; };
9C2695862513D0960059594E /* XLFormRightDetailCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormRightDetailCell.m; path = XL/XLFormRightDetailCell.m; sourceTree = "<group>"; };
9C26958F2513D0CF0059594E /* XLFormValidationStatus.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormValidationStatus.h; path = XLForm/XL/XLFormValidationStatus.h; sourceTree = SOURCE_ROOT; };
9C2695902513D0CF0059594E /* XLFormValidationStatus.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormValidationStatus.m; path = XLForm/XL/XLFormValidationStatus.m; sourceTree = SOURCE_ROOT; };
9C2695912513D0CF0059594E /* XLFormValidator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormValidator.h; path = XLForm/XL/XLFormValidator.h; sourceTree = SOURCE_ROOT; };
9C2695922513D0CF0059594E /* XLFormRegexValidator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormRegexValidator.h; path = XLForm/XL/XLFormRegexValidator.h; sourceTree = SOURCE_ROOT; };
9C2695932513D0D00059594E /* XLFormRegexValidator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormRegexValidator.m; path = XLForm/XL/XLFormRegexValidator.m; sourceTree = SOURCE_ROOT; };
9C2695942513D0D00059594E /* XLFormValidatorProtocol.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLFormValidatorProtocol.h; path = XLForm/XL/XLFormValidatorProtocol.h; sourceTree = SOURCE_ROOT; };
9C2695952513D0D00059594E /* XLFormValidator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLFormValidator.m; path = XLForm/XL/XLFormValidator.m; sourceTree = SOURCE_ROOT; };
E267FD201BE8048900F86B42 /* XLForm.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = XLForm.framework; sourceTree = BUILT_PRODUCTS_DIR; };
E267FD251BE8048900F86B42 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
E267FD2C1BE804E200F86B42 /* XLFormBaseCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormBaseCell.h; sourceTree = "<group>"; };
E267FD2D1BE804E200F86B42 /* XLFormBaseCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormBaseCell.m; sourceTree = "<group>"; };
E267FD2E1BE804E200F86B42 /* XLFormButtonCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormButtonCell.h; sourceTree = "<group>"; };
E267FD2F1BE804E200F86B42 /* XLFormButtonCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormButtonCell.m; sourceTree = "<group>"; };
E267FD301BE804E200F86B42 /* XLFormCheckCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormCheckCell.h; sourceTree = "<group>"; };
E267FD311BE804E200F86B42 /* XLFormCheckCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormCheckCell.m; sourceTree = "<group>"; };
E267FD321BE804E200F86B42 /* XLFormDateCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormDateCell.h; sourceTree = "<group>"; };
E267FD331BE804E200F86B42 /* XLFormDateCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormDateCell.m; sourceTree = "<group>"; };
E267FD341BE804E200F86B42 /* XLFormDatePickerCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormDatePickerCell.h; sourceTree = "<group>"; };
E267FD351BE804E200F86B42 /* XLFormDatePickerCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormDatePickerCell.m; sourceTree = "<group>"; };
E267FD361BE804E200F86B42 /* XLFormDescriptorCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormDescriptorCell.h; sourceTree = "<group>"; };
E267FD371BE804E200F86B42 /* XLFormInlineRowDescriptorCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormInlineRowDescriptorCell.h; sourceTree = "<group>"; };
E267FD381BE804E200F86B42 /* XLFormInlineSelectorCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormInlineSelectorCell.h; sourceTree = "<group>"; };
E267FD391BE804E200F86B42 /* XLFormInlineSelectorCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormInlineSelectorCell.m; sourceTree = "<group>"; };
E267FD3A1BE804E200F86B42 /* XLFormLeftRightSelectorCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormLeftRightSelectorCell.h; sourceTree = "<group>"; };
E267FD3B1BE804E200F86B42 /* XLFormLeftRightSelectorCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormLeftRightSelectorCell.m; sourceTree = "<group>"; };
E267FD3C1BE804E200F86B42 /* XLFormPickerCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormPickerCell.h; sourceTree = "<group>"; };
E267FD3D1BE804E200F86B42 /* XLFormPickerCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormPickerCell.m; sourceTree = "<group>"; };
E267FD3E1BE804E200F86B42 /* XLFormSegmentedCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormSegmentedCell.h; sourceTree = "<group>"; };
E267FD3F1BE804E200F86B42 /* XLFormSegmentedCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormSegmentedCell.m; sourceTree = "<group>"; };
E267FD401BE804E200F86B42 /* XLFormSelectorCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormSelectorCell.h; sourceTree = "<group>"; };
E267FD411BE804E200F86B42 /* XLFormSelectorCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormSelectorCell.m; sourceTree = "<group>"; };
E267FD421BE804E200F86B42 /* XLFormSliderCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormSliderCell.h; sourceTree = "<group>"; };
E267FD431BE804E200F86B42 /* XLFormSliderCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormSliderCell.m; sourceTree = "<group>"; };
E267FD441BE804E200F86B42 /* XLFormStepCounterCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormStepCounterCell.h; sourceTree = "<group>"; };
E267FD451BE804E200F86B42 /* XLFormStepCounterCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormStepCounterCell.m; sourceTree = "<group>"; };
E267FD461BE804E200F86B42 /* XLFormSwitchCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormSwitchCell.h; sourceTree = "<group>"; };
E267FD471BE804E200F86B42 /* XLFormSwitchCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormSwitchCell.m; sourceTree = "<group>"; };
E267FD481BE804E200F86B42 /* XLFormTextFieldCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormTextFieldCell.h; sourceTree = "<group>"; };
E267FD491BE804E200F86B42 /* XLFormTextFieldCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormTextFieldCell.m; sourceTree = "<group>"; };
E267FD4A1BE804E200F86B42 /* XLFormTextViewCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormTextViewCell.h; sourceTree = "<group>"; };
E267FD4B1BE804E200F86B42 /* XLFormTextViewCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormTextViewCell.m; sourceTree = "<group>"; };
E267FD4D1BE804E200F86B42 /* XLFormOptionsObject.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormOptionsObject.h; sourceTree = "<group>"; };
E267FD4E1BE804E200F86B42 /* XLFormOptionsObject.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormOptionsObject.m; sourceTree = "<group>"; };
E267FD4F1BE804E200F86B42 /* XLFormOptionsViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormOptionsViewController.h; sourceTree = "<group>"; };
E267FD501BE804E200F86B42 /* XLFormOptionsViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormOptionsViewController.m; sourceTree = "<group>"; };
E267FD511BE804E200F86B42 /* XLFormRowDescriptorViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormRowDescriptorViewController.h; sourceTree = "<group>"; };
E267FD521BE804E200F86B42 /* XLFormViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormViewController.h; sourceTree = "<group>"; };
E267FD531BE804E200F86B42 /* XLFormViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormViewController.m; sourceTree = "<group>"; };
E267FD551BE804E200F86B42 /* XLFormDescriptor.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormDescriptor.h; sourceTree = "<group>"; };
E267FD561BE804E200F86B42 /* XLFormDescriptor.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormDescriptor.m; sourceTree = "<group>"; };
E267FD571BE804E200F86B42 /* XLFormDescriptorDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormDescriptorDelegate.h; sourceTree = "<group>"; };
E267FD581BE804E200F86B42 /* XLFormRowDescriptor.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormRowDescriptor.h; sourceTree = "<group>"; };
E267FD591BE804E200F86B42 /* XLFormRowDescriptor.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormRowDescriptor.m; sourceTree = "<group>"; };
E267FD5A1BE804E200F86B42 /* XLFormSectionDescriptor.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormSectionDescriptor.h; sourceTree = "<group>"; };
E267FD5B1BE804E200F86B42 /* XLFormSectionDescriptor.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormSectionDescriptor.m; sourceTree = "<group>"; };
E267FD5D1BE804E200F86B42 /* NSArray+XLFormAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSArray+XLFormAdditions.h"; sourceTree = "<group>"; };
E267FD5E1BE804E200F86B42 /* NSArray+XLFormAdditions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSArray+XLFormAdditions.m"; sourceTree = "<group>"; };
E267FD5F1BE804E200F86B42 /* NSExpression+XLFormAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSExpression+XLFormAdditions.h"; sourceTree = "<group>"; };
E267FD601BE804E200F86B42 /* NSExpression+XLFormAdditions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSExpression+XLFormAdditions.m"; sourceTree = "<group>"; };
E267FD611BE804E200F86B42 /* NSObject+XLFormAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSObject+XLFormAdditions.h"; sourceTree = "<group>"; };
E267FD621BE804E200F86B42 /* NSObject+XLFormAdditions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSObject+XLFormAdditions.m"; sourceTree = "<group>"; };
E267FD631BE804E200F86B42 /* NSPredicate+XLFormAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSPredicate+XLFormAdditions.h"; sourceTree = "<group>"; };
E267FD641BE804E200F86B42 /* NSPredicate+XLFormAdditions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSPredicate+XLFormAdditions.m"; sourceTree = "<group>"; };
E267FD651BE804E200F86B42 /* NSString+XLFormAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSString+XLFormAdditions.h"; sourceTree = "<group>"; };
E267FD661BE804E200F86B42 /* NSString+XLFormAdditions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSString+XLFormAdditions.m"; sourceTree = "<group>"; };
E267FD671BE804E200F86B42 /* UIView+XLFormAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIView+XLFormAdditions.h"; sourceTree = "<group>"; };
E267FD681BE804E200F86B42 /* UIView+XLFormAdditions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "UIView+XLFormAdditions.m"; sourceTree = "<group>"; };
E267FD6A1BE804E200F86B42 /* XLFormRightDetailCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormRightDetailCell.h; sourceTree = "<group>"; };
E267FD6B1BE804E200F86B42 /* XLFormRightDetailCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormRightDetailCell.m; sourceTree = "<group>"; };
E267FD6C1BE804E200F86B42 /* XLFormRightImageButton.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormRightImageButton.h; sourceTree = "<group>"; };
E267FD6D1BE804E200F86B42 /* XLFormRightImageButton.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormRightImageButton.m; sourceTree = "<group>"; };
E267FD6E1BE804E200F86B42 /* XLFormRowNavigationAccessoryView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormRowNavigationAccessoryView.h; sourceTree = "<group>"; };
E267FD6F1BE804E200F86B42 /* XLFormRowNavigationAccessoryView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormRowNavigationAccessoryView.m; sourceTree = "<group>"; };
E267FD701BE804E200F86B42 /* XLFormTextView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormTextView.h; sourceTree = "<group>"; };
E267FD711BE804E200F86B42 /* XLFormTextView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormTextView.m; sourceTree = "<group>"; };
E267FD731BE804E200F86B42 /* XLFormRegexValidator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormRegexValidator.h; sourceTree = "<group>"; };
E267FD741BE804E200F86B42 /* XLFormRegexValidator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormRegexValidator.m; sourceTree = "<group>"; };
E267FD751BE804E200F86B42 /* XLFormValidationStatus.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormValidationStatus.h; sourceTree = "<group>"; };
E267FD761BE804E200F86B42 /* XLFormValidationStatus.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormValidationStatus.m; sourceTree = "<group>"; };
E267FD771BE804E200F86B42 /* XLFormValidator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormValidator.h; sourceTree = "<group>"; };
E267FD781BE804E200F86B42 /* XLFormValidator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = XLFormValidator.m; sourceTree = "<group>"; };
E267FD791BE804E200F86B42 /* XLFormValidatorProtocol.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XLFormValidatorProtocol.h; sourceTree = "<group>"; };
E267FD7A1BE804E200F86B42 /* XLForm.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XLForm.h; path = XL/XLForm.h; sourceTree = "<group>"; };
E267FD7B1BE804E200F86B42 /* XLForm.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = XLForm.m; path = XL/XLForm.m; sourceTree = "<group>"; };
E267FDC71BE806D000F86B42 /* XLForm.bundle */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.plug-in"; path = XLForm.bundle; sourceTree = "<group>"; };
@@ -216,124 +216,119 @@
E267FD2B1BE804E200F86B42 /* Cell */ = {
isa = PBXGroup;
children = (
E267FD2C1BE804E200F86B42 /* XLFormBaseCell.h */,
E267FD2D1BE804E200F86B42 /* XLFormBaseCell.m */,
E267FD2E1BE804E200F86B42 /* XLFormButtonCell.h */,
E267FD2F1BE804E200F86B42 /* XLFormButtonCell.m */,
E267FD301BE804E200F86B42 /* XLFormCheckCell.h */,
E267FD311BE804E200F86B42 /* XLFormCheckCell.m */,
E267FD321BE804E200F86B42 /* XLFormDateCell.h */,
E267FD331BE804E200F86B42 /* XLFormDateCell.m */,
E267FD341BE804E200F86B42 /* XLFormDatePickerCell.h */,
E267FD351BE804E200F86B42 /* XLFormDatePickerCell.m */,
E267FD361BE804E200F86B42 /* XLFormDescriptorCell.h */,
6442F64E1C1FC3AA00C9152F /* XLFormImageCell.h */,
6442F64F1C1FC3AA00C9152F /* XLFormImageCell.m */,
E267FD371BE804E200F86B42 /* XLFormInlineRowDescriptorCell.h */,
E267FD381BE804E200F86B42 /* XLFormInlineSelectorCell.h */,
E267FD391BE804E200F86B42 /* XLFormInlineSelectorCell.m */,
E267FD3A1BE804E200F86B42 /* XLFormLeftRightSelectorCell.h */,
E267FD3B1BE804E200F86B42 /* XLFormLeftRightSelectorCell.m */,
E267FD3C1BE804E200F86B42 /* XLFormPickerCell.h */,
E267FD3D1BE804E200F86B42 /* XLFormPickerCell.m */,
E267FD3E1BE804E200F86B42 /* XLFormSegmentedCell.h */,
E267FD3F1BE804E200F86B42 /* XLFormSegmentedCell.m */,
E267FD401BE804E200F86B42 /* XLFormSelectorCell.h */,
E267FD411BE804E200F86B42 /* XLFormSelectorCell.m */,
E267FD421BE804E200F86B42 /* XLFormSliderCell.h */,
E267FD431BE804E200F86B42 /* XLFormSliderCell.m */,
E267FD441BE804E200F86B42 /* XLFormStepCounterCell.h */,
E267FD451BE804E200F86B42 /* XLFormStepCounterCell.m */,
E267FD461BE804E200F86B42 /* XLFormSwitchCell.h */,
E267FD471BE804E200F86B42 /* XLFormSwitchCell.m */,
E267FD481BE804E200F86B42 /* XLFormTextFieldCell.h */,
E267FD491BE804E200F86B42 /* XLFormTextFieldCell.m */,
E267FD4A1BE804E200F86B42 /* XLFormTextViewCell.h */,
E267FD4B1BE804E200F86B42 /* XLFormTextViewCell.m */,
9C2695072513CEFC0059594E /* XLFormBaseCell.h */,
9C2695152513CEFE0059594E /* XLFormBaseCell.m */,
9C26950A2513CEFC0059594E /* XLFormButtonCell.h */,
9C26950B2513CEFC0059594E /* XLFormButtonCell.m */,
9C26950E2513CEFD0059594E /* XLFormCheckCell.h */,
9C2695082513CEFC0059594E /* XLFormCheckCell.m */,
9C2695182513CEFF0059594E /* XLFormDateCell.h */,
9C2695132513CEFE0059594E /* XLFormDateCell.m */,
9C2695092513CEFC0059594E /* XLFormDatePickerCell.h */,
9C26950D2513CEFD0059594E /* XLFormDatePickerCell.m */,
9C2695162513CEFE0059594E /* XLFormDescriptorCell.h */,
9C26950F2513CEFD0059594E /* XLFormImageCell.h */,
9C2695172513CEFE0059594E /* XLFormImageCell.m */,
9C2695122513CEFE0059594E /* XLFormInlineRowDescriptorCell.h */,
9C26950C2513CEFC0059594E /* XLFormInlineSelectorCell.h */,
9C2695142513CEFE0059594E /* XLFormInlineSelectorCell.m */,
9C2695102513CEFD0059594E /* XLFormLeftRightSelectorCell.h */,
9C2695112513CEFE0059594E /* XLFormLeftRightSelectorCell.m */,
9C2695362513CFA70059594E /* XLFormPickerCell.h */,
9C26952C2513CFA60059594E /* XLFormPickerCell.m */,
9C2695392513CFA70059594E /* XLFormSegmentedCell.h */,
9C2695352513CFA70059594E /* XLFormSegmentedCell.m */,
9C26953A2513CFA70059594E /* XLFormSelectorCell.h */,
9C26952E2513CFA60059594E /* XLFormSelectorCell.m */,
9C2695332513CFA60059594E /* XLFormSliderCell.h */,
9C26952D2513CFA60059594E /* XLFormSliderCell.m */,
9C2695312513CFA60059594E /* XLFormStepCounterCell.h */,
9C26952B2513CFA60059594E /* XLFormStepCounterCell.m */,
9C2695382513CFA70059594E /* XLFormSwitchCell.h */,
9C2695372513CFA70059594E /* XLFormSwitchCell.m */,
9C2695322513CFA60059594E /* XLFormTextFieldCell.h */,
9C2695302513CFA60059594E /* XLFormTextFieldCell.m */,
9C2695342513CFA60059594E /* XLFormTextViewCell.h */,
9C26952F2513CFA60059594E /* XLFormTextViewCell.m */,
);
name = Cell;
path = XL/Cell;
sourceTree = "<group>";
};
E267FD4C1BE804E200F86B42 /* Controllers */ = {
isa = PBXGroup;
children = (
E267FD4D1BE804E200F86B42 /* XLFormOptionsObject.h */,
E267FD4E1BE804E200F86B42 /* XLFormOptionsObject.m */,
E267FD4F1BE804E200F86B42 /* XLFormOptionsViewController.h */,
E267FD501BE804E200F86B42 /* XLFormOptionsViewController.m */,
E267FD511BE804E200F86B42 /* XLFormRowDescriptorViewController.h */,
E267FD521BE804E200F86B42 /* XLFormViewController.h */,
E267FD531BE804E200F86B42 /* XLFormViewController.m */,
9C2695502513CFF50059594E /* XLFormOptionsObject.h */,
9C26954E2513CFF50059594E /* XLFormOptionsObject.m */,
9C26954F2513CFF50059594E /* XLFormOptionsViewController.h */,
9C2695512513CFF50059594E /* XLFormOptionsViewController.m */,
9C26954D2513CFF50059594E /* XLFormRowDescriptorViewController.h */,
9C26954B2513CFF50059594E /* XLFormViewController.h */,
9C26954C2513CFF50059594E /* XLFormViewController.m */,
);
name = Controllers;
path = XL/Controllers;
sourceTree = "<group>";
};
E267FD541BE804E200F86B42 /* Descriptors */ = {
isa = PBXGroup;
children = (
E267FD551BE804E200F86B42 /* XLFormDescriptor.h */,
E267FD561BE804E200F86B42 /* XLFormDescriptor.m */,
E267FD571BE804E200F86B42 /* XLFormDescriptorDelegate.h */,
E267FD581BE804E200F86B42 /* XLFormRowDescriptor.h */,
E267FD591BE804E200F86B42 /* XLFormRowDescriptor.m */,
E267FD5A1BE804E200F86B42 /* XLFormSectionDescriptor.h */,
E267FD5B1BE804E200F86B42 /* XLFormSectionDescriptor.m */,
9C26955F2513D0230059594E /* XLFormDescriptor.h */,
9C26955D2513D0230059594E /* XLFormDescriptor.m */,
9C2695592513D0230059594E /* XLFormDescriptorDelegate.h */,
9C26955C2513D0230059594E /* XLFormRowDescriptor.h */,
9C26955A2513D0230059594E /* XLFormRowDescriptor.m */,
9C26955B2513D0230059594E /* XLFormSectionDescriptor.h */,
9C26955E2513D0230059594E /* XLFormSectionDescriptor.m */,
);
name = Descriptors;
path = XL/Descriptors;
sourceTree = "<group>";
};
E267FD5C1BE804E200F86B42 /* Helpers */ = {
isa = PBXGroup;
children = (
E267FD5D1BE804E200F86B42 /* NSArray+XLFormAdditions.h */,
E267FD5E1BE804E200F86B42 /* NSArray+XLFormAdditions.m */,
E267FD5F1BE804E200F86B42 /* NSExpression+XLFormAdditions.h */,
E267FD601BE804E200F86B42 /* NSExpression+XLFormAdditions.m */,
E267FD611BE804E200F86B42 /* NSObject+XLFormAdditions.h */,
E267FD621BE804E200F86B42 /* NSObject+XLFormAdditions.m */,
E267FD631BE804E200F86B42 /* NSPredicate+XLFormAdditions.h */,
E267FD641BE804E200F86B42 /* NSPredicate+XLFormAdditions.m */,
E267FD651BE804E200F86B42 /* NSString+XLFormAdditions.h */,
E267FD661BE804E200F86B42 /* NSString+XLFormAdditions.m */,
E267FD671BE804E200F86B42 /* UIView+XLFormAdditions.h */,
E267FD681BE804E200F86B42 /* UIView+XLFormAdditions.m */,
9C2695672513D0510059594E /* NSArray+XLFormAdditions.h */,
9C26956D2513D0510059594E /* NSArray+XLFormAdditions.m */,
9C2695692513D0510059594E /* NSExpression+XLFormAdditions.h */,
9C26956E2513D0510059594E /* NSExpression+XLFormAdditions.m */,
9C26956A2513D0510059594E /* NSObject+XLFormAdditions.h */,
9C2695712513D0510059594E /* NSObject+XLFormAdditions.m */,
9C26956B2513D0510059594E /* NSPredicate+XLFormAdditions.h */,
9C26956F2513D0510059594E /* NSPredicate+XLFormAdditions.m */,
9C2695722513D0520059594E /* NSString+XLFormAdditions.h */,
9C2695682513D0510059594E /* NSString+XLFormAdditions.m */,
9C2695702513D0510059594E /* UIView+XLFormAdditions.h */,
9C26956C2513D0510059594E /* UIView+XLFormAdditions.m */,
E267FD691BE804E200F86B42 /* Views */,
);
name = Helpers;
path = XL/Helpers;
sourceTree = "<group>";
};
E267FD691BE804E200F86B42 /* Views */ = {
isa = PBXGroup;
children = (
E267FD6A1BE804E200F86B42 /* XLFormRightDetailCell.h */,
E267FD6B1BE804E200F86B42 /* XLFormRightDetailCell.m */,
E267FD6C1BE804E200F86B42 /* XLFormRightImageButton.h */,
E267FD6D1BE804E200F86B42 /* XLFormRightImageButton.m */,
E267FD6E1BE804E200F86B42 /* XLFormRowNavigationAccessoryView.h */,
E267FD6F1BE804E200F86B42 /* XLFormRowNavigationAccessoryView.m */,
E267FD701BE804E200F86B42 /* XLFormTextView.h */,
E267FD711BE804E200F86B42 /* XLFormTextView.m */,
9C2695802513D0950059594E /* XLFormRightDetailCell.h */,
9C2695862513D0960059594E /* XLFormRightDetailCell.m */,
9C26957F2513D0950059594E /* XLFormRightImageButton.h */,
9C2695852513D0950059594E /* XLFormRightImageButton.m */,
9C2695842513D0950059594E /* XLFormRowNavigationAccessoryView.h */,
9C2695822513D0950059594E /* XLFormRowNavigationAccessoryView.m */,
9C2695812513D0950059594E /* XLFormTextView.h */,
9C2695832513D0950059594E /* XLFormTextView.m */,
);
path = Views;
name = Views;
sourceTree = "<group>";
};
E267FD721BE804E200F86B42 /* Validation */ = {
isa = PBXGroup;
children = (
E267FD731BE804E200F86B42 /* XLFormRegexValidator.h */,
E267FD741BE804E200F86B42 /* XLFormRegexValidator.m */,
E267FD751BE804E200F86B42 /* XLFormValidationStatus.h */,
E267FD761BE804E200F86B42 /* XLFormValidationStatus.m */,
E267FD771BE804E200F86B42 /* XLFormValidator.h */,
E267FD781BE804E200F86B42 /* XLFormValidator.m */,
E267FD791BE804E200F86B42 /* XLFormValidatorProtocol.h */,
9C2695922513D0CF0059594E /* XLFormRegexValidator.h */,
9C2695932513D0D00059594E /* XLFormRegexValidator.m */,
9C26958F2513D0CF0059594E /* XLFormValidationStatus.h */,
9C2695902513D0CF0059594E /* XLFormValidationStatus.m */,
9C2695912513D0CF0059594E /* XLFormValidator.h */,
9C2695952513D0D00059594E /* XLFormValidator.m */,
9C2695942513D0D00059594E /* XLFormValidatorProtocol.h */,
);
name = Validation;
path = XL/Validation;
sourceTree = "<group>";
};
/* End PBXGroup section */
@@ -343,47 +338,47 @@
isa = PBXHeadersBuildPhase;
buildActionMask = 2147483647;
files = (
E267FD881BE804E200F86B42 /* XLFormInlineSelectorCell.h in Headers */,
E267FD871BE804E200F86B42 /* XLFormInlineRowDescriptorCell.h in Headers */,
E267FDA11BE804E200F86B42 /* XLFormViewController.h in Headers */,
E267FD9C1BE804E200F86B42 /* XLFormOptionsObject.h in Headers */,
E267FD7E1BE804E200F86B42 /* XLFormButtonCell.h in Headers */,
E267FD841BE804E200F86B42 /* XLFormDatePickerCell.h in Headers */,
E267FD961BE804E200F86B42 /* XLFormSwitchCell.h in Headers */,
E267FDA61BE804E200F86B42 /* XLFormRowDescriptor.h in Headers */,
E267FD901BE804E200F86B42 /* XLFormSelectorCell.h in Headers */,
E267FDA81BE804E200F86B42 /* XLFormSectionDescriptor.h in Headers */,
E267FDAE1BE804E200F86B42 /* NSObject+XLFormAdditions.h in Headers */,
E267FD9E1BE804E200F86B42 /* XLFormOptionsViewController.h in Headers */,
E267FD821BE804E200F86B42 /* XLFormDateCell.h in Headers */,
E267FD801BE804E200F86B42 /* XLFormCheckCell.h in Headers */,
E267FD8E1BE804E200F86B42 /* XLFormSegmentedCell.h in Headers */,
E267FD8A1BE804E200F86B42 /* XLFormLeftRightSelectorCell.h in Headers */,
E267FD921BE804E200F86B42 /* XLFormSliderCell.h in Headers */,
E267FD941BE804E200F86B42 /* XLFormStepCounterCell.h in Headers */,
E267FDBA1BE804E200F86B42 /* XLFormRowNavigationAccessoryView.h in Headers */,
E267FDAA1BE804E200F86B42 /* NSArray+XLFormAdditions.h in Headers */,
E267FDB21BE804E200F86B42 /* NSString+XLFormAdditions.h in Headers */,
E267FDB81BE804E200F86B42 /* XLFormRightImageButton.h in Headers */,
E267FDA51BE804E200F86B42 /* XLFormDescriptorDelegate.h in Headers */,
E267FDC41BE804E200F86B42 /* XLFormValidatorProtocol.h in Headers */,
E267FDC21BE804E200F86B42 /* XLFormValidator.h in Headers */,
E267FDAC1BE804E200F86B42 /* NSExpression+XLFormAdditions.h in Headers */,
E267FDB61BE804E200F86B42 /* XLFormRightDetailCell.h in Headers */,
E267FDB01BE804E200F86B42 /* NSPredicate+XLFormAdditions.h in Headers */,
E267FDBC1BE804E200F86B42 /* XLFormTextView.h in Headers */,
E267FDC01BE804E200F86B42 /* XLFormValidationStatus.h in Headers */,
E267FDB41BE804E200F86B42 /* UIView+XLFormAdditions.h in Headers */,
E267FD8C1BE804E200F86B42 /* XLFormPickerCell.h in Headers */,
E267FDBE1BE804E200F86B42 /* XLFormRegexValidator.h in Headers */,
E267FD9A1BE804E200F86B42 /* XLFormTextViewCell.h in Headers */,
9C2695202513CEFF0059594E /* XLFormCheckCell.h in Headers */,
9C26952A2513CEFF0059594E /* XLFormDateCell.h in Headers */,
9C2695602513D0230059594E /* XLFormDescriptorDelegate.h in Headers */,
9C2695962513D0D00059594E /* XLFormValidationStatus.h in Headers */,
9C2695562513CFF50059594E /* XLFormOptionsViewController.h in Headers */,
9C2695522513CFF50059594E /* XLFormViewController.h in Headers */,
9C2695192513CEFF0059594E /* XLFormBaseCell.h in Headers */,
9C2695542513CFF50059594E /* XLFormRowDescriptorViewController.h in Headers */,
9C2695772513D0520059594E /* NSPredicate+XLFormAdditions.h in Headers */,
9C2695992513D0D00059594E /* XLFormRegexValidator.h in Headers */,
9C2695242513CEFF0059594E /* XLFormInlineRowDescriptorCell.h in Headers */,
9C26957E2513D0520059594E /* NSString+XLFormAdditions.h in Headers */,
9C26957C2513D0520059594E /* UIView+XLFormAdditions.h in Headers */,
9C2695222513CEFF0059594E /* XLFormLeftRightSelectorCell.h in Headers */,
9C2695632513D0230059594E /* XLFormRowDescriptor.h in Headers */,
9C2695282513CEFF0059594E /* XLFormDescriptorCell.h in Headers */,
9C2695622513D0230059594E /* XLFormSectionDescriptor.h in Headers */,
9C2695572513CFF50059594E /* XLFormOptionsObject.h in Headers */,
9C2695432513CFA70059594E /* XLFormSliderCell.h in Headers */,
9C2695482513CFA70059594E /* XLFormSwitchCell.h in Headers */,
9C2695412513CFA70059594E /* XLFormStepCounterCell.h in Headers */,
9C2695422513CFA70059594E /* XLFormTextFieldCell.h in Headers */,
9C2695892513D0960059594E /* XLFormTextView.h in Headers */,
9C26951C2513CEFF0059594E /* XLFormButtonCell.h in Headers */,
9C26959B2513D0D00059594E /* XLFormValidatorProtocol.h in Headers */,
9C2695752513D0520059594E /* NSExpression+XLFormAdditions.h in Headers */,
9C2695872513D0960059594E /* XLFormRightImageButton.h in Headers */,
9C2695442513CFA70059594E /* XLFormTextViewCell.h in Headers */,
9C2695762513D0520059594E /* NSObject+XLFormAdditions.h in Headers */,
9C26954A2513CFA70059594E /* XLFormSelectorCell.h in Headers */,
9C2695982513D0D00059594E /* XLFormValidator.h in Headers */,
E267FDC51BE804E200F86B42 /* XLForm.h in Headers */,
E267FDA31BE804E200F86B42 /* XLFormDescriptor.h in Headers */,
E267FD981BE804E200F86B42 /* XLFormTextFieldCell.h in Headers */,
E267FD7C1BE804E200F86B42 /* XLFormBaseCell.h in Headers */,
E267FD861BE804E200F86B42 /* XLFormDescriptorCell.h in Headers */,
6442F6501C1FC3AA00C9152F /* XLFormImageCell.h in Headers */,
E267FDA01BE804E200F86B42 /* XLFormRowDescriptorViewController.h in Headers */,
9C26958C2513D0960059594E /* XLFormRowNavigationAccessoryView.h in Headers */,
9C2695662513D0230059594E /* XLFormDescriptor.h in Headers */,
9C2695882513D0960059594E /* XLFormRightDetailCell.h in Headers */,
9C26951E2513CEFF0059594E /* XLFormInlineSelectorCell.h in Headers */,
9C2695732513D0520059594E /* NSArray+XLFormAdditions.h in Headers */,
9C2695212513CEFF0059594E /* XLFormImageCell.h in Headers */,
9C26951B2513CEFF0059594E /* XLFormDatePickerCell.h in Headers */,
9C2695462513CFA70059594E /* XLFormPickerCell.h in Headers */,
9C2695492513CFA70059594E /* XLFormSegmentedCell.h in Headers */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -414,11 +409,12 @@
E267FD171BE8048900F86B42 /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 0710;
LastUpgradeCheck = 0940;
ORGANIZATIONNAME = XLForm;
TargetAttributes = {
E267FD1F1BE8048900F86B42 = {
CreatedOnToolsVersion = 7.1;
LastSwiftMigration = 1170;
};
};
};
@@ -427,6 +423,7 @@
developmentRegion = English;
hasScannedForEncodings = 0;
knownRegions = (
English,
en,
);
mainGroup = E267FD161BE8048900F86B42;
@@ -455,42 +452,42 @@
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
E267FDB51BE804E200F86B42 /* UIView+XLFormAdditions.m in Sources */,
E267FDC11BE804E200F86B42 /* XLFormValidationStatus.m in Sources */,
E267FDBD1BE804E200F86B42 /* XLFormTextView.m in Sources */,
E267FDB91BE804E200F86B42 /* XLFormRightImageButton.m in Sources */,
E267FDAB1BE804E200F86B42 /* NSArray+XLFormAdditions.m in Sources */,
E267FD811BE804E200F86B42 /* XLFormCheckCell.m in Sources */,
E267FDB71BE804E200F86B42 /* XLFormRightDetailCell.m in Sources */,
E267FD831BE804E200F86B42 /* XLFormDateCell.m in Sources */,
E267FD9B1BE804E200F86B42 /* XLFormTextViewCell.m in Sources */,
E267FD8F1BE804E200F86B42 /* XLFormSegmentedCell.m in Sources */,
E267FDAD1BE804E200F86B42 /* NSExpression+XLFormAdditions.m in Sources */,
E267FDBF1BE804E200F86B42 /* XLFormRegexValidator.m in Sources */,
E267FDC31BE804E200F86B42 /* XLFormValidator.m in Sources */,
E267FD931BE804E200F86B42 /* XLFormSliderCell.m in Sources */,
E267FDB11BE804E200F86B42 /* NSPredicate+XLFormAdditions.m in Sources */,
E267FDA41BE804E200F86B42 /* XLFormDescriptor.m in Sources */,
E267FD8B1BE804E200F86B42 /* XLFormLeftRightSelectorCell.m in Sources */,
E267FD9F1BE804E200F86B42 /* XLFormOptionsViewController.m in Sources */,
E267FD8D1BE804E200F86B42 /* XLFormPickerCell.m in Sources */,
E267FD951BE804E200F86B42 /* XLFormStepCounterCell.m in Sources */,
E267FDBB1BE804E200F86B42 /* XLFormRowNavigationAccessoryView.m in Sources */,
E267FD7D1BE804E200F86B42 /* XLFormBaseCell.m in Sources */,
E267FDA21BE804E200F86B42 /* XLFormViewController.m in Sources */,
E267FDB31BE804E200F86B42 /* NSString+XLFormAdditions.m in Sources */,
E267FD851BE804E200F86B42 /* XLFormDatePickerCell.m in Sources */,
E267FDAF1BE804E200F86B42 /* NSObject+XLFormAdditions.m in Sources */,
E267FD991BE804E200F86B42 /* XLFormTextFieldCell.m in Sources */,
E267FD9D1BE804E200F86B42 /* XLFormOptionsObject.m in Sources */,
E267FD7F1BE804E200F86B42 /* XLFormButtonCell.m in Sources */,
E267FD911BE804E200F86B42 /* XLFormSelectorCell.m in Sources */,
E267FDA91BE804E200F86B42 /* XLFormSectionDescriptor.m in Sources */,
6442F6511C1FC3AA00C9152F /* XLFormImageCell.m in Sources */,
E267FD971BE804E200F86B42 /* XLFormSwitchCell.m in Sources */,
9C2695782513D0520059594E /* UIView+XLFormAdditions.m in Sources */,
9C26953C2513CFA70059594E /* XLFormPickerCell.m in Sources */,
9C2695612513D0230059594E /* XLFormRowDescriptor.m in Sources */,
9C26953E2513CFA70059594E /* XLFormSelectorCell.m in Sources */,
9C26959C2513D0D00059594E /* XLFormValidator.m in Sources */,
9C2695402513CFA70059594E /* XLFormTextFieldCell.m in Sources */,
9C26959A2513D0D00059594E /* XLFormRegexValidator.m in Sources */,
9C26957A2513D0520059594E /* NSExpression+XLFormAdditions.m in Sources */,
9C26953F2513CFA70059594E /* XLFormTextViewCell.m in Sources */,
9C2695262513CEFF0059594E /* XLFormInlineSelectorCell.m in Sources */,
9C2695552513CFF50059594E /* XLFormOptionsObject.m in Sources */,
9C2695452513CFA70059594E /* XLFormSegmentedCell.m in Sources */,
9C2695972513D0D00059594E /* XLFormValidationStatus.m in Sources */,
9C2695582513CFF50059594E /* XLFormOptionsViewController.m in Sources */,
9C26951D2513CEFF0059594E /* XLFormButtonCell.m in Sources */,
9C26957B2513D0520059594E /* NSPredicate+XLFormAdditions.m in Sources */,
9C26951F2513CEFF0059594E /* XLFormDatePickerCell.m in Sources */,
9C2695472513CFA70059594E /* XLFormSwitchCell.m in Sources */,
9C26958B2513D0960059594E /* XLFormTextView.m in Sources */,
9C2695642513D0230059594E /* XLFormDescriptor.m in Sources */,
9C26953D2513CFA70059594E /* XLFormSliderCell.m in Sources */,
9C2695742513D0520059594E /* NSString+XLFormAdditions.m in Sources */,
9C2695232513CEFF0059594E /* XLFormLeftRightSelectorCell.m in Sources */,
9C26958D2513D0960059594E /* XLFormRightImageButton.m in Sources */,
9C26958A2513D0960059594E /* XLFormRowNavigationAccessoryView.m in Sources */,
9C26953B2513CFA70059594E /* XLFormStepCounterCell.m in Sources */,
9C2695532513CFF50059594E /* XLFormViewController.m in Sources */,
9C26951A2513CEFF0059594E /* XLFormCheckCell.m in Sources */,
9C2695292513CEFF0059594E /* XLFormImageCell.m in Sources */,
9C2695272513CEFF0059594E /* XLFormBaseCell.m in Sources */,
9C2695252513CEFF0059594E /* XLFormDateCell.m in Sources */,
9C26958E2513D0960059594E /* XLFormRightDetailCell.m in Sources */,
9C2695652513D0230059594E /* XLFormSectionDescriptor.m in Sources */,
9C26957D2513D0520059594E /* NSObject+XLFormAdditions.m in Sources */,
9C2695792513D0520059594E /* NSArray+XLFormAdditions.m in Sources */,
E267FDC61BE804E200F86B42 /* XLForm.m in Sources */,
E267FD891BE804E200F86B42 /* XLFormInlineSelectorCell.m in Sources */,
E267FDA71BE804E200F86B42 /* XLFormRowDescriptor.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -505,13 +502,23 @@
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
@@ -520,6 +527,7 @@
DEBUG_INFORMATION_FORMAT = dwarf;
ENABLE_STRICT_OBJC_MSGSEND = YES;
ENABLE_TESTABILITY = YES;
"EXCLUDED_ARCHS[sdk=iphonesimulator*]" = arm64;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_DYNAMIC_NO_PIC = NO;
GCC_NO_COMMON_BLOCKS = YES;
@@ -534,7 +542,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
@@ -552,21 +560,32 @@
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution";
COPY_PHASE_STRIP = NO;
CURRENT_PROJECT_VERSION = 3.0.2;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
"EXCLUDED_ARCHS[sdk=iphonesimulator*]" = arm64;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_NO_COMMON_BLOCKS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
@@ -575,7 +594,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
TARGETED_DEVICE_FAMILY = "1,2";
@@ -588,6 +607,9 @@
E267FD291BE8048900F86B42 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
CLANG_ENABLE_MODULES = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "";
CURRENT_PROJECT_VERSION = 1;
DEFINES_MODULE = YES;
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
@@ -595,15 +617,21 @@
INFOPLIST_FILE = XLForm/Info.plist;
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
MARKETING_VERSION = 4.3.0;
PRODUCT_BUNDLE_IDENTIFIER = com.xmartlabs.XLForm;
PRODUCT_NAME = "$(TARGET_NAME)";
SKIP_INSTALL = YES;
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
SWIFT_VERSION = 5.0;
};
name = Debug;
};
E267FD2A1BE8048900F86B42 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
CLANG_ENABLE_MODULES = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "";
CURRENT_PROJECT_VERSION = 1;
DEFINES_MODULE = YES;
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
@@ -611,9 +639,11 @@
INFOPLIST_FILE = XLForm/Info.plist;
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
MARKETING_VERSION = 4.3.0;
PRODUCT_BUNDLE_IDENTIFIER = com.xmartlabs.XLForm;
PRODUCT_NAME = "$(TARGET_NAME)";
SKIP_INSTALL = YES;
SWIFT_VERSION = 5.0;
};
name = Release;
};
@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IDEDidComputeMac32BitWarning</key>
<true/>
</dict>
</plist>
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0710"
LastUpgradeVersion = "0940"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
+1 -1
View File
@@ -15,7 +15,7 @@
<key>CFBundlePackageType</key>
<string>FMWK</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<string>$(MARKETING_VERSION)</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
@@ -27,6 +27,6 @@
@interface NSArray (XLFormAdditions)
-(NSInteger)formIndexForItem:(id)item;
-(NSInteger)formIndexForItem:(nonnull id)item;
@end
@@ -28,7 +28,7 @@
@implementation NSArray (XLFormAdditions)
-(NSInteger)formIndexForItem:(id)item
-(NSInteger)formIndexForItem:(nonnull id)item
{
for (id selectedValueItem in self) {
if ([[selectedValueItem valueData] isEqual:[item valueData]]){
@@ -28,6 +28,6 @@
@interface NSExpression (XLFormAdditions)
-(NSMutableArray*) getExpressionVars;
-(nullable NSMutableArray*) getExpressionVars;
@end
@@ -29,7 +29,7 @@
@implementation NSExpression (XLFormAdditions)
-(NSMutableArray*) getExpressionVars{
-(nullable NSMutableArray*) getExpressionVars{
switch (self.expressionType) {
case NSFunctionExpressionType:{
NSString* str = [NSString stringWithFormat:@"%@", self];
@@ -38,11 +38,9 @@
else
str = [str substringFromIndex:1];
return [[NSMutableArray alloc] initWithObjects: str, nil];
break;
}
default:
return nil;
break;
}
}
@@ -27,7 +27,7 @@
@interface NSObject (XLFormAdditions)
-(NSString *)displayText;
-(id)valueData;
-(nullable NSString *)displayText;
-(nullable id)valueData;
@end
@@ -29,18 +29,18 @@
@implementation NSObject (XLFormAdditions)
-(NSString *)displayText
-(nullable NSString *)displayText
{
if ([self isKindOfClass:[NSString class]] || [self isKindOfClass:[NSNumber class]]){
return [self description];
}
if ([self conformsToProtocol:@protocol(XLFormOptionObject)]){
return [(id<XLFormOptionObject>)self formDisplayText];
}
if ([self isKindOfClass:[NSString class]] || [self isKindOfClass:[NSNumber class]]){
return [self description];
}
return nil;
}
-(id)valueData
-(nullable id)valueData
{
if ([self isKindOfClass:[NSString class]] || [self isKindOfClass:[NSNumber class]] || [self isKindOfClass:[NSDate class]]){
return self;
@@ -27,5 +27,5 @@
@interface NSPredicate (XLFormAdditions)
-(NSMutableArray*) getPredicateVars;
-(nonnull NSMutableArray*) getPredicateVars;
@end
@@ -28,7 +28,7 @@
@implementation NSPredicate (XLFormAdditions)
-(NSMutableArray*) getPredicateVars{
-(nonnull NSMutableArray*) getPredicateVars{
NSMutableArray* ret = [[NSMutableArray alloc] init];
if ([self isKindOfClass:([NSCompoundPredicate class])]) {
for (id object in ((NSCompoundPredicate*) self).subpredicates ) {
@@ -28,8 +28,8 @@
@interface NSString (XLFormAdditions)
-(NSPredicate *)formPredicate;
-(nonnull NSPredicate *)formPredicate;
-(NSString *)formKeyForPredicateType:(XLPredicateType)predicateType;
-(nonnull NSString *)formKeyForPredicateType:(XLPredicateType)predicateType;
@end
@@ -27,7 +27,7 @@
@implementation NSString (XLFormAdditions)
-(NSPredicate *)formPredicate
-(nonnull NSPredicate *)formPredicate
{
// returns an array of strings where the first one is the new string with the correct replacements
// and the rest are all the tags that appear in the string
@@ -57,7 +57,7 @@
}
-(NSString *)formKeyForPredicateType:(XLPredicateType)predicateType
-(nonnull NSString *)formKeyForPredicateType:(XLPredicateType)predicateType
{
return [NSString stringWithFormat:@"%@-%@", self, (predicateType == XLPredicateTypeHidden ? @"hidden" : @"disabled") ];
}
@@ -28,9 +28,9 @@
@interface UIView (XLFormAdditions)
+(id)autolayoutView;
-(NSLayoutConstraint *)layoutConstraintSameHeightOf:(UIView *)view;
-(UIView *)findFirstResponder;
-(UITableViewCell<XLFormDescriptorCell> *)formDescriptorCell;
+(nonnull instancetype)autolayoutView;
-(nonnull NSLayoutConstraint *)layoutConstraintSameHeightOf:(nonnull UIView *)view;
-(nullable UIView *)findFirstResponder;
-(nullable UITableViewCell<XLFormDescriptorCell> *)formDescriptorCell;
@end
@@ -27,47 +27,62 @@
@implementation UIView (XLFormAdditions)
+ (id)autolayoutView
+ (nonnull instancetype)autolayoutView
{
UIView *view = [self new];
__kindof UIView *view = [self new];
view.translatesAutoresizingMaskIntoConstraints = NO;
return view;
}
-(NSLayoutConstraint *)layoutConstraintSameHeightOf:(UIView *)view
- (nonnull NSLayoutConstraint *)layoutConstraintSameHeightOf:(nonnull UIView *)view
{
return [NSLayoutConstraint constraintWithItem:self attribute:NSLayoutAttributeHeight relatedBy:NSLayoutRelationEqual toItem:view attribute:NSLayoutAttributeHeight multiplier:1.0f constant:0.0f];
return [NSLayoutConstraint constraintWithItem:self
attribute:NSLayoutAttributeHeight
relatedBy:NSLayoutRelationEqual
toItem:view
attribute:NSLayoutAttributeHeight
multiplier:1.0
constant:0.0];
}
- (UIView *)findFirstResponder
- (nullable UIView *)findFirstResponder
{
UIView *firstResponder = nil;
if (self.isFirstResponder) {
return self;
firstResponder = self;
}
for (UIView *subView in self.subviews) {
UIView *firstResponder = [subView findFirstResponder];
if (firstResponder != nil) {
return firstResponder;
else {
for (UIView *subView in self.subviews) {
UIView *fr = [subView findFirstResponder];
if (fr != nil) {
firstResponder = fr;
break;
}
}
}
return nil;
return firstResponder;
}
- (UITableViewCell<XLFormDescriptorCell> *)formDescriptorCell
- (nullable UITableViewCell<XLFormDescriptorCell> *)formDescriptorCell
{
UITableViewCell<XLFormDescriptorCell> * tableViewCell = nil;
if ([self isKindOfClass:[UITableViewCell class]]) {
if ([self conformsToProtocol:@protocol(XLFormDescriptorCell)]){
return (UITableViewCell<XLFormDescriptorCell> *)self;
}
return nil;
}
if (self.superview) {
UITableViewCell<XLFormDescriptorCell> * tableViewCell = [self.superview formDescriptorCell];
if (tableViewCell != nil) {
return tableViewCell;
tableViewCell = (UITableViewCell<XLFormDescriptorCell> *)self;
}
}
return nil;
else if (self.superview) {
UITableViewCell<XLFormDescriptorCell> * cell = [self.superview formDescriptorCell];
if (cell != nil) {
tableViewCell = cell;
}
}
return tableViewCell;
}
@end
@@ -42,8 +42,8 @@
@protocol XLFormReturnKeyProtocol
@property UIReturnKeyType returnKeyType;
@property UIReturnKeyType nextReturnKeyType;
@property (nonatomic, assign) UIReturnKeyType returnKeyType;
@property (nonatomic, assign) UIReturnKeyType nextReturnKeyType;
@end
+27 -2
View File
@@ -27,7 +27,7 @@
@implementation XLFormBaseCell
- (id)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
if (self) {
@@ -50,7 +50,32 @@
{
self.textLabel.font = [UIFont preferredFontForTextStyle:UIFontTextStyleBody];
self.detailTextLabel.font = [UIFont preferredFontForTextStyle:UIFontTextStyleBody];
self.textLabel.textColor = self.rowDescriptor.isDisabled ? [UIColor grayColor] : [UIColor blackColor];
UIColor * textColor = nil;
UIColor * disabledTextColor = nil;
if (@available(iOS 13.0, *)) {
textColor = [UIColor labelColor];
disabledTextColor = [UIColor systemGray3Color];
}
else if (@available(iOS 12.0, *)) {
textColor = [self traitCollection].userInterfaceStyle == UIUserInterfaceStyleDark ? [UIColor lightTextColor] : [UIColor darkTextColor];
disabledTextColor = [UIColor systemGrayColor];
}
else {
textColor = [UIColor blackColor];
disabledTextColor = [UIColor grayColor];
}
if (self.rowDescriptor.isDisabled) {
self.textLabel.textColor = disabledTextColor;
}
else {
self.textLabel.textColor = textColor;
}
}
-(void)highlight
+15 -5
View File
@@ -26,14 +26,24 @@
#import "XLFormRowDescriptor.h"
#import "XLFormButtonCell.h"
@interface XLFormButtonCell ()
@property(nonatomic) BOOL useTintColor;
@end
@implementation XLFormButtonCell
- (id)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
return [super initWithStyle:style reuseIdentifier:reuseIdentifier];
self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
if (self) {
_useTintColor = YES;
}
return self;
}
#pragma mark - XLFormDescriptorCell
-(void)configure
@@ -52,12 +62,12 @@
self.editingAccessoryType = self.accessoryType;
self.selectionStyle = isDisabled ? UITableViewCellSelectionStyleNone : UITableViewCellSelectionStyleDefault;
if (simpleAction){
if (simpleAction && _useTintColor){
CGFloat red, green, blue, alpha;
[self.tintColor getRed:&red green:&green blue:&blue alpha:&alpha];
self.textLabel.textColor = [UIColor colorWithRed:red green:green blue:blue alpha:(isDisabled ? 0.3 : 1.0)];
}
self.detailTextLabel.text = self.rowDescriptor.value;
}
@@ -32,11 +32,20 @@ typedef NS_ENUM(NSUInteger, XLFormDateDatePickerMode) {
XLFormDateDatePickerModeTime
};
typedef NS_ENUM(NSUInteger, XLFormDateDatePickerStyle) {
XLFormDateDatePickerStyleAutomatic,
XLFormDateDatePickerStyleCompact,
XLFormDateDatePickerStyleInline,
XLFormDateDatePickerStyleWheels
};
@interface XLFormDateCell : XLFormBaseCell
@property (nonatomic) XLFormDateDatePickerMode formDatePickerMode;
@property (nonatomic) NSDate *minimumDate;
@property (nonatomic) NSDate *maximumDate;
@property (nonatomic) NSInteger minuteInterval;
@property (nonatomic, assign) XLFormDateDatePickerMode formDatePickerMode;
@property (nonatomic, assign) XLFormDateDatePickerStyle formDatePickerStyle;
@property (nonatomic, copy ) NSDate *minimumDate;
@property (nonatomic, copy ) NSDate *maximumDate;
@property (nonatomic, assign) NSInteger minuteInterval;
@property (nonatomic, copy ) NSLocale *locale;
@end
@@ -37,6 +37,7 @@
@implementation XLFormDateCell
{
UIColor * _beforeChangeColor;
NSDateFormatter *_dateFormatter;
}
@@ -47,6 +48,7 @@
[self.datePicker setDate:self.rowDescriptor.value animated:[self.rowDescriptor.rowType isEqualToString:XLFormRowDescriptorTypeCountDownTimer]];
}
[self setModeToDatePicker:self.datePicker];
[self setStyleToDatePicker:self.datePicker];
return self.datePicker;
}
return [super inputView];
@@ -73,6 +75,7 @@
XLFormRowDescriptor * datePickerRowDescriptor = [XLFormRowDescriptor formRowDescriptorWithTag:nil rowType:XLFormRowDescriptorTypeDatePicker];
XLFormDatePickerCell * datePickerCell = (XLFormDatePickerCell *)[datePickerRowDescriptor cellForFormController:self.formViewController];
[self setModeToDatePicker:datePickerCell.datePicker];
[self setStyleToDatePicker:datePickerCell.datePicker];
if (self.rowDescriptor.value){
[datePickerCell.datePicker setDate:self.rowDescriptor.value animated:[self.rowDescriptor.rowType isEqualToString:XLFormRowDescriptorTypeCountDownTimerInline]];
}
@@ -109,6 +112,7 @@
{
[super configure];
self.formDatePickerMode = XLFormDateDatePickerModeGetFromRowDescriptor;
_dateFormatter = [[NSDateFormatter alloc] init];
}
-(void)update
@@ -173,16 +177,24 @@
}
}
if ([self.rowDescriptor.rowType isEqualToString:XLFormRowDescriptorTypeDate] || [self.rowDescriptor.rowType isEqualToString:XLFormRowDescriptorTypeDateInline]){
return [NSDateFormatter localizedStringFromDate:date dateStyle:NSDateFormatterMediumStyle timeStyle:NSDateFormatterNoStyle];
_dateFormatter.dateStyle = NSDateFormatterMediumStyle;
_dateFormatter.timeStyle = NSDateFormatterNoStyle;
return [_dateFormatter stringFromDate:date];
}
else if ([self.rowDescriptor.rowType isEqualToString:XLFormRowDescriptorTypeTime] || [self.rowDescriptor.rowType isEqualToString:XLFormRowDescriptorTypeTimeInline]){
return [NSDateFormatter localizedStringFromDate:date dateStyle:NSDateFormatterNoStyle timeStyle:NSDateFormatterShortStyle];
_dateFormatter.dateStyle = NSDateFormatterNoStyle;
_dateFormatter.timeStyle = NSDateFormatterShortStyle;
return [_dateFormatter stringFromDate:date];
}
else if ([self.rowDescriptor.rowType isEqualToString:XLFormRowDescriptorTypeCountDownTimer] || [self.rowDescriptor.rowType isEqualToString:XLFormRowDescriptorTypeCountDownTimerInline]){
NSDateComponents *time = [[NSCalendar currentCalendar] components:NSCalendarUnitHour | NSCalendarUnitMinute fromDate:date];
NSCalendar *calendar = [NSCalendar currentCalendar];
[calendar setTimeZone:[NSTimeZone timeZoneForSecondsFromGMT:0]];
NSDateComponents *time = [calendar components:NSCalendarUnitHour | NSCalendarUnitMinute fromDate:date];
return [NSString stringWithFormat:@"%ld%@ %ldmin", (long)[time hour], (long)[time hour] == 1 ? @"hour" : @"hours", (long)[time minute]];
}
return [NSDateFormatter localizedStringFromDate:date dateStyle:NSDateFormatterShortStyle timeStyle:NSDateFormatterShortStyle];
_dateFormatter.dateStyle = NSDateFormatterShortStyle;
_dateFormatter.timeStyle = NSDateFormatterShortStyle;
return [_dateFormatter stringFromDate:date];
}
-(void)setModeToDatePicker:(UIDatePicker *)datePicker
@@ -195,6 +207,7 @@
}
else if ([self.rowDescriptor.rowType isEqualToString:XLFormRowDescriptorTypeCountDownTimer] || [self.rowDescriptor.rowType isEqualToString:XLFormRowDescriptorTypeCountDownTimerInline]){
datePicker.datePickerMode = UIDatePickerModeCountDownTimer;
datePicker.timeZone = [NSTimeZone timeZoneForSecondsFromGMT:0];
}
else{
datePicker.datePickerMode = UIDatePickerModeDateAndTime;
@@ -208,6 +221,30 @@
if (self.maximumDate)
datePicker.maximumDate = self.maximumDate;
if (self.locale) {
datePicker.locale = self.locale;
}
}
-(void)setStyleToDatePicker:(UIDatePicker *)datePicker
{
if (@available(iOS 14.0, *)) {
switch (self.formDatePickerStyle) {
case XLFormDateDatePickerStyleInline:
datePicker.preferredDatePickerStyle = UIDatePickerStyleInline;
break;
case XLFormDateDatePickerStyleCompact:
datePicker.preferredDatePickerStyle = UIDatePickerStyleCompact;
break;
case XLFormDateDatePickerStyleWheels:
datePicker.preferredDatePickerStyle = UIDatePickerStyleWheels;
break;
default:
datePicker.preferredDatePickerStyle = UIDatePickerStyleAutomatic;
break;
}
}
}
#pragma mark - Properties
@@ -217,10 +254,16 @@
if (_datePicker) return _datePicker;
_datePicker = [[UIDatePicker alloc] init];
[self setModeToDatePicker:_datePicker];
[self setStyleToDatePicker:_datePicker];
[_datePicker addTarget:self action:@selector(datePickerValueChanged:) forControlEvents:UIControlEventValueChanged];
return _datePicker;
}
-(void)setLocale:(NSLocale *)locale
{
_locale = locale;
_dateFormatter.locale = locale;
}
#pragma mark - Target Action
@@ -242,6 +285,7 @@
if ([nextFormRow.rowType isEqualToString:XLFormRowDescriptorTypeDatePicker]){
XLFormDatePickerCell * datePickerCell = (XLFormDatePickerCell *)[nextFormRow cellForFormController:self.formViewController];
[self setModeToDatePicker:datePickerCell.datePicker];
[self setStyleToDatePicker:datePickerCell.datePicker];
}
}
}
@@ -37,16 +37,6 @@
return YES;
}
#pragma mark - Properties
-(UIDatePicker *)datePicker
{
if (_datePicker) return _datePicker;
_datePicker = [UIDatePicker autolayoutView];
[_datePicker addTarget:self action:@selector(datePickerValueChanged:) forControlEvents:UIControlEventValueChanged];
return _datePicker;
}
#pragma mark- Target Action
- (void)datePickerValueChanged:(UIDatePicker *)sender
@@ -66,7 +56,12 @@
-(void)configure
{
[super configure];
[self.contentView addSubview:self.datePicker];
UIDatePicker *datePicker = [UIDatePicker autolayoutView];
[datePicker addTarget:self action:@selector(datePickerValueChanged:) forControlEvents:UIControlEventValueChanged];
[self.contentView addSubview:datePicker];
_datePicker = datePicker;
[self.contentView addConstraint:[NSLayoutConstraint constraintWithItem:self.datePicker attribute:NSLayoutAttributeCenterX relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeCenterX multiplier:1 constant:0]];
[self.contentView addConstraints:[NSLayoutConstraint constraintsWithVisualFormat:@"V:|-0-[datePicker]-0-|" options:0 metrics:0 views:@{@"datePicker" : self.datePicker}]];
}
@@ -49,15 +49,15 @@ typedef NS_OPTIONS(NSUInteger, XLFormRowNavigationOptions) {
@interface XLFormDescriptor : NSObject
@property (readonly, nonatomic, nonnull) NSMutableArray * formSections;
@property (readonly, nullable) NSString * title;
@property (nonatomic) BOOL endEditingTableViewOnScroll;
@property (nonatomic) BOOL assignFirstResponderOnShow;
@property (nonatomic) BOOL addAsteriskToRequiredRowsTitle;
@property (getter=isDisabled) BOOL disabled;
@property (nonatomic) XLFormRowNavigationOptions rowNavigationOptions;
@property (nonatomic, strong, readonly, nonnull) NSMutableArray * formSections;
@property (nonatomic, readonly, nullable, copy) NSString * title;
@property (nonatomic, assign) BOOL endEditingTableViewOnScroll;
@property (nonatomic, assign) BOOL assignFirstResponderOnShow;
@property (nonatomic, assign) BOOL addAsteriskToRequiredRowsTitle;
@property (nonatomic, getter=isDisabled, assign) BOOL disabled;
@property (nonatomic, assign) XLFormRowNavigationOptions rowNavigationOptions;
@property (weak, nullable) id<XLFormDescriptorDelegate> delegate;
@property (nonatomic, weak, nullable) id<XLFormDescriptorDelegate> delegate;
+(nonnull instancetype)formDescriptor;
+(nonnull instancetype)formDescriptorWithTitle:(nullable NSString *)title;
@@ -32,10 +32,13 @@
NSString * const XLFormErrorDomain = @"XLFormErrorDomain";
NSString * const XLValidationStatusErrorKey = @"XLValidationStatusErrorKey";
NSString * const XLFormSectionsKey = @"formSections";
@interface XLFormSectionDescriptor (_XLFormDescriptor)
@property NSArray * allRows;
@property (nonatomic, weak) NSArray *allRows;
-(BOOL)evaluateIsHidden;
@end
@@ -51,11 +54,11 @@ NSString * const XLValidationStatusErrorKey = @"XLValidationStatusErrorKey";
@interface XLFormDescriptor()
@property NSMutableArray * formSections;
@property (readonly) NSMutableArray * allSections;
@property NSString * title;
@property (readonly) NSMutableDictionary* allRowsByTag;
@property NSMutableDictionary* rowObservers;
@property (nonatomic, strong) NSMutableArray *formSections;
@property (nonatomic, strong, readonly) NSMutableArray *allSections;
@property (nonatomic, copy ) NSString *title;
@property (nonatomic, strong, readonly) NSMutableDictionary *allRowsByTag;
@property (atomic , strong) NSMutableDictionary *rowObservers;
@end
@@ -63,15 +66,14 @@ NSString * const XLValidationStatusErrorKey = @"XLValidationStatusErrorKey";
-(instancetype)init
{
return [self initWithTitle:nil];
return [self initWithTitle:@""];
}
-(instancetype)initWithTitle:(NSString *)title;
{
self = [super init];
if (self){
if (self = [super init]) {
_formSections = [NSMutableArray array];
_allSections = [NSMutableArray array];
_allSections = [NSMutableArray array];
_allRowsByTag = [NSMutableDictionary dictionary];
_rowObservers = [NSMutableDictionary dictionary];
_title = title;
@@ -79,14 +81,19 @@ NSString * const XLValidationStatusErrorKey = @"XLValidationStatusErrorKey";
_disabled = NO;
_endEditingTableViewOnScroll = YES;
_rowNavigationOptions = XLFormRowNavigationOptionEnabled;
[self addObserver:self forKeyPath:@"formSections" options:(NSKeyValueObservingOptionNew | NSKeyValueObservingOptionOld) context:0];
[self addObserver:self
forKeyPath:XLFormSectionsKey
options:(NSKeyValueObservingOptionNew | NSKeyValueObservingOptionOld)
context:0];
}
return self;
}
+(instancetype)formDescriptor
{
return [[self class] formDescriptorWithTitle:nil];
return [[self class] formDescriptorWithTitle:@""];
}
+(instancetype)formDescriptorWithTitle:(NSString *)title
@@ -101,11 +108,11 @@ NSString * const XLValidationStatusErrorKey = @"XLValidationStatusErrorKey";
-(void)addFormSection:(XLFormSectionDescriptor *)formSection atIndex:(NSUInteger)index
{
if (index == 0){
if (index == 0) {
[self insertObject:formSection inAllSectionsAtIndex:0];
}
else{
XLFormSectionDescriptor* previousSection = [self.formSections objectAtIndex:MIN(self.formSections.count, index-1)];
else {
XLFormSectionDescriptor *previousSection = [self.formSections objectAtIndex:MIN(self.formSections.count, index-1)];
[self addFormSection:formSection afterSection:previousSection];
}
}
@@ -114,26 +121,28 @@ NSString * const XLValidationStatusErrorKey = @"XLValidationStatusErrorKey";
{
NSUInteger sectionIndex;
NSUInteger allSectionIndex;
if ((sectionIndex = [self.allSections indexOfObject:formSection]) == NSNotFound){
if ((sectionIndex = [self.allSections indexOfObject:formSection]) == NSNotFound) {
allSectionIndex = [self.allSections indexOfObject:afterSection];
if (allSectionIndex != NSNotFound) {
[self insertObject:formSection inAllSectionsAtIndex:(allSectionIndex + 1)];
}
else { //case when afterSection does not exist. Just insert at the end.
[self addFormSection:formSection];
return;
}
}
formSection.hidden = formSection.hidden;
}
-(void)addFormRow:(XLFormRowDescriptor *)formRow beforeRow:(XLFormRowDescriptor *)beforeRow
{
if (beforeRow.sectionDescriptor){
if (beforeRow.sectionDescriptor) {
[beforeRow.sectionDescriptor addFormRow:formRow beforeRow:beforeRow];
}
else{
else {
[[self.allSections lastObject] addFormRow:formRow beforeRow:beforeRow];
}
}
@@ -144,27 +153,25 @@ NSString * const XLValidationStatusErrorKey = @"XLValidationStatusErrorKey";
[self addFormRow:formRow beforeRow:beforeRowForm];
}
-(void)addFormRow:(XLFormRowDescriptor *)formRow afterRow:(XLFormRowDescriptor *)afterRow
{
if (afterRow.sectionDescriptor){
if (afterRow.sectionDescriptor) {
[afterRow.sectionDescriptor addFormRow:formRow afterRow:afterRow];
}
else{
else {
[[self.allSections lastObject] addFormRow:formRow afterRow:afterRow];
}
}
-(void)addFormRow:(XLFormRowDescriptor *)formRow afterRowTag:(NSString *)afterRowTag
{
XLFormRowDescriptor * afterRowForm = [self formRowWithTag:afterRowTag];
XLFormRowDescriptor *afterRowForm = [self formRowWithTag:afterRowTag];
[self addFormRow:formRow afterRow:afterRowForm];
}
-(void)removeFormSectionAtIndex:(NSUInteger)index
{
if (self.formSections.count > index){
if (self.formSections.count > index) {
XLFormSectionDescriptor *formSection = [self.formSections objectAtIndex:index];
[self removeObjectFromFormSectionsAtIndex:index];
NSUInteger allSectionIndex = [self.allSections indexOfObject:formSection];
@@ -175,43 +182,47 @@ NSString * const XLValidationStatusErrorKey = @"XLValidationStatusErrorKey";
-(void)removeFormSection:(XLFormSectionDescriptor *)formSection
{
NSUInteger index = NSNotFound;
if ((index = [self.formSections indexOfObject:formSection]) != NSNotFound){
if ((index = [self.formSections indexOfObject:formSection]) != NSNotFound) {
[self removeFormSectionAtIndex:index];
}
else if ((index = [self.allSections indexOfObject:formSection]) != NSNotFound){
if ((index = [self.allSections indexOfObject:formSection]) != NSNotFound) {
[self removeObjectFromAllSectionsAtIndex:index];
};
}
}
-(void)removeFormRow:(XLFormRowDescriptor *)formRow
{
for (XLFormSectionDescriptor * section in self.formSections){
if ([section.formRows containsObject:formRow]){
for (XLFormSectionDescriptor *section in self.formSections) {
if ([section.formRows containsObject:formRow]) {
[section removeFormRow:formRow];
break;
}
}
}
-(void)showFormSection:(XLFormSectionDescriptor*)formSection
-(void)showFormSection:(XLFormSectionDescriptor *)formSection
{
NSUInteger formIndex = [self.formSections indexOfObject:formSection];
if (formIndex != NSNotFound) {
return;
}
NSUInteger index = [self.allSections indexOfObject:formSection];
if (index != NSNotFound){
if (index != NSNotFound) {
while (formIndex == NSNotFound && index > 0) {
XLFormSectionDescriptor* previous = [self.allSections objectAtIndex:--index];
formIndex = [self.formSections indexOfObject:previous];
}
[self insertObject:formSection inFormSectionsAtIndex:(formIndex == NSNotFound ? 0 : ++formIndex)];
}
}
-(void)hideFormSection:(XLFormSectionDescriptor*)formSection
-(void)hideFormSection:(XLFormSectionDescriptor *)formSection
{
NSUInteger index = [self.formSections indexOfObject:formSection];
if (index != NSNotFound){
if (index != NSNotFound) {
[self removeObjectFromFormSectionsAtIndex:index];
}
}
@@ -224,28 +235,29 @@ NSString * const XLValidationStatusErrorKey = @"XLValidationStatusErrorKey";
-(XLFormRowDescriptor *)formRowWithHash:(NSUInteger)hash
{
for (XLFormSectionDescriptor * section in self.allSections){
for (XLFormRowDescriptor * row in section.allRows) {
if ([row hash] == hash){
for (XLFormSectionDescriptor *section in self.allSections) {
for (XLFormRowDescriptor *row in section.allRows) {
if ([row hash] == hash) {
return row;
}
}
}
return nil;
}
-(void)removeFormRowWithTag:(NSString *)tag
{
XLFormRowDescriptor * formRow = [self formRowWithTag:tag];
XLFormRowDescriptor *formRow = [self formRowWithTag:tag];
[self removeFormRow:formRow];
}
-(XLFormRowDescriptor *)formRowAtIndex:(NSIndexPath *)indexPath
{
if ((self.formSections.count > indexPath.section) && [[self.formSections objectAtIndex:indexPath.section] formRows].count > indexPath.row){
if ((self.formSections.count > indexPath.section) && [[self.formSections objectAtIndex:indexPath.section] formRows].count > indexPath.row) {
return [[[self.formSections objectAtIndex:indexPath.section] formRows] objectAtIndex:indexPath.row];
}
return nil;
}
@@ -256,55 +268,62 @@ NSString * const XLValidationStatusErrorKey = @"XLValidationStatusErrorKey";
-(NSIndexPath *)indexPathOfFormRow:(XLFormRowDescriptor *)formRow
{
XLFormSectionDescriptor * section = formRow.sectionDescriptor;
if (section){
NSIndexPath *result = nil;
XLFormSectionDescriptor *section = formRow.sectionDescriptor;
if (section) {
NSUInteger sectionIndex = [self.formSections indexOfObject:section];
if (sectionIndex != NSNotFound){
if (sectionIndex != NSNotFound) {
NSUInteger rowIndex = [section.formRows indexOfObject:formRow];
if (rowIndex != NSNotFound){
return [NSIndexPath indexPathForRow:rowIndex inSection:sectionIndex];
if (rowIndex != NSNotFound) {
result = [NSIndexPath indexPathForRow:rowIndex inSection:sectionIndex];
}
}
}
return nil;
return result;
}
-(NSIndexPath *)globalIndexPathOfFormRow:(XLFormRowDescriptor *)formRow
{
XLFormSectionDescriptor * section = formRow.sectionDescriptor;
if (section){
NSIndexPath *result = nil;
XLFormSectionDescriptor *section = formRow.sectionDescriptor;
if (section) {
NSUInteger sectionIndex = [self.allSections indexOfObject:section];
if (sectionIndex != NSNotFound){
if (sectionIndex != NSNotFound) {
NSUInteger rowIndex = [section.allRows indexOfObject:formRow];
if (rowIndex != NSNotFound){
return [NSIndexPath indexPathForRow:rowIndex inSection:sectionIndex];
if (rowIndex != NSNotFound) {
result = [NSIndexPath indexPathForRow:rowIndex inSection:sectionIndex];
}
}
}
return nil;
return result;
}
-(NSDictionary *)formValues
{
NSMutableDictionary * result = [NSMutableDictionary dictionary];
for (XLFormSectionDescriptor * section in self.formSections) {
if (section.multivaluedTag.length > 0){
NSMutableArray * multiValuedValuesArray = [NSMutableArray new];
for (XLFormRowDescriptor * row in section.formRows) {
if (row.value){
NSMutableDictionary *result = [NSMutableDictionary dictionary];
for (XLFormSectionDescriptor *section in self.formSections) {
if (section.multivaluedTag.length > 0) {
NSMutableArray *multiValuedValuesArray = [NSMutableArray new];
for (XLFormRowDescriptor *row in section.formRows) {
if (row.value && row.value != [NSNull null]) {
[multiValuedValuesArray addObject:row.value];
}
}
[result setObject:multiValuedValuesArray forKey:section.multivaluedTag];
}
else{
for (XLFormRowDescriptor * row in section.formRows) {
if (row.tag.length > 0){
[result setObject:(row.value ?: [NSNull null]) forKey:row.tag];
else {
for (XLFormRowDescriptor *row in section.formRows) {
id value = [row.value valueData];
if (row.tag.length > 0 && value != nil) {
[result setObject:value forKey:row.tag];
}
}
}
}
return result;
}
@@ -312,49 +331,55 @@ NSString * const XLValidationStatusErrorKey = @"XLValidationStatusErrorKey";
{
NSMutableDictionary * result = [NSMutableDictionary dictionary];
for (XLFormSectionDescriptor * section in self.formSections) {
if (section.multivaluedTag.length > 0){
NSMutableArray * multiValuedValuesArray = [NSMutableArray new];
if (section.multivaluedTag.length > 0) {
NSMutableArray *multiValuedValuesArray = [NSMutableArray new];
for (XLFormRowDescriptor * row in section.formRows) {
if ([row.value valueData]){
if ([row.value valueData]) {
[multiValuedValuesArray addObject:[row.value valueData]];
}
}
[result setObject:multiValuedValuesArray forKey:section.multivaluedTag];
}
else{
else {
for (XLFormRowDescriptor * row in section.formRows) {
NSString * httpParameterKey = nil;
if ((httpParameterKey = [self httpParameterKeyForRow:row cell:[row cellForFormController:formViewController]])){
NSString *httpParameterKey = nil;
if ((httpParameterKey = [self httpParameterKeyForRow:row cell:[row cellForFormController:formViewController]])) {
id parameterValue = [row.value valueData] ?: [NSNull null];
[result setObject:parameterValue forKey:httpParameterKey];
}
}
}
}
return result;
}
-(NSString *)httpParameterKeyForRow:(XLFormRowDescriptor *)row cell:(UITableViewCell<XLFormDescriptorCell> *)descriptorCell
{
if ([descriptorCell respondsToSelector:@selector(formDescriptorHttpParameterName)]){
return [descriptorCell formDescriptorHttpParameterName];
NSString *result = nil;
if ([descriptorCell respondsToSelector:@selector(formDescriptorHttpParameterName)]) {
result = [descriptorCell formDescriptorHttpParameterName];
}
if (row.tag.length > 0){
return row.tag;
else if (row.tag.length > 0) {
result = row.tag;
}
return nil;
return result;
}
-(NSArray *)localValidationErrors:(XLFormViewController *)formViewController {
NSMutableArray * result = [NSMutableArray array];
for (XLFormSectionDescriptor * section in self.formSections) {
for (XLFormRowDescriptor * row in section.formRows) {
XLFormValidationStatus* status = [row doValidation];
-(NSArray *)localValidationErrors:(XLFormViewController *)formViewController
{
NSMutableArray *result = [NSMutableArray array];
for (XLFormSectionDescriptor *section in self.formSections) {
for (XLFormRowDescriptor *row in section.formRows) {
XLFormValidationStatus *status = [row doValidation];
if (status != nil && (![status isValid])) {
NSDictionary *userInfo = @{ NSLocalizedDescriptionKey: status.msg,
XLValidationStatusErrorKey: status };
NSError * error = [[NSError alloc] initWithDomain:XLFormErrorDomain code:XLFormErrorCodeGen userInfo:userInfo];
if (error){
NSError *error = [[NSError alloc] initWithDomain:XLFormErrorDomain code:XLFormErrorCodeGen userInfo:userInfo];
if (error) {
[result addObject:error];
}
}
@@ -367,11 +392,11 @@ NSString * const XLValidationStatusErrorKey = @"XLValidationStatusErrorKey";
- (void)setFirstResponder:(XLFormViewController *)formViewController
{
for (XLFormSectionDescriptor * formSection in self.formSections) {
for (XLFormRowDescriptor * row in formSection.formRows) {
UITableViewCell<XLFormDescriptorCell> * cell = [row cellForFormController:formViewController];
if ([cell formDescriptorCellCanBecomeFirstResponder]){
if ([cell formDescriptorCellBecomeFirstResponder]){
for (XLFormSectionDescriptor *formSection in self.formSections) {
for (XLFormRowDescriptor *row in formSection.formRows) {
UITableViewCell<XLFormDescriptorCell> *cell = [row cellForFormController:formViewController];
if ([cell formDescriptorCellCanBecomeFirstResponder]) {
if ([cell formDescriptorCellBecomeFirstResponder]) {
return;
}
}
@@ -382,18 +407,23 @@ NSString * const XLValidationStatusErrorKey = @"XLValidationStatusErrorKey";
#pragma mark - KVO
-(void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(NSDictionary *)change context:(void *)context
- (void)observeValueForKeyPath:(nullable NSString *)keyPath
ofObject:(nullable id)object
change:(nullable NSDictionary<NSKeyValueChangeKey, id> *)change
context:(nullable void *)context
{
if (!self.delegate) return;
if ([keyPath isEqualToString:@"formSections"]){
if ([[change objectForKey:NSKeyValueChangeKindKey] isEqualToNumber:@(NSKeyValueChangeInsertion)]){
NSIndexSet * indexSet = [change objectForKey:NSKeyValueChangeIndexesKey];
XLFormSectionDescriptor * section = [self.formSections objectAtIndex:indexSet.firstIndex];
if (!self.delegate) {
return;
}
else if ([keyPath isEqualToString:XLFormSectionsKey]) {
if ([[change objectForKey:NSKeyValueChangeKindKey] isEqualToNumber:@(NSKeyValueChangeInsertion)]) {
NSIndexSet *indexSet = [change objectForKey:NSKeyValueChangeIndexesKey];
XLFormSectionDescriptor *section = [self.formSections objectAtIndex:indexSet.firstIndex];
[self.delegate formSectionHasBeenAdded:section atIndex:indexSet.firstIndex];
}
else if ([[change objectForKey:NSKeyValueChangeKindKey] isEqualToNumber:@(NSKeyValueChangeRemoval)]){
NSIndexSet * indexSet = [change objectForKey:NSKeyValueChangeIndexesKey];
XLFormSectionDescriptor * removedSection = [[change objectForKey:NSKeyValueChangeOldKey] objectAtIndex:0];
else if ([[change objectForKey:NSKeyValueChangeKindKey] isEqualToNumber:@(NSKeyValueChangeRemoval)]) {
NSIndexSet *indexSet = [change objectForKey:NSKeyValueChangeIndexesKey];
XLFormSectionDescriptor *removedSection = [[change objectForKey:NSKeyValueChangeOldKey] objectAtIndex:0];
[self.delegate formSectionHasBeenRemoved:removedSection atIndex:indexSet.firstIndex];
}
}
@@ -401,10 +431,16 @@ NSString * const XLValidationStatusErrorKey = @"XLValidationStatusErrorKey";
-(void)dealloc
{
@try {
[self removeObserver:self forKeyPath:@"formSections"];
}
@catch (NSException * __unused exception) {}
[self removeObserver:self forKeyPath:XLFormSectionsKey];
[_formSections removeAllObjects];
_formSections = nil;
[_allSections removeAllObjects];
_allSections = nil;
[_allRowsByTag removeAllObjects];
_allRowsByTag = nil;
[_rowObservers removeAllObjects];
_rowObservers = nil;
}
#pragma mark - KVC
@@ -414,19 +450,23 @@ NSString * const XLValidationStatusErrorKey = @"XLValidationStatusErrorKey";
return self.formSections.count;
}
- (id)objectInFormSectionsAtIndex:(NSUInteger)index {
- (id)objectInFormSectionsAtIndex:(NSUInteger)index
{
return [self.formSections objectAtIndex:index];
}
- (NSArray *)formSectionsAtIndexes:(NSIndexSet *)indexes {
- (NSArray *)formSectionsAtIndexes:(NSIndexSet *)indexes
{
return [self.formSections objectsAtIndexes:indexes];
}
- (void)insertObject:(XLFormSectionDescriptor *)formSection inFormSectionsAtIndex:(NSUInteger)index {
- (void)insertObject:(XLFormSectionDescriptor *)formSection inFormSectionsAtIndex:(NSUInteger)index
{
[self.formSections insertObject:formSection atIndex:index];
}
- (void)removeObjectFromFormSectionsAtIndex:(NSUInteger)index {
- (void)removeObjectFromFormSectionsAtIndex:(NSUInteger)index
{
[self.formSections removeObjectAtIndex:index];
}
@@ -445,7 +485,8 @@ NSString * const XLValidationStatusErrorKey = @"XLValidationStatusErrorKey";
return [self.allSections objectsAtIndexes:indexes];
}
- (void)removeObjectFromAllSectionsAtIndex:(NSUInteger)index {
- (void)removeObjectFromAllSectionsAtIndex:(NSUInteger)index
{
XLFormSectionDescriptor* section = [self.allSections objectAtIndex:index];
[section.allRows enumerateObjectsUsingBlock:^(id obj, NSUInteger __unused idx, BOOL *stop) {
XLFormRowDescriptor * row = (id)obj;
@@ -456,7 +497,8 @@ NSString * const XLValidationStatusErrorKey = @"XLValidationStatusErrorKey";
[self.allSections removeObjectAtIndex:index];
}
- (void)insertObject:(XLFormSectionDescriptor *)section inAllSectionsAtIndex:(NSUInteger)index {
- (void)insertObject:(XLFormSectionDescriptor *)section inAllSectionsAtIndex:(NSUInteger)index
{
section.formDescriptor = self;
[self.allSections insertObject:section atIndex:index];
section.hidden = section.hidden;
@@ -466,24 +508,23 @@ NSString * const XLValidationStatusErrorKey = @"XLValidationStatusErrorKey";
row.hidden = row.hidden;
row.disabled = row.disabled;
}];
}
#pragma mark - EvaluateForm
-(void)forceEvaluate
{
for (XLFormSectionDescriptor* section in self.allSections){
for (XLFormRowDescriptor* row in section.allRows) {
for (XLFormSectionDescriptor *section in self.allSections) {
for (XLFormRowDescriptor *row in section.allRows) {
[self addRowToTagCollection:row];
}
}
for (XLFormSectionDescriptor* section in self.allSections){
for (XLFormRowDescriptor* row in section.allRows) {
for (XLFormSectionDescriptor *section in self.allSections) {
for (XLFormRowDescriptor *row in section.allRows) {
[row evaluateIsDisabled];
[row evaluateIsHidden];
}
[section evaluateIsHidden];
}
}
@@ -500,60 +541,65 @@ NSString * const XLValidationStatusErrorKey = @"XLValidationStatusErrorKey";
-(XLFormRowDescriptor *)nextRowDescriptorForRow:(XLFormRowDescriptor *)row
{
XLFormRowDescriptor *result = nil;
NSUInteger indexOfRow = [row.sectionDescriptor.formRows indexOfObject:row];
if (indexOfRow != NSNotFound){
if (indexOfRow + 1 < row.sectionDescriptor.formRows.count){
return [row.sectionDescriptor.formRows objectAtIndex:++indexOfRow];
if (indexOfRow != NSNotFound) {
if (indexOfRow + 1 < row.sectionDescriptor.formRows.count) {
result = [row.sectionDescriptor.formRows objectAtIndex:++indexOfRow];
}
else{
else {
NSUInteger sectionIndex = [self.formSections indexOfObject:row.sectionDescriptor];
NSUInteger numberOfSections = [self.formSections count];
if (sectionIndex != NSNotFound && sectionIndex < numberOfSections - 1){
if (sectionIndex != NSNotFound && sectionIndex < numberOfSections - 1) {
sectionIndex++;
XLFormSectionDescriptor * sectionDescriptor;
while ([[(sectionDescriptor = [row.sectionDescriptor.formDescriptor.formSections objectAtIndex:sectionIndex]) formRows] count] == 0 && sectionIndex < numberOfSections - 1){
XLFormSectionDescriptor *sectionDescriptor;
while ([[(sectionDescriptor = [row.sectionDescriptor.formDescriptor.formSections objectAtIndex:sectionIndex]) formRows] count] == 0 && sectionIndex < numberOfSections - 1) {
sectionIndex++;
}
return [sectionDescriptor.formRows firstObject];
result = [sectionDescriptor.formRows firstObject];
}
}
}
return nil;
return result;
}
-(XLFormRowDescriptor *)previousRowDescriptorForRow:(XLFormRowDescriptor *)row
{
XLFormRowDescriptor *result = nil;
NSUInteger indexOfRow = [row.sectionDescriptor.formRows indexOfObject:row];
if (indexOfRow != NSNotFound){
if (indexOfRow > 0 ){
return [row.sectionDescriptor.formRows objectAtIndex:--indexOfRow];
if (indexOfRow != NSNotFound) {
if (indexOfRow > 0 ) {
result = [row.sectionDescriptor.formRows objectAtIndex:--indexOfRow];
}
else{
else {
NSUInteger sectionIndex = [self.formSections indexOfObject:row.sectionDescriptor];
if (sectionIndex != NSNotFound && sectionIndex > 0){
if (sectionIndex != NSNotFound && sectionIndex > 0) {
sectionIndex--;
XLFormSectionDescriptor * sectionDescriptor;
while ([[(sectionDescriptor = [row.sectionDescriptor.formDescriptor.formSections objectAtIndex:sectionIndex]) formRows] count] == 0 && sectionIndex > 0 ){
while ([[(sectionDescriptor = [row.sectionDescriptor.formDescriptor.formSections objectAtIndex:sectionIndex]) formRows] count] == 0 && sectionIndex > 0 ) {
sectionIndex--;
}
return [sectionDescriptor.formRows lastObject];
result = [sectionDescriptor.formRows lastObject];
}
}
}
return nil;
return result;
}
-(void)addRowToTagCollection:(XLFormRowDescriptor*) rowDescriptor
-(void)addRowToTagCollection:(XLFormRowDescriptor *)rowDescriptor
{
if (rowDescriptor.tag) {
if (rowDescriptor.tag.length) {
self.allRowsByTag[rowDescriptor.tag] = rowDescriptor;
}
}
-(void)removeRowFromTagCollection:(XLFormRowDescriptor *)rowDescriptor
{
if (rowDescriptor.tag){
if (rowDescriptor.tag.length) {
[self.allRowsByTag removeObjectForKey:rowDescriptor.tag];
}
}
@@ -561,32 +607,36 @@ NSString * const XLValidationStatusErrorKey = @"XLValidationStatusErrorKey";
-(void)addObserversOfObject:(id)sectionOrRow predicateType:(XLPredicateType)predicateType
{
NSPredicate* predicate;
NSPredicate *predicate;
id descriptor;
switch(predicateType){
switch (predicateType) {
case XLPredicateTypeHidden:
if ([sectionOrRow isKindOfClass:([XLFormRowDescriptor class])]) {
descriptor = ((XLFormRowDescriptor*)sectionOrRow).tag;
predicate = ((XLFormRowDescriptor*)sectionOrRow).hidden;
descriptor = ((XLFormRowDescriptor *)sectionOrRow).tag;
predicate = ((XLFormRowDescriptor *)sectionOrRow).hidden;
}
else if ([sectionOrRow isKindOfClass:([XLFormSectionDescriptor class])]) {
descriptor = sectionOrRow;
predicate = ((XLFormSectionDescriptor*)sectionOrRow).hidden;
predicate = ((XLFormSectionDescriptor *)sectionOrRow).hidden;
}
break;
case XLPredicateTypeDisabled:
if ([sectionOrRow isKindOfClass:([XLFormRowDescriptor class])]) {
descriptor = ((XLFormRowDescriptor*)sectionOrRow).tag;
predicate = ((XLFormRowDescriptor*)sectionOrRow).disabled;
descriptor = ((XLFormRowDescriptor *)sectionOrRow).tag;
predicate = ((XLFormRowDescriptor *)sectionOrRow).disabled;
}
else {
return;
}
else return;
break;
}
NSMutableArray* tags = [predicate getPredicateVars];
for (NSString* tag in tags) {
NSString* auxTag = [tag formKeyForPredicateType:predicateType];
if (!self.rowObservers[auxTag]){
NSMutableArray *tags = [predicate getPredicateVars];
for (NSString *tag in tags) {
NSString *auxTag = [tag formKeyForPredicateType:predicateType];
if (!self.rowObservers[auxTag]) {
self.rowObservers[auxTag] = [NSMutableArray array];
}
if (![self.rowObservers[auxTag] containsObject:descriptor])
@@ -597,31 +647,32 @@ NSString * const XLValidationStatusErrorKey = @"XLValidationStatusErrorKey";
-(void)removeObserversOfObject:(id)sectionOrRow predicateType:(XLPredicateType)predicateType
{
NSPredicate* predicate;
NSPredicate *predicate;
id descriptor;
switch(predicateType){
switch(predicateType) {
case XLPredicateTypeHidden:
if ([sectionOrRow isKindOfClass:([XLFormRowDescriptor class])]) {
descriptor = ((XLFormRowDescriptor*)sectionOrRow).tag;
predicate = ((XLFormRowDescriptor*)sectionOrRow).hidden;
descriptor = ((XLFormRowDescriptor *)sectionOrRow).tag;
predicate = ((XLFormRowDescriptor *)sectionOrRow).hidden;
}
else if ([sectionOrRow isKindOfClass:([XLFormSectionDescriptor class])]) {
descriptor = sectionOrRow;
predicate = ((XLFormSectionDescriptor*)sectionOrRow).hidden;
predicate = ((XLFormSectionDescriptor *)sectionOrRow).hidden;
}
break;
case XLPredicateTypeDisabled:
if ([sectionOrRow isKindOfClass:([XLFormRowDescriptor class])]) {
descriptor = ((XLFormRowDescriptor*)sectionOrRow).tag;
predicate = ((XLFormRowDescriptor*)sectionOrRow).disabled;
descriptor = ((XLFormRowDescriptor *)sectionOrRow).tag;
predicate = ((XLFormRowDescriptor *)sectionOrRow).disabled;
}
break;
}
if (descriptor && [predicate isKindOfClass:[NSPredicate class] ]) {
NSMutableArray* tags = [predicate getPredicateVars];
for (NSString* tag in tags) {
NSString* auxTag = [tag formKeyForPredicateType:predicateType];
if (self.rowObservers[auxTag]){
if (descriptor && [predicate isKindOfClass:[NSPredicate class]]) {
NSMutableArray *tags = [predicate getPredicateVars];
for (NSString *tag in tags) {
NSString *auxTag = [tag formKeyForPredicateType:predicateType];
if (self.rowObservers[auxTag]) {
[self.rowObservers[auxTag] removeObject:descriptor];
}
}
@@ -29,7 +29,6 @@
@interface XLFormImageCell() <UIImagePickerControllerDelegate, UINavigationControllerDelegate>
{
UIPopoverController *popoverController;
UIImagePickerController *imagePickerController;
UIAlertController *alertController;
}
@@ -72,6 +71,7 @@
- (void)formDescriptorCellDidSelectedWithFormController:(XLFormViewController *)controller
{
__weak typeof(self) weak = self;
alertController = [UIAlertController alertControllerWithTitle: self.rowDescriptor.title
message: nil
preferredStyle: UIAlertControllerStyleActionSheet];
@@ -79,14 +79,14 @@
[alertController addAction:[UIAlertAction actionWithTitle: NSLocalizedString(@"Choose From Library", nil)
style: UIAlertActionStyleDefault
handler: ^(UIAlertAction * _Nonnull action) {
[self openImage:UIImagePickerControllerSourceTypePhotoLibrary];
[weak openImage:UIImagePickerControllerSourceTypePhotoLibrary];
}]];
if ([UIImagePickerController isSourceTypeAvailable:UIImagePickerControllerSourceTypeCamera]) {
[alertController addAction:[UIAlertAction actionWithTitle: NSLocalizedString(@"Take Photo", nil)
style: UIAlertActionStyleDefault
handler: ^(UIAlertAction * _Nonnull action) {
[self openImage:UIImagePickerControllerSourceTypeCamera];
[weak openImage:UIImagePickerControllerSourceTypeCamera];
}]];
}
@@ -101,7 +101,7 @@
}
dispatch_async(dispatch_get_main_queue(), ^{
[self.formViewController presentViewController:alertController animated: true completion: nil];
[weak.formViewController presentViewController:self->alertController animated: true completion: nil];
});
}
@@ -113,16 +113,15 @@
imagePickerController.sourceType = source;
if ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPad) {
popoverController = [[UIPopoverController alloc] initWithContentViewController:imagePickerController];
[popoverController presentPopoverFromRect: self.contentView.frame
inView: self.formViewController.view
permittedArrowDirections: UIPopoverArrowDirectionAny
animated: YES];
} else {
[self.formViewController presentViewController: imagePickerController
animated: YES
completion: nil];
imagePickerController.modalPresentationStyle = UIModalPresentationPopover;
imagePickerController.popoverPresentationController.sourceRect = self.contentView.frame;
imagePickerController.popoverPresentationController.sourceView = self.formViewController.view;
imagePickerController.popoverPresentationController.permittedArrowDirections = UIPopoverArrowDirectionAny;
}
[self.formViewController presentViewController: imagePickerController
animated: YES
completion: nil];
}
#pragma mark - UIImagePickerControllerDelegate
@@ -138,8 +137,8 @@
}
if ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPad) {
if (popoverController && popoverController.isPopoverVisible) {
[popoverController dismissPopoverAnimated: YES];
if (self.formViewController.presentedViewController && self.formViewController.presentedViewController.modalPresentationStyle == UIModalPresentationPopover) {
[self.formViewController dismissViewControllerAnimated:YES completion:nil];
}
} else {
[self.formViewController dismissViewControllerAnimated: YES completion: nil];
@@ -28,11 +28,6 @@
#import "NSObject+XLFormAdditions.h"
#import "XLFormLeftRightSelectorCell.h"
@interface XLFormLeftRightSelectorCell() <UIActionSheetDelegate>
@end
@implementation XLFormLeftRightSelectorCell
{
UITextField * _constraintTextField;
@@ -195,74 +190,24 @@
-(void)leftButtonPressed:(UIButton *)leftButton
{
#if __IPHONE_OS_VERSION_MAX_ALLOWED < 80000
UIActionSheet * actionSheet = [[UIActionSheet alloc] initWithTitle:self.rowDescriptor.selectorTitle
delegate:self cancelButtonTitle:nil
destructiveButtonTitle:nil
otherButtonTitles:nil];
UIAlertController * alertController = [UIAlertController alertControllerWithTitle:self.rowDescriptor.selectorTitle
message:nil
preferredStyle:UIAlertControllerStyleActionSheet];
[alertController addAction:[UIAlertAction actionWithTitle:NSLocalizedString(@"Cancel", nil)
style:UIAlertActionStyleCancel
handler:nil]];
__weak typeof(self) weak = self;
for (XLFormLeftRightSelectorOption * leftOption in self.rowDescriptor.selectorOptions) {
[actionSheet addButtonWithTitle:[leftOption.leftValue displayText]];
[alertController addAction:[UIAlertAction actionWithTitle:[leftOption.leftValue displayText]
style:UIAlertActionStyleDefault
handler:^(UIAlertAction *action) {
weak.rowDescriptor.value = [weak chooseNewRightValueFromOption:leftOption];
weak.rowDescriptor.leftRightSelectorLeftOptionSelected = [weak leftOptionForDescription:[leftOption.leftValue displayText]].leftValue;
[weak.formViewController updateFormRow:weak.rowDescriptor];
}]];
}
actionSheet.cancelButtonIndex = [actionSheet addButtonWithTitle:NSLocalizedString(@"Cancel", nil)];
actionSheet.tag = [self.rowDescriptor hash];
[actionSheet showInView:self.formViewController.view];
#else
if ([UIAlertController class]) {
UIAlertController * alertController = [UIAlertController alertControllerWithTitle:self.rowDescriptor.selectorTitle
message:nil
preferredStyle:UIAlertControllerStyleActionSheet];
[alertController addAction:[UIAlertAction actionWithTitle:NSLocalizedString(@"Cancel", nil)
style:UIAlertActionStyleCancel
handler:nil]];
__weak __typeof(self)weakSelf = self;
for (XLFormLeftRightSelectorOption * leftOption in self.rowDescriptor.selectorOptions) {
[alertController addAction:[UIAlertAction actionWithTitle:[leftOption.leftValue displayText]
style:UIAlertActionStyleDefault
handler:^(UIAlertAction *action) {
weakSelf.rowDescriptor.value = [self chooseNewRightValueFromOption:leftOption];
weakSelf.rowDescriptor.leftRightSelectorLeftOptionSelected = [self leftOptionForDescription:[leftOption.leftValue displayText]].leftValue;
[weakSelf.formViewController updateFormRow:weakSelf.rowDescriptor];
}]];
}
[self.formViewController presentViewController:alertController animated:YES completion:nil];
}
else{
UIActionSheet * actionSheet = [[UIActionSheet alloc] initWithTitle:self.rowDescriptor.selectorTitle
delegate:self cancelButtonTitle:nil
destructiveButtonTitle:nil
otherButtonTitles:nil];
for (XLFormLeftRightSelectorOption * leftOption in self.rowDescriptor.selectorOptions) {
[actionSheet addButtonWithTitle:[leftOption.leftValue displayText]];
}
actionSheet.cancelButtonIndex = [actionSheet addButtonWithTitle:NSLocalizedString(@"Cancel", nil)];
actionSheet.tag = [self.rowDescriptor hash];
[actionSheet showInView:self.formViewController.view];
}
#endif
[self.formViewController presentViewController:alertController animated:YES completion:nil];
}
#if __IPHONE_OS_VERSION_MIN_REQUIRED < 80000
#pragma mark - UIActionSheetDelegate
- (void)actionSheet:(UIActionSheet *)actionSheet clickedButtonAtIndex:(NSInteger)buttonIndex
{
if ([actionSheet cancelButtonIndex] != buttonIndex){
NSString * title = [actionSheet buttonTitleAtIndex:buttonIndex];
if (![self.rowDescriptor.leftRightSelectorLeftOptionSelected isEqual:[self leftOptionForDescription:title].leftValue]){
self.rowDescriptor.value = [self chooseNewRightValueFromOption:[self leftOptionForDescription:title]];
self.rowDescriptor.leftRightSelectorLeftOptionSelected = [self leftOptionForDescription:title].leftValue;
[self.formViewController updateFormRow:self.rowDescriptor];
}
}
}
#endif
@end
@@ -28,6 +28,9 @@
@interface XLFormOptionsObject : NSObject <XLFormOptionObject,NSCoding>
@property (nonatomic, copy) NSString * formDisplaytext;
@property (nonatomic, strong) id formValue;
+(XLFormOptionsObject *)formOptionsObjectWithValue:(id)value displayText:(NSString *)displayText;
+(XLFormOptionsObject *)formOptionsOptionForValue:(id)value fromOptions:(NSArray *)options;
+(XLFormOptionsObject *)formOptionsOptionForDisplayText:(NSString *)displayText fromOptions:(NSArray *)options;

Some files were not shown because too many files have changed in this diff Show More