• Tommy C. Li's avatar
    Omnibox UI Refresh: Make "invisible focus" apperance more consistent · 26c6253c
    Tommy C. Li authored
    On the New Tab Page, when the user clicks the fake Google search box,
    i.e. the "fakebox", we give the Omnibox "invisible focus".
    
    This is a unique state where we set the Omnibox is focused and
    capturing key events, but the caret is invisible.
    
    In the past, the caret being invisible was sufficient for the Omnibox
    to be "invisibly" focused.
    
    In MD Refresh, however, we have three new focus indicators:
     1. Focus ring
     2. Placeholder text
     3. Background color change
    
    This CL updates all three of the above visual indicators for the
    Omnibox to be keyed on the invisible-focus state rather than the
    ordinary focus state.
    
    This solves the flicker present in the below bug and actually follows
    the concept of invisible-focus correctly.
    
    The concept of invisible-focus is kind of evil, and long term, we would
    like to get rid of it -- but this is a short term fix for MD Refresh.
    
    Bug: 859826
    Change-Id: I2e0ede93e69485745bbf119a3f366b0dbfa197ab
    Reviewed-on: https://chromium-review.googlesource.com/1144211
    Commit-Queue: Tommy Li <tommycli@chromium.org>
    Reviewed-by: default avatarMichael Wasserman <msw@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#576752}
    26c6253c
textfield.h 24.5 KB