• Matthew Mourgos's avatar
    CrOS Settings: Only show shelf navigation setting in tablet mode · 689d984a
    Matthew Mourgos authored
    Currently the shelf navigation setting is supposed to be hidden on
    clamshell-only devices. PowerManagerClient is used to detect when tablet
    mode is unsupported but has not been accurately been detecting when
    this is the case.
    
    After discussion with UX, it has been decided to instead only show the
    setting when in tablet mode. This will ensure that clamshell-only users
    are not shown a setting intended for tablet mode users.
    
    This change removes usage of PowerManagerClient and instead uses
    ash::TabletMode::Get()->InTabletMode() to determine when the shelf
    navigation setting should be shown in a11y settings.
    ash::TabletModeObserver is also used so that when tablet mode is changed
    the setting is shown in tablet mode and hidden in clamshell mode.
    
    Bug: 1062213
    Change-Id: I01a7c3946c557dc65eebd69b52b63240aa39461e
    Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2197868Reviewed-by: default avatarToni Baržić <tbarzic@chromium.org>
    Reviewed-by: default avatarJames Cook <jamescook@chromium.org>
    Commit-Queue: Matthew Mourgos <mmourgos@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#768513}
    689d984a
accessibility_handler.cc 4.59 KB