ObjFW  Diff

Differences From Artifact [9d245e3712]:

To Artifact [c9756630f5]:


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
52
53



54
55
56

57
58
59

60
61
62

63
64
65

66
67
68
69

70
71
72

73
74
75
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
52
53

54

55
56
57

58
59
60

61
62
63

64
65
66
67

68
69
70

71
72
73
74







+
-
-
-
+
+
+
-


-
-
+
+

-
+

-
+

-
+
-
-
-
+
+

-
-
+
+
+
-

-
+


-
+


-
+


-
+



-
+


-
+



#  import <ObjFW/OFObject.h>
#  import <ObjFW/OFString.h>
# endif
#endif

OF_ASSUME_NONNULL_BEGIN

@class OFDictionary OF_GENERIC(KeyType, ObjectType);
@class HIDGameControllerAxis;
@class HIDGameControllerButton;
@class HIDGameControllerDirectionalPad;
@class OHGameControllerAxis;
@class OHGameControllerButton;
@class OHGameControllerDirectionalPad;
@class OFDictionary OF_GENERIC(KeyType, ObjectType);

/**
 * @class HIDGameControllerMapping \
 *	  HIDGameControllerMapping.h ObjFWHID/HIDGameControllerMapping.h
 * @class OHGameControllerMapping \
 *	  OHGameControllerMapping.h ObjFWHID/OHGameControllerMapping.h
 *
 * @brief A mapping for a @ref HIDGameController.
 * @brief A mapping for a @ref OHGameController.
 */
@interface HIDGameControllerMapping: OFObject
@interface OHGameControllerMapping: OFObject
{
	OFDictionary OF_GENERIC(OFString *, HIDGameControllerButton *)
	OFDictionary OF_GENERIC(OFString *, OHGameControllerButton *) *_buttons;
	    *_buttons;
	OFDictionary OF_GENERIC(OFString *, HIDGameControllerAxis *) *_axes;
	OFDictionary OF_GENERIC(OFString *, HIDGameControllerDirectionalPad *)
	OFDictionary OF_GENERIC(OFString *, OHGameControllerAxis *) *_axes;
	OFDictionary OF_GENERIC(OFString *, OHGameControllerDirectionalPad *)
	    *_directionalPads;
	OF_RESERVE_IVARS(HIDGameControllerMapping, 4)
}
	OF_RESERVE_IVARS(OHGameControllerMapping, 4)
}


/**
 * @brief A map of all button names to their @ref HIDGameControllerButton.
 * @brief A map of all button names to their @ref OHGameControllerButton.
 */
@property (readonly, nonatomic)
    OFDictionary OF_GENERIC(OFString *, HIDGameControllerButton *) *buttons;
    OFDictionary OF_GENERIC(OFString *, OHGameControllerButton *) *buttons;

/**
 * @brief A map of all axis names to their @ref HIDGameControllerAxis.
 * @brief A map of all axis names to their @ref OHGameControllerAxis.
 */
@property (readonly, nonatomic)
    OFDictionary OF_GENERIC(OFString *, HIDGameControllerAxis *) *axes;
    OFDictionary OF_GENERIC(OFString *, OHGameControllerAxis *) *axes;

/**
 * @brief A map of all directional pads to their
 *	  @ref HIDGameControllerDirectionalPad.
 *	  @ref OHGameControllerDirectionalPad.
 */
@property (readonly, nonatomic) OFDictionary OF_GENERIC(OFString *,
    HIDGameControllerDirectionalPad *) *directionalPads;
    OHGameControllerDirectionalPad *) *directionalPads;
@end

OF_ASSUME_NONNULL_END