Cleanup Editor.java.

- Make members that can be private private
- Remove unused member.
- Remove useless @hide.

Bug: 27558597
Change-Id: Ib5f39dbcabd85fb2a5df1c93a83d594085fd722a
diff --git a/core/java/android/widget/Editor.java b/core/java/android/widget/Editor.java
index dd5d813..c619c6d 100644
--- a/core/java/android/widget/Editor.java
+++ b/core/java/android/widget/Editor.java
@@ -162,15 +162,15 @@
     boolean mAllowUndo = true;
 
     // Cursor Controllers.
-    InsertionPointCursorController mInsertionPointCursorController;
+    private InsertionPointCursorController mInsertionPointCursorController;
     SelectionModifierCursorController mSelectionModifierCursorController;
     // Action mode used when text is selected or when actions on an insertion cursor are triggered.
     ActionMode mTextActionMode;
-    boolean mInsertionControllerEnabled;
-    boolean mSelectionControllerEnabled;
+    private boolean mInsertionControllerEnabled;
+    private boolean mSelectionControllerEnabled;
 
     // Used to highlight a word when it is corrected by the IME
-    CorrectionHighlighter mCorrectionHighlighter;
+    private CorrectionHighlighter mCorrectionHighlighter;
 
     InputContentType mInputContentType;
     InputMethodState mInputMethodState;
@@ -184,7 +184,7 @@
         }
         boolean needsRecord() { return isDirty || !renderNode.isValid(); }
     }
-    TextRenderNode[] mTextRenderNodes;
+    private TextRenderNode[] mTextRenderNodes;
 
     boolean mFrozenWithFocus;
     boolean mSelectionMoved;
@@ -195,10 +195,9 @@
 
     boolean mDiscardNextActionUp;
     boolean mIgnoreActionUpEvent;
-    private boolean mIgnoreNextMouseActionUpOrDown;
 
     long mShowCursor;
-    Blink mBlink;
+    private Blink mBlink;
 
     boolean mCursorVisible = true;
     boolean mSelectAllOnFocus;
@@ -206,7 +205,7 @@
 
     CharSequence mError;
     boolean mErrorWasChanged;
-    ErrorPopup mErrorPopup;
+    private ErrorPopup mErrorPopup;
 
     /**
      * This flag is set if the TextView tries to display an error before it
@@ -214,7 +213,7 @@
      * It causes the error to be shown later, when onAttachedToWindow()
      * is called.
      */
-    boolean mShowErrorAfterAttach;
+    private boolean mShowErrorAfterAttach;
 
     boolean mInBatchEditControllers;
     boolean mShowSoftInputOnFocus = true;
@@ -223,9 +222,9 @@
 
     boolean mIsBeingLongClicked;
 
-    SuggestionsPopupWindow mSuggestionsPopupWindow;
+    private SuggestionsPopupWindow mSuggestionsPopupWindow;
     SuggestionRangeSpan mSuggestionRangeSpan;
-    Runnable mShowSuggestionRunnable;
+    private Runnable mShowSuggestionRunnable;
 
     final Drawable[] mCursorDrawable = new Drawable[2];
     int mCursorCount; // Current number of used mCursorDrawable: 0 (resource=0), 1 or 2 (split)
@@ -237,7 +236,7 @@
     // Global listener that detects changes in the global position of the TextView
     private PositionListener mPositionListener;
 
-    float mLastDownPositionX, mLastDownPositionY;
+    private float mLastDownPositionX, mLastDownPositionY;
     private float mContextMenuAnchorX, mContextMenuAnchorY;
     Callback mCustomSelectionActionModeCallback;
     Callback mCustomInsertionActionModeCallback;
@@ -264,7 +263,7 @@
     // - SelectionSpans, for which we need to call updateSelection if an IME is attached
     private SpanController mSpanController;
 
-    WordIterator mWordIterator;
+    private WordIterator mWordIterator;
     SpellChecker mSpellChecker;
 
     // This word iterator is set with text and used to determine word boundaries
@@ -279,7 +278,7 @@
 
     final ProcessTextIntentActionsHandler mProcessTextIntentActionsHandler;
 
-    final CursorAnchorInfoNotifier mCursorAnchorInfoNotifier = new CursorAnchorInfoNotifier();
+    private final CursorAnchorInfoNotifier mCursorAnchorInfoNotifier = new CursorAnchorInfoNotifier();
 
     private final Runnable mShowFloatingToolbar = new Runnable() {
         @Override
@@ -931,9 +930,6 @@
         mWordIteratorWithText = null;
     }
 
-    /**
-     * @hide
-     */
     public WordIterator getWordIterator() {
         if (mWordIterator == null) {
             mWordIterator = new WordIterator(mTextView.getTextServicesLocale());
@@ -1285,7 +1281,6 @@
                 mBlink.uncancel();
                 makeBlink();
             }
-            final InputMethodManager imm = InputMethodManager.peekInstance();
             if (mTextView.hasSelection() && !extractedTextModeWillBeStarted()) {
                 refreshTextActionMode();
             }
@@ -2017,7 +2012,7 @@
         return selectionStarted;
     }
 
-    boolean extractedTextModeWillBeStarted() {
+    private boolean extractedTextModeWillBeStarted() {
         if (!(mTextView.isInExtractedMode())) {
             final InputMethodManager imm = InputMethodManager.peekInstance();
             return  imm != null && imm.isFullscreenMode();
@@ -2170,7 +2165,7 @@
         return mSelectionControllerEnabled;
     }
 
-    InsertionPointCursorController getInsertionController() {
+    private InsertionPointCursorController getInsertionController() {
         if (!mInsertionControllerEnabled) {
             return null;
         }
@@ -2185,7 +2180,7 @@
         return mInsertionPointCursorController;
     }
 
-    SelectionModifierCursorController getSelectionController() {
+    private SelectionModifierCursorController getSelectionController() {
         if (!mSelectionControllerEnabled) {
             return null;
         }
@@ -2200,9 +2195,6 @@
         return mSelectionModifierCursorController;
     }
 
-    /**
-     * @hide
-     */
     @VisibleForTesting
     public Drawable[] getCursorDrawable() {
         return mCursorDrawable;
@@ -2677,7 +2669,7 @@
      * pop-up should be displayed.
      * Also monitors {@link Selection} to call back to the attached input method.
      */
-    class SpanController implements SpanWatcher {
+    private class SpanController implements SpanWatcher {
 
         private static final int DISPLAY_TIMEOUT_MS = 3000; // 3 secs