Revert 268405 "Make sure that ScratchBuffer::Allocate() always r..."
[chromium-blink-merge.git] / content / browser / accessibility / browser_accessibility_mac.h
blobdc04484b67e97fefd1b38b10346e46f9a0397524
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
3 // found in the LICENSE file.
5 #ifndef CONTENT_BROWSER_ACCESSIBILITY_BROWSER_ACCESSIBILITY_MAC_H_
6 #define CONTENT_BROWSER_ACCESSIBILITY_BROWSER_ACCESSIBILITY_MAC_H_
8 #include <map>
9 #include <utility>
10 #include <vector>
12 #include "content/browser/accessibility/browser_accessibility.h"
14 @class BrowserAccessibilityCocoa;
16 namespace content {
18 class BrowserAccessibilityMac : public BrowserAccessibility {
19 public:
20 // BrowserAccessibility overrides.
21 virtual void NativeReleaseReference() OVERRIDE;
22 virtual bool IsNative() const OVERRIDE;
23 virtual void OnDataChanged() OVERRIDE;
25 // The BrowserAccessibilityCocoa associated with us.
26 BrowserAccessibilityCocoa* native_view() const {
27 return browser_accessibility_cocoa_;
30 private:
31 // This gives BrowserAccessibility::Create access to the class constructor.
32 friend class BrowserAccessibility;
34 BrowserAccessibilityMac();
36 // Allows access to the BrowserAccessibilityCocoa which wraps this.
37 // BrowserAccessibility.
38 // We own this object until our manager calls ReleaseReference;
39 // thereafter, the cocoa object owns us.
40 BrowserAccessibilityCocoa* browser_accessibility_cocoa_;
41 DISALLOW_COPY_AND_ASSIGN(BrowserAccessibilityMac);
44 } // namespace content
46 #endif // CONTENT_BROWSER_ACCESSIBILITY_BROWSER_ACCESSIBILITY_MAC_H_