Skip to content

Commit 3e0ddf5

Browse files
committed
Prevent autocapitalisation of search bar input.
1 parent 96ed130 commit 3e0ddf5

File tree

2 files changed

+3
-8
lines changed

2 files changed

+3
-8
lines changed

Swift Push/Info.plist

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
<key>CFBundleSignature</key>
2020
<string>????</string>
2121
<key>CFBundleVersion</key>
22-
<string>391</string>
22+
<string>393</string>
2323
<key>LSRequiresIPhoneOS</key>
2424
<true/>
2525
<key>UIBackgroundModes</key>

Swift Push/ViewController.swift

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -42,12 +42,6 @@ class ViewController: UIViewController, UITableViewDataSource, UITableViewDelega
4242
print("\(fetchError), \(fetchError.userInfo)")
4343
}
4444

45-
// let bounds = self.navigationController?.navigationBar.bounds as CGRect!
46-
// let visualEffectView = UIVisualEffectView (effect: UIBlurEffect (style: .Light)) as UIVisualEffectView
47-
// visualEffectView.frame = bounds
48-
// visualEffectView.autoresizingMask = .FlexibleHeight | .FlexibleWidth
49-
// self.navigationController?.navigationBar.addSubview(visualEffectView)
50-
5145
self.navigationController?.navigationBar.barTintColor = UIColor.lightGrayColor()
5246
self.navigationController?.navigationBar.translucent = true
5347

@@ -56,6 +50,7 @@ class ViewController: UIViewController, UITableViewDataSource, UITableViewDelega
5650
controller.searchResultsUpdater = self
5751
controller.dimsBackgroundDuringPresentation = false
5852
controller.hidesNavigationBarDuringPresentation = false
53+
controller.searchBar.autocapitalizationType = .None
5954
controller.searchBar.sizeToFit()
6055

6156
self.tableView.tableHeaderView = controller.searchBar
@@ -98,7 +93,7 @@ class ViewController: UIViewController, UITableViewDataSource, UITableViewDelega
9893

9994
func configureCell(cell: UITableViewCell, atIndexPath indexPath: NSIndexPath) {
10095
// Fetch Record
101-
print ("configureCell \(indexPath)")
96+
// print ("configureCell \(indexPath)")
10297
let record = fetchedResultsController!.objectAtIndexPath(indexPath)
10398

10499
cell.textLabel!.numberOfLines = 0

0 commit comments

Comments
 (0)