histogram_macros.cc 520 B

123456789101112131415161718
  1. // Copyright 2019 The Chromium Authors. All rights reserved.
  2. // Use of this source code is governed by a BSD-style license that can be
  3. // found in the LICENSE file.
  4. #include "ash/metrics/histogram_macros.h"
  5. #include "ash/shell.h"
  6. #include "ash/wm/tablet_mode/tablet_mode_controller.h"
  7. namespace ash {
  8. bool InTabletMode() {
  9. TabletModeController* tablet_mode_controller =
  10. Shell::Get()->tablet_mode_controller();
  11. return tablet_mode_controller && tablet_mode_controller->InTabletMode();
  12. }
  13. } // namespace ash