summaryrefslogtreecommitdiffstats
path: root/ash/high_contrast/high_contrast_controller.h
blob: 10d0b7de8222f32e36dbd5881b363b7f339ff498 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#ifndef ASH_HIGH_CONTRAST_HIGH_CONTRAST_CONTROLLER_H_
#define ASH_HIGH_CONTRAST_HIGH_CONTRAST_CONTROLLER_H_

#include "ash/ash_export.h"
#include "ash/shell_observer.h"
#include "base/basictypes.h"

namespace aura {
class Window;
}

namespace ash {

class ASH_EXPORT HighContrastController : public ShellObserver {
 public:
  HighContrastController();
  virtual ~HighContrastController();

  // Set high contrast mode and update all available displays.
  void SetEnabled(bool enabled);

  // ShellObserver:
  virtual void OnRootWindowAdded(aura::Window* root_window) OVERRIDE;

 private:
  // Update high contrast mode on the passed display.
  void UpdateDisplay(aura::Window* root_window);

  // Indicates if the high contrast mode is enabled or disabled.
  bool enabled_;

  DISALLOW_COPY_AND_ASSIGN(HighContrastController);
};

}  // namespace ash

#endif  // ASH_HIGH_CONTRAST_HIGH_CONTRAST_CONTROLLER_H_