1 // Licensed under the Apache License, Version 2.0
2 // <LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
3 // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your option.
4 // All files in the project carrying such notice may not be copied, modified, or distributed
5 // except according to those terms.
6 //! Mappings for the contents of PortableDevice.h
7 use shared::basetsd::ULONG_PTR;
8 use shared::wtypes::PROPERTYKEY;
9 DEFINE_GUID!{GUID_DEVINTERFACE_WPD,
10     0x6AC27878, 0xA6FA, 0x4155, 0xBA, 0x85, 0xF9, 0x8F, 0x49, 0x1D, 0x4F, 0x33}
11 DEFINE_GUID!{GUID_DEVINTERFACE_WPD_PRIVATE,
12     0xBA0C718F, 0x4DED, 0x49B7, 0xBD, 0xD3, 0xFA, 0xBE, 0x28, 0x66, 0x12, 0x11}
13 DEFINE_GUID!{GUID_DEVINTERFACE_WPD_SERVICE,
14     0x9EF44F80, 0x3D64, 0x4246, 0xA6, 0xAA, 0x20, 0x6F, 0x32, 0x8D, 0x1E, 0xDC}
15 //51
16 pub const WPD_DEVICE_OBJECT_ID: &'static str = "DEVICE";
17 pub const WMDRMDEVICEAPP_USE_WPD_DEVICE_PTR: ULONG_PTR = -1isize as ULONG_PTR;
18 pub const PORTABLE_DEVICE_TYPE: &'static str = "PortableDeviceType";
19 pub const PORTABLE_DEVICE_ICON: &'static str = "Icons";
20 pub const PORTABLE_DEVICE_NAMESPACE_TIMEOUT: &'static str = "PortableDeviceNameSpaceTimeout";
21 pub const PORTABLE_DEVICE_NAMESPACE_EXCLUDE_FROM_SHELL: &'static str
22     = "PortableDeviceNameSpaceExcludeFromShell";
23 pub const PORTABLE_DEVICE_NAMESPACE_THUMBNAIL_CONTENT_TYPES: &'static str
24     = "PortableDeviceNameSpaceThumbnailContentTypes";
25 pub const PORTABLE_DEVICE_IS_MASS_STORAGE: &'static str = "PortableDeviceIsMassStorage";
26 pub const PORTABLE_DEVICE_DRM_SCHEME_WMDRM10_PD: &'static str = "WMDRM10-PD";
27 pub const PORTABLE_DEVICE_DRM_SCHEME_PDDRM: &'static str = "PDDRM";
28 //101
29 ENUM!{enum WPD_DEVICE_TYPES {
30     WPD_DEVICE_TYPE_GENERIC = 0,
31     WPD_DEVICE_TYPE_CAMERA = 1,
32     WPD_DEVICE_TYPE_MEDIA_PLAYER = 2,
33     WPD_DEVICE_TYPE_PHONE = 3,
34     WPD_DEVICE_TYPE_VIDEO = 4,
35     WPD_DEVICE_TYPE_PERSONAL_INFORMATION_MANAGER = 5,
36     WPD_DEVICE_TYPE_AUDIO_RECORDER = 6,
37 }}
38 //133
39 ENUM!{enum WPD_DEVICE_TRANSPORTS {
40     WPD_DEVICE_TRANSPORT_UNSPECIFIED = 0,
41     WPD_DEVICE_TRANSPORT_USB = 1,
42     WPD_DEVICE_TRANSPORT_IP = 2,
43     WPD_DEVICE_TRANSPORT_BLUETOOTH = 3,
44 }}
45 //175
46 ENUM!{enum WPD_POWER_SOURCES {
47     WPD_POWER_SOURCE_BATTERY = 0,
48     WPD_POWER_SOURCE_EXTERNAL = 1,
49 }}
50 //696
51 DEFINE_GUID!{WPD_FUNCTIONAL_OBJECT_PROPERTIES_V1,
52     0x8F052D93, 0xABCA, 0x4FC5, 0xA5, 0xAC, 0xB0, 0x1D, 0xF4, 0xDB, 0xE5, 0x98}
53 DEFINE_PROPERTYKEY!{WPD_FUNCTIONAL_OBJECT_CATEGORY,
54     0x8F052D93, 0xABCA, 0x4FC5, 0xA5, 0xAC, 0xB0, 0x1D, 0xF4, 0xDB, 0xE5, 0x98, 2}
55 //1140
56 DEFINE_GUID!{WPD_DEVICE_PROPERTIES_V1,
57     0x26D4979A, 0xE643, 0x4626, 0x9E, 0x2B, 0x73, 0x6D, 0xC0, 0xC9, 0x2F, 0xDC}
58 DEFINE_PROPERTYKEY!{WPD_DEVICE_SYNC_PARTNER,
59     0x26D4979A, 0xE643, 0x4626, 0x9E, 0x2B, 0x73, 0x6D, 0xC0, 0xC9, 0x2F, 0xDC, 2}
60 DEFINE_PROPERTYKEY!{WPD_DEVICE_FIRMWARE_VERSION,
61     0x26D4979A, 0xE643, 0x4626, 0x9E, 0x2B, 0x73, 0x6D, 0xC0, 0xC9, 0x2F, 0xDC, 3}
62 DEFINE_PROPERTYKEY!{WPD_DEVICE_POWER_LEVEL,
63     0x26D4979A, 0xE643, 0x4626, 0x9E, 0x2B, 0x73, 0x6D, 0xC0, 0xC9, 0x2F, 0xDC, 4}
64 DEFINE_PROPERTYKEY!{WPD_DEVICE_POWER_SOURCE,
65     0x26D4979A, 0xE643, 0x4626, 0x9E, 0x2B, 0x73, 0x6D, 0xC0, 0xC9, 0x2F, 0xDC, 5}
66 DEFINE_PROPERTYKEY!{WPD_DEVICE_PROTOCOL,
67     0x26D4979A, 0xE643, 0x4626, 0x9E, 0x2B, 0x73, 0x6D, 0xC0, 0xC9, 0x2F, 0xDC, 6}
68 DEFINE_PROPERTYKEY!{WPD_DEVICE_MANUFACTURER,
69     0x26D4979A, 0xE643, 0x4626, 0x9E, 0x2B, 0x73, 0x6D, 0xC0, 0xC9, 0x2F, 0xDC, 7}
70 DEFINE_PROPERTYKEY!{WPD_DEVICE_MODEL,
71     0x26D4979A, 0xE643, 0x4626, 0x9E, 0x2B, 0x73, 0x6D, 0xC0, 0xC9, 0x2F, 0xDC, 8}
72 DEFINE_PROPERTYKEY!{WPD_DEVICE_SERIAL_NUMBER,
73     0x26D4979A, 0xE643, 0x4626, 0x9E, 0x2B, 0x73, 0x6D, 0xC0, 0xC9, 0x2F, 0xDC, 9}
74 DEFINE_PROPERTYKEY!{WPD_DEVICE_SUPPORTS_NON_CONSUMABLE,
75     0x26D4979A, 0xE643, 0x4626, 0x9E, 0x2B, 0x73, 0x6D, 0xC0, 0xC9, 0x2F, 0xDC, 10}
76 DEFINE_PROPERTYKEY!{WPD_DEVICE_DATETIME,
77     0x26D4979A, 0xE643, 0x4626, 0x9E, 0x2B, 0x73, 0x6D, 0xC0, 0xC9, 0x2F, 0xDC, 11}
78 DEFINE_PROPERTYKEY!{WPD_DEVICE_FRIENDLY_NAME,
79     0x26D4979A, 0xE643, 0x4626, 0x9E, 0x2B, 0x73, 0x6D, 0xC0, 0xC9, 0x2F, 0xDC, 12}
80 DEFINE_PROPERTYKEY!{WPD_DEVICE_SUPPORTED_DRM_SCHEMES,
81     0x26D4979A, 0xE643, 0x4626, 0x9E, 0x2B, 0x73, 0x6D, 0xC0, 0xC9, 0x2F, 0xDC, 13}
82 DEFINE_PROPERTYKEY!{WPD_DEVICE_SUPPORTED_FORMATS_ARE_ORDERED,
83     0x26D4979A, 0xE643, 0x4626, 0x9E, 0x2B, 0x73, 0x6D, 0xC0, 0xC9, 0x2F, 0xDC, 14}
84 DEFINE_PROPERTYKEY!{WPD_DEVICE_TYPE,
85     0x26D4979A, 0xE643, 0x4626, 0x9E, 0x2B, 0x73, 0x6D, 0xC0, 0xC9, 0x2F, 0xDC, 15}
86 DEFINE_PROPERTYKEY!{WPD_DEVICE_NETWORK_IDENTIFIER,
87     0x26D4979A, 0xE643, 0x4626, 0x9E, 0x2B, 0x73, 0x6D, 0xC0, 0xC9, 0x2F, 0xDC, 16}
88 DEFINE_GUID!{WPD_DEVICE_PROPERTIES_V2,
89     0x463DD662, 0x7FC4, 0x4291, 0x91, 0x1C, 0x7F, 0x4C, 0x9C, 0xCA, 0x97, 0x99}
90 DEFINE_PROPERTYKEY!{WPD_DEVICE_FUNCTIONAL_UNIQUE_ID,
91     0x463DD662, 0x7FC4, 0x4291, 0x91, 0x1C, 0x7F, 0x4C, 0x9C, 0xCA, 0x97, 0x99, 2}
92 DEFINE_PROPERTYKEY!{WPD_DEVICE_MODEL_UNIQUE_ID,
93     0x463DD662, 0x7FC4, 0x4291, 0x91, 0x1C, 0x7F, 0x4C, 0x9C, 0xCA, 0x97, 0x99, 3}
94 DEFINE_PROPERTYKEY!{WPD_DEVICE_TRANSPORT,
95     0x463DD662, 0x7FC4, 0x4291, 0x91, 0x1C, 0x7F, 0x4C, 0x9C, 0xCA, 0x97, 0x99, 4}
96 DEFINE_PROPERTYKEY!{WPD_DEVICE_USE_DEVICE_STAGE,
97     0x463DD662, 0x7FC4, 0x4291, 0x91, 0x1C, 0x7F, 0x4C, 0x9C, 0xCA, 0x97, 0x99, 5}
98 DEFINE_GUID!{WPD_DEVICE_PROPERTIES_V3,
99     0x6C2B878C, 0xC2EC, 0x490D, 0xB4, 0x25, 0xD7, 0xA7, 0x5E, 0x23, 0xE5, 0xED}
100 DEFINE_PROPERTYKEY!{WPD_DEVICE_EDP_IDENTITY,
101     0x6C2B878C, 0xC2EC, 0x490D, 0xB4, 0x25, 0xD7, 0xA7, 0x5E, 0x23, 0xE5, 0xED, 1}
102 //1488
103 DEFINE_PROPERTYKEY!{WPD_PROPERTY_COMMON_COMMAND_CATEGORY,
104     0xF0422A9C, 0x5DC8, 0x4440, 0xB5, 0xBD, 0x5D, 0xF2, 0x88, 0x35, 0x65, 0x8A, 1001}
105 DEFINE_PROPERTYKEY!{WPD_PROPERTY_COMMON_COMMAND_ID,
106     0xF0422A9C, 0x5DC8, 0x4440, 0xB5, 0xBD, 0x5D, 0xF2, 0x88, 0x35, 0x65, 0x8A, 1002}
107 DEFINE_PROPERTYKEY!{WPD_PROPERTY_COMMON_HRESULT,
108     0xF0422A9C, 0x5DC8, 0x4440, 0xB5, 0xBD, 0x5D, 0xF2, 0x88, 0x35, 0x65, 0x8A, 1003}
109 DEFINE_PROPERTYKEY!{WPD_PROPERTY_COMMON_DRIVER_ERROR_CODE,
110     0xF0422A9C, 0x5DC8, 0x4440, 0xB5, 0xBD, 0x5D, 0xF2, 0x88, 0x35, 0x65, 0x8A, 1004}
111 DEFINE_PROPERTYKEY!{WPD_PROPERTY_COMMON_COMMAND_TARGET,
112     0xF0422A9C, 0x5DC8, 0x4440, 0xB5, 0xBD, 0x5D, 0xF2, 0x88, 0x35, 0x65, 0x8A, 1006}
113 DEFINE_PROPERTYKEY!{WPD_PROPERTY_COMMON_PERSISTENT_UNIQUE_IDS,
114     0xF0422A9C, 0x5DC8, 0x4440, 0xB5, 0xBD, 0x5D, 0xF2, 0x88, 0x35, 0x65, 0x8A, 1007}
115 DEFINE_PROPERTYKEY!{WPD_PROPERTY_COMMON_OBJECT_IDS,
116     0xF0422A9C, 0x5DC8, 0x4440, 0xB5, 0xBD, 0x5D, 0xF2, 0x88, 0x35, 0x65, 0x8A, 1008}
117 DEFINE_PROPERTYKEY!{WPD_PROPERTY_COMMON_CLIENT_INFORMATION,
118     0xF0422A9C, 0x5DC8, 0x4440, 0xB5, 0xBD, 0x5D, 0xF2, 0x88, 0x35, 0x65, 0x8A, 1009}
119 DEFINE_PROPERTYKEY!{WPD_PROPERTY_COMMON_CLIENT_INFORMATION_CONTEXT,
120     0xF0422A9C, 0x5DC8, 0x4440, 0xB5, 0xBD, 0x5D, 0xF2, 0x88, 0x35, 0x65, 0x8A, 1010}
121 DEFINE_PROPERTYKEY!{WPD_PROPERTY_COMMON_ACTIVITY_ID,
122     0xF0422A9C, 0x5DC8, 0x4440, 0xB5, 0xBD, 0x5D, 0xF2, 0x88, 0x35, 0x65, 0x8A, 1011}
123 DEFINE_PROPERTYKEY!{WPD_OPTION_VALID_OBJECT_IDS,
124     0xF0422A9C, 0x5DC8, 0x4440, 0xB5, 0xBD, 0x5D, 0xF2, 0x88, 0x35, 0x65, 0x8A, 5001}
125 //3440
126 DEFINE_PROPERTYKEY!{WPD_OBJECT_ID,
127     0xEF6B490D, 0x5CD8, 0x437A, 0xAF, 0xFC, 0xDA, 0x8B, 0x60, 0xEE, 0x4A, 0x3C, 2}
128 DEFINE_PROPERTYKEY!{WPD_OBJECT_PARENT_ID,
129     0xEF6B490D, 0x5CD8, 0x437A, 0xAF, 0xFC, 0xDA, 0x8B, 0x60, 0xEE, 0x4A, 0x3C, 3}
130 DEFINE_PROPERTYKEY!{WPD_OBJECT_NAME,
131     0xEF6B490D, 0x5CD8, 0x437A, 0xAF, 0xFC, 0xDA, 0x8B, 0x60, 0xEE, 0x4A, 0x3C, 4}
132 DEFINE_PROPERTYKEY!{WPD_OBJECT_PERSISTENT_UNIQUE_ID,
133     0xEF6B490D, 0x5CD8, 0x437A, 0xAF, 0xFC, 0xDA, 0x8B, 0x60, 0xEE, 0x4A, 0x3C, 5}
134 DEFINE_PROPERTYKEY!{WPD_OBJECT_FORMAT,
135     0xEF6B490D, 0x5CD8, 0x437A, 0xAF, 0xFC, 0xDA, 0x8B, 0x60, 0xEE, 0x4A, 0x3C, 6}
136 DEFINE_PROPERTYKEY!{WPD_OBJECT_ISHIDDEN,
137     0xEF6B490D, 0x5CD8, 0x437A, 0xAF, 0xFC, 0xDA, 0x8B, 0x60, 0xEE, 0x4A, 0x3C, 9}
138 DEFINE_PROPERTYKEY!{WPD_OBJECT_ISSYSTEM,
139     0xEF6B490D, 0x5CD8, 0x437A, 0xAF, 0xFC, 0xDA, 0x8B, 0x60, 0xEE, 0x4A, 0x3C, 10}
140 DEFINE_PROPERTYKEY!{WPD_OBJECT_SIZE,
141     0xEF6B490D, 0x5CD8, 0x437A, 0xAF, 0xFC, 0xDA, 0x8B, 0x60, 0xEE, 0x4A, 0x3C, 11}
142 DEFINE_PROPERTYKEY!{WPD_OBJECT_ORIGINAL_FILE_NAME,
143     0xEF6B490D, 0x5CD8, 0x437A, 0xAF, 0xFC, 0xDA, 0x8B, 0x60, 0xEE, 0x4A, 0x3C, 12}
144 DEFINE_PROPERTYKEY!{WPD_OBJECT_NON_CONSUMABLE,
145     0xEF6B490D, 0x5CD8, 0x437A, 0xAF, 0xFC, 0xDA, 0x8B, 0x60, 0xEE, 0x4A, 0x3C, 13}
146 DEFINE_PROPERTYKEY!{WPD_OBJECT_KEYWORDS,
147     0xEF6B490D, 0x5CD8, 0x437A, 0xAF, 0xFC, 0xDA, 0x8B, 0x60, 0xEE, 0x4A, 0x3C, 15}
148 DEFINE_PROPERTYKEY!{WPD_OBJECT_SYNC_ID,
149     0xEF6B490D, 0x5CD8, 0x437A, 0xAF, 0xFC, 0xDA, 0x8B, 0x60, 0xEE, 0x4A, 0x3C, 16}
150 DEFINE_PROPERTYKEY!{WPD_OBJECT_IS_DRM_PROTECTED,
151     0xEF6B490D, 0x5CD8, 0x437A, 0xAF, 0xFC, 0xDA, 0x8B, 0x60, 0xEE, 0x4A, 0x3C, 17}
152 DEFINE_PROPERTYKEY!{WPD_OBJECT_DATE_CREATED,
153     0xEF6B490D, 0x5CD8, 0x437A, 0xAF, 0xFC, 0xDA, 0x8B, 0x60, 0xEE, 0x4A, 0x3C, 18}
154 DEFINE_PROPERTYKEY!{WPD_OBJECT_DATE_MODIFIED,
155     0xEF6B490D, 0x5CD8, 0x437A, 0xAF, 0xFC, 0xDA, 0x8B, 0x60, 0xEE, 0x4A, 0x3C, 19}
156 DEFINE_PROPERTYKEY!{WPD_OBJECT_DATE_AUTHORED,
157     0xEF6B490D, 0x5CD8, 0x437A, 0xAF, 0xFC, 0xDA, 0x8B, 0x60, 0xEE, 0x4A, 0x3C, 20}
158 DEFINE_PROPERTYKEY!{WPD_OBJECT_BACK_REFERENCES,
159     0xEF6B490D, 0x5CD8, 0x437A, 0xAF, 0xFC, 0xDA, 0x8B, 0x60, 0xEE, 0x4A, 0x3C, 21}
160 DEFINE_PROPERTYKEY!{WPD_OBJECT_CAN_DELETE,
161     0xEF6B490D, 0x5CD8, 0x437A, 0xAF, 0xFC, 0xDA, 0x8B, 0x60, 0xEE, 0x4A, 0x3C, 26}
162 DEFINE_PROPERTYKEY!{WPD_OBJECT_LANGUAGE_LOCALE,
163     0xEF6B490D, 0x5CD8, 0x437A, 0xAF, 0xFC, 0xDA, 0x8B, 0x60, 0xEE, 0x4A, 0x3C, 27}
164