-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Adds the ability to show/hide input bar. Closes #203. Closes #229 #230
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This logic is not needed anymore, duration would always be 0.25
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well, this is to avoid calling the logic in. UIView animation block if the textInputBat should be hidden without animation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, my bad. You're right!
I'll fix it in this branch.
|
@dzenbot Thanks for the quick response, I made a comment and already pulled the changes. Would you like me to update that line of code in my branch? |
|
@dzenbot This branch is broken, the bar disappears as soon as textfield becomes first response. |
|
Would appreciate more context about the issue you're facing. |
|
I noticed that you have a subview above your cells. Is that a section header view? Or a custom subview? Can you repro on the sample project? |
|
That's just a UIView added on top of the main tableView. I'll update to that branch again sometimes today or tomorrow, and will report back. Thanks |
|
Investigated this, and it seem like the issue is not related to this branch. This issue was introduced in 1.6. textview becomes first responder but the toolbar doesn't appear. It looks like it's hidden behind another view, because as I'm scrolling down and dismissing the keyboard interactively I can see parts of the toolbar animating down along with the keyboard Here is the viewHierarchy when the toolbar is hidden: |
|
Maybe the SLKInputAccessoryView is covering the input bar? |
- Dismiss the keyboard and the auto-completion view right after hiding the textInputBar - Fixes cases where hiding the textInputBar wouldn't be possible when the keyboard was up - Avoids hidding the textInputBar with alpha, instead fixed some auto-layout constraints so the textView would follow the dismissal animation
…nt animation duration anymore.
|
So far, this branch behaves great. I haven't found any apparent bugs. The one about auto-rotation seems fixed now. @aryaxt Since the issue you're experiencing isn't related to this branch, let's open it in a new issue. I haven't been able to repro so far tho. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I like this block-based approach to handle the case with and without animations. Much cleaner than calling a separate method or duplicating the code.
|
Awesome work guys! |



@aryaxt: I've made some improvements and refactorings to your original PR in #229:
hideInputBar:animated:tosetTextInputbarHidden:animated:Known bugs:
Please try pulling this branch. Thanks for this great improvement!