|
|
Chromium Code Reviews|
Created:
3 years, 8 months ago by jif Modified:
3 years, 6 months ago CC:
chromium-reviews, jdonnelly+watch_chromium.org, ios-reviews+chrome_chromium.org, ios-reviews_chromium.org, pkl (ping after 24h if needed), noyau+watch_chromium.org, marq+watch_chromium.org, sdefresne+watch_chromium.org Target Ref:
refs/heads/master Project:
chromium Visibility:
Public. |
DescriptionFix text alignment issue in Chrome iOS' omnibox.
|preEditTextAlignment| was expecting |bestTextAlignment| to either return a right
alignment or a left alignment, but |bestTextAlignment| was sometimes
returning NSTextAlignmentNatural.
Swiping down the omnibox_popup_view triggered the bug because it results in a
call to |HideKeyboard|, which calls |resignFirstResponder|, which triggers a
relayout of the omnibox UITextField.
BUG=575181
Patch Set 1 #
Messages
Total messages: 16 (7 generated)
Description was changed from ========== Fix computation of alignment of text field in Chrome iOS' omnibox. BUG=575181 ========== to ========== Fix computation of alignment of text field in Chrome iOS' omnibox. |preEditTextAlignment| was expecting |bestTextAlignment| to either return a right alignment or a left alignment. It was sometimes returning NSTextAlignmentNatural. Swiping down the omnibox_popup_view triggered the bug because it results in a call to |HideKeyboard|, which calls |resignFirstResponder|, which triggers a relayout of the omnibox UITextField. BUG=575181 ==========
Description was changed from ========== Fix computation of alignment of text field in Chrome iOS' omnibox. |preEditTextAlignment| was expecting |bestTextAlignment| to either return a right alignment or a left alignment. It was sometimes returning NSTextAlignmentNatural. Swiping down the omnibox_popup_view triggered the bug because it results in a call to |HideKeyboard|, which calls |resignFirstResponder|, which triggers a relayout of the omnibox UITextField. BUG=575181 ========== to ========== Fix text alignement issue in Chrome iOS' omnibox. |preEditTextAlignment| was expecting |bestTextAlignment| to either return a right alignment or a left alignment. It was sometimes returning NSTextAlignmentNatural. Swiping down the omnibox_popup_view triggered the bug because it results in a call to |HideKeyboard|, which calls |resignFirstResponder|, which triggers a relayout of the omnibox UITextField. BUG=575181 ==========
Description was changed from ========== Fix text alignement issue in Chrome iOS' omnibox. |preEditTextAlignment| was expecting |bestTextAlignment| to either return a right alignment or a left alignment. It was sometimes returning NSTextAlignmentNatural. Swiping down the omnibox_popup_view triggered the bug because it results in a call to |HideKeyboard|, which calls |resignFirstResponder|, which triggers a relayout of the omnibox UITextField. BUG=575181 ========== to ========== Fix text alignement issue in Chrome iOS' omnibox. |preEditTextAlignment| was expecting |bestTextAlignment| to either return a right alignment or a left alignment, but actually |bestTextAlignment| was sometimes returning NSTextAlignmentNatural. Swiping down the omnibox_popup_view triggered the bug because it results in a call to |HideKeyboard|, which calls |resignFirstResponder|, which triggers a relayout of the omnibox UITextField. BUG=575181 ==========
Description was changed from ========== Fix text alignement issue in Chrome iOS' omnibox. |preEditTextAlignment| was expecting |bestTextAlignment| to either return a right alignment or a left alignment, but actually |bestTextAlignment| was sometimes returning NSTextAlignmentNatural. Swiping down the omnibox_popup_view triggered the bug because it results in a call to |HideKeyboard|, which calls |resignFirstResponder|, which triggers a relayout of the omnibox UITextField. BUG=575181 ========== to ========== Fix text alignement issue in Chrome iOS' omnibox. |preEditTextAlignment| was expecting |bestTextAlignment| to either return a right alignment or a left alignment, but |bestTextAlignment| was sometimes returning NSTextAlignmentNatural. Swiping down the omnibox_popup_view triggered the bug because it results in a call to |HideKeyboard|, which calls |resignFirstResponder|, which triggers a relayout of the omnibox UITextField. BUG=575181 ==========
jif@chromium.org changed reviewers: + rohitrao@chromium.org
ptal
Description was changed from ========== Fix text alignement issue in Chrome iOS' omnibox. |preEditTextAlignment| was expecting |bestTextAlignment| to either return a right alignment or a left alignment, but |bestTextAlignment| was sometimes returning NSTextAlignmentNatural. Swiping down the omnibox_popup_view triggered the bug because it results in a call to |HideKeyboard|, which calls |resignFirstResponder|, which triggers a relayout of the omnibox UITextField. BUG=575181 ========== to ========== Fix text alignment issue in Chrome iOS' omnibox. |preEditTextAlignment| was expecting |bestTextAlignment| to either return a right alignment or a left alignment, but |bestTextAlignment| was sometimes returning NSTextAlignmentNatural. Swiping down the omnibox_popup_view triggered the bug because it results in a call to |HideKeyboard|, which calls |resignFirstResponder|, which triggers a relayout of the omnibox UITextField. BUG=575181 ==========
rohitrao@chromium.org changed reviewers: + justincohen@chromium.org
Adding Justin, because I thought we intentionally used Natural here instead of forcing Left or Right. Justin, should the text alignment be fixed based on the device locale, or should it vary based on the content of the text? Is this a holdover from query-in-the-omnibox? Can we remove some of this logic, because now we're only showing URLs in the omnibox and never showing arbitrary text?
why is www.bbc.com right aligned when Natural?
On 2017/04/26 19:46:24, justincohen wrote: > why is http://www.bbc.com right aligned when Natural? because we do that comparison in omnibox_text_field_ios.mm: [self bestTextAlignment] == NSTextAlignmentLeft ...but [self bestTextAlignment] returns NSTextAlignmentRight or NSTextAlignmentNatural.
Oh, I misunderstood, this is about preEdit. I wonder if any of this alignment logic code is necessary anymore now that this landed: https://chromereviews.googleplex.com/471117013 Should everything just be left aligned when not editing (see bug for above CL)
On 2017/04/26 20:52:28, justincohen wrote: > Oh, I misunderstood, this is about preEdit. > > I wonder if any of this alignment logic code is necessary anymore now that this > landed: https://chromereviews.googleplex.com/471117013 > > Should everything just be left aligned when not editing (see bug for above CL) We only show URLs in the omnibox these days, so I agree that everything is always left-aligned (when not editing). I think?
Has this changelist been abandoned?
On 2017/06/13 04:36:37, Mark P wrote: > Has this changelist been abandoned? It shouldn't, as it's fixing a bug with iOS11, but I'm not getting a lot of traction. Transferring ownership of the bug to owner.
I think this CL can be abandoned in lieu of https://codereview.chromium.org/2937713002/ |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
