OSDN Git Service

DTXMania089リリースに際してのtag付け。
[dtxmania/dtxmania.git] / 110401(DTXMania089) / SlimDXc_Jun2010(VC++2008) / source / directinput / DeviceInstance.h
1 /*\r
2 * Copyright (c) 2007-2010 SlimDX Group\r
3\r
4 * Permission is hereby granted, free of charge, to any person obtaining a copy\r
5 * of this software and associated documentation files (the "Software"), to deal\r
6 * in the Software without restriction, including without limitation the rights\r
7 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\r
8 * copies of the Software, and to permit persons to whom the Software is\r
9 * furnished to do so, subject to the following conditions:\r
10\r
11 * The above copyright notice and this permission notice shall be included in\r
12 * all copies or substantial portions of the Software.\r
13\r
14 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\r
15 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\r
16 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\r
17 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\r
18 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\r
19 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\r
20 * THE SOFTWARE.\r
21 */\r
22 #pragma once\r
23 \r
24 #include "../multimedia/Enums.h"\r
25 #include "Enums.h"\r
26 \r
27 namespace SlimDX\r
28 {\r
29         namespace DirectInput\r
30         {\r
31                 /// <summary>\r
32                 /// Contains information about a device's identity.\r
33                 /// </summary>\r
34                 public ref class DeviceInstance\r
35                 {\r
36                 private:\r
37                         System::Guid instanceGuid;\r
38                         System::Guid productGuid;\r
39                         System::Guid ffDriverGuid;\r
40                         DeviceType type;\r
41                         int subType;\r
42                         System::String^ instanceName;\r
43                         System::String^ productName;\r
44                         SlimDX::Multimedia::UsageId usage;\r
45                         SlimDX::Multimedia::UsagePage usagePage;\r
46                         bool hid;\r
47 \r
48                 internal:\r
49                         DeviceInstance( const DIDEVICEINSTANCE &deviceInstance );\r
50 \r
51                 public:\r
52                         /// <summary>\r
53                         /// Gets the unique identifier for the instance of the device. Instance Guids are\r
54                         /// specific to a particular computer.\r
55                         /// </summary>\r
56                         property System::Guid InstanceGuid\r
57                         {\r
58                                 System::Guid get() { return instanceGuid; }\r
59                         }\r
60 \r
61                         /// <summary>\r
62                         /// Gets the unique identifier for the product. This identifier is established\r
63                         /// by the manufacturer of the device.\r
64                         /// </summary>\r
65                         property System::Guid ProductGuid\r
66                         {\r
67                                 System::Guid get() { return productGuid; }\r
68                         }\r
69 \r
70                         /// <summary>\r
71                         /// Gets the unique identifier for the driver being used for force-feedback. The\r
72                         /// driver's manufacturer establishes this identifier.\r
73                         /// </summary>\r
74                         property System::Guid ForceFeedbackDriverGuid\r
75                         {\r
76                                 System::Guid get() { return ffDriverGuid; }\r
77                         }\r
78 \r
79                         /// <summary>\r
80                         /// Gets the main device type specifier.\r
81                         /// </summary>\r
82                         property DeviceType Type\r
83                         {\r
84                                 DeviceType get() { return type; }\r
85                         }\r
86 \r
87                         /// <summary>\r
88                         /// Gets the secondary device type specifier.\r
89                         /// </summary>\r
90                         property int Subtype\r
91                         {\r
92                                 int get() { return subType; }\r
93                         }\r
94 \r
95                         /// <summary>\r
96                         /// Gets the friendly name for the instance.\r
97                         /// </summary>\r
98                         property System::String^ InstanceName\r
99                         {\r
100                                 System::String^ get() { return instanceName; }\r
101                         }\r
102 \r
103                         /// <summary>\r
104                         /// Gets the friendly name for the product.\r
105                         /// </summary>\r
106                         property System::String^ ProductName\r
107                         {\r
108                                 System::String^ get() { return productName; }\r
109                         }\r
110 \r
111                         /// <summary>\r
112                         /// If the device is a Human Interface Device, this member contains\r
113                         /// the HID usage code.\r
114                         /// </summary>\r
115                         property SlimDX::Multimedia::UsageId UsageId\r
116                         {\r
117                                 SlimDX::Multimedia::UsageId get() { return usage; }\r
118                         }\r
119 \r
120                         /// <summary>\r
121                         /// If the device is a Human Interface Device, this member contains\r
122                         /// the HID usage page code.\r
123                         /// </summary>\r
124                         property SlimDX::Multimedia::UsagePage UsagePage\r
125                         {\r
126                                 SlimDX::Multimedia::UsagePage get() { return usagePage; }\r
127                         }\r
128 \r
129                         /// <summary>\r
130                         /// Gets a value indicating whether the device is a Human Interface Device.\r
131                         /// </summary>\r
132                         property bool HumanInterfaceDevice\r
133                         {\r
134                                 bool get() { return hid; }\r
135                         }\r
136                 };\r
137         }\r
138 }