~mmach/netext73/webkit2gtk

« back to all changes in this revision

Viewing changes to Source/WTF/wtf/PlatformEnableCocoa.h

  • Committer: mmach
  • Date: 2023-06-16 17:21:37 UTC
  • Revision ID: netbit73@gmail.com-20230616172137-2rqx6yr96ga9g3kp
1

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 * Copyright (C) 2006-2020 Apple Inc. All rights reserved.
 
3
 * Copyright (C) 2007-2009 Torch Mobile, Inc.
 
4
 * Copyright (C) 2010, 2011 Research In Motion Limited. All rights reserved.
 
5
 * Copyright (C) 2013 Samsung Electronics. All rights reserved.
 
6
 *
 
7
 * Redistribution and use in source and binary forms, with or without
 
8
 * modification, are permitted provided that the following conditions
 
9
 * are met:
 
10
 * 1. Redistributions of source code must retain the above copyright
 
11
 *    notice, this list of conditions and the following disclaimer.
 
12
 * 2. Redistributions in binary form must reproduce the above copyright
 
13
 *    notice, this list of conditions and the following disclaimer in the
 
14
 *    documentation and/or other materials provided with the distribution.
 
15
 *
 
16
 * THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY
 
17
 * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 
18
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
 
19
 * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL APPLE INC. OR
 
20
 * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
 
21
 * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
 
22
 * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
 
23
 * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
 
24
 * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
 
25
 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
 
26
 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
27
 */
 
28
 
 
29
#pragma once
 
30
 
 
31
#ifndef WTF_PLATFORM_GUARD_AGAINST_INDIRECT_INCLUSION
 
32
#error "Please #include <wtf/Platform.h> instead of this file directly."
 
33
#endif
 
34
 
 
35
#if !PLATFORM(COCOA)
 
36
#error "This file should only be included when building for one of Apple's Cocoa platforms."
 
37
#endif
 
38
 
 
39
 
 
40
/* --------- Apple Cocoa platforms --------- */
 
41
 
 
42
#if !defined(ENABLE_AIRPLAY_PICKER) && (PLATFORM(IOS_FAMILY) && !PLATFORM(MACCATALYST))
 
43
#define ENABLE_AIRPLAY_PICKER 1
 
44
#endif
 
45
 
 
46
#if !defined(ENABLE_APPLE_PAY_REMOTE_UI) && (PLATFORM(IOS_FAMILY) && !PLATFORM(APPLETV) && !PLATFORM(MACCATALYST) && !PLATFORM(WATCHOS))
 
47
#define ENABLE_APPLE_PAY_REMOTE_UI 1
 
48
#endif
 
49
 
 
50
#if !defined(ENABLE_CONTENT_EXTENSIONS)
 
51
#define ENABLE_CONTENT_EXTENSIONS 1
 
52
#endif
 
53
 
 
54
#if !defined(ENABLE_CONTEXT_MENUS) && PLATFORM(IOS_FAMILY)
 
55
#define ENABLE_CONTEXT_MENUS 0
 
56
#endif
 
57
 
 
58
#if !defined(ENABLE_CONTEXT_MENU_EVENT) && (PLATFORM(IOS_FAMILY) && !PLATFORM(MACCATALYST))
 
59
#define ENABLE_CONTEXT_MENU_EVENT 0
 
60
#endif
 
61
 
 
62
#if !defined(ENABLE_CUSTOM_CURSOR_SUPPORT) && PLATFORM(IOS_FAMILY)
 
63
#define ENABLE_CUSTOM_CURSOR_SUPPORT 0
 
64
#endif
 
65
 
 
66
#if !defined(ENABLE_DRAG_SUPPORT) && PLATFORM(IOS_FAMILY)
 
67
#define ENABLE_DRAG_SUPPORT 0
 
68
#endif
 
69
 
 
70
#if !defined(ENABLE_GEOLOCATION) && PLATFORM(IOS_FAMILY)
 
71
#define ENABLE_GEOLOCATION 1
 
72
#endif
 
73
 
 
74
#if !defined(ENABLE_INSPECTOR_ALTERNATE_DISPATCHERS)
 
75
#define ENABLE_INSPECTOR_ALTERNATE_DISPATCHERS 1
 
76
#endif
 
77
 
 
78
#if !defined(ENABLE_INSPECTOR_TELEMETRY) && PLATFORM(MAC)
 
79
#define ENABLE_INSPECTOR_TELEMETRY 1
 
80
#endif
 
81
 
 
82
#if !defined(ENABLE_LETTERPRESS) && PLATFORM(IOS_FAMILY)
 
83
#define ENABLE_LETTERPRESS 1
 
84
#endif
 
85
 
 
86
#if !defined(ENABLE_AUTOCORRECT) && PLATFORM(IOS_FAMILY)
 
87
#define ENABLE_AUTOCORRECT 1
 
88
#endif
 
89
 
 
90
#if !defined(ENABLE_AUTOCAPITALIZE) && PLATFORM(IOS_FAMILY)
 
91
#define ENABLE_AUTOCAPITALIZE 1
 
92
#endif
 
93
 
 
94
#if !defined(ENABLE_IOS_GESTURE_EVENTS) && (PLATFORM(IOS_FAMILY) && USE(APPLE_INTERNAL_SDK))
 
95
#define ENABLE_IOS_GESTURE_EVENTS 1
 
96
#endif
 
97
 
 
98
#if !defined(ENABLE_IOS_TOUCH_EVENTS) && (PLATFORM(IOS_FAMILY) && USE(APPLE_INTERNAL_SDK))
 
99
#define ENABLE_IOS_TOUCH_EVENTS 1
 
100
#endif
 
101
 
 
102
#if !defined(ENABLE_TEXT_AUTOSIZING) && PLATFORM(IOS_FAMILY)
 
103
#define ENABLE_TEXT_AUTOSIZING 1
 
104
#endif
 
105
 
 
106
#if !defined(ENABLE_METER_ELEMENT) && PLATFORM(IOS_FAMILY)
 
107
#define ENABLE_METER_ELEMENT 0
 
108
#endif
 
109
 
 
110
#if !defined(ENABLE_NETSCAPE_PLUGIN_API) && PLATFORM(IOS_FAMILY)
 
111
#define ENABLE_NETSCAPE_PLUGIN_API 0
 
112
#endif
 
113
 
 
114
#if !defined(ENABLE_ORIENTATION_EVENTS) && PLATFORM(IOS_FAMILY)
 
115
#define ENABLE_ORIENTATION_EVENTS 1
 
116
#endif
 
117
 
 
118
#if !defined(ENABLE_POINTER_LOCK) && PLATFORM(IOS_FAMILY)
 
119
#define ENABLE_POINTER_LOCK 0
 
120
#endif
 
121
 
 
122
#if !defined(ENABLE_REMOTE_INSPECTOR)
 
123
#define ENABLE_REMOTE_INSPECTOR 1
 
124
#endif
 
125
 
 
126
#if !defined(ENABLE_TEXT_CARET) && PLATFORM(IOS_FAMILY)
 
127
#define ENABLE_TEXT_CARET 0
 
128
#endif
 
129
 
 
130
#if !defined(ENABLE_TEXT_SELECTION) && PLATFORM(IOS_FAMILY)
 
131
#define ENABLE_TEXT_SELECTION 0
 
132
#endif
 
133
 
 
134
#if !defined(ENABLE_TOUCH_EVENTS) && (PLATFORM(IOS_FAMILY) && USE(APPLE_INTERNAL_SDK))
 
135
#define ENABLE_TOUCH_EVENTS 1
 
136
#endif
 
137
 
 
138
#if !defined(ENABLE_WEB_ARCHIVE)
 
139
#define ENABLE_WEB_ARCHIVE 1
 
140
#endif
 
141
 
 
142
#if !defined(ENABLE_WEBGL) && PLATFORM(IOS_FAMILY)
 
143
#define ENABLE_WEBGL 1
 
144
#endif
 
145
 
 
146
#if !defined(ENABLE_PRIMARY_SNAPSHOTTED_PLUGIN_HEURISTIC)
 
147
#define ENABLE_PRIMARY_SNAPSHOTTED_PLUGIN_HEURISTIC 1
 
148
#endif
 
149
 
 
150
#if !defined(ENABLE_WKPDFVIEW) && PLATFORM(IOS)
 
151
#define ENABLE_WKPDFVIEW 1
 
152
#endif
 
153
 
 
154
#if !defined(ENABLE_MEDIA_SOURCE) && PLATFORM(MAC)
 
155
#define ENABLE_MEDIA_SOURCE 1
 
156
#endif
 
157
 
 
158
#if !defined(ENABLE_PREVIEW_CONVERTER) && PLATFORM(IOS)
 
159
#define ENABLE_PREVIEW_CONVERTER 1
 
160
#endif
 
161
 
 
162
#if !defined(ENABLE_META_VIEWPORT) && PLATFORM(IOS_FAMILY)
 
163
#define ENABLE_META_VIEWPORT 1
 
164
#endif
 
165
 
 
166
#if !defined(ENABLE_FULLSCREEN_API) && PLATFORM(MAC)
 
167
#define ENABLE_FULLSCREEN_API 1
 
168
#endif
 
169
 
 
170
#if !defined(ENABLE_SMOOTH_SCROLLING) && PLATFORM(MAC)
 
171
#define ENABLE_SMOOTH_SCROLLING 1
 
172
#endif
 
173
 
 
174
#if !defined(ENABLE_VIDEO_TRACK) && PLATFORM(MAC) && ENABLE(VIDEO)
 
175
#define ENABLE_VIDEO_TRACK 1
 
176
#endif
 
177
 
 
178
#if !defined(ENABLE_WEB_AUDIO) && PLATFORM(MAC)
 
179
#define ENABLE_WEB_AUDIO 1
 
180
#endif
 
181
 
 
182
#if !defined(ENABLE_CURSOR_VISIBILITY) && PLATFORM(MAC)
 
183
#define ENABLE_CURSOR_VISIBILITY 1
 
184
#endif
 
185
 
 
186
#if !defined(ENABLE_MAC_GESTURE_EVENTS) && (PLATFORM(MAC) && USE(APPLE_INTERNAL_SDK))
 
187
#define ENABLE_MAC_GESTURE_EVENTS 1
 
188
#endif
 
189
 
 
190
#if !defined(ENABLE_WEBPROCESS_NSRUNLOOP) && (PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101400)
 
191
#define ENABLE_WEBPROCESS_NSRUNLOOP 1
 
192
#endif
 
193
 
 
194
#if !defined(ENABLE_WEBPROCESS_WINDOWSERVER_BLOCKING) && (PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101400)
 
195
#define ENABLE_WEBPROCESS_WINDOWSERVER_BLOCKING 1
 
196
#endif
 
197
 
 
198
#if !defined(ENABLE_LEGACY_ENCRYPTED_MEDIA) && !PLATFORM(MACCATALYST)
 
199
#define ENABLE_LEGACY_ENCRYPTED_MEDIA 1
 
200
#endif
 
201
 
 
202
#if !defined(ENABLE_FILE_REPLACEMENT)
 
203
#define ENABLE_FILE_REPLACEMENT 1
 
204
#endif
 
205
 
 
206
#if !defined(ENABLE_PAYMENT_REQUEST)
 
207
#define ENABLE_PAYMENT_REQUEST 1
 
208
#endif
 
209
 
 
210
#if !defined(ENABLE_ASYNC_SCROLLING)
 
211
#define ENABLE_ASYNC_SCROLLING 1
 
212
#endif
 
213
 
 
214
#if !defined(ENABLE_UI_SIDE_COMPOSITING)
 
215
#define ENABLE_UI_SIDE_COMPOSITING 1
 
216
#endif
 
217
 
 
218
#if !defined(ENABLE_FULL_KEYBOARD_ACCESS) && PLATFORM(MAC)
 
219
#define ENABLE_FULL_KEYBOARD_ACCESS 1
 
220
#endif
 
221
 
 
222
#if !defined(ENABLE_MONOSPACE_FONT_EXCEPTION) && ((PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED < 101500) || PLATFORM(WATCHOS) || PLATFORM(APPLETV))
 
223
#define ENABLE_MONOSPACE_FONT_EXCEPTION 1
 
224
#endif
 
225
 
 
226
#if !defined(ENABLE_PLATFORM_DRIVEN_TEXT_CHECKING) && PLATFORM(MACCATALYST)
 
227
#define ENABLE_PLATFORM_DRIVEN_TEXT_CHECKING 1
 
228
#endif
 
229
 
 
230
#if !defined(ENABLE_WEB_PLAYBACK_CONTROLS_MANAGER) && PLATFORM(MAC)
 
231
#define ENABLE_WEB_PLAYBACK_CONTROLS_MANAGER 1
 
232
#endif
 
233
 
 
234
#if !defined(ENABLE_RESOURCE_USAGE)
 
235
#define ENABLE_RESOURCE_USAGE 1
 
236
#endif
 
237
 
 
238
#if !defined(ENABLE_SEC_ITEM_SHIM)
 
239
#define ENABLE_SEC_ITEM_SHIM 1
 
240
#endif
 
241
 
 
242
#if !defined(ENABLE_DATA_DETECTION) && (!PLATFORM(WATCHOS) && !PLATFORM(APPLETV) && !PLATFORM(MACCATALYST))
 
243
#define ENABLE_DATA_DETECTION 1
 
244
#endif