This feature is currently used to enable dragging the start and end
selection handles of a TextView at the same time. Could be used for
other things later.
Deleted some dead code in ArrowKeyMovementMethod and CursorControllers.
Change-Id: I930accd97ca1ca1917aab8a807db2c950fc7b409
Merge commit '9aed300279db6953356aed5ef24a42291f5829cb' into gingerbread-plus-aosp
* commit '9aed300279db6953356aed5ef24a42291f5829cb':
Text selection anchors changed to use windows
Merge commit 'd9c80ab31ac3755141765e2c030bd1404ff0b050' into gingerbread-plus-aosp
* commit 'd9c80ab31ac3755141765e2c030bd1404ff0b050':
Fix for a memory leak in TextKeyListener.
Merge commit 'c4f628a1ba359926cf53ed7652d9abba6ea29123'
* commit 'c4f628a1ba359926cf53ed7652d9abba6ea29123':
Adds a time zone parameter to formatDateRange
Merge commit 'c0b4f6d30d962d75125628317b5f5ea622531dfe' into gingerbread-plus-aosp
* commit 'c0b4f6d30d962d75125628317b5f5ea622531dfe':
Adds a time zone parameter to formatDateRange
For a critical feature request in Calendar we need the ability
to format a date range in a time zone other than the local tz.
This adds a new method signature to formatDateRange to allow for
a tz to be specified and maintains the old behavior if the parameter
is not used. Also deprecates the FORMAT_UTC flag.
Change-Id: I16b3e939760ec86c954b51a318d01b7bbf86acc9
Merge commit '883bbb72284736b5601f9e96d1116969c51b75de' into gingerbread-plus-aosp
* commit '883bbb72284736b5601f9e96d1116969c51b75de':
Hide mCursorController field in ArrowKeyMovementMethod.
Merge commit 'f470ed8630e9e648727443b065b9f1c69fee34d6' into gingerbread-plus-aosp
* commit 'f470ed8630e9e648727443b065b9f1c69fee34d6':
Support surrogate pairs when layouting text
The current framework does not consider surrogate pairs
when getting the index of the character. This bug becomes
visible when creating the text including Emojis. For
example cursor breaks up when it moves around the Emojis.
Our proposed solution will consider the surrogate pairs
when calculating the index. It will fix not only the Emoji
case, but also the letters that use surrogate pairs.
Change-Id: I4983f2e4df933c8af9d5f0cc27df871e8e10fed4
Merge commit '2703a42d16af0e62da1bba02b6c935d98debf936' into gingerbread-plus-aosp
* commit '2703a42d16af0e62da1bba02b6c935d98debf936':
When an EditText gains focus by tapping, move the insertion point where tapped.
Merge commit '3e05a0beb2fad0b21558019d2adf6805da70e10e' into gingerbread-plus-aosp
* commit '3e05a0beb2fad0b21558019d2adf6805da70e10e':
Hysteresis effect in Text selection.
Vertical movement requires going over a given threshold to change line.
Makes it easier to move down without changing line, so that one can see the
cursor better. Also simplifies long line selection.
Change-Id: I791da500232c6e510af64c637ed994c5da9a4fea
Merge commit 'd018a0ce72124f668d859b19fe3e73f5637d3c7c' into gingerbread-plus-aosp
* commit 'd018a0ce72124f668d859b19fe3e73f5637d3c7c':
Text selection without trackball.
Backported from HC.
Squashed commit of the following:
commit af214a595c7a9fdd11a2dc384f7d4665abf751c0
Fixes in TextView's selection.
commit eb9fd59ebe6500a66c2003d46b5802299970ae8d
TextView with Selection Contextual Mode
commit 4c4c338ef355b369ce4b57d6c6fba7ee8f9dddf4
Cosmetic changes around TextView.
commit d4b4b054e87480d984ad18766f5e76553e3080d8
Double and one and a half tap removed from TextView.
commit 897c2847ba1fca8ef01eadadd1bc3de007af3ee5
Selection handlers in TextView
commit 832be74a5394649e28927484d9a86c6d53b430e7
New cursor controller in TextViews.
Change-Id: I01cc64736e2abea605317ee53907a1713617fc17
When the text ends with an empty line, the getSpans() call to retrieve
styles for it would also retrieve the styles of the preceding line.
Add a special case to detect and prevent this.
Change-Id: I888131cacce6bf45e68c53c931ebe8d58db0b7a9
ClipboardManager was in android.text(!!) so it needed to be moved
up to android.content to have access to the richer data types we
now need.
ClippedData is the data representation. Still needs a lot of
fleshing out to allow holding more than one data type at a time
and perhaps conversions between them. (MIME-oriented interrogation
and conversion will be done through ContentProvider, which needs
to grow an ability to report multiple MIME types and accept a
desired MIME type when a stream is being opened.)
Change-Id: Ifa51bedcd084a677813b255d171804e8496b0cb5
Text selection is now triggered by a long press. This behavior should be shared
across applications and is already implemented in the browser.
New UI guidelines say that double tap should be used for zooming only.
Change-Id: I9fae692cf3f6e565350f666fa3d5a86884439349
Editable TextView now display a cursor controller under the insertion
point so that it can be precisely moved.
Change-Id: Ia2e6ddc57d249647ff6683e10e4226db3df27223
There was an issue in the Time.toMillis example.
Also removed some whitespaces so the file
applies to the Android coding Styleguide
Change-Id: Ic1383e506b30ff181c6e14a12f675b52e5c8ccbc
When auto-correction is used, the text is modified to underline the corrected word, which
modifies mGapLength and mGapStart. The mGapLength shift was not properly handled in getTextRunCursor.
Bug 2807595
Change-Id: I43ee216f6780270e452aa9199ffd892fe7ab6c3f
Merge commit '8b0d5bc3f858ae2b737ac654fa05c439344ad631'
* commit '8b0d5bc3f858ae2b737ac654fa05c439344ad631':
Fixing counting the number of days in call log screen.
Recent refactoring for bidi introduced an index shift in the getOffsetBeforeAfter
method. This problem appears for multi-line text input only, when the text line
mStart index is not 0.
As a result, moving the cursor using the trackball in a multi-line EditText crashes.
Change-Id: I1f121f0f9272ef7d338399f369ba6d77e1ca71c5
Add internal API (getTextRunAdvances) to Paint, use when measuring.
Add internal API (getTextRunCursor) to Paint, use when determining
valid cursor positions.
Remove java-level shaping code. Remove 'prep' code in TextLine
(except for replacement text) since shaping now is done on the fly as
needed in native.
Provide explicit shaping context bounds to internal text measuring,
cursor movement, and rendering APIs.
Update for to changes in external API in ushape.h.
Change-Id: I146958b624802ce8553125e5c3c6c03031bc9608
Also remove unused debugging code that depends on junit.
Remove trailing whitespace in changed code.
Change-Id: Ie02d1b8220c599a672ee6e91af0fba634e0f620c