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

85 Коммитов

Автор SHA1 Сообщение Дата
Boris Zbarsky 3f10f5ed57 Bug 1308287 part 1. Change [NeedsSubjectPrincipal] to only do the Maybe thing for interfaces that can be exposed to workers. r=baku
The idea is to not make consumers think about whether the principal exists or
not when the caller knows for sure that it does.

The substantive changes are in dom/bindings, nsHTMLDocument::SetDesignMode, and
around the CanUseStorage bits.  Everything else is pretty mechanical.
2016-10-10 21:07:48 -04:00
Andrea Marchesini 0d3521f59a Bug 1306241 - Use NeedsSubjectPrincipal in dom/html/* - part 1, r=ehsan 2016-10-03 10:34:14 +02:00
Michael Kaply 45150edb90 Bug 209637 - Add support for application/vnd.wap.xhtml+xml. r=bz 2016-09-28 09:48:17 -05:00
Xidorn Quan 2f49a48a09 Bug 1304302 part 10 - Replace all uses of StyleSheetHandle. r=heycam
This commit is generated by the following commands with some minor
manual adjustment:

find . \( -name '*.h' -or -name '*.cpp' \) -not -path './layout/style/StyleSheet*' -exec sed -i -b \
  -e '/^\(#include\|using\)/s/StyleSheetHandle/StyleSheet/g' \
  -e 's/\(mozilla::\)\?StyleSheetHandle::RefPtr/RefPtr<\1StyleSheet>/g' \
  -e 's/StyleSheetHandle()/nullptr/g' \
  -e 's/->AsStyleSheet()//g' \
  -e 's/StyleSheetHandle/StyleSheet*/g' {} +
sed -i -b 's/sheet->AsVoidPtr()/sheet.get()/' layout/style/Loader.cpp
sed -i -b 's/AsHandle()/this/' layout/style/StyleSheet.cpp

MozReview-Commit-ID: 7abdvlKHukd

--HG--
extra : source : e5682242db07203b5a91810fe1e243c955310588
2016-09-26 22:03:25 +10:00
Michael Layzell e12728495c Bug 1018486 - Part 9: Changes to account for modifications to clang plugin, r=ehsan
MozReview-Commit-ID: EPQMbfHYxUK
2016-09-07 10:50:47 -04:00
Nicholas Nethercote b71747b2ac Bug 1299727 - Rename NS_WARN_IF_FALSE as NS_WARNING_ASSERTION. r=erahm.
The new name makes the sense of the condition much clearer. E.g. compare:

  NS_WARN_IF_FALSE(!rv.Failed());

with:

  NS_WARNING_ASSERTION(!rv.Failed());

The new name also makes it clearer that it only has effect in debug builds,
because that's standard for assertions.

--HG--
extra : rebase_source : 886e57a9e433e0cb6ed635cc075b34b7ebf81853
2016-09-01 15:01:16 +10:00
Nicholas Nethercote c94421bf7c Bug 1297961 (part 2) - Use nsIURI::GetSpecOrDefault() for comparisons to fixed URIs. r=hurley.
--HG--
extra : rebase_source : c742ded3ca4ff6ddf745cf8d720261624f172027
2016-08-26 16:02:32 +10:00
Nicholas Nethercote 742fc7eb48 Bug 1297961 (part 1) - Introduce nsURI::GetSpecOrDefault(). r=hurley.
This function is an infallible alternative to nsIURI::GetSpec(). It's useful
when it's appropriate to handle a GetSpec() failure with a failure string, e.g.
for log/warning/error messages. It allows code like this:

  nsAutoCString spec;
  uri->GetSpec(spec);
  printf("uri: %s", spec.get());

to be changed to this:

  printf("uri: %s", uri->GetSpecOrDefault().get());

This introduces a slight behavioural change. Previously, if GetSpec() failed,
an empty string would be used here. Now, "[nsIURI::GetSpec failed]" will be
produced instead. In most cases this failure string will make for a clearer
log/warning/error message than the empty string.
* * *
Bug 1297961 (part 1b) - More GetSpecOrDefault() additions. r=hurley.

I will fold this into part 1 before landing.

--HG--
extra : rebase_source : ddc19a5624354ac098be019ca13cc24b99b80ddc
2016-08-26 16:02:31 +10:00
Aryeh Gregor f6c34fc75b Bug 748308 - Support insertParagraph and insertLineBreak per spec/Blink/WebKit; r=masayuki
Previously we supported insertParagraph as a synonym for formatBlock
"p", which is both useless and incompatible with all other browsers.
Edge's behavior doesn't look useful and looks redundant with insertHTML
(although it matches the name nicely, probably because they invented
the command).  Blink/WebKit treat it the same as hitting Enter, which is
useful for cross-browser testing until we get synthesizeKey() in wpt.

At the same time, I added insertLineBreak, which Blink/WebKit support
with the same functionality as pressing Shift-Enter.

The new event.html failures are spurious -- we used to pass by mistake
because we didn't support insertlinebreak at all.  insertlinebreak.html
has only new passes, no new failures, although it's not clear on the
diff.

MozReview-Commit-ID: 16oPcxXwGcj
2016-08-23 14:13:17 +03:00
Dragana Damjanovic 67635a6600 Bug 1295636 - SetHostPort should reset the port if the host parameter does not have a port number. r=valentin, r=smaug
--HG--
extra : rebase_source : 2e63afd5708c55810206f9bc47b6f078a0824400
2016-08-17 23:25:00 -04:00
Dragana Damjanovic aaec45b427 Bug 1292522 - Fix regression from bug 409885. r=smaug
--HG--
extra : rebase_source : d82d3cd162ce722254a205df1cd116ca195335e5
2016-08-16 09:44:00 -04:00
Nicholas Nethercote e7f10a07fd Bug 1293603 (part 2) - Make Run() declarations consistent. r=erahm.
This patch makes most Run() declarations in subclasses of nsIRunnable have the
same form: |NS_IMETHOD Run() override|.

As a result of these changes, I had to add |override| to a couple of other
functions to satisfy clang's -Winconsistent-missing-override warning.

--HG--
extra : rebase_source : 815d0018b0b13329bb5698c410f500dddcc3ee12
2016-08-08 12:18:10 +10:00
Boris Zbarsky 5b840d9b96 Bug 1288791 part 2. Rename WrapNativeParent to FindAssociatedGlobal and update it to actually do that. r=bkelly 2016-07-27 11:05:36 -04:00
Chris Peterson b175c9fdd5 Bug 1277106 - Part 2: Expand MOZ_UTF16() strings to u"" string literals. r=Waldo 2016-07-20 22:03:25 -07:00
Boris Zbarsky 2b85094faf Bug 909633. Remove the HTML Microdata API, since no one else ended up implementing it and now it's been removed from the spec. r=bkelly,jgraham 2016-05-20 23:13:17 -04:00
Trevor Saunders 256fff4fc9 bug 1271436 - add nsIDocShell::GetCommandManager() r=smaug 2016-05-17 18:16:07 -04:00
Boris Zbarsky 59de5a530f Bug 1270349 part 5. Use LegacyUnenumerableNamedProperties instead of passing flags to GetSupportedNames to determine whether named props on DOM proxies should be reflected in ownPropertyKeys. r=peterv 2016-05-09 22:25:40 -04:00
Boris Zbarsky 76180fb5a7 Bug 1270349 part 4. Use LegacyUnenumerableNamedProperties instead of NameIsEnumerable() calls to determine whether named props on DOM proxies should be enumerable. r=peterv 2016-05-09 22:25:40 -04:00
Kyle Huey 941ab1f522 Bug 1268313: Part 7 - Move NS_NewRunnableMethod and friends to mozilla::NewRunnableMethod. r=froydnj 2016-05-05 01:45:00 -07:00
Carsten "Tomcat" Book ba3fe0975c Backed out changeset 85ce8cb0639a (bug 1268313)
--HG--
extra : rebase_source : 56d1cf41a2dc4959b67f834e07192a5c772176a8
2016-04-29 14:21:16 +02:00
Kyle Huey 48a594a09e Bug 1268313: Part 7 - Move NS_NewRunnableMethod and friends to mozilla::NewRunnableMethod. r=froydnj 2016-04-28 14:08:25 -07:00
Kyle Huey c73656947b Bug 1265927: Move nsRunnable to mozilla::Runnable, CancelableRunnable to mozilla::CancelableRunnable. r=froydnj 2016-04-25 17:23:21 -07:00
L. David Baron b1db407049 Bug 1265591 patch 2 - Rename nsIPresShell::ReconstructStyleData to RestyleForCSSRuleChanges. r=heycam
MozReview-Commit-ID: BU3X0fBEKE3
2016-04-19 11:38:35 -07:00
Jonathan Watt fb7bb15e68 Bug 1263782 - Kill off the deprecated nsINode::IsInDoc(). r=baku 2016-03-31 11:58:25 +01:00
Nicholas Nethercote d376f9f82e Bug 1260871 - Remove do_GetAtom() and rename NS_NewAtom() as NS_Atomize(). r=erahm.
do_GetAtom() is currently just a synonym for NS_NewAtom().

--HG--
extra : rebase_source : f4409784f931616cbc300591e6b843d30805c273
2016-03-29 10:09:43 +11:00
Dragana Damjanovic dd.mozilla@gmail.com f049188b1b Bug 409885 - Use SetHostPort in nsHTMLDocument::SetDomain. r=bz 2016-03-24 02:14:00 +01:00
Trevor Saunders 2c05850952 bug 1257287 - add nsIDocShell::GetEdItingSession() 2016-03-18 15:54:07 -04:00
Christoph Kerschbaumer f29ec8d62f Bug 1254689 - Remove SEC_NORMAL where loadingPrincipal is SystemPrincipal or NullPrincipal. r=sicking 2016-03-09 13:55:59 -08:00
Wes Kocher 817d8829fc Backed out changeset 7cbab9ec76d5 (bug 1254689) for browser_dbg_addon-sources.js failures
MozReview-Commit-ID: 3zPliH7mmPj

--HG--
extra : rebase_source : 90a6c96c2106ec23043160ed93041cd7e15b1640
2016-03-09 10:56:23 -08:00
Christoph Kerschbaumer 007c074be0 Bug 1254689 - Remove SEC_NORMAL where loadingPrincipal is SystemPrincipal or NullPrincipal (r=sicking)
MozReview-Commit-ID: LKK3MGMODNI
2016-03-09 09:01:45 -08:00
Cameron McCormack 0ecd5593cc Bug 1244074 - Part 4: Use StyleSheetHandle instead of concrete style sheet class in most places. r=dholbert 2016-02-24 18:01:12 +11:00
Cameron McCormack 7c95c39734 Bug 1244068 - Part 4: Use StyleSetHandle instead of concrete style set class in most places. r=dholbert 2016-02-24 18:01:11 +11:00
Andrew McCreight 11fea9d072 Bug 1249377 - Hold a strong reference to |root| in nsHTMLDocument::SetBody. r=bz 2016-02-19 06:26:07 -08:00
Valentin Gosu 35e6e18584 Bug 583170 - Handling IPv6 literal address differently to other browsers r=bz 2016-02-10 13:13:00 +01:00
Kyle Huey 91efc5a86c Bug 1241764: Replace nsPIDOMWindow with nsPIDOMWindowInner/Outer. r=mrbkap,smaug 2016-01-30 09:05:36 -08:00
Nicholas Nethercote 5721b2ad2e Bug 1232852 (part 5) - Remove some unused parameters in and around layout/base/. r=heycam.
--HG--
extra : rebase_source : 3f114d32650a260fe2eda847f24c2967a9d94185
2016-01-05 16:08:17 -08:00
Cameron McCormack fd2fba0c73 Bug 990250 - Fold nsIStyleSheet into CSSStyleSheet. r=dbaron 2015-11-17 17:04:09 +11:00
Michael Layzell 9b275dd822 Bug 1223041 - Emit console warning when document.execCommand('copy'/'cut') is triggered outside of a short-lived user-initiated event, r=bz 2015-11-12 09:36:42 -05:00
Bill McCloskey 4f99faeaed Bug 967873 - Proxy nsDocumentViewer::PermitUnload to the child process (r=Gijs) 2015-11-11 18:04:21 -08:00
Jonathan Watt 75eee57062 Bug 1220827 - Replace question comment in nsHTMLDocument::Open with an explanatory comment to explain why we create a new Window. r=smaug 2015-10-05 18:34:46 +01:00
Jonathan Watt b2cd535c73 Bug 1220599 - Fix erroneous nsHTMLDocument::Open comment to note that we reuse the document rather than creating a new one. r=baku 2015-09-23 11:12:24 +01:00
Birunthan Mohanathas 44936aabb2 Bug 1217320 - Remove more XPIDL signature comments in .cpp files. r=froydnj
Comment-only, DONTBUILD.
2015-10-27 06:54:25 +02: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
Boris Zbarsky 04e8705012 Backing out changeset f6759ed53f46 (bug 799937) due to causing extension breakage. 2015-10-14 11:07:06 -04:00
Aryeh Gregor f8cdabf861 Bug 799937 - Make createElement()'s result always in the HTML namespace (except for XUL documents); r=bz
The new expected failures in web-platform are in a test that doesn't
match the spec, which has already been synced upstream and will be
synced shortly.  For the same test in imptests, I chose to modify the
test instead, because it's easier and imptests is going to be removed.
2015-10-14 11:16:08 +05:30
Bill McCloskey c5d5457154 Back out bug 967873 - Proxy nsDocumentViewer::PermitUnload to the child process 2015-10-07 11:15:11 -07:00
Ehsan Akhgari 158253749d Bug 1210302 - Part 3: Add a NS_ParseRequestContentType API; r=mcmanus,sicking 2015-10-06 20:26:46 -04:00
Bill McCloskey 207404ad2d Bug 967873 - Proxy nsDocumentViewer::PermitUnload to the child process (r=Gijs) 2015-10-01 21:18:48 -07:00
Bobby Holley 110f12e7ca Bug 1072150 - Use the opt-out for various sloppy consumers. r=bz 2015-09-24 14:02:41 -07:00
Birunthan Mohanathas 7315345693 Bug 1191100 - Remove XPIDL signature comments in .cpp files. r=ehsan
Comment-only so DONTBUILD.
2015-08-04 16:17:36 -07:00