Граф коммитов

45 Коммитов

Автор SHA1 Сообщение Дата
Jonathan Watt 913d6b76ee Bug 1557687. Remove nsPrintData::mDocWasToBeDestroyed. r=bobowen
This shows that this variable has never been read going back all the way to
the original Mercurial import in 2007:

  hg grep -f --diff mDocWasToBeDestroyed layout/printing/ns*

Differential Revision: https://phabricator.services.mozilla.com/D34143

--HG--
extra : rebase_source : c14a51dab1825e26fb8031d291d2c69e78931c84
extra : amend_source : 73794b07d703987db8d2eb49dd97d74b1a9be325
2019-05-29 10:42:14 +01:00
Jonathan Watt 098392f093 Bug 1552785. Remove internal code for various frameset printing behaviors. r=bobowen
Differential Revision: https://phabricator.services.mozilla.com/D33624

--HG--
extra : rebase_source : 336e87a05970895684602c9db3e5222918f861c8
extra : source : 98fbf1ed617549496036099b5aee333aa6b29925
2019-05-21 16:01:34 +01:00
Jonathan Watt dbcde07e70 Bug 1551882. Refactor the print preview listener code to make its purpose clear. r=bobowen
Differential Revision: https://phabricator.services.mozilla.com/D31252

--HG--
rename : layout/printing/nsPrintPreviewListener.cpp => layout/printing/PrintPreviewUserEventSuppressor.cpp
rename : layout/printing/nsPrintPreviewListener.h => layout/printing/PrintPreviewUserEventSuppressor.h
extra : rebase_source : a2bfc2635d8cb98ee7c93597c6f805122e99111f
extra : amend_source : 2d3c11cbc8e07fa90b1960c4e1a4422c12f2761b
2019-05-16 23:16:11 +01:00
Cameron McCormack a9c935c355 Bug 1511854 - Part 1: Fix some formatting oddities in layout/ after the clang-format. r=TYLin
Differential Revision: https://phabricator.services.mozilla.com/D13686

--HG--
extra : moz-landing-system : lando
2018-12-05 18:44:03 +00:00
Sylvestre Ledru 265e672179 Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format
# ignore-this-changeset

--HG--
extra : amend_source : 4d301d3b0b8711c4692392aa76088ba7fd7d1022
2018-11-30 11:46:48 +01:00
Jonathan Watt 7085690980 Bug 1430683 - Remove nsPrintData::mOrigDCScale. r=bobowen
MozReview-Commit-ID: 3iUiCuiVBei
2018-01-08 11:43:16 +00:00
Daniel Holbert 680815cd6e Bug 1412346 part 5: (automated patch) Switch a bunch of C++ files in layout to use our standard mode lines. r=jfkthame
This patch was generated automatically by the "modeline.py" script, available
here: https://github.com/amccreight/moz-source-tools/blob/master/modeline.py

For every file that is modified in this patch, the changes are as follows:
 (1) The patch changes the file to use the exact C++ mode lines from the
     Mozilla coding style guide, available here:
https://developer.mozilla.org/en-US/docs/Mozilla/Developer_guide/Coding_Style#Mode_Line

 (2) The patch deletes any blank lines between the mode line & the MPL
     boilerplate comment.

 (3) If the file previously had the mode lines and MPL boilerplate in a
     single contiguous C++ comment, then the patch splits them into
     separate C++ comments, to match the boilerplate in the coding style.

MozReview-Commit-ID: EuRsDue63tK

--HG--
extra : rebase_source : 3356d4b80ff6213935192e87cdbc9103fec6084c
2017-10-27 10:33:53 -07:00
L. David Baron 70c24e3e54 Bug 1405875 - Remove debug file mechanism from printing. r=mats
This was used only by nsRegressionTester::DumpFrameModel, which was
removed in the previous patch.

MozReview-Commit-ID: I8fS7vzlFQw
2017-10-05 11:15:57 -07:00
Nicholas Nethercote f941156987 Bug 1386600 - Change nsIStringBundle methods to return |AString| instead of |wstring|. r=emk,sr=dbaron.
This removes about 2/3 of the occurrences of nsXPIDLString in the tree. The
places where nsXPIDLStrings are null-checked are replaced with |rv| checks.

The patch also removes a couple of unused declarations from
nsIStringBundle.idl.

Note that nsStringBundle::GetStringFromNameHelper() was merged into
GetStringFromName(), because they both would have had the same signature.

--HG--
extra : rebase_source : ac40bc31c2a4997f2db0bd5069cc008757a2df6d
2017-08-04 14:40:52 +10:00
Masayuki Nakano 3def411e37 Bug 1360135 Get rid of nsPrintData::mSelectedPO because it's unused r=dholbert
MozReview-Commit-ID: 3nG5ZPXOsvq

--HG--
extra : rebase_source : cc01c2a44d458f59d595cba95e5b2bd45cd9061f
2017-05-10 17:25:56 +09:00
Masayuki Nakano 3fd5206e5b Bug 1354443 part.1-1 Make nsPrintData refcountable r=dholbert
MozReview-Commit-ID: 78azPbH9S9x
2017-05-09 17:08:20 +09:00
Ting-Yu Lin 0be6d30488 Bug 1342994 Part 2 - Use UniquePtr to replace explicit new/delete and non-owing pointers in printing APIs. r=dholbert
Also, rewrite some for-loops as range-based.

Other APIs still using nsPrintObject* involve with
nsPrintData::mPrintDocList or nsPagePrintTimer::mPrintObj.

nsPrintEngine::FindPrintObjectByDOMWin() could have its argument converted
to UniquePtr, but it needs to return nullptr to represent "found nothing."
Therefore, I leave its argument as it was for consistency.

MozReview-Commit-ID: 7hXaVy5IKHQ

--HG--
extra : rebase_source : 6be730b85d5566446942b8cdc31b49846384bc25
2017-03-06 16:28:20 +08:00
Ting-Yu Lin d58538758d Bug 1342994 Part 1 - Strip trailing whitespaces in nsPrintData, nsPrintEngine and nsPrintObject. r=dholbert
MozReview-Commit-ID: GGBrj4Eo45L

--HG--
extra : rebase_source : c52cb4744133c2628b495d47192bed852384327b
2017-03-06 15:35:39 +08:00
Jonathan Watt 07c5338755 Bug 1313525 - Remove the nsIPrintOptions interface. r=mstange
--HG--
rename : widget/nsIPrintOptions.idl => widget/nsIPrinterEnumerator.idl
2016-10-28 00:31:14 +01:00
Jonathan Watt b15368cfcb Bug 1279451 - Remove a lot of unnecessary includes of nsAutoPtr.h. rs=sparky 2016-06-07 21:10:18 +01:00
Bob Owen 80ef8208d0 Bug 1189846 Part 8: Make RemotePrintJob a print progress listener forwarder. r=jimm
MozReview-Commit-ID: 4ADQ6Hx46fZ
2016-05-16 10:40:54 +01:00
Kyle Huey 91efc5a86c Bug 1241764: Replace nsPIDOMWindow with nsPIDOMWindowInner/Outer. r=mrbkap,smaug 2016-01-30 09:05:36 -08:00
Nathan Froyd 01583602a9 Bug 1207245 - part 6 - rename nsRefPtr<T> to RefPtr<T>; r=ehsan; a=Tomcat
The bulk of this commit was generated with a script, executed at the top
level of a typical source code checkout.  The only non-machine-generated
part was modifying MFBT's moz.build to reflect the new naming.

CLOSED TREE makes big refactorings like this a piece of cake.

 # The main substitution.
find . -name '*.cpp' -o -name '*.cc' -o -name '*.h' -o -name '*.mm' -o -name '*.idl'| \
    xargs perl -p -i -e '
 s/nsRefPtr\.h/RefPtr\.h/g; # handle includes
 s/nsRefPtr ?</RefPtr</g;   # handle declarations and variables
'

 # Handle a special friend declaration in gfx/layers/AtomicRefCountedWithFinalize.h.
perl -p -i -e 's/::nsRefPtr;/::RefPtr;/' gfx/layers/AtomicRefCountedWithFinalize.h

 # Handle nsRefPtr.h itself, a couple places that define constructors
 # from nsRefPtr, and code generators specially.  We do this here, rather
 # than indiscriminantly s/nsRefPtr/RefPtr/, because that would rename
 # things like nsRefPtrHashtable.
perl -p -i -e 's/nsRefPtr/RefPtr/g' \
     mfbt/nsRefPtr.h \
     xpcom/glue/nsCOMPtr.h \
     xpcom/base/OwningNonNull.h \
     ipc/ipdl/ipdl/lower.py \
     ipc/ipdl/ipdl/builtin.py \
     dom/bindings/Codegen.py \
     python/lldbutils/lldbutils/utils.py

 # In our indiscriminate substitution above, we renamed
 # nsRefPtrGetterAddRefs, the class behind getter_AddRefs.  Fix that up.
find . -name '*.cpp' -o -name '*.h' -o -name '*.idl' | \
    xargs perl -p -i -e 's/nsRefPtrGetterAddRefs/RefPtrGetterAddRefs/g'

if [ -d .git ]; then
    git mv mfbt/nsRefPtr.h mfbt/RefPtr.h
else
    hg mv mfbt/nsRefPtr.h mfbt/RefPtr.h
fi

--HG--
rename : mfbt/nsRefPtr.h => mfbt/RefPtr.h
2015-10-18 01:24:48 -04:00
Ehsan Akhgari 4354953b4f Bug 1118486 - Part 1: Use `= delete` instead of MOZ_DELETE directly; r=Waldo
Most of this patch (with the exception of dom/bindings/Codegen.py) was
generated by the following bash script:

#!/bin/bash

function convert() {
echo "Converting $1 to $2..."
find . ! -wholename "*nsprpub*" \
       ! -wholename "*security/nss*" \
       ! -wholename "*/.hg*" \
       ! -wholename "*/.git*" \
       ! -wholename "obj-*" \
         -type f \
      \( -iname "*.cpp" \
         -o -iname "*.h" \
         -o -iname "*.cc" \
         -o -iname "*.idl" \
         -o -iname "*.ipdl" \
         -o -iname "*.ipdlh" \
         -o -iname "*.mm" \) | \
    xargs -n 1 sed -i -e "s/\b$1\b/$2/g"
}

convert MOZ_DELETE '= delete'
2015-01-08 23:19:05 -05:00
Ehsan Akhgari 2b84010cb8 Bug 1048246 - Fix more bad implicit constructors in layout; r=roc
--HG--
extra : rebase_source : ed828993139bc70232508364a9f046e38b7d3e06
2014-08-07 19:48:38 -04:00
Ehsan Akhgari 1b83407ce9 Bug 927728 - Part 1: Replace PRUnichar with char16_t; r=roc
This patch was automatically generated by the following script:

#!/bin/bash
# Command to convert PRUnichar to char16_t

function convert() {
echo "Converting $1 to $2..."
find . ! -wholename "*nsprpub*" \
       ! -wholename "*security/nss*" \
       ! -wholename "*modules/libmar*" \
       ! -wholename "*/.hg*" \
       ! -wholename "obj-ff-dbg*" \
       ! -name prtypes.h \
       ! -name Char16.h \
         -type f \
      \( -iname "*.cpp" \
         -o -iname "*.h" \
         -o -iname "*.c" \
         -o -iname "*.cc" \
         -o -iname "*.idl" \
         -o -iname "*.ipdl" \
         -o -iname "*.ipdlh" \
         -o -iname "*.mm" \) | \
    xargs -n 1 sed -i -e "s/\b$1\b/$2/g"
}

convert PRUnichar char16_t
2014-01-04 10:02:17 -05:00
Robert O'Callahan 9dfcbeeab2 Bug 889219. Part 1: Clean up nsPrintEngine string usage for document titles/URLs. r=mats
--HG--
extra : rebase_source : 17a67d9956e9df9e19c86ea70ac3045e636c49ae
2013-07-24 23:48:37 +12:00
Ehsan Akhgari e368dc9c85 Bug 579517 - Part 1: Automated conversion of NSPR numeric types to stdint types in Gecko; r=bsmedberg
This patch was generated by a script.  Here's the source of the script for
future reference:

function convert() {
echo "Converting $1 to $2..."
find . ! -wholename "*nsprpub*" \
       ! -wholename "*security/nss*" \
       ! -wholename "*/.hg*" \
       ! -wholename "obj-ff-dbg*" \
       ! -name nsXPCOMCID.h \
       ! -name prtypes.h \
         -type f \
      \( -iname "*.cpp" \
         -o -iname "*.h" \
         -o -iname "*.c" \
         -o -iname "*.cc" \
         -o -iname "*.idl" \
         -o -iname "*.ipdl" \
         -o -iname "*.ipdlh" \
         -o -iname "*.mm" \) | \
    xargs -n 1 sed -i -e "s/\b$1\b/$2/g"
}

convert PRInt8 int8_t
convert PRUint8 uint8_t
convert PRInt16 int16_t
convert PRUint16 uint16_t
convert PRInt32 int32_t
convert PRUint32 uint32_t
convert PRInt64 int64_t
convert PRUint64 uint64_t

convert PRIntn int
convert PRUintn unsigned

convert PRSize size_t

convert PROffset32 int32_t
convert PROffset64 int64_t

convert PRPtrdiff ptrdiff_t

convert PRFloat64 double
2012-08-22 11:56:38 -04:00
Gervase Markham 82ff7027aa Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
Jeff Walden 62f48d8793 Bug 711647 - Add MOZ_DELETE to a bunch of deliberately-not-implemented methods across the tree. r=dbaron
--HG--
extra : rebase_source : 507006c0f099da6851b585d2062267d285978ad7
2011-12-16 14:42:07 -05:00
Margaret Leibovic fcece73caf Bug 704691 - Fire STATE_IS_NETWORK notifications with print status so that the download manager can track "Save as PDF" prints. r=bz 2011-11-28 13:43:33 -08:00
Marco Bonardo c11a565ee6 Backout af0a7f54f483 (bug 704691), 17b4093b5ec5, 23f26ba05f1a (bug 697383) for various failures 2011-11-28 23:53:22 +01:00
Margaret Leibovic 9ad2cc77c8 Bug 704691 - Fire STATE_IS_NETWORK notifications with print status so that the download manager can track "Save as PDF" prints. r=bz 2011-11-28 13:43:33 -08:00
Michael Wu d2b70213ac Bug 675553 - Switch from PRBool to bool on a CLOSED TREE , r=bsmedberg,khuey,bz,cjones
--HG--
rename : tools/trace-malloc/bloatblame.c => tools/trace-malloc/bloatblame.cpp
2011-09-28 23:19:26 -07:00
Zack Weinberg 3929b6bfdd Bug 651017, part 5: mechanical changes.
--HG--
extra : rebase_source : 8bbdf48488736b51d05e734e2e9316c1460cfed5
2011-04-16 18:22:44 -07:00
Daniel Holbert d509dc0e16 Bug 551298, patch B: Replace uses of THEBES_INLINE_DECL_REFCOUNTING with NS_INLINE_DECL_REFCOUNTING. r=roc 2010-04-01 11:05:40 -07:00
Daniel Holbert 605900c19f Backed out changeset 29bc09de2f77 (Bug 551298) due to Linux debug mochitest-5 orange 2010-04-01 09:38:53 -07:00
Daniel Holbert f670acaa95 Bug 551298, patch B: Replace uses of THEBES_INLINE_DECL_REFCOUNTING with NS_INLINE_DECL_REFCOUNTING. r=roc 2010-04-01 08:08:51 -07:00
Arpad Borsos c0f2dadc80 Bug 474369 - get rid of nsVoidArray; layout part; r+sr=roc 2009-02-03 15:42:18 +01:00
kjh-5727@comcast.net bc93bea324 Bug 377096 - Factor out nsIPrintOptions::AvailablePrinters. r=pavlov, sr=biesi. 2007-05-06 04:29:41 -07:00
sharparrow1%yahoo.com 8c4edcac47 Bug 370966: Fix error handling in nsPrintEngine. r+sr=roc. 2007-02-23 03:58:36 +00:00
sharparrow1%yahoo.com 01ccd95a11 Bug 361844: Printing cleanup; r+sr=roc. Changes the way the presentation is managed for print preview, plus many smaller cleanups. 2006-12-10 08:05:05 +00:00
sharparrow1%yahoo.com 341097b456 Bug 344696: Remove nsIDeviceContext::Get/SetZoom. r+sr=roc. 2006-07-21 00:16:07 +00:00
sharparrow1%yahoo.com 1e650e3784 Bug 331415: some printing code cleanup. r+sr=roc. 2006-03-30 00:27:42 +00:00
cbiesinger%web.de 26a83fee9a bug 292998
- move textZoom storage to the prescontext from the documentviewer
- copy the textZoom between document viewers for fastback
r=bryner sr=dbaron
2005-08-13 11:54:22 +00:00
bryner%brianryner.com 5c02a6978c Change nsIPresContext to nsPresContext globally, follow-up to bug 253470. rs=roc 2004-07-31 23:15:21 +00:00
gerv%gerv.net 9d2ee4928c Bug 236613: change to MPL/LGPL/GPL tri-license. 2004-04-17 21:52:36 +00:00
hpradhan%hotpop.com 4d399b535b bug 232035 : fix leak and cleanup some stuff in printing code r=dbaron sr=jst 2004-01-28 11:17:14 +00:00
hpradhan%hotpop.com 3b99f154bd bug 231233 : nsPrintData.h cleanup r+sr=jst 2004-01-24 07:23:56 +00:00
rods%netscape.com fa04fb294e Move printing code out of the DocumentViewer
add in #defines to turn on and off printing and print preview
Bug 139905 r=dcone sr=jst
2002-08-21 12:01:05 +00:00