OLD | NEW |
---|---|
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CHROME_BROWSER_CHROMEOS_ACCESSIBILITY_MAGNIFICATION_MANAGER_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_ACCESSIBILITY_MAGNIFICATION_MANAGER_H_ |
6 #define CHROME_BROWSER_CHROMEOS_ACCESSIBILITY_MAGNIFICATION_MANAGER_H_ | 6 #define CHROME_BROWSER_CHROMEOS_ACCESSIBILITY_MAGNIFICATION_MANAGER_H_ |
7 | 7 |
8 #include "chrome/browser/chromeos/accessibility/accessibility_util.h" | 8 #include "chrome/browser/chromeos/accessibility/accessibility_util.h" |
9 | 9 |
10 namespace chromeos { | 10 namespace chromeos { |
(...skipping 11 matching lines...) Expand all Loading... | |
22 public: | 22 public: |
23 // Creates an instance of MagnificationManager. This should be called once, | 23 // Creates an instance of MagnificationManager. This should be called once, |
24 // Returns the existing instance. If there is no instance, creates one. | 24 // Returns the existing instance. If there is no instance, creates one. |
25 // because only one instance should exist at the same time. | 25 // because only one instance should exist at the same time. |
26 static void Initialize(); | 26 static void Initialize(); |
27 // Deletes the existing instance of MagnificationManager. | 27 // Deletes the existing instance of MagnificationManager. |
28 static void Shutdown(); | 28 static void Shutdown(); |
29 // Returns the existing instance. If there is no instance, returns NULL. | 29 // Returns the existing instance. If there is no instance, returns NULL. |
30 static MagnificationManager* Get(); | 30 static MagnificationManager* Get(); |
31 | 31 |
32 // Returns if the screen magnifier is enabled. | |
33 virtual bool IsMagnifierEnabled() const = 0; | |
32 // Returns the current type of the screen magnifier. | 34 // Returns the current type of the screen magnifier. |
33 virtual ash::MagnifierType GetMagnifierType() = 0; | 35 virtual ash::MagnifierType GetMagnifierType() const = 0; |
34 // Changes the type of the screen magnifier. | 36 // Changes the type of the screen magnifier. |
35 virtual void SetMagnifier(ash::MagnifierType type) = 0; | 37 virtual void SetMagnifier(bool enabled, ash::MagnifierType type) = 0; |
Zachary Kuznia
2012/12/20 05:54:21
Please separate this into SetMagnifierEnabled and
yoshiki
2012/12/21 07:32:09
Done.
| |
36 | 38 |
37 // Saves the magnifier scale to the pref. | 39 // Saves the magnifier scale to the pref. |
38 virtual void SaveScreenMagnifierScale(double scale) = 0; | 40 virtual void SaveScreenMagnifierScale(double scale) = 0; |
39 // Loads the magnifier scale from the pref. | 41 // Loads the magnifier scale from the pref. |
40 virtual double GetSavedScreenMagnifierScale() = 0; | 42 virtual double GetSavedScreenMagnifierScale() const = 0; |
41 | 43 |
42 protected: | 44 protected: |
43 virtual ~MagnificationManager() {} | 45 virtual ~MagnificationManager() {} |
44 }; | 46 }; |
45 | 47 |
46 } // namespace chromeos | 48 } // namespace chromeos |
47 | 49 |
48 #endif // CHROME_BROWSER_CHROMEOS_ACCESSIBILITY_MAGNIFICATION_MANAGER_H_ | 50 #endif // CHROME_BROWSER_CHROMEOS_ACCESSIBILITY_MAGNIFICATION_MANAGER_H_ |
OLD | NEW |