Bug 1225682 - Don't use nsAuto{,C}String as class member variables in widget/. r=roc
authorMike Hommey <mh+mozilla@glandium.org>
Thu, 19 Nov 2015 18:31:56 +0900
changeset 275160 fc1d5300303627cadc21b7c49f4c7fce6926d7d6
parent 275159 15bbe7c7bb3c03b6da28b893ba6f35bf7bf8fed5
child 275161 bb12e45c0dd8664c8d28c7094a4d25ab4275f5f7
push id16506
push usercbook@mozilla.com
push dateWed, 02 Dec 2015 14:23:03 +0000
treeherderfx-team@ad92bd131ec3 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersroc
bugs1225682
milestone45.0a1
Bug 1225682 - Don't use nsAuto{,C}String as class member variables in widget/. r=roc
widget/GfxInfoBase.cpp
widget/TextEventDispatcher.h
widget/gtk/WakeLockListener.cpp
--- a/widget/GfxInfoBase.cpp
+++ b/widget/GfxInfoBase.cpp
@@ -1131,17 +1131,17 @@ nsresult GfxInfoBase::GetInfo(JSContext*
 
   aResult.setObject(*obj.mObj);
   return NS_OK;
 }
 
 const nsCString&
 GfxInfoBase::GetApplicationVersion()
 {
-  static nsAutoCString version;
+  static nsCString version;
   static bool versionInitialized = false;
   if (!versionInitialized) {
     // If we fail to get the version, we will not try again.
     versionInitialized = true;
 
     // Get the version from xpcom/system/nsIXULAppInfo.idl
     nsCOMPtr<nsIXULAppInfo> app = do_GetService("@mozilla.org/xre/app-info;1");
     if (app) {
--- a/widget/TextEventDispatcher.h
+++ b/widget/TextEventDispatcher.h
@@ -264,17 +264,17 @@ private:
     PendingComposition();
     nsresult SetString(const nsAString& aString);
     nsresult AppendClause(uint32_t aLength, uint32_t aAttribute);
     nsresult SetCaret(uint32_t aOffset, uint32_t aLength);
     nsresult Flush(TextEventDispatcher* aDispatcher, nsEventStatus& aStatus);
     void Clear();
 
   private:
-    nsAutoString mString;
+    nsString mString;
     RefPtr<TextRangeArray> mClauses;
     TextRange mCaret;
 
     void EnsureClauseArray();
   };
   PendingComposition mPendingComposition;
 
   // While dispatching an event, this is incremented.
--- a/widget/gtk/WakeLockListener.cpp
+++ b/widget/gtk/WakeLockListener.cpp
@@ -58,17 +58,17 @@ private:
   bool SendFreeDesktopInhibitMessage();
   bool SendGNOMEInhibitMessage();
   bool SendMessage(DBusMessage* aMessage);
 
   static void ReceiveInhibitReply(DBusPendingCall* aPending, void* aUserData);
   void InhibitFailed();
   void InhibitSucceeded(uint32_t aInhibitRequest);
 
-  nsAutoCString mTopic;
+  nsCString mTopic;
   DBusConnection* mConnection;
 
   DesktopEnvironment mDesktopEnvironment;
 
   uint32_t mInhibitRequest;
 
   bool mShouldInhibit;
   bool mWaitingForReply;