-
Notifications
You must be signed in to change notification settings - Fork 461
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
UITextField different textRect for editing and static text. #344 #345
base: master
Are you sure you want to change the base?
Conversation
…#344 UITextField+NUI.m fix override_editingRectForBounds method.
The code you submitted causes an infinite recursion loop. Please test your additions before submitting them as a pull request. Additionally, I am hesitant to accept code that doesn't have some basic tests written as well. |
Yes i am test it with my project, works as i expect. ``` javascript`
|
NUISwizzler class implements swizzle for editingRectForBounds of UITextField and other methods for all views.
|
If override_editingRectForBounds only calls the original method, should be editingRectForBounds simply excluded from swizzle? |
I think, reason that override_editingRectForBounds exist, is for future features. At current version i never met of usage it. |
Cool if it works. But in order for me to be able to accept this PR, I need it to some with some rudimentary tests to ensure that this feature doesn't break in the future. Please add in tests and I'll be happy to revisit this. |
Sorry, but i am can't write test for this case, this is because that
method is not called by XCTest.framework. I think by this reason NUI project does not have test case for "padding" property of UITextField, which swizzle textRectForBounds method.
Just run NUIDemo project with my pull request, and you see that it runs correctly. |
UITextField+NUI.m fix override_editingRectForBounds method.