Bug 999349 - Add "DO NOT USE" annotation to nsIPlatformCharset. r=emk
authorHenri Sivonen <hsivonen@hsivonen.fi>
Tue, 22 Apr 2014 12:35:44 +0300
changeset 198269 1e0f8b517b86e3fe3775edc3df05ea8fe49cf9b3
parent 198268 a7289f22cafd1a4290fde3e8bb613030b3bff4f6
child 198270 5d418a48ba48c527595ff82cbd294f03c8bc778c
push id3624
push userasasaki@mozilla.com
push dateMon, 09 Jun 2014 21:49:01 +0000
treeherdermozilla-beta@b1a5da15899a [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersemk
bugs999349
milestone31.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 999349 - Add "DO NOT USE" annotation to nsIPlatformCharset. r=emk
content/base/src/nsDOMFile.cpp
dom/file/ArchiveZipEvent.cpp
dom/workers/RuntimeService.cpp
intl/locale/public/nsIPlatformCharset.h
--- a/content/base/src/nsDOMFile.cpp
+++ b/content/base/src/nsDOMFile.cpp
@@ -15,17 +15,16 @@
 #include "nsIClassInfo.h"
 #include "nsIConverterInputStream.h"
 #include "nsIDocument.h"
 #include "nsIFileStreams.h"
 #include "nsIInputStream.h"
 #include "nsIIPCSerializableInputStream.h"
 #include "nsIMemoryReporter.h"
 #include "nsIMIMEService.h"
-#include "nsIPlatformCharset.h"
 #include "nsISeekableStream.h"
 #include "nsIUnicharInputStream.h"
 #include "nsIUnicodeDecoder.h"
 #include "nsNetCID.h"
 #include "nsNetUtil.h"
 #include "nsIUUIDGenerator.h"
 #include "nsHostObjectProtocolHandler.h"
 #include "nsStringStream.h"
--- a/dom/file/ArchiveZipEvent.cpp
+++ b/dom/file/ArchiveZipEvent.cpp
@@ -3,18 +3,16 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this file,
  * You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "ArchiveZipEvent.h"
 #include "ArchiveZipFile.h"
 
 #include "nsContentUtils.h"
-#include "nsIPlatformCharset.h"
-#include "nsNativeCharsetUtils.h"
 #include "nsCExternalHandlerService.h"
 
 using namespace mozilla::dom;
 
 USING_FILE_NAMESPACE
 
 #ifndef PATH_MAX
 #  define PATH_MAX 65536 // The filename length is stored in 2 bytes
--- a/dom/workers/RuntimeService.cpp
+++ b/dom/workers/RuntimeService.cpp
@@ -7,17 +7,16 @@
 #include "RuntimeService.h"
 
 #include "nsIChannel.h"
 #include "nsIContentSecurityPolicy.h"
 #include "nsIDocument.h"
 #include "nsIDOMChromeWindow.h"
 #include "nsIEffectiveTLDService.h"
 #include "nsIObserverService.h"
-#include "nsIPlatformCharset.h"
 #include "nsIPrincipal.h"
 #include "nsIScriptContext.h"
 #include "nsIScriptSecurityManager.h"
 #include "nsISupportsPriority.h"
 #include "nsITimer.h"
 #include "nsIURI.h"
 #include "nsPIDOMWindow.h"
 
--- a/intl/locale/public/nsIPlatformCharset.h
+++ b/intl/locale/public/nsIPlatformCharset.h
@@ -29,16 +29,23 @@ typedef enum {
      kPlatformCharsetSel_Menu = 2,
      kPlatformCharsetSel_4xBookmarkFile = 3,
      kPlatformCharsetSel_KeyboardInput = 4,
      kPlatformCharsetSel_WindowManager = 5,
      kPlatformCharsetSel_4xPrefsJS = 6,
      kPlatformCharsetSel_PlainTextInFile = 7
 } nsPlatformCharsetSel;
 
+/**
+ * DO NOT ADD NEW USES OF THIS INTERFACE!
+ * Removal is https://bugzilla.mozilla.org/show_bug.cgi?id=943272
+ *
+ * Instead, use UTF-16 APIs on Windows and UTF-8 APIs everywhere else.
+ * Assume plain text files are UTF-8.
+ */
 class nsIPlatformCharset : public nsISupports
 {
 public:
  
   NS_DECLARE_STATIC_IID_ACCESSOR(NS_IPLATFORMCHARSET_IID)
 
   NS_IMETHOD GetCharset(nsPlatformCharsetSel selector, nsACString& oResult) = 0;