Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

- (void)didEndEditing gets called on tapping a token after 3rd row using multiple TITokenFieldViews #83

Open
ObjectiveB opened this issue Mar 5, 2014 · 8 comments
Assignees

Comments

@ObjectiveB
Copy link

I'm adding the TITokenFieldViews (2-3 of them) one below another to a parent view. This is to achieve multiple token views (To/CC/Bcc etc.). But I get a strange behavior. In any TITokenFieldView, I start typing and the tokens get added properly. I'm able to tap and select a particular token on the first couple of lines. But on tapping to select a token on the 4th or 5th line (and so on), the TITokenFieldView contracts to "N recipients". The - (void)didEndEditing method is somehow fired when I tap a token on the 4th line (or above). Why is this happening?

@ObjectiveB
Copy link
Author

If it helps, this issue happens even with a single TITokenFieldView. But I'm adding the TITokenFieldView as a subview to a webview.scrollView entity.

@thermogl
Copy link
Owner

thermogl commented Mar 5, 2014

I'm unable to replicate this with the example project, can you put together a project which demonstrates the issue for me?

@ObjectiveB
Copy link
Author

I was able to reproduce it. It happens when the view hierarchy is this: TITokenFieldView as subview of a parent UIView "ABC". The parent UIView is then added as a subview of the overall webView.scrollView entity.

I tried removing the UIView "ABC" and added the TITokenFieldView as a direct subview to webView.scrollView. Now it works as intended, doesn't collapse. Was able to replicate this in your example project as well using the same view hierarchy as described above. Try adding the TITokenFieldView as a subview to a UIView which is then a subview to a web view's scrollview.

@thermogl
Copy link
Owner

thermogl commented Mar 6, 2014

So it works if you don't use a view between the TITokenFieldView and the UIWebView scrollview?

@ObjectiveB
Copy link
Author

Yep. Works when there's no view in between, contracts on tapping tokens from line 3 or 4 onward when there's a view in between.

@thermogl
Copy link
Owner

thermogl commented Mar 6, 2014

And this view is just a standard UIView? No default property values have been changed (specifically to do with touch)?

@ObjectiveB
Copy link
Author

Yeah, a plain vanilla UIView, just alloc init-ed and a frame set. Nothing set or changed w.r.t touch events.

@thermogl
Copy link
Owner

thermogl commented Mar 6, 2014

Weird weird weird. I'll have a poke around soon

@thermogl thermogl self-assigned this Mar 6, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants