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

25 Коммитов

Автор SHA1 Сообщение Дата
Nicholas Nethercote d225f7151b Bug 1400460 - Rename nsIAtom as nsAtom. r=hiro.
(Path is actually r=froydnj.)

Bug 1400459 devirtualized nsIAtom so that it is no longer a subclass of
nsISupports. This means that nsAtom is now a better name for it than nsIAtom.

MozReview-Commit-ID: 91U22X2NydP

--HG--
rename : xpcom/ds/nsIAtom.h => xpcom/ds/nsAtom.h
extra : rebase_source : ac3e904a21b8b48e74534fff964f1623ee937c67
2017-10-03 09:05:19 +11:00
Nicholas Nethercote dfd3b7e7aa Bug 1400459 (part 2) - Devirtualize nsIAtom. r=heycam.
This patch merges nsAtom into nsIAtom. For the moment, both names can be used
interchangeably due to a typedef. The patch also devirtualizes nsIAtom, by
making it not inherit from nsISupports, removing NS_DECL_NSIATOM, and dropping
the use of NS_IMETHOD_. It also removes nsIAtom's IIDs.

These changes trigger knock-on changes throughout the codebase, changing the
types of lots of things as follows.

- nsCOMPtr<nsIAtom> --> RefPtr<nsIAtom>

- nsCOMArray<nsIAtom> --> nsTArray<RefPtr<nsIAtom>>
  - Count() --> Length()
  - ObjectAt() --> ElementAt()
  - AppendObject() --> AppendElement()
  - RemoveObjectAt() --> RemoveElementAt()

- ns*Hashtable<nsISupportsHashKey, ...> -->
  ns*Hashtable<nsRefPtrHashKey<nsIAtom>, ...>

- nsInterfaceHashtable<T, nsIAtom> --> nsRefPtrHashtable<T, nsIAtom>
  - This requires adding a Get() method to nsRefPtrHashtable that it lacks but
    nsInterfaceHashtable has.

- nsCOMPtr<nsIMutableArray> --> nsTArray<RefPtr<nsIAtom>>
  - nsArrayBase::Create() --> nsTArray()
  - GetLength() --> Length()
  - do_QueryElementAt() --> operator[]

The patch also has some changes to Rust code that manipulates nsIAtom.

MozReview-Commit-ID: DykOl8aEnUJ

--HG--
extra : rebase_source : 254404e318e94b4c93ec8d4081ff0f0fda8aa7d1
2017-09-26 08:33:21 +10:00
Makoto Kato 2a3c054c7b Bug 1394661 - Use user locale instead of system locale for font fallback. r=gandalf
Until Firefox 54, font fallback uses user locale.  Example, OS is Windows 10 JA with JA UI, Firefox uses JA font for fallback even if Firefox is US version.

But since we changed some locale code on Firefox 55 development cycle, there were some regressions such as bug 1346674.  So we changed fallback locale to system locale (instead of Firefox UX locale) for font selection by bug 1348259.

It isn't good for old compatibility, so we should use user locale for font fallback like Firefox 54.  Now we can get user locale by OSPreferences::GetRegionalPrefsLocales, use it for font fallback


MozReview-Commit-ID: 7qwDDeU1ZPt

--HG--
extra : rebase_source : 3a307dd239bea516e117961a944b714bc43a993c
2017-08-30 17:33:12 +09:00
Emilio Cobos Álvarez ff0fdb1a67 Bug 1394311: Use lowercase consistently for looking up the language group. r=manishearth
This should be the only callee affected, given
gfxPlatformFontList::GetFontPrefLangFor already uses case-insensitive string
comparison.

This makes it also consistent with the rest of the functions in the file, which
lowercase their inputs as well.

MozReview-Commit-ID: 4fNUBdpayHL

--HG--
extra : rebase_source : d669f5da2a1ed06f6348fc6b86eb379b514ddcf3
2017-08-28 09:06:11 +02:00
Masatoshi Kimura b515c9c804 Bug 1373984 - Turn nsIDocument::mCharacterSet into mozilla::NotNull<const mozilla::Encoding*>. r=hsivonen
MozReview-Commit-ID: GF0YXDwfA14

--HG--
extra : rebase_source : fdae0046f882d47fb539a7f882364e5c5caafdcd
extra : source : 49249788c0dee331ac2989dc39f0505d965a7bd8
2017-06-18 20:37:50 +09:00
Sebastian Hengst dfc1ad2562 Backed out changeset 7235d05662b0 (bug 1373984) for Android bustage. r=backout on a CLOSED TREE 2017-06-25 18:30:13 +02:00
Masatoshi Kimura 2e04751921 Bug 1373984 - Turn nsIDocument::mCharacterSet into mozilla::NotNull<const mozilla::Encoding*>. r=hsivonen
MozReview-Commit-ID: GF0YXDwfA14

--HG--
extra : rebase_source : a84ab644f52e68676b45f112ff69f868d89f6177
extra : source : 49249788c0dee331ac2989dc39f0505d965a7bd8
2017-06-18 20:37:50 +09:00
Wes Kocher e02435a31e Backed out changeset 77af189b5c49 (bug 1373984) for build bustage in nsHtml5Parser.cpp a=backout CLOSED TREE
MozReview-Commit-ID: 6kBmU71j2To
2017-06-25 05:10:14 -07:00
Masatoshi Kimura 241039fd97 Bug 1373984 - Turn nsIDocument::mCharacterSet into mozilla::NotNull<const mozilla::Encoding*>. r=hsivonen
MozReview-Commit-ID: GF0YXDwfA14

--HG--
extra : rebase_source : 09da1685795583513bf019d61c58230c2c4d298d
extra : source : 49249788c0dee331ac2989dc39f0505d965a7bd8
2017-06-18 20:37:50 +09:00
Masatoshi Kimura 838ccc4108 Bug 1369025 - Remove mozilla::dom::EncodingUtils. r=hsivonen
MozReview-Commit-ID: 5O5WtxbmATQ

--HG--
rename : dom/encoding/encodingsgroups.properties => intl/locale/encodingsgroups.properties
extra : rebase_source : 13143b43ee745b618e05ed1b6991d69781c2767d
2017-06-17 11:54:40 +09:00
Manish Goregaokar e104a8487b Bug 1367619 - Use RWLock when accessing font prefs service off main thread; r=heycam
MozReview-Commit-ID: Dxdq6Etbwxa

--HG--
extra : rebase_source : ec9f847c7dce6a101db6a3d157395f5b73d87ba1
2017-05-25 15:04:13 -07:00
Jonathan Kew b1d22b8fd2 Bug 734008 - DeCOMtaminate nsILanguageAtomService, make it a non-refcounted singleton and clean up various call sites. r=m_kato 2015-04-03 21:39:23 +02:00
Manish Goregaokar bf23cb1d19 Bug 1362599 - Guard against threadsafety issues in lang group stuff. r=heycam 2017-05-20 21:44:37 +02:00
Manish Goregaokar 42199474b9 Bug 1351200 - Part 3: stylo: Bypass cache when fetching font size prefs from Stylo; r=emilio
MozReview-Commit-ID: 7WBduQ6lBTC
2017-04-10 09:18:00 +08:00
Phil Ringnalda 98df36e955 Backed out 3 changesets (bug 1351200) for Windows and static-analysis build bustage
CLOSED TREE

Backed out changeset 1cce9249b4a2 (bug 1351200)
Backed out changeset 792fb55377f5 (bug 1351200)
Backed out changeset 767bee78574c (bug 1351200)
2017-04-09 08:24:54 -07:00
Manish Goregaokar 8bfdb295a6 Bug 1351200 - Part 3: stylo: Bypass cache when fetching font size prefs from Stylo; r=emilio
MozReview-Commit-ID: 7WBduQ6lBTC

--HG--
extra : rebase_source : f3bee21a7d105cad96231aa5bec5660cdbface06
2017-04-04 11:11:27 -07:00
Zibi Braniecki 9a76e90f11 Bug 1348259 - Switch nsLanguageAtomService to use OSPreferences::GetSystemLocale. r=m_kato
MozReview-Commit-ID: DvKbtrpfNJe

--HG--
extra : rebase_source : 7a62729ce4251c7cd046449c84f5072ed66cf7c9
2017-03-21 16:20:07 -07:00
Zibi Braniecki f096c9aab9 Bug 1346674 - Migrate all uses of nsILocaleService::GetApplicationLocale to mozILocaleService::GetAppLocale. r=jfkthame
MozReview-Commit-ID: 2E7mj3yQnxB

--HG--
extra : rebase_source : 97ba5b1738b2f116ec75830ed1b23f279680035e
2017-03-12 20:39:22 -07:00
David Major 773fd87a6b Bug 1338928: Add constexpr to static data under intl/ for better codegen on Windows. r=emk
MozReview-Commit-ID: I47OgjC0K5F
2017-02-15 15:08:31 +13:00
Nicholas Nethercote c8c2a2bc4d Bug 1262324 (part 2) - Introduce nsUConvProp. r=emk.
This patch fixes the hack of using a trio of |const char*| pointers to
represent a property that has two strings and a length.

--HG--
extra : rebase_source : 9f603b768146a78baf9fa2b4096cccfae9f87322
2016-04-06 13:31:38 +10: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
Nicholas Nethercote dfe9948e43 Bug 1255655 - Const-ify k{Unix,Win}Charsets and kLangGroups. r=smontagu.
--HG--
extra : rebase_source : 178ec56c7c10747b4bf7eac7cf9982fa95ee80f0
2016-03-11 12:58:17 +11:00
Birunthan Mohanathas 73081c85f0 Bug 1005863 - Part 1: Use props2arrays for langGroups.properties. r=hsivonen 2015-01-14 07:30:49 +02:00
Jonathan Kew d0f999a115 Bug 1104589 - Improve the mapping of lang tags to langGroup codes. r=smontagu 2014-11-26 10:24:16 +00:00
Birunthan Mohanathas aef3149a23 Bug 1038537 - Part 3: Flatten intl/locale/src/ directory. r=smontagu
--HG--
rename : intl/locale/src/Makefile.in => intl/locale/Makefile.in
rename : intl/locale/src/PluralForm.jsm => intl/locale/PluralForm.jsm
rename : intl/locale/src/langGroups.properties => intl/locale/langGroups.properties
rename : intl/locale/src/language.properties => intl/locale/language.properties
rename : intl/locale/src/mac/moz.build => intl/locale/mac/moz.build
rename : intl/locale/src/mac/nsCollationMacUC.cpp => intl/locale/mac/nsCollationMacUC.cpp
rename : intl/locale/src/mac/nsCollationMacUC.h => intl/locale/mac/nsCollationMacUC.h
rename : intl/locale/src/mac/nsDateTimeFormatMac.cpp => intl/locale/mac/nsDateTimeFormatMac.cpp
rename : intl/locale/src/mac/nsDateTimeFormatMac.h => intl/locale/mac/nsDateTimeFormatMac.h
rename : intl/locale/src/mac/nsMacCharset.cpp => intl/locale/mac/nsMacCharset.cpp
rename : intl/locale/src/nsCollation.cpp => intl/locale/nsCollation.cpp
rename : intl/locale/src/nsCollation.h => intl/locale/nsCollation.h
rename : intl/locale/src/nsLanguageAtomService.cpp => intl/locale/nsLanguageAtomService.cpp
rename : intl/locale/src/nsLanguageAtomService.h => intl/locale/nsLanguageAtomService.h
rename : intl/locale/src/nsLocale.cpp => intl/locale/nsLocale.cpp
rename : intl/locale/src/nsLocale.h => intl/locale/nsLocale.h
rename : intl/locale/src/nsLocaleConstructors.h => intl/locale/nsLocaleConstructors.h
rename : intl/locale/src/nsLocaleService.cpp => intl/locale/nsLocaleService.cpp
rename : intl/locale/src/nsPlatformCharset.h => intl/locale/nsPlatformCharset.h
rename : intl/locale/src/nsScriptableDateFormat.cpp => intl/locale/nsScriptableDateFormat.cpp
rename : intl/locale/src/nsUConvPropertySearch.cpp => intl/locale/nsUConvPropertySearch.cpp
rename : intl/locale/src/nsUConvPropertySearch.h => intl/locale/nsUConvPropertySearch.h
rename : intl/locale/src/props2arrays.py => intl/locale/props2arrays.py
rename : intl/locale/src/unix/Makefile.in => intl/locale/unix/Makefile.in
rename : intl/locale/src/unix/moz.build => intl/locale/unix/moz.build
rename : intl/locale/src/unix/nsAndroidCharset.cpp => intl/locale/unix/nsAndroidCharset.cpp
rename : intl/locale/src/unix/nsCollationUnix.cpp => intl/locale/unix/nsCollationUnix.cpp
rename : intl/locale/src/unix/nsCollationUnix.h => intl/locale/unix/nsCollationUnix.h
rename : intl/locale/src/unix/nsDateTimeFormatUnix.cpp => intl/locale/unix/nsDateTimeFormatUnix.cpp
rename : intl/locale/src/unix/nsDateTimeFormatUnix.h => intl/locale/unix/nsDateTimeFormatUnix.h
rename : intl/locale/src/unix/nsPosixLocale.cpp => intl/locale/unix/nsPosixLocale.cpp
rename : intl/locale/src/unix/nsUNIXCharset.cpp => intl/locale/unix/nsUNIXCharset.cpp
rename : intl/locale/src/unix/unixcharset.properties => intl/locale/unix/unixcharset.properties
rename : intl/locale/src/windows/Makefile.in => intl/locale/windows/Makefile.in
rename : intl/locale/src/windows/moz.build => intl/locale/windows/moz.build
rename : intl/locale/src/windows/nsCollationWin.cpp => intl/locale/windows/nsCollationWin.cpp
rename : intl/locale/src/windows/nsCollationWin.h => intl/locale/windows/nsCollationWin.h
rename : intl/locale/src/windows/nsDateTimeFormatWin.cpp => intl/locale/windows/nsDateTimeFormatWin.cpp
rename : intl/locale/src/windows/nsDateTimeFormatWin.h => intl/locale/windows/nsDateTimeFormatWin.h
rename : intl/locale/src/windows/nsWin32Locale.cpp => intl/locale/windows/nsWin32Locale.cpp
rename : intl/locale/src/windows/nsWinCharset.cpp => intl/locale/windows/nsWinCharset.cpp
rename : intl/locale/src/windows/wincharset.properties => intl/locale/windows/wincharset.properties
2014-07-24 10:56:38 -07:00