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 "nsIJumpListItem.idl",
84 "nsIPrintSettingsWin.idl",
85 "nsITaskbarOverlayIconController.idl",
86 "nsITaskbarPreview.idl",
87 "nsITaskbarPreviewButton.idl",
88 "nsITaskbarPreviewController.idl",
89 "nsITaskbarProgress.idl",
90 "nsITaskbarTabPreview.idl",
91 "nsITaskbarWindowPreview.idl",
92 "nsIWindowsUIUtils.idl",
96 if CONFIG["NS_PRINTING"]:
97 # Needs to go before the XPIDL_MODULE line.
99 "nsIPrintDialogService.idl",
102 TEST_DIRS += ["tests", "tests/gtest"]
106 # Don't build the DSO under the 'build' directory as windows does.
108 # The DSOs get built in the toolkit dir itself. Do this so that
109 # multiple implementations of widget can be built on the same
116 "nsIBidiKeyboard.idl",
118 "nsIClipboardHelper.idl",
119 "nsIClipboardOwner.idl",
120 "nsIColorPicker.idl",
121 "nsIDisplayInfo.idl",
122 "nsIDragService.idl",
123 "nsIDragSession.idl",
125 "nsIFormatConverter.idl",
127 "nsIGfxInfoDebug.idl",
129 "nsIPaperMargin.idl",
131 "nsIPrinterList.idl",
132 "nsIPrintSettings.idl",
133 "nsIPrintSettingsService.idl",
135 "nsIScreenManager.idl",
136 "nsISharePicker.idl",
138 "nsISystemStatusBar.idl",
139 "nsITransferable.idl",
140 "nsIUserIdleService.idl",
141 "nsIUserIdleServiceInternal.idl",
144 XPIDL_MODULE = "widget"
149 "GfxInfoCollector.h",
153 "nsBaseDragService.h",
154 "nsBaseFilePicker.h",
156 "nsIDeviceContextSpec.h",
157 "nsIRollupListener.h",
159 "nsIWidgetListener.h",
161 "nsPrinterListBase.h",
162 "nsUserIdleService.h",
169 "ClipboardWriteRequestChild.h",
170 "ClipboardWriteRequestParent.h",
176 "DimensionRequest.h",
179 "EventMessageList.h",
184 "NativeKeyBindingsType.h",
186 "TextEventDispatcher.h",
187 "TextEventDispatcherListener.h",
193 "WindowButtonType.h",
196 EXPORTS.mozilla.widget += [
197 "CompositorWidget.h",
201 "InProcessCompositorWidget.h",
202 "MediaKeysEventSourceFactory.h",
204 "NativeMenuSupport.h",
207 "PuppetBidiKeyboard.h",
208 "RemoteLookAndFeel.h",
213 "WidgetMessageUtils.h",
214 "WindowOcclusionState.h",
218 "ClipboardWriteRequestChild.cpp",
219 "ClipboardWriteRequestParent.cpp",
220 "CompositorWidget.cpp",
223 "DimensionRequest.cpp",
226 "GfxInfoCollector.cpp",
229 "InProcessCompositorWidget.cpp",
232 "nsBaseAppShell.cpp",
233 "nsBaseClipboard.cpp",
234 "nsClipboardHelper.cpp",
235 "nsClipboardProxy.cpp",
236 "nsColorPickerProxy.cpp",
237 "nsDragServiceProxy.cpp",
238 "nsFilePickerProxy.cpp",
239 "nsHTMLFormatConverter.cpp",
241 "nsIDeviceContextSpec.cpp",
242 "nsIWidgetListener.cpp",
243 "nsPrimitiveHelpers.cpp",
244 "nsPrintSettingsImpl.cpp",
246 "nsTransferable.cpp",
247 "nsUserIdleService.cpp",
248 "nsXPLookAndFeel.cpp",
249 "PuppetBidiKeyboard.cpp",
251 "RemoteLookAndFeel.cpp",
253 "ScrollbarDrawing.cpp",
254 "ScrollbarDrawingAndroid.cpp",
255 "ScrollbarDrawingCocoa.cpp",
256 "ScrollbarDrawingGTK.cpp",
257 "ScrollbarDrawingWin.cpp",
258 "ScrollbarDrawingWin11.cpp",
259 "SharedWidgetUtils.cpp",
261 "TextEventDispatcher.cpp",
262 "TextRecognition.cpp",
267 "TouchResampler.cpp",
268 "VsyncDispatcher.cpp",
269 "WidgetEventImpl.cpp",
273 if CONFIG["OS_ARCH"] == "Linux":
274 EXPORTS.mozilla.widget += ["LSBUtils.h"]
275 SOURCES += ["LSBUtils.cpp"]
277 if CONFIG["NS_PRINTING"]:
279 "nsDeviceContextSpecProxy.h",
280 "nsPrintSettingsService.h",
283 "nsDeviceContextSpecProxy.cpp",
287 "nsPrinterListBase.cpp",
288 "nsPrintSettingsService.cpp",
291 if toolkit in ("cocoa", "gtk"):
295 "nsPrinterListCUPS.cpp",
298 # nsBaseWidget.cpp needs to be built separately because of name clashes in the OS X headers
299 # nsBaseDragService.cpp moved out of UNIFIED to fix xgill crash (bug 1259850) after moving widget/ContentHelper -> apz/util/TouchActionHelper
301 "nsBaseDragService.cpp",
306 if CONFIG["MOZ_INSTRUMENT_EVENT_LOOP"]:
308 "WidgetTraceEvent.h",
315 if CONFIG["MOZ_X11"] or CONFIG["MOZ_WAYLAND"]:
318 if toolkit in {"gtk", "cocoa", "windows", "android", "uikit"}:
320 "nsBaseFilePicker.cpp",
323 if toolkit in ("gtk", "windows", "cocoa", "android"):
328 DEFINES["MOZ_CROSS_PROCESS_IME"] = True
330 include("/ipc/chromium/chromium-config.mozbuild")
347 # We use the CUPS headers on Cocoa and GTK, but on GTK we don't depend on there being system headers.
349 LOCAL_INCLUDES += ["/third_party/cups/include"]
351 if toolkit == "windows":
353 "headless/HeadlessWidgetTypes.ipdlh",
354 "windows/PCompositorWidget.ipdl",
355 "windows/PlatformWidgetTypes.ipdlh",
357 elif CONFIG["MOZ_WIDGET_TOOLKIT"] == "gtk":
359 "gtk/PCompositorWidget.ipdl",
360 "gtk/PlatformWidgetTypes.ipdlh",
361 "headless/HeadlessWidgetTypes.ipdlh",
363 elif toolkit == "android":
365 "android/PCompositorWidget.ipdl",
366 "android/PlatformWidgetTypes.ipdlh",
367 "headless/HeadlessWidgetTypes.ipdlh",
371 "generic/PCompositorWidget.ipdl",
372 "generic/PlatformWidgetTypes.ipdlh",
373 "headless/HeadlessWidgetTypes.ipdlh",
377 "PClipboardWriteRequest.ipdl",
380 PREPROCESSED_IPDL_SOURCES += [
381 "LookAndFeelTypes.ipdlh",
385 "/widget/%s" % toolkit,
387 FINAL_LIBRARY = "xul"
389 if CONFIG["MOZ_ENABLE_D3D10_LAYER"]:
390 DEFINES["MOZ_ENABLE_D3D10_LAYER"] = True
392 if CONFIG["MOZ_WIDGET_TOOLKIT"] == "gtk":
393 CXXFLAGS += CONFIG["MOZ_GTK3_CFLAGS"]
394 if CONFIG["MOZ_WAYLAND"]:
395 CXXFLAGS += CONFIG["MOZ_WAYLAND_CFLAGS"]