diff options
author | Brandon Maxwell <maxwelb@google.com> | 2015-11-12 12:31:51 -0800 |
---|---|---|
committer | Brandon Maxwell <maxwelb@google.com> | 2015-11-12 15:41:05 -0800 |
commit | f3b23ba40d6c6c60f7e01c84df69712d7ae9bae0 (patch) | |
tree | 36a032a1d52f51649f18d2797e5e6237f7128fdb | |
parent | d81cc6c64f3213f571c1f1e7a5c7e59b71491fb0 (diff) |
Modiying callLog context menu to force numbers LTR
Bug:25516713
Change-Id: I5b239afa81c7a5e8225f21d57161a5012ab5e421
-rw-r--r-- | src/com/android/dialer/calllog/CallLogListItemViewHolder.java | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/com/android/dialer/calllog/CallLogListItemViewHolder.java b/src/com/android/dialer/calllog/CallLogListItemViewHolder.java index cb4c1e401..63fbe298e 100644 --- a/src/com/android/dialer/calllog/CallLogListItemViewHolder.java +++ b/src/com/android/dialer/calllog/CallLogListItemViewHolder.java @@ -28,11 +28,12 @@ import android.support.v7.widget.CardView; import android.support.v7.widget.RecyclerView; import android.telecom.PhoneAccountHandle; import android.telephony.PhoneNumberUtils; +import android.text.BidiFormatter; +import android.text.TextDirectionHeuristics; import android.text.TextUtils; import android.view.ContextMenu; import android.view.MenuItem; import android.view.View; -import android.view.ViewGroup; import android.view.ViewStub; import android.widget.ImageView; import android.widget.QuickContactBadge; @@ -278,7 +279,8 @@ public final class CallLogListItemViewHolder extends RecyclerView.ViewHolder if (callType == CallLog.Calls.VOICEMAIL_TYPE) { menu.setHeaderTitle(mContext.getResources().getText(R.string.voicemail)); } else { - menu.setHeaderTitle(PhoneNumberUtils.createTtsSpannable(number)); + menu.setHeaderTitle(PhoneNumberUtils.createTtsSpannable( + BidiFormatter.getInstance().unicodeWrap(number, TextDirectionHeuristics.LTR))); } menu.add(ContextMenu.NONE, R.id.context_menu_copy_to_clipboard, ContextMenu.NONE, |