Commit Graph

9 Commits

Author SHA1 Message Date
Josh Bodily c3c6681b9e Add Horizontal Text Alignment to UIEditBox (#16772)
* Add Horizontal Text Alignment to UIEditBox

* Fix compile error

* Fix win32 compile
2016-11-09 10:38:00 +08:00
mogemimi 98cc48bc62 Add missing override keyword 2016-07-13 15:03:53 +09:00
Xpol Wan 90456d29ba Fixes 1605 include path in 541 files
using the tools/coding-style/include-linter.py with -f options.
2016-03-20 21:53:44 +08:00
zilongshanren a93bc88d31 add Mac Editbox multiline support.
1. It also refactor the original logic and optimize the iOS EditBox implementation.
2016-02-04 14:21:07 +08:00
andyque 367a105a48 refactor EditBox iOS&Android implementation
Fixed issue: https://github.com/cocos2d/cocos2d-x/issues/13616#issuecomment-135742727
2015-08-31 18:36:27 +08:00
andyque a35e89225e Re-implement Editbox on Android platform.
This PR also fixed issue:

https://github.com/cocos2d/cocos2d-x/issues/9572

For the new EditBox:

1. Added a ResizeLayout for updating layout when soft keyboard is shown.
This is because some Android devices won't refresh the view and when
the view is panned, the native EditText will turn black. This is really
a hack, but it works for many Android devices from 2.3 to 5.0.

When keyboard is beginning to show, the ResizeLayout's doLayout
method will be called 24 frames per second. Once the keyboard is closed,
or the user begins to input, the doLayout method will be disabled.

2. EditText is working in a different UI thread, so all the data
are passed to GL thread via callbacks in UI thead.

3. It also overrides onKeyDown method in Cocos2dxEditBox.
When the EditText got the focus, users could press back key to exit
the game. This behavior is not allowed. We give developer the choice to
handle back key event manually.
2015-08-07 17:27:15 +08:00
Mazyad Alabduljaleel 9d5fdcb973 Support Color4B for editbox text 2015-03-02 15:31:59 +04:00
Ricardo Quesada 6f3ca63f00 Moved base/CCPlatform* -> platform/CCPlatform* 2014-09-09 17:17:07 -07:00
Ricardo Quesada 9082ca18c3 Platform fixed 2014-09-09 16:50:02 -07:00