blob: 23451021ac3441e9093b739e4a8f0c2d58e802a4 (
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
42
43
44
45
46
47
48
49
50
51
|
/* clang-format off */
/* -*- Mode: Objective-C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* clang-format on */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#import <Foundation/Foundation.h>
#import <UIKit/UIAccessibility.h>
/* This protocol's primary use is so widget/cocoa can talk back to us
properly.
ChildView owns the topmost MUIRootAccessible, and needs to take care of
setting up that parent/child relationship.
This protocol is thus used to make sure it knows it's talking to us, and not
just some random |id|.
*/
@protocol MUIRootAccessibleProtocol <NSObject>
- (BOOL)hasRepresentedView;
- (nullable id)representedView;
// UIAccessibility
- (BOOL)isAccessibilityElement;
- (nullable NSString*)accessibilityLabel;
- (CGRect)accessibilityFrame;
- (nullable NSString*)accessibilityValue;
- (uint64_t)accessibilityTraits;
// UIAccessibilityContainer
- (NSInteger)accessibilityElementCount;
- (nullable id)accessibilityElementAtIndex:(NSInteger)index;
- (NSInteger)indexOfAccessibilityElement:(nonnull id)element;
- (nullable NSArray*)accessibilityElements;
- (UIAccessibilityContainerType)accessibilityContainerType;
@end
|