Bug 1447498 - remove some unneeded includes in mailnews/news. r=jorgk
authoraceman <acelists@atlas.sk>
Tue, 20 Mar 2018 23:40:00 +0100
changeset 30703 cc67b8f8435c6a3f93762e5fd6f28e390711afa9
parent 30702 e2d00a308beb120d38359892518cc5602b71c585
child 30704 5e1cd8191d43ee71693dc35cee3e1496f633f07e
push id2198
push userclokep@gmail.com
push dateMon, 07 May 2018 22:01:28 +0000
treeherdercomm-beta@c31c128cd17a [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjorgk
bugs1447498
Bug 1447498 - remove some unneeded includes in mailnews/news. r=jorgk
mailnews/news/src/nsNNTPNewsgroupList.cpp
mailnews/news/src/nsNNTPProtocol.cpp
mailnews/news/src/nsNNTPProtocol.h
mailnews/news/src/nsNewsDownloader.cpp
mailnews/news/src/nsNewsDownloader.h
mailnews/news/src/nsNewsFolder.cpp
mailnews/news/src/nsNewsFolder.h
mailnews/news/src/nsNntpIncomingServer.cpp
mailnews/news/src/nsNntpIncomingServer.h
mailnews/news/src/nsNntpService.cpp
mailnews/news/src/nsNntpService.h
mailnews/news/src/nsNntpUrl.cpp
--- a/mailnews/news/src/nsNNTPNewsgroupList.cpp
+++ b/mailnews/news/src/nsNNTPNewsgroupList.cpp
@@ -16,24 +16,22 @@
 #include "nsCOMPtr.h"
 #include "nsIDBFolderInfo.h"
 #include "nsINewsDatabase.h"
 #include "nsIMsgStatusFeedback.h"
 #include "nsCOMPtr.h"
 #include "nsPIDOMWindow.h"
 #include "mozIDOMWindow.h"
 #include "nsIMsgMailNewsUrl.h"
-#include "nsIMsgAccountManager.h"
 #include "nsIMsgIncomingServer.h"
 #include "nsINntpIncomingServer.h"
 #include "nsMsgBaseCID.h"
 #include "nsIMsgFilter.h"
 #include "nsNNTPNewsgroupList.h"
 
-#include "nsINNTPArticleList.h"
 #include "nsMsgKeySet.h"
 
 #include "nntpCore.h"
 #include "nsIStringBundle.h"
 
 #include "plstr.h"
 #include "prmem.h"
 #include "prprf.h"
--- a/mailnews/news/src/nsNNTPProtocol.cpp
+++ b/mailnews/news/src/nsNNTPProtocol.cpp
@@ -5,19 +5,17 @@
 
 #include "msgCore.h"    // precompiled header...
 #include "MailNewsTypes.h"
 #include "nntpCore.h"
 #include "nsNetUtil.h"
 #include "nsIMsgMailNewsUrl.h"
 #include "nsIMsgHdr.h"
 #include "nsNNTPProtocol.h"
-#include "nsINNTPArticleList.h"
 #include "nsIOutputStream.h"
-#include "nsIMemory.h"
 #include "nsIPipe.h"
 #include "nsCOMPtr.h"
 #include "nsMsgI18N.h"
 #include "nsINNTPNewsgroupPost.h"
 #include "nsMsgBaseCID.h"
 #include "nsMsgNewsCID.h"
 
 #include "nsINntpUrl.h"
@@ -51,18 +49,16 @@
 
 #include "nsIPrompt.h"
 #include "nsIMsgStatusFeedback.h"
 
 #include "nsIMsgFolder.h"
 #include "nsIMsgNewsFolder.h"
 #include "nsIDocShell.h"
 
-#include "nsIMsgFilterList.h"
-
 // for the memory cache...
 #include "nsICacheEntry.h"
 #include "nsICacheStorage.h"
 #include "nsIApplicationCache.h"
 #include "nsIStreamListener.h"
 #include "nsNetCID.h"
 
 #include "nsIPrefBranch.h"
--- a/mailnews/news/src/nsNNTPProtocol.h
+++ b/mailnews/news/src/nsNNTPProtocol.h
@@ -21,17 +21,16 @@
 #include "nsIMsgNewsFolder.h"
 #include "nsIMsgWindow.h"
 
 #include "nsMsgLineBuffer.h"
 #include "nsIStringBundle.h"
 #include "nsITimer.h"
 #include "nsICacheEntryOpenCallback.h"
 #include "nsIProtocolProxyCallback.h"
-#include "nsIProtocolProxyService.h"
 
 // this is only needed as long as our libmime hack is in place
 #include "prio.h"
 
 // State Flags (Note, I use the word state in terms of storing
 // state information about the connection (authentication, have we sent
 // commands, etc. I do not intend it to refer to protocol state)
 
--- a/mailnews/news/src/nsNewsDownloader.cpp
+++ b/mailnews/news/src/nsNewsDownloader.cpp
@@ -8,29 +8,25 @@
 #include "netCore.h"
 #include "nsIMsgNewsFolder.h"
 #include "nsIStringBundle.h"
 #include "nsNewsDownloader.h"
 #include "nsINntpService.h"
 #include "nsMsgNewsCID.h"
 #include "nsIMsgSearchSession.h"
 #include "nsIMsgSearchTerm.h"
-#include "nsIMsgSearchValidityManager.h"
 #include "nsRDFCID.h"
 #include "nsIMsgAccountManager.h"
 #include "nsMsgFolderFlags.h"
-#include "nsIRequestObserver.h"
 #include "nsIMsgMailSession.h"
 #include "nsMsgMessageFlags.h"
-#include "nsIMsgStatusFeedback.h"
 #include "nsServiceManagerUtils.h"
 #include "nsComponentManagerUtils.h"
 #include "nsMsgUtils.h"
 #include "mozilla/Services.h"
-#include "nsIArray.h"
 #include "nsArrayUtils.h"
 
 // This file contains the news article download state machine.
 
 // if pIds is not null, download the articles whose id's are passed in. Otherwise,
 // which articles to download is determined by nsNewsDownloader object,
 // or subclasses thereof. News can download marked objects, for example.
 nsresult nsNewsDownloader::DownloadArticles(nsIMsgWindow *window, nsIMsgFolder *folder, nsTArray<nsMsgKey> *pIds)
--- a/mailnews/news/src/nsNewsDownloader.h
+++ b/mailnews/news/src/nsNewsDownloader.h
@@ -9,16 +9,18 @@
 
 #include "nsIMsgDatabase.h"
 #include "nsIUrlListener.h"
 #include "nsIMsgFolder.h"
 #include "nsIMsgHdr.h"
 #include "nsIMsgWindow.h"
 #include "nsIMsgSearchNotify.h"
 #include "nsIMsgSearchSession.h"
+#include "nsIMsgStatusFeedback.h"
+#include "nsTArray.h"
 
 // base class for downloading articles in a single newsgroup. Keys to download are passed in
 // to DownloadArticles method.
 class nsNewsDownloader : public nsIUrlListener, public nsIMsgSearchNotify
 {
 public:
   nsNewsDownloader(nsIMsgWindow *window, nsIMsgDatabase *db, nsIUrlListener *listener);
 
--- a/mailnews/news/src/nsNewsFolder.cpp
+++ b/mailnews/news/src/nsNewsFolder.cpp
@@ -11,62 +11,57 @@
 #include "nntpCore.h"
 #include "nsIMsgMailNewsUrl.h"
 #include "nsNewsFolder.h"
 #include "nsMsgFolderFlags.h"
 #include "MailNewsTypes.h"
 #include "prprf.h"
 #include "prsystem.h"
 #include "nsIArray.h"
-#include "nsIServiceManager.h"
+#include "nsTArray.h"
+#include "nsArrayUtils.h"
 #include "nsINntpService.h"
-#include "nsIFolderListener.h"
+#include "nsIMsgFilterService.h"
 #include "nsCOMPtr.h"
 #include "nsIRDFService.h"
 #include "nsRDFCID.h"
 #include "nsMsgDBCID.h"
 #include "nsMsgNewsCID.h"
 #include "nsMsgUtils.h"
 #include "nsNewsUtils.h"
 
 #include "nsCOMPtr.h"
 #include "nsIMsgIncomingServer.h"
 #include "nsINntpIncomingServer.h"
 #include "nsINewsDatabase.h"
 #include "nsMsgBaseCID.h"
 #include "nsILineInputStream.h"
 
 #include "nsIMsgWindow.h"
-#include "nsIDocShell.h"
 #include "nsIPrompt.h"
 #include "nsIWindowWatcher.h"
 
 #include "nsNetUtil.h"
 #include "nsIAuthPrompt.h"
 #include "nsIURL.h"
 #include "nsNetCID.h"
 #include "nsINntpUrl.h"
 
 #include "nsIInterfaceRequestor.h"
-#include "nsIInterfaceRequestorUtils.h"
 #include "nsArrayEnumerator.h"
 #include "nsNewsDownloader.h"
 #include "nsIStringBundle.h"
 #include "nsMsgI18N.h"
 #include "nsNativeCharsetUtils.h"
-#include "nsIMsgAccountManager.h"
-#include "nsArrayUtils.h"
-#include "nsIMsgAsyncPrompter.h"
+
 #include "nsIMsgFolderNotificationService.h"
 #include "nsIMutableArray.h"
 #include "nsILoginInfo.h"
 #include "nsILoginManager.h"
-#include "nsIPromptService.h"
 #include "nsEmbedCID.h"
-#include "nsIDOMWindow.h"
 #include "mozilla/Services.h"
 #include "nsAutoPtr.h"
 #include "nsIInputStream.h"
 #include "nsMemory.h"
 #include "nsIURIMutator.h"
 
 static NS_DEFINE_CID(kRDFServiceCID, NS_RDFSERVICE_CID);
 
--- a/mailnews/news/src/nsNewsFolder.h
+++ b/mailnews/news/src/nsNewsFolder.h
@@ -8,22 +8,21 @@
 */
 
 #ifndef nsMsgNewsFolder_h__
 #define nsMsgNewsFolder_h__
 
 #include "mozilla/Attributes.h"
 #include "nsMsgDBFolder.h"
 #include "nsIFile.h"
-#include "nsINntpIncomingServer.h" // need this for the IID
 #include "nsNewsUtils.h"
 #include "nsMsgKeySet.h"
 #include "nsIMsgNewsFolder.h"
 #include "nsCOMPtr.h"
-#include "nsIMsgFilterService.h"
+#include "nsIMsgFilterList.h"
 #include "nsIArray.h"
 
 class nsMsgNewsFolder : public nsMsgDBFolder, public nsIMsgNewsFolder
 {
 public:
   nsMsgNewsFolder(void);
 
   NS_DECL_ISUPPORTS_INHERITED
--- a/mailnews/news/src/nsNntpIncomingServer.cpp
+++ b/mailnews/news/src/nsNntpIncomingServer.cpp
@@ -9,17 +9,16 @@
 #include "nsNewsFolder.h"
 #include "nsIMsgFolder.h"
 #include "nsIFile.h"
 #include "nsCOMPtr.h"
 #include "nsINntpService.h"
 #include "nsINNTPProtocol.h"
 #include "nsMsgNewsCID.h"
 #include "nsNNTPProtocol.h"
-#include "nsIDirectoryService.h"
 #include "nsMailDirServiceDefs.h"
 #include "nsMsgUtils.h"
 #include "nsIPrompt.h"
 #include "nsIStringBundle.h"
 #include "nntpCore.h"
 #include "nsIWindowWatcher.h"
 #include "nsITreeColumns.h"
 #include "nsIDOMElement.h"
--- a/mailnews/news/src/nsNntpIncomingServer.h
+++ b/mailnews/news/src/nsNntpIncomingServer.h
@@ -18,16 +18,17 @@
 
 #include "nsIMsgWindow.h"
 #include "nsISubscribableServer.h"
 #include "nsITimer.h"
 #include "nsIFile.h"
 #include "nsITreeView.h"
 #include "nsITreeSelection.h"
 #include "nsCOMArray.h"
+#include "nsTArray.h"
 
 #include "nsNntpMockChannel.h"
 #include "nsAutoPtr.h"
 
 class nsINntpUrl;
 class nsIMsgMailNewsUrl;
 
 /* get some implementation from nsMsgIncomingServer */
--- a/mailnews/news/src/nsNntpService.cpp
+++ b/mailnews/news/src/nsNntpService.cpp
@@ -10,55 +10,45 @@
 #include "nsIMsgNewsFolder.h"
 #include "nsNNTPNewsgroupPost.h"
 #include "nsIMsgIdentity.h"
 #include "nsString.h"
 #include "nsNewsUtils.h"
 #include "nsNewsDatabase.h"
 #include "nsMsgDBCID.h"
 #include "nsMsgBaseCID.h"
-#include "nsIPrefBranch.h"
-#include "nsIPrefService.h"
 #include "nsNntpService.h"
 #include "nsIChannel.h"
 #include "nsILoadGroup.h"
 #include "nsCOMPtr.h"
-#include "nsIDirectoryService.h"
 #include "nsIMsgAccountManager.h"
-#include "nsIMessengerMigrator.h"
 #include "nsINntpIncomingServer.h"
-#include "nsICategoryManager.h"
 #include "nsIDocShell.h"
 #include "nsIDocShellLoadInfo.h"
-#include "nsIMessengerWindowService.h"
-#include "nsIWindowMediator.h"
 #include "mozIDOMWindow.h"
 #include "nsIMsgSearchSession.h"
 #include "nsMailDirServiceDefs.h"
 #include "nsIWebNavigation.h"
-#include "nsIIOService.h"
 #include "nsNetCID.h"
-#include "nsIPrompt.h"
 #include "nsNewsDownloader.h"
 #include "prprf.h"
 #include "nsICacheStorage.h"
 #include "nsICacheStorageService.h"
-#include "nsILoadContextInfo.h"
-#include "nsICacheEntry.h"
 #include "nsMsgUtils.h"
 #include "nsNetUtil.h"
 #include "nsIWindowWatcher.h"
 #include "nsICommandLine.h"
 #include "nsIMsgMailNewsUrl.h"
 #include "nsIMsgMailSession.h"
 #include "nsISupportsPrimitives.h"
 #include "nsArrayUtils.h"
 #include "nsIStreamListener.h"
 #include "nsIInputStream.h"
 #include "nsIURIMutator.h"
+#include "nsTArray.h"
 
 #include "../../base/src/MailnewsLoadContextInfo.h"
 
 #undef GetPort  // XXX Windows!
 #undef SetPort  // XXX Windows!
 
 #define PREF_MAIL_ROOT_NNTP   "mail.root.nntp"        // old - for backward compatibility only
 #define PREF_MAIL_ROOT_NNTP_REL   "mail.root.nntp-rel"
--- a/mailnews/news/src/nsNntpService.h
+++ b/mailnews/news/src/nsNntpService.h
@@ -6,21 +6,19 @@
 #ifndef nsNntpService_h___
 #define nsNntpService_h___
 
 #include "nsINntpService.h"
 #include "nsIProtocolHandler.h"
 #include "nsIMsgMessageService.h"
 #include "nsINntpIncomingServer.h"
 #include "nsIMsgIncomingServer.h"
-#include "nsIFile.h"
 #include "MailNewsTypes.h"
 #include "nsIMsgProtocolInfo.h"
 #include "nsIMsgWindow.h"
-#include "nsINntpUrl.h"
 #include "nsCOMPtr.h"
 #include "nsIContentHandler.h"
 #include "nsICacheStorage.h"
 
 #include "nsICommandLineHandler.h"
 
 class nsIURI;
 class nsIUrlListener;
--- a/mailnews/news/src/nsNntpUrl.cpp
+++ b/mailnews/news/src/nsNntpUrl.cpp
@@ -1,26 +1,24 @@
 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
 /* 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 "msgCore.h"    // precompiled header...
 
-#include "nsIURL.h"
 #include "nsNntpUrl.h"
 
 #include "nsString.h"
 #include "nsNewsUtils.h"
 #include "nsMsgUtils.h"
 
 #include "nntpCore.h"
 
 #include "nsCOMPtr.h"
-#include "nsIMsgDatabase.h"
 #include "nsMsgDBCID.h"
 #include "nsMsgNewsCID.h"
 #include "nsIMsgFolder.h"
 #include "nsIMsgNewsFolder.h"
 #include "nsINntpService.h"
 #include "nsIMsgMessageService.h"
 #include "nsIMsgAccountManager.h"
 #include "nsServiceManagerUtils.h"