Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions XCDFormInputAccessoryView.podspec
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
Pod::Spec.new do |s|
s.name = "XCDFormInputAccessoryView"
s.version = "1.0.0-kfi"
s.summary = "Input accessory view with previous, next and done buttons."
s.homepage = "https://github.com/0xced/XCDFormInputAccessoryView"
s.license = { :type => 'MIT', :file => 'README.md' }
s.author = { "Cédric Luthi" => "cedric.luthi@gmail.com" }
s.source = { :git => "https://ricobeck@github.com/ricobeck/XCDFormInputAccessoryView.git", :branch => "develop" }
s.platform = :ios
s.source_files = 'XCDFormInputAccessoryView'
s.requires_arc = true
end
22 changes: 22 additions & 0 deletions XCDFormInputAccessoryView.podspec.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"name": "XCDFormInputAccessoryView",
"version": "1.0.0-kfi",
"summary": "Input accessory view with previous, next and done buttons.",
"homepage": "https://github.com/0xced/XCDFormInputAccessoryView",
"license": {
"type": "MIT",
"file": "README.md"
},
"authors": {
"Cédric Luthi": "cedric.luthi@gmail.com"
},
"source": {
"git": "https://ricobeck@github.com/ricobeck/XCDFormInputAccessoryView.git",
"branch": "develop"
},
"platforms": {
"ios": null
},
"source_files": "XCDFormInputAccessoryView",
"requires_arc": true
}
2 changes: 2 additions & 0 deletions XCDFormInputAccessoryView/XCDFormInputAccessoryView.m
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,8 @@ - (void) updateSegmentedControl
UISegmentedControl *segmentedControl = (UISegmentedControl *)[_toolbar.items[0] customView];
BOOL isFirst = [[responders objectAtIndex:0] isFirstResponder];
BOOL isLast = [[responders lastObject] isFirstResponder];

segmentedControl.selectedSegmentIndex = UISegmentedControlNoSegment;
[segmentedControl setEnabled:!isFirst forSegmentAtIndex:0];
[segmentedControl setEnabled:!isLast forSegmentAtIndex:1];
}
Expand Down