This method actually never throws. IsFullScreenDoc() simply checks
whether GetFullScreenElement() returns nullptr, which means if that
method returns true, the "!el" check would never fail.
--HG--
extra : source : f32a1aeb6835fd4b4c47ef3abe6b9d7366ae4f07
This also fixes bug 980560.
This is needed for patch 15, which will make the rules passed to these
methods no longer implement nsIStyleRule.
TODO (bug 1221908): Given the amount that these parameters are used (not
at all), perhaps we should have a followup on removing them and
simplifying these notifications?
--HG--
extra : commitid : 2RmPg80eWs6
The only substantive change here, apart from a few variables changing in
size from uint16_t to uint8_t, is FontFaceSet's use of SheetType::Unknown
(0xFF) instead of 0 for FontFaceRecords for script-created FontFaces.
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
In the case of DisplayWidthHeight viewports, setting the allowDoubleTapToZoom
flag to true is fine because the ZoomConstraintsClient code will flip it back
to false based on the width of the CSS viewport. Setting it to true in the
GetViewportInfo code allows us to maintain the invariant that the default value
of allowDoubleTapToZoom is the same as the initial value of allowZoom.
--HG--
extra : commitid : JVnPDtrwQsq
This patch gives ns{I,}Document the ability to track use counters and
also to send those to telemetry at document destruction time. We push
things to telemetry lazily because we're can't definitively say whether
something has been used until the document is torn down.
The bulk of this commit was generated by running:
run-clang-tidy.py \
-checks='-*,llvm-namespace-comment' \
-header-filter=^/.../mozilla-central/.* \
-fix