Bug 1337698 - Use UniquePtr instead of nsAutoPtr in editor

* PlaceholderTransaction should use UniquePtr
* HTMLEditor should use UniquePtr
* TypeInState should use UniquePtr

Tag #1375
This commit is contained in:
Matt A. Tobin 2020-04-17 05:43:18 -04:00 committed by Roy Tam
commit 32e4ad01e3
10 changed files with 32 additions and 44 deletions

View file

@ -11,6 +11,7 @@
#include "mozilla/OwningNonNull.h" // for OwningNonNull
#include "mozilla/SelectionState.h" // for RangeUpdater, etc.
#include "mozilla/StyleSheet.h" // for StyleSheet
#include "mozilla/UniquePtr.h"
#include "mozilla/dom/Text.h"
#include "nsCOMPtr.h" // for already_AddRefed, nsCOMPtr
#include "nsCycleCollectionParticipant.h"
@ -980,7 +981,7 @@ protected:
// Name of placeholder transaction.
nsIAtom* mPlaceHolderName;
// Saved selection state for placeholder transaction batching.
SelectionState* mSelState;
mozilla::UniquePtr<SelectionState> mSelState;
nsString* mPhonetic;
// IME composition this is not null between compositionstart and
// compositionend.