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/.
6
7with Files('**'):
8    BUG_COMPONENT = ('Core', 'XUL')
9
10with Files('*Menu*'):
11    BUG_COMPONENT = ('Firefox', 'Menus')
12
13if CONFIG['ENABLE_TESTS']:
14    MOCHITEST_MANIFESTS += ['test/mochitest.ini']
15    MOCHITEST_CHROME_MANIFESTS += ['test/chrome.ini']
16    BROWSER_CHROME_MANIFESTS += ['test/browser.ini']
17
18EXPORTS += [
19    'nsIScrollbarMediator.h',
20    'nsXULPopupManager.h',
21    'nsXULTooltipListener.h',
22]
23
24UNIFIED_SOURCES += [
25    'nsBox.cpp',
26    'nsBoxFrame.cpp',
27    'nsBoxLayout.cpp',
28    'nsBoxLayoutState.cpp',
29    'nsButtonBoxFrame.cpp',
30    'nsRepeatService.cpp',
31    'nsRootBoxFrame.cpp',
32    'nsScrollbarButtonFrame.cpp',
33    'nsScrollbarFrame.cpp',
34    'nsSliderFrame.cpp',
35    'nsSprocketLayout.cpp',
36    'nsStackFrame.cpp',
37    'nsStackLayout.cpp',
38    'nsXULTooltipListener.cpp',
39]
40
41if CONFIG['MOZ_XUL']:
42    UNIFIED_SOURCES += [
43        'nsDeckFrame.cpp',
44        'nsDocElementBoxFrame.cpp',
45        'nsImageBoxFrame.cpp',
46        'nsLeafBoxFrame.cpp',
47        'nsMenuBarFrame.cpp',
48        'nsMenuBarListener.cpp',
49        'nsMenuFrame.cpp',
50        'nsMenuPopupFrame.cpp',
51        'nsPopupSetFrame.cpp',
52        'nsResizerFrame.cpp',
53        'nsSplitterFrame.cpp',
54        'nsTextBoxFrame.cpp',
55        'nsTitleBarFrame.cpp',
56        'nsXULLabelFrame.cpp',
57        'nsXULPopupManager.cpp',
58    ]
59
60if CONFIG['MOZ_XUL']:
61    DIRS += ['tree', 'grid']
62
63CFLAGS += CONFIG['TK_CFLAGS']
64CXXFLAGS += CONFIG['TK_CFLAGS']
65
66include('/ipc/chromium/chromium-config.mozbuild')
67
68FINAL_LIBRARY = 'xul'
69LOCAL_INCLUDES += [
70    '../base',
71    '../generic',
72    '../painting',
73    '../style',
74    '/dom/base',
75    '/dom/xul',
76]
77
78if CONFIG['CC_TYPE'] in ('clang', 'gcc'):
79    CXXFLAGS += ['-Wno-error=shadow']
80