Bug 1409972 - Part 5. Use the common printingui implementation. r?mshal
This patch will change moz.build of printingui and xre to use common printingui
implementation.
Memo of merging printingui:
* The nsProgress / nsProgressParam is used by Windows and GTK, macOS doesn't
have this implementation.
* The merged implementation located toolkit/components/printingui/ directory.
MozReview-Commit-ID: 3Z5MAzGVo1b
--- a/toolkit/components/printingui/moz.build
+++ b/toolkit/components/printingui/moz.build
@@ -2,19 +2,21 @@
# vim: set filetype=python:
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
with Files('**'):
BUG_COMPONENT = ('Toolkit', 'Printing')
-toolkit = CONFIG['MOZ_WIDGET_TOOLKIT']
-
DIRS += ['ipc']
if CONFIG['NS_PRINTING']:
- if toolkit == 'windows':
- DIRS += ['win']
- elif toolkit == 'cocoa':
- DIRS += ['mac']
- elif CONFIG['MOZ_PDF_PRINTING']:
- DIRS += ['unixshared']
+ UNIFIED_SOURCES += [
+ 'nsPrintingPromptService.cpp',
+ ]
+ if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'windows' or CONFIG['MOZ_PDF_PRINTING']:
+ UNIFIED_SOURCES += [
+ 'nsPrintProgress.cpp',
+ 'nsPrintProgressParams.cpp',
+ ]
+
+FINAL_LIBRARY = 'xul'
--- a/toolkit/xre/moz.build
+++ b/toolkit/xre/moz.build
@@ -40,30 +40,30 @@ if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'wind
'../../other-licenses/nsis/Contrib/CityHash/cityhash/city.cpp',
]
UNIFIED_SOURCES += [
'nsNativeAppSupportWin.cpp',
]
DEFINES['PROXY_PRINTING'] = 1
LOCAL_INCLUDES += [
'../../other-licenses/nsis/Contrib/CityHash/cityhash',
- '../components/printingui/win',
+ '../components/printingui',
]
elif CONFIG['MOZ_WIDGET_TOOLKIT'] == 'cocoa':
UNIFIED_SOURCES += [
'MacApplicationDelegate.mm',
'MacAutoreleasePool.mm',
'MacLaunchHelper.mm',
'nsCommandLineServiceMac.cpp',
'nsNativeAppSupportCocoa.mm',
'updaterfileutils_osx.mm',
]
DEFINES['PROXY_PRINTING'] = 1
LOCAL_INCLUDES += [
- '../components/printingui/mac',
+ '../components/printingui',
]
elif CONFIG['MOZ_WIDGET_TOOLKIT'] == 'uikit':
UNIFIED_SOURCES += [
'nsNativeAppSupportDefault.cpp',
'UIKitDirProvider.mm',
]
elif 'gtk' in CONFIG['MOZ_WIDGET_TOOLKIT']:
UNIFIED_SOURCES += [
@@ -125,17 +125,17 @@ if CONFIG['MOZ_UPDATER']:
if CONFIG['MOZ_WIDGET_TOOLKIT'] != 'android':
UNIFIED_SOURCES += [
'nsUpdateDriver.cpp',
]
if CONFIG['MOZ_PDF_PRINTING']:
DEFINES['PROXY_PRINTING'] = 1
LOCAL_INCLUDES += [
- '../components/printingui/unixshared',
+ '../components/printingui',
]
include('/ipc/chromium/chromium-config.mozbuild')
FINAL_LIBRARY = 'xul'
if CONFIG['MOZ_GL_DEFAULT_PROVIDER'] == 'GLX':
DEFINES['USE_GLX_TEST'] = True