1 # -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*-
2 # vim: set filetype=python:
3 # This Source Code Form is subject to the terms of the Mozilla Public
4 # License, v. 2.0. If a copy of the MPL was not distributed with this
5 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 BUG_COMPONENT = ("Core", "Widget")
10 with Files("crashtests/*1128214*"):
11 BUG_COMPONENT = ("Core", "Layout")
13 with Files("crashtests/*303901*"):
14 BUG_COMPONENT = ("Core", "Graphics")
16 with Files("crashtests/*380359*"):
17 BUG_COMPONENT = ("Core", "Widget")
19 with Files("reftests/**"):
20 BUG_COMPONENT = ("Core", "Widget: Cocoa")
22 with Files("reftests/*fallback*"):
23 BUG_COMPONENT = ("Core", "Layout: Form Controls")
25 with Files("*CompositorWidget*"):
26 BUG_COMPONENT = ("Core", "Graphics")
28 with Files("*ContentCache*"):
29 BUG_COMPONENT = ("Core", "DOM: UI Events & Focus Handling")
31 with Files("*ContentData*"):
32 BUG_COMPONENT = ("Core", "DOM: UI Events & Focus Handling")
34 with Files("*Events.h"):
35 BUG_COMPONENT = ("Core", "DOM: UI Events & Focus Handling")
37 with Files("*FontRange*"):
38 BUG_COMPONENT = ("Core", "Widget: Cocoa")
41 BUG_COMPONENT = ("Core", "Graphics")
43 with Files("*IMEData*"):
44 BUG_COMPONENT = ("Core", "DOM: UI Events & Focus Handling")
46 with Files("*TextEventDispatcher*"):
47 BUG_COMPONENT = ("Core", "DOM: UI Events & Focus Handling")
49 with Files("*NativeKeyBindings*"):
50 BUG_COMPONENT = ("Core", "DOM: UI Events & Focus Handling")
52 toolkit = CONFIG["MOZ_WIDGET_TOOLKIT"]
58 if toolkit in ("android", "cocoa", "gtk", "uikit", "windows"):
61 if toolkit == "cocoa":
63 "nsIMacDockSupport.idl",
64 "nsIMacFinderProgress.idl",
65 "nsIMacSharingService.idl",
66 "nsIMacUserActivityUpdater.idl",
67 "nsIMacWebAppUtils.idl",
68 "nsIStandaloneNativeMenu.idl",
69 "nsITaskbarProgress.idl",
70 "nsITouchBarHelper.idl",
71 "nsITouchBarInput.idl",
72 "nsITouchBarUpdater.idl",
74 elif toolkit == "gtk":
76 "nsIApplicationChooser.idl",
77 "nsIGtkTaskbarProgress.idl",
78 "nsITaskbarProgress.idl",
80 elif toolkit == "windows":
82 "nsIJumpListBuilder.idl",
83 "nsIPrintSettingsWin.idl",
84 "nsITaskbarOverlayIconController.idl",
85 "nsITaskbarPreview.idl",
86 "nsITaskbarPreviewButton.idl",
87 "nsITaskbarPreviewController.idl",
88 "nsITaskbarProgress.idl",
89 "nsITaskbarTabPreview.idl",
90 "nsITaskbarWindowPreview.idl",
91 "nsIWindowsUIUtils.idl",
94 elif toolkit in ("android", "uikit"):
96 "nsIGeckoViewBridge.idl",
99 if CONFIG["NS_PRINTING"]:
100 # Needs to go before the XPIDL_MODULE line.
102 "nsIPrintDialogService.idl",
105 TEST_DIRS += ["tests", "tests/gtest"]
109 # Don't build the DSO under the 'build' directory as windows does.
111 # The DSOs get built in the toolkit dir itself. Do this so that
112 # multiple implementations of widget can be built on the same
119 "nsIBidiKeyboard.idl",
121 "nsIClipboardHelper.idl",
122 "nsIClipboardOwner.idl",
123 "nsIColorPicker.idl",
124 "nsIDisplayInfo.idl",
125 "nsIDragService.idl",
126 "nsIDragSession.idl",
128 "nsIFormatConverter.idl",
130 "nsIGfxInfoDebug.idl",
131 "nsIMockDragServiceController.idl",
133 "nsIPaperMargin.idl",
135 "nsIPrinterList.idl",
136 "nsIPrintSettings.idl",
137 "nsIPrintSettingsService.idl",
139 "nsIScreenManager.idl",
140 "nsISharePicker.idl",
142 "nsISystemStatusBar.idl",
143 "nsITransferable.idl",
144 "nsIUserIdleService.idl",
145 "nsIUserIdleServiceInternal.idl",
148 XPIDL_MODULE = "widget"
153 "GfxInfoCollector.h",
157 "nsBaseDragService.h",
158 "nsBaseFilePicker.h",
160 "nsDragServiceProxy.h",
161 "nsIDeviceContextSpec.h",
162 "nsIRollupListener.h",
164 "nsIWidgetListener.h",
166 "nsPrinterListBase.h",
167 "nsUserIdleService.h",
174 "ClipboardContentAnalysisChild.h",
175 "ClipboardContentAnalysisParent.h",
176 "ClipboardReadRequestChild.h",
177 "ClipboardReadRequestParent.h",
178 "ClipboardWriteRequestChild.h",
179 "ClipboardWriteRequestParent.h",
185 "DimensionRequest.h",
188 "EventMessageList.h",
193 "NativeKeyBindingsType.h",
195 "TextEventDispatcher.h",
196 "TextEventDispatcherListener.h",
202 "WindowButtonType.h",
205 EXPORTS.mozilla.widget += [
206 "CompositorWidget.h",
207 "GfxInfoDeviceVendorDefs.h",
208 "GfxInfoDriverVendorDefs.h",
209 "GfxInfoDriverVersionCmpDefs.h",
210 "GfxInfoFeatureDefs.h",
211 "GfxInfoFeatureStatusDefs.h",
212 "GfxInfoOperatingSystemDefs.h",
213 "GfxInfoWindowProtocolDefs.h",
217 "InProcessCompositorWidget.h",
218 "MediaKeysEventSourceFactory.h",
220 "NativeMenuSupport.h",
223 "PuppetBidiKeyboard.h",
224 "RemoteLookAndFeel.h",
229 "WidgetMessageUtils.h",
230 "WindowOcclusionState.h",
234 "ClipboardContentAnalysisChild.cpp",
235 "ClipboardContentAnalysisParent.cpp",
236 "ClipboardReadRequestParent.cpp",
237 "ClipboardWriteRequestChild.cpp",
238 "ClipboardWriteRequestParent.cpp",
239 "CompositorWidget.cpp",
242 "DimensionRequest.cpp",
245 "GfxInfoCollector.cpp",
248 "InProcessCompositorWidget.cpp",
251 "nsBaseAppShell.cpp",
252 "nsBaseClipboard.cpp",
253 "nsClipboardHelper.cpp",
254 "nsClipboardProxy.cpp",
255 "nsColorPickerProxy.cpp",
256 "nsDragServiceProxy.cpp",
257 "nsFilePickerProxy.cpp",
258 "nsHTMLFormatConverter.cpp",
260 "nsIDeviceContextSpec.cpp",
261 "nsIWidgetListener.cpp",
262 "nsPrimitiveHelpers.cpp",
263 "nsPrintSettingsImpl.cpp",
264 "nsTransferable.cpp",
265 "nsUserIdleService.cpp",
266 "nsXPLookAndFeel.cpp",
267 "PuppetBidiKeyboard.cpp",
269 "RemoteLookAndFeel.cpp",
271 "ScrollbarDrawing.cpp",
272 "ScrollbarDrawingAndroid.cpp",
273 "ScrollbarDrawingCocoa.cpp",
274 "ScrollbarDrawingGTK.cpp",
275 "ScrollbarDrawingWin.cpp",
276 "ScrollbarDrawingWin11.cpp",
277 "SharedWidgetUtils.cpp",
279 "TextEventDispatcher.cpp",
280 "TextRecognition.cpp",
285 "TouchResampler.cpp",
286 "VsyncDispatcher.cpp",
287 "WidgetEventImpl.cpp",
291 if CONFIG["OS_ARCH"] == "Linux":
292 EXPORTS.mozilla.widget += ["LSBUtils.h"]
293 SOURCES += ["LSBUtils.cpp"]
295 if CONFIG["NS_PRINTING"]:
297 "nsDeviceContextSpecProxy.h",
298 "nsPrintSettingsService.h",
301 "nsDeviceContextSpecProxy.cpp",
305 "nsPrinterListBase.cpp",
306 "nsPrintSettingsService.cpp",
309 if toolkit in ("cocoa", "gtk"):
313 "nsPrinterListCUPS.cpp",
316 # nsBaseWidget.cpp needs to be built separately because of name clashes in the OS X headers
317 # nsBaseDragService.cpp moved out of UNIFIED to fix xgill crash (bug 1259850) after moving widget/ContentHelper -> apz/util/TouchActionHelper
319 "nsBaseDragService.cpp",
328 if CONFIG["MOZ_X11"] or CONFIG["MOZ_WAYLAND"]:
331 if toolkit in {"gtk", "cocoa", "windows", "android", "uikit"}:
333 "nsBaseFilePicker.cpp",
336 if toolkit in ("gtk", "windows", "cocoa", "uikit", "android"):
341 DEFINES["MOZ_CROSS_PROCESS_IME"] = True
343 include("/ipc/chromium/chromium-config.mozbuild")
360 # We use the CUPS headers on Cocoa and GTK, but on GTK we don't depend on there being system headers.
362 LOCAL_INCLUDES += ["/third_party/cups/include"]
364 if toolkit == "windows":
366 "headless/HeadlessWidgetTypes.ipdlh",
367 "windows/PCompositorWidget.ipdl",
368 "windows/PlatformWidgetTypes.ipdlh",
370 elif CONFIG["MOZ_WIDGET_TOOLKIT"] == "gtk":
372 "gtk/PCompositorWidget.ipdl",
373 "gtk/PlatformWidgetTypes.ipdlh",
374 "headless/HeadlessWidgetTypes.ipdlh",
376 elif toolkit == "android":
378 "android/PCompositorWidget.ipdl",
379 "android/PlatformWidgetTypes.ipdlh",
380 "headless/HeadlessWidgetTypes.ipdlh",
384 "generic/PCompositorWidget.ipdl",
385 "generic/PlatformWidgetTypes.ipdlh",
386 "headless/HeadlessWidgetTypes.ipdlh",
390 "LookAndFeelTypes.ipdlh",
391 "PClipboardContentAnalysis.ipdl",
392 "PClipboardReadRequest.ipdl",
393 "PClipboardWriteRequest.ipdl",
397 "/widget/%s" % toolkit,
400 if CONFIG["ENABLE_TESTS"]:
402 "MockDragServiceController.cpp",
405 FINAL_LIBRARY = "xul"
407 if CONFIG["MOZ_WIDGET_TOOLKIT"] == "gtk":
408 CXXFLAGS += CONFIG["MOZ_GTK3_CFLAGS"]
409 if CONFIG["MOZ_WAYLAND"]:
410 CXXFLAGS += CONFIG["MOZ_WAYLAND_CFLAGS"]