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

1025 Коммитов

Автор SHA1 Сообщение Дата
Nicholas Nethercote d4f9aa5530 Bug 1384835 (part 2, attempt 2) - Remove the Preferences::Get*String() variants that return nsAdoptingString. r=froydnj.
--HG--
extra : rebase_source : 6c24fbacb03d4adebe5f22b5e7fc60b069913f20
2017-07-31 14:23:50 +10:00
Sebastian Hengst 1d708511f0 Backed out changeset 5df4d8778602 (bug 1384835) 2017-07-28 10:29:29 +02:00
Nicholas Nethercote 0574a6b496 Bug 1384835 (part 2) - Remove the Preferences::Get*String() variants that return nsAdoptingString. r=froydnj.
Because we want to remove nsAdoptingString. We have other variants that don't
use nsAdoptingString, which can be used instead. There are three basic
patterns.

1. The easiest case is when we don't check for success.

> nsAdoptingString s = Preferences::GetString("foo");
> foo(s);

becomes:

> nsAutoString s;
> Preferences::GetString("foo", s);
> foo(s);

2. The next case is when we check if the result is empty.

> nsAdoptingString s = Preferences::GetString("foo");
> if (s.IsEmpty()) { ... }

becomes:

> nsAutoString s;
> Preferences::GetString("foo", s);
> if (s.IsEmpty()) { ... }

3. The final case is when we null check the result.

> nsAdoptingString s = Preferences::GetString("foo");
> if (s) { ... }

becomes:

> nsAutoString s;
> nsresult rv = Preferences::GetString("foo", s);
> if (NS_SUCCEEDED(rv)) { ... }

The patch also avoids some UTF8/UTF16 conversions in a few places.

--HG--
extra : rebase_source : f339b1a3dda4dc93979d38c30c001fbe77485b55
2017-07-25 20:36:14 +10:00
Julian Seward 408d24da56 Bug 1382563 - Remove ns*String::AssignWithConversion. r=erahm.
This patch replaces four functions of the name AssignWithConversion which
are essentially wrappers around CopyASCIItoUTF16 and LossyCopyUTF16toASCII
with direct calls to the latter two functions.  The replaced functions are:

  void nsCString::AssignWithConversion( const nsAString& aData )
  void nsString::AssignWithConversion( const nsACString& aData )

  void nsTString_CharT::AssignWithConversion(
                            const incompatible_char_type* aData,
                            int32_t aLength = -1);

The last of the three exists inside the double-included nsTString* world and
so describes two functions, giving four in total.

This has two advantages:

* it removes code

* at the call points, it makes clear (from the replacement name) which
  conversion is being carried out.  The generic name "AssignWithConversion"
  doesn't make that obvious -- one had to infer it from the types.

The patch also removes two commented out lines from
editor/composer/nsComposerCommands.cpp, that appear to be related.  They are
at top level, where they would never have compiled.  They look like
leftovers from some previous change.

--HG--
extra : rebase_source : fb47bf450771c3c9ee3341dd14520f5da69ec4f5
2017-07-24 19:23:52 +02:00
Bevis Tseng 95b18d794e Bug 1382172 - Name nsITimerCallback instances in native implementation. r=billm
--HG--
extra : rebase_source : 84de1abfcc30a6964144c2e6718a508c71027b65
2017-07-27 02:18:20 +08:00
Bevis Tseng a7505864a8 Bug 1378930 - Part 2: Remove the aName parameter from SchedulerGroup/DocGroup/DispatcherTrait. r=billm
--HG--
extra : rebase_source : 11319e568a51d16754a6a9990f76c35c86c2bda7
2017-07-26 16:13:35 +08:00
Bill McCloskey f115503a0b Bug 1372405 - Provide names for all runnables in the tree (r=froydnj)
MozReview-Commit-ID: DKR6ROiHRS7
2017-06-26 14:19:58 -07:00
Nicholas Nethercote fe9268c4cd Bug 1374580 (part 2) - Remove nsAFlat{,C}String typedefs. r=froydnj.
All the instances are converted as follows.

- nsAFlatString  --> nsString
- nsAFlatCString --> nsCString

--HG--
extra : rebase_source : b37350642c58a85a08363df2e7c610873faa6e41
2017-06-20 19:19:05 +10:00
Florian Quèze 66f6d259bc Bug 1374282 - script generated patch to remove Task.jsm calls, r=Mossop. 2017-06-22 12:51:42 +02:00
Bill McCloskey 0767e31489 Bug 1372736 - Avoid using AbstractThread for non-media MozPromises (r=bkelly)
MozReview-Commit-ID: BBi0pK4DXxf
2017-06-15 20:16:25 -07:00
Bill McCloskey c85ab6308c Bug 1366072 - Change promises to take nsISerialEventTarget instead of AbstractThread (r=jwwang)
MozReview-Commit-ID: 4azUhSB6whu
2017-06-13 14:51:01 -07:00
Makoto Kato ce6328824f Bug 1365383 - Spellchecker should consider that callback isn't set. r=masayuki
InitSpellChecker allows that 3rd callback parameter is null.  We should consider that it is null.

MozReview-Commit-ID: BMAM6BiYlw5

--HG--
extra : rebase_source : fbe767694d6380988854ff133b780b8fe334bf3a
2017-05-18 14:50:25 +09:00
Yoshi Huang df0da41d1c Bug 1361641 - Part 2: convert mochitest plain tests in editor/ to use srcdoc. r=smaug 2017-05-09 10:25:23 +08:00
Christoph Kerschbaumer 7711007990 Bug 1359092 - Extend loadURI within nsIWebNavigation.idl by a triggeringPrincipal argument. r=bz 2017-04-25 12:22:25 +02:00
Carsten "Tomcat" Book 1fa6c5a322 Backed out changeset 3e42f84996ea (bug 1359092) for causing assertion failures 2017-04-25 10:46:31 +02:00
Christoph Kerschbaumer 10ba7f4ab5 Bug 1359092 - Extend loadURI within nsIWebNavigation.idl by a triggeringPrincipal argument. r=bz 2017-04-24 21:57:25 +02:00
Xidorn Quan d8c29760a1 Bug 1355734 - Remove text-decoration-line: -moz-anchor-decoration. r=heycam,masayuki
MozReview-Commit-ID: 4TmVncV1K5G

--HG--
extra : rebase_source : 568218d415642f1088c82d4b2e03d5885067b162
2017-04-13 16:17:03 +08:00
Makoto Kato a8f8cbc728 Bug 1056322 - Don't run DictionaryFetcher when spllchecker isn't initialized. r=masayuki
When CanSpellCheck isn't called yet, mSpellChecker won't be initialized.  So we should check it before running DictionaryFetcher.

I think that UpdateCurrentDictionary is called by OnFocus as long as nsEditorSpellCheck::InitSpellChecker isn't called.  But I cannot find test case to reproduce this...

MozReview-Commit-ID: 5H1pJ0AnX5X

--HG--
extra : rebase_source : 5f2a59261c67a7f8f363588c7596e68f6debff9e
2017-04-12 17:43:51 +09:00
Makoto Kato 694268f807 Bug 1330912 - Part 2. Use async version on UpdateCurrentDictionary. r=masayuki
Now, mozInlineSpellChecker::UpdateCurrentDictionary will use sync IPC messages via nsEditorSpellCheck::DictionaryFetched.

Part 1 adds async API to set current dictionary.  So we should use it on nsEditorSpellCheck::DictionaryFetched instead of sync API.

MozReview-Commit-ID: 5gl2eQpzKm1

--HG--
extra : rebase_source : 1fabc4abdd170494f1804ad875a181e652ea66a0
2017-04-11 17:05:19 +09:00
Aryeh Gregor c442eea5f2 Bug 1297414 - Support execCommand("defaultParagraphSeparator"); r=masayuki
Later commits will add the actual functionality.

MozReview-Commit-ID: 6Ac9V6MjZpa
2017-04-04 13:47:28 +03:00
Makoto Kato cd753d1158 Bug 1351074 - Part 2. Use testing-common for AsyncSpellCheckTestHelper.jsm. r=masayuki
TESTING_JS_MODULES uses testing-common, not gre.  So we should replace gre with testing-common for mochitest.

MozReview-Commit-ID: BqsS2D3IGR6

--HG--
extra : rebase_source : a8553684f8f106c1dfb6e2d9b51df7ebeb15275d
2017-03-29 15:34:49 +09:00
Phil Ringnalda 7ac3bd5b7e Backed out 3 changesets (bug 1351074) for reftest harness and browser_all_files_referenced.js bustage
CLOSED TREE

Backed out changeset 941e0f9ff9a7 (bug 1351074)
Backed out changeset 4fdf3b87a70b (bug 1351074)
Backed out changeset 586428f69838 (bug 1351074)
2017-04-02 19:46:49 -07:00
Makoto Kato cd8761e0f4 Bug 1351074 - Part 2. Use testing-common for AsyncSpellCheckTestHelper.jsm. r=masayuki
TESTING_JS_MODULES uses testing-common, not gre.  So we should replace gre with testing-common for mochitest.

MozReview-Commit-ID: BqsS2D3IGR6

--HG--
extra : rebase_source : 2143fcdf33c428c82c6b2e00b542649b958aeccc
2017-03-29 15:34:49 +09:00
Olli Pettay 93e93a4e02 Bug 1350926, label a runnable in editor, r=masayuki 2017-03-29 14:43:28 -04:00
Zibi Braniecki 3d91da8726 Bug 1347314 - Migrate calls to ChromeRegistry::GetSelectedLocale to use LocaleService::GetAppLocale. r=jfkthame,Pike
In cases, where the caller is looking for the locale to be used for JS Intl API,
we can now replace it with `undefined` which causes JS Intl API to use the default
locale which since bug 1346674 is resolved to the app locale.

This allows us to remove a lot of calls for the app locale.

The remaining ones are split between `AsBCP47` and `AsLangTag`.
Here, the `AsLangTag` is used, as described in the API docs, for cases where
the language string is used for localization purposes, such as language negotaition
matching to our language resources etc.
`AsBCP47` is used when the returned value is handed over to ICU API.

MozReview-Commit-ID: DzmFEUvMq3N

--HG--
extra : rebase_source : 513ed31d995864939aa893e73c81ffdf591a6617
2017-03-14 16:09:54 -07:00
Sebastian Hengst 0a04f3b9e2 Backed out changeset cc308a73ad05 (bug 1347314) for eslint failure in test_device.html. r=backout 2017-03-22 18:20:26 +01:00
Zibi Braniecki c2cd68a689 Bug 1347314 - Migrate calls to ChromeRegistry::GetSelectedLocale to use LocaleService::GetAppLocale. r=jfkthame,Pike
In cases, where the caller is looking for the locale to be used for JS Intl API,
we can now replace it with `undefined` which causes JS Intl API to use the default
locale which since bug 1346674 is resolved to the app locale.

This allows us to remove a lot of calls for the app locale.

The remaining ones are split between `AsBCP47` and `AsLangTag`.
Here, the `AsLangTag` is used, as described in the API docs, for cases where
the language string is used for localization purposes, such as language negotaition
matching to our language resources etc.
`AsBCP47` is used when the returned value is handed over to ICU API.

MozReview-Commit-ID: DzmFEUvMq3N

--HG--
extra : rebase_source : 13fa4c397ba4c79303a2cd76684b5b8c4bd17331
2017-03-14 16:09:54 -07:00
David Major ed12ea611f Bug 1346078: Remove nsAString_internal and just use the nsAString name directly. r=bsmedberg
MozReview-Commit-ID: DWDEDMIVKm7

--HG--
extra : rebase_source : 7fe8dc07c816dca234c67761e61cdee372a87e97
2017-03-10 15:17:23 +13:00
Florian Quèze 9d62681259 Bug 1345253 - Use element.firstChild.remove() instead of element.removeChild(element.firstChild), r=jaws. 2017-03-08 10:17:52 +01:00
Masatoshi Kimura 7be7b11a1c Bug 1342144 - Remove version parameter from the type attribute of script elements. r=jmaher
This patch is generated by the following sed script:
find . ! -wholename '*/.hg*' -type f \( -iname '*.html' -o -iname '*.xhtml' -o -iname '*.xul' -o -iname '*.js' \) -exec sed -i -e 's/\(\(text\|application\)\/javascript\);version=1.[0-9]/\1/g' {} \;

MozReview-Commit-ID: AzhtdwJwVNg

--HG--
extra : rebase_source : e8f90249454c0779d926f87777f457352961748d
2017-02-23 06:10:07 +09:00
Florian Quèze 0e0865f4fc Bug 1331599 - script-generated patch to replace removeEventListener calls with the once option when possible, r=jaws. 2017-01-25 07:01:52 +01:00
Florian Quèze 85611a7b6d Bug 1331081 - script generated patch to omit addEventListener/removeEventListener's third parameter when it's false, r=jaws.
--HG--
extra : rebase_source : a22344ee1569f58f1f0a01017bfe0d46a6a14602
2017-01-17 11:50:25 +01:00
Cameron McCormack babad063ff Bug 1328832 - Part 2: Rename mozFlushType to mozilla::FlushType and make it an enum class. r=bzbarsky
MozReview-Commit-ID: D3fIngSHSsl
2017-01-05 15:31:56 +08:00
Cameron McCormack ce51bd51e0 Bug 1328832 - Part 1: Rename mozFlushType.h to FlushType.h. r=bzbarsky
MozReview-Commit-ID: 1ubwNkBEdfz

--HG--
rename : dom/base/mozFlushType.h => dom/base/FlushType.h
2017-01-05 14:54:02 +08:00
Gijs Kruitbosch cb6c0c81ac Bug 1322414 - part 2,3,4: use a separate 'primary' attribute for primary child browsers, r=bz,mconley
MozReview-Commit-ID: 2yb0WGFYBsH

--HG--
extra : rebase_source : 376171077c577e41e82cec5e994c425c6d9f2d80
extra : histedit_source : 39aad91381749a263042cd0452fe32019a1974b8
2016-12-09 09:23:24 -10:00
Gerald Squelart 0affeb4ab0 Bug 1316432 - Fix nsCOMPtr constructions&assignments from 0 - r=froydnj
Giving '0' (literal zero) to nsCOMPtr is now ambiguous, as both
nsCOMPtr(decltype(nullptr)) and nsCOMPtr(T*) could be used.
In any case, our coding standards mandate the use of 'nullptr' for pointers.
So I'm changing all zeroes into nullptr's where necessary.

MozReview-Commit-ID: LXiZTu87Ck6

--HG--
extra : rebase_source : f9dcc6b06e9ebf9c30a576f9319f76a51b6dc26f
2016-11-10 14:11:27 +11:00
Sebastian Hengst eb26ee2f07 Bug 1310297 - Remove test annotations using b2g, mulet or gonk: editor. r=RyanVM
MozReview-Commit-ID: GDieTLdlpRH

--HG--
extra : rebase_source : 8332d4abdea9d0ad27ad7cceace96ad75aff6b2c
2016-11-05 11:29:19 +01:00
Aryeh Gregor 9fc7d0745c Bug 1271120 - Port test_bug1219928.html from chrome to plain; r=masayuki
This test still doesn't work in e10s, though.  mrbkap says further
debugging is needed (bug 1269209 comment 3).

MozReview-Commit-ID: 3iHNkQVYQMn
2016-09-01 17:15:28 +03:00
Aryeh Gregor f00c374e3b Bug 1271120 - Port test_bug1209414.html from chrome to plain; r=masayuki
MozReview-Commit-ID: ExX9ZNsVaXq
2016-08-23 15:56:23 +03:00
Aryeh Gregor b21c462f2e Bug 1269209 - Port test_bug1205983.html from chrome to plain; r=masayuki
MozReview-Commit-ID: FPFRvbOftw4
2016-10-31 18:09:37 +02:00
Aryeh Gregor 225ac7af74 Bug 1269209 - Port test_bug1200533.html from chrome to plain; r=masayuki
MozReview-Commit-ID: 2CrI1aTjaYJ
2016-08-22 21:07:52 +03:00
Aryeh Gregor 5aea5b7b05 Bug 1269209 - Port test_bug1204147.html from chrome to plain; r=masayuki
MozReview-Commit-ID: KBeFI73j1Jx
2016-08-22 21:06:41 +03:00
Aryeh Gregor 29cf33b800 Bug 1269209 - Port test_bug717433.html from chrome to plain; r=masayuki
MozReview-Commit-ID: 426kBYZCCWy
2016-10-31 18:08:42 +02:00
Aryeh Gregor 75524f3039 Bug 1269209 - Port test_bug697981.html from chrome to plain; r=masayuki
MozReview-Commit-ID: IrnlEWhIBzk
2016-10-31 18:08:13 +02:00
Aryeh Gregor 45101741a1 Bug 1269209 - Port test_bug678842.html from chrome to plain; r=masayuki
MozReview-Commit-ID: LUSLjnMYl1I
2016-08-22 21:03:23 +03:00
Aryeh Gregor e98e939603 Bug 1269209 - Port test_bug338427.html from chrome to plain; r=masayuki
MozReview-Commit-ID: HiDXAKaZlQA
2016-10-31 18:06:46 +02:00
Aryeh Gregor 6dc53c6bec Bug 1269209 - Port test_async_UpdateCurrentDictionary.html from chrome to plain; r=masayuki
MozReview-Commit-ID: 3dneNqKrYCe
2016-08-22 21:00:48 +03:00
Jonathan Kew e007b6ec83 Bug 1301655 - pt 0 - Add an optional parameter to nsIChromeRegistry.getSelectedLocale to allow callers to request the locale be returned as a valid BCP47 lang tag. r=gandalf 2016-10-28 12:04:06 +01:00
Sebastian Hengst 8873da9713 Backed out changeset c7d8d25e09b6 (bug 1269209)
MozReview-Commit-ID: KivGNRxiRDu
2016-10-28 00:38:50 +02:00
Sebastian Hengst 1a5704fe4d Backed out changeset 5d2f4867ec7f (bug 1269209)
MozReview-Commit-ID: IX1osGGXxnp
2016-10-28 00:38:46 +02:00