• Peter Kasting's avatar
    Add background tab colors and inactive images to the theme system. · 8c35e22c
    Peter Kasting authored
    These will eventually be used for three purposes:
    (1) To allow generating different background tab images from a common tint for
        the inactive and incognito cases, thus allowing background tabs that blend
        into the frame for custom themes.
    (2) To allow autogenerating the background tab colors from the background tab
        images, thus letting us autocalculate better tab text/separator/etc. colors.
    (3) To allow theme authors to customize/override this behavior more precisely.
    
    Reasons (1) and (2) dictated the design here; reason (3) is basically a free
    bonus.  I thought about not making these resources overrideable by theme
    authors, but there was some technical reason that turned out to not be easily
    feasible, and there seems little reason to prevent it.
    
    This also allows us to read THEME_TAB_BACKGROUND_INCOGNITO on Mac (Views).
    
    This shouldn't result in a visual change on its own.
    
    Bug: 862664
    Change-Id: Icc57f78fd526d68b83c692fbac669a7371bb38ff
    Reviewed-on: https://chromium-review.googlesource.com/1147869
    Commit-Queue: Peter Kasting <pkasting@chromium.org>
    Reviewed-by: default avatarMitsuru Oshima <oshima@chromium.org>
    Reviewed-by: default avatarEvan Stade <estade@chromium.org>
    Reviewed-by: default avatarAllen Bauer <kylixrd@chromium.org>
    Reviewed-by: default avatarBret Sepulveda <bsep@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#578790}
    8c35e22c
browser_theme_pack.cc 54.7 KB