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"]
54 if toolkit in ("android", "cocoa", "gtk", "uikit", "windows"):
57 if toolkit == "cocoa":
59 "nsIMacDockSupport.idl",
60 "nsIMacFinderProgress.idl",
61 "nsIMacSharingService.idl",
62 "nsIMacUserActivityUpdater.idl",
63 "nsIMacWebAppUtils.idl",
64 "nsIStandaloneNativeMenu.idl",
65 "nsITaskbarProgress.idl",
66 "nsITouchBarHelper.idl",
67 "nsITouchBarInput.idl",
68 "nsITouchBarUpdater.idl",
70 elif toolkit == "gtk":
72 "nsIApplicationChooser.idl",
73 "nsIGtkTaskbarProgress.idl",
74 "nsITaskbarProgress.idl",
76 elif toolkit == "windows":
78 "nsIJumpListBuilder.idl",
79 "nsIJumpListItem.idl",
80 "nsIPrintSettingsWin.idl",
81 "nsITaskbarOverlayIconController.idl",
82 "nsITaskbarPreview.idl",
83 "nsITaskbarPreviewButton.idl",
84 "nsITaskbarPreviewController.idl",
85 "nsITaskbarProgress.idl",
86 "nsITaskbarTabPreview.idl",
87 "nsITaskbarWindowPreview.idl",
88 "nsIWindowsUIUtils.idl",
92 TEST_DIRS += ["tests", "tests/gtest"]
96 # Don't build the DSO under the 'build' directory as windows does.
98 # The DSOs get built in the toolkit dir itself. Do this so that
99 # multiple implementations of widget can be built on the same
106 "nsIBidiKeyboard.idl",
108 "nsIClipboardHelper.idl",
109 "nsIClipboardOwner.idl",
110 "nsIColorPicker.idl",
111 "nsIDisplayInfo.idl",
112 "nsIDragService.idl",
113 "nsIDragSession.idl",
115 "nsIFormatConverter.idl",
117 "nsIGfxInfoDebug.idl",
119 "nsIPaperMargin.idl",
121 "nsIPrinterList.idl",
122 "nsIPrintSettings.idl",
123 "nsIPrintSettingsService.idl",
125 "nsIScreenManager.idl",
126 "nsISharePicker.idl",
128 "nsISystemStatusBar.idl",
129 "nsITransferable.idl",
130 "nsIUserIdleService.idl",
131 "nsIUserIdleServiceInternal.idl",
134 XPIDL_MODULE = "widget"
139 "GfxInfoCollector.h",
142 "nsBaseDragService.h",
143 "nsBaseFilePicker.h",
146 "nsIDeviceContextSpec.h",
147 "nsIRollupListener.h",
149 "nsIWidgetListener.h",
151 "nsPrinterListBase.h",
152 "nsUserIdleService.h",
153 "nsWidgetInitData.h",
167 "EventMessageList.h",
172 "NativeKeyBindingsType.h",
174 "TextEventDispatcher.h",
175 "TextEventDispatcherListener.h",
183 EXPORTS.mozilla.widget += [
184 "CompositorWidget.h",
187 "InProcessCompositorWidget.h",
188 "MediaKeysEventSourceFactory.h",
190 "NativeMenuSupport.h",
193 "PuppetBidiKeyboard.h",
194 "RemoteLookAndFeel.h",
199 "WidgetMessageUtils.h",
200 "WindowOcclusionState.h",
204 "CompositorWidget.cpp",
209 "GfxInfoCollector.cpp",
212 "InProcessCompositorWidget.cpp",
215 "nsBaseAppShell.cpp",
217 "nsClipboardHelper.cpp",
218 "nsClipboardProxy.cpp",
219 "nsColorPickerProxy.cpp",
220 "nsContentProcessWidgetFactory.cpp",
221 "nsDragServiceProxy.cpp",
222 "nsFilePickerProxy.cpp",
223 "nsHTMLFormatConverter.cpp",
224 "nsIWidgetListener.cpp",
225 "nsPrimitiveHelpers.cpp",
226 "nsPrintSettingsImpl.cpp",
228 "nsTransferable.cpp",
229 "nsUserIdleService.cpp",
230 "nsXPLookAndFeel.cpp",
231 "PuppetBidiKeyboard.cpp",
233 "RemoteLookAndFeel.cpp",
235 "ScrollbarDrawing.cpp",
236 "ScrollbarDrawingAndroid.cpp",
237 "ScrollbarDrawingCocoa.cpp",
238 "ScrollbarDrawingGTK.cpp",
239 "ScrollbarDrawingWin.cpp",
240 "ScrollbarDrawingWin11.cpp",
241 "SharedWidgetUtils.cpp",
243 "TextEventDispatcher.cpp",
244 "TextRecognition.cpp",
249 "TouchResampler.cpp",
250 "VsyncDispatcher.cpp",
251 "WidgetEventImpl.cpp",
255 if CONFIG["OS_ARCH"] == "Linux":
256 EXPORTS.mozilla.widget += ["LSBUtils.h"]
257 SOURCES += ["LSBUtils.cpp"]
259 if CONFIG["NS_PRINTING"]:
261 "nsIPrintDialogService.idl",
264 "nsDeviceContextSpecProxy.h",
265 "nsPrintSettingsService.h",
268 "nsDeviceContextSpecProxy.cpp",
272 "nsPrinterListBase.cpp",
273 "nsPrintSettingsService.cpp",
276 if toolkit in ("cocoa", "gtk"):
280 "nsPrinterListCUPS.cpp",
283 # nsBaseWidget.cpp needs to be built separately because of name clashes in the OS X headers
284 # nsBaseDragService.cpp moved out of UNIFIED to fix xgill crash (bug 1259850) after moving widget/ContentHelper -> apz/util/TouchActionHelper
286 "nsBaseDragService.cpp",
291 if CONFIG["MOZ_INSTRUMENT_EVENT_LOOP"]:
293 "WidgetTraceEvent.h",
296 EXPORTS.ipc = ["nsGUIEventIPC.h"]
298 if CONFIG["MOZ_X11"] or CONFIG["MOZ_WAYLAND"]:
301 if toolkit in ("cocoa", "windows"):
303 "nsBaseClipboard.cpp",
306 if toolkit in {"gtk", "cocoa", "windows", "android", "uikit"}:
308 "nsBaseFilePicker.cpp",
311 if toolkit in ("gtk", "windows", "cocoa", "android"):
316 DEFINES["MOZ_CROSS_PROCESS_IME"] = True
318 include("/ipc/chromium/chromium-config.mozbuild")
335 # We use the CUPS headers on Cocoa and GTK, but on GTK we don't depend on there being system headers.
337 LOCAL_INCLUDES += ["/third_party/cups/include"]
339 if toolkit == "windows":
341 "headless/HeadlessWidgetTypes.ipdlh",
342 "windows/PCompositorWidget.ipdl",
343 "windows/PlatformWidgetTypes.ipdlh",
345 elif CONFIG["MOZ_WIDGET_TOOLKIT"] == "gtk":
347 "gtk/PCompositorWidget.ipdl",
348 "gtk/PlatformWidgetTypes.ipdlh",
349 "headless/HeadlessWidgetTypes.ipdlh",
351 elif toolkit == "android":
353 "android/PCompositorWidget.ipdl",
354 "android/PlatformWidgetTypes.ipdlh",
355 "headless/HeadlessWidgetTypes.ipdlh",
359 "generic/PCompositorWidget.ipdl",
360 "generic/PlatformWidgetTypes.ipdlh",
361 "headless/HeadlessWidgetTypes.ipdlh",
364 PREPROCESSED_IPDL_SOURCES += [
365 "LookAndFeelTypes.ipdlh",
369 "/widget/%s" % toolkit,
371 FINAL_LIBRARY = "xul"
373 if CONFIG["MOZ_ENABLE_D3D10_LAYER"]:
374 DEFINES["MOZ_ENABLE_D3D10_LAYER"] = True
376 if CONFIG["MOZ_WIDGET_TOOLKIT"] == "gtk":
377 CXXFLAGS += CONFIG["MOZ_GTK3_CFLAGS"]
378 if CONFIG["MOZ_WAYLAND"]:
379 CXXFLAGS += CONFIG["MOZ_WAYLAND_CFLAGS"]
381 REQUIRES_UNIFIED_BUILD = True