Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(166)

Side by Side Diff: content/browser/accessibility/browser_accessibility_state_impl.h

Issue 785723002: Add new extension APIs related to animation policy. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 CONTENT_BROWSER_ACCESSIBILITY_BROWSER_ACCESSIBILITY_STATE_IMPL_H_ 5 #ifndef CONTENT_BROWSER_ACCESSIBILITY_BROWSER_ACCESSIBILITY_STATE_IMPL_H_
6 #define CONTENT_BROWSER_ACCESSIBILITY_BROWSER_ACCESSIBILITY_STATE_IMPL_H_ 6 #define CONTENT_BROWSER_ACCESSIBILITY_BROWSER_ACCESSIBILITY_STATE_IMPL_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 void EnableAccessibility() override; 43 void EnableAccessibility() override;
44 void DisableAccessibility() override; 44 void DisableAccessibility() override;
45 void ResetAccessibilityMode() override; 45 void ResetAccessibilityMode() override;
46 void OnScreenReaderDetected() override; 46 void OnScreenReaderDetected() override;
47 bool IsAccessibleBrowser() override; 47 bool IsAccessibleBrowser() override;
48 void AddHistogramCallback(base::Closure callback) override; 48 void AddHistogramCallback(base::Closure callback) override;
49 49
50 void UpdateHistogramsForTesting() override; 50 void UpdateHistogramsForTesting() override;
51 51
52 AccessibilityMode accessibility_mode() const { return accessibility_mode_; }; 52 AccessibilityMode accessibility_mode() const { return accessibility_mode_; };
53 const std::string& GetImageAnimationPolicy() const override;
54 void SetImageAnimationPolicy(const std::string& policy) override;
53 55
54 // Adds the given accessibility mode to the current accessibility mode bitmap. 56 // Adds the given accessibility mode to the current accessibility mode bitmap.
55 void AddAccessibilityMode(AccessibilityMode mode); 57 void AddAccessibilityMode(AccessibilityMode mode);
56 58
57 // Removes the given accessibility mode from the current accessibility mode 59 // Removes the given accessibility mode from the current accessibility mode
58 // bitmap, managing the bits that are shared with other modes such that a 60 // bitmap, managing the bits that are shared with other modes such that a
59 // bit will only be turned off when all modes that depend on it have been 61 // bit will only be turned off when all modes that depend on it have been
60 // removed. 62 // removed.
61 void RemoveAccessibilityMode(AccessibilityMode mode); 63 void RemoveAccessibilityMode(AccessibilityMode mode);
62 64
(...skipping 11 matching lines...) Expand all
74 // Leaky singleton, destructor generally won't be called. 76 // Leaky singleton, destructor generally won't be called.
75 ~BrowserAccessibilityStateImpl() override; 77 ~BrowserAccessibilityStateImpl() override;
76 78
77 void UpdatePlatformSpecificHistograms(); 79 void UpdatePlatformSpecificHistograms();
78 80
79 // Updates the accessibility mode of all web contents, including swapped out 81 // Updates the accessibility mode of all web contents, including swapped out
80 // ones. |add| specifies whether the mode should be added or removed. 82 // ones. |add| specifies whether the mode should be added or removed.
81 void AddOrRemoveFromAllWebContents(AccessibilityMode mode, bool add); 83 void AddOrRemoveFromAllWebContents(AccessibilityMode mode, bool add);
82 84
83 AccessibilityMode accessibility_mode_; 85 AccessibilityMode accessibility_mode_;
86 std::string animation_policy_;
84 87
85 std::vector<base::Closure> histogram_callbacks_; 88 std::vector<base::Closure> histogram_callbacks_;
86 89
87 DISALLOW_COPY_AND_ASSIGN(BrowserAccessibilityStateImpl); 90 DISALLOW_COPY_AND_ASSIGN(BrowserAccessibilityStateImpl);
88 }; 91 };
89 92
90 } // namespace content 93 } // namespace content
91 94
92 #endif // CONTENT_BROWSER_ACCESSIBILITY_BROWSER_ACCESSIBILITY_STATE_IMPL_H_ 95 #endif // CONTENT_BROWSER_ACCESSIBILITY_BROWSER_ACCESSIBILITY_STATE_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698