summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--core/java/android/view/SurfaceView.java4
-rw-r--r--core/java/android/view/TextureView.java4
-rw-r--r--core/java/android/view/View.java14
-rw-r--r--core/java/android/widget/TextView.java6
-rw-r--r--opengl/java/android/opengl/GLSurfaceView.java4
5 files changed, 9 insertions, 23 deletions
diff --git a/core/java/android/view/SurfaceView.java b/core/java/android/view/SurfaceView.java
index eece043..9b23b35 100644
--- a/core/java/android/view/SurfaceView.java
+++ b/core/java/android/view/SurfaceView.java
@@ -256,7 +256,7 @@ public class SurfaceView extends View {
}
@Override
- protected void onDetachedFromWindowInternal() {
+ protected void onDetachedFromWindow() {
if (mGlobalListenersAdded) {
ViewTreeObserver observer = getViewTreeObserver();
observer.removeOnScrollChangedListener(mScrollChangedListener);
@@ -278,7 +278,7 @@ public class SurfaceView extends View {
mSession = null;
mLayout.token = null;
- super.onDetachedFromWindowInternal();
+ super.onDetachedFromWindow();
}
@Override
diff --git a/core/java/android/view/TextureView.java b/core/java/android/view/TextureView.java
index f1aa247..ef0d80d 100644
--- a/core/java/android/view/TextureView.java
+++ b/core/java/android/view/TextureView.java
@@ -229,9 +229,9 @@ public class TextureView extends View {
}
@Override
- protected void onDetachedFromWindowInternal() {
+ protected void onDetachedFromWindow() {
+ super.onDetachedFromWindow();
destroySurface();
- super.onDetachedFromWindowInternal();
}
private void destroySurface() {
diff --git a/core/java/android/view/View.java b/core/java/android/view/View.java
index bd6b2e1..a57b311 100644
--- a/core/java/android/view/View.java
+++ b/core/java/android/view/View.java
@@ -13110,19 +13110,6 @@ public class View implements Drawable.Callback, KeyEvent.Callback,
* @see #onAttachedToWindow()
*/
protected void onDetachedFromWindow() {
- }
-
- /**
- * This is a framework-internal mirror of onDetachedFromWindow() that's called
- * after onDetachedFromWindow().
- *
- * If you override this you *MUST* call super.onDetachedFromWindowInternal()!
- * The super method should be called at the end of the overriden method to ensure
- * subclasses are destroyed first
- *
- * @hide
- */
- protected void onDetachedFromWindowInternal() {
mPrivateFlags &= ~PFLAG_CANCEL_NEXT_UP_EVENT;
mPrivateFlags3 &= ~PFLAG3_IS_LAID_OUT;
@@ -13310,7 +13297,6 @@ public class View implements Drawable.Callback, KeyEvent.Callback,
}
onDetachedFromWindow();
- onDetachedFromWindowInternal();
ListenerInfo li = mListenerInfo;
final CopyOnWriteArrayList<OnAttachStateChangeListener> listeners =
diff --git a/core/java/android/widget/TextView.java b/core/java/android/widget/TextView.java
index 779b232..e5cb16f 100644
--- a/core/java/android/widget/TextView.java
+++ b/core/java/android/widget/TextView.java
@@ -4730,7 +4730,9 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener
}
@Override
- protected void onDetachedFromWindowInternal() {
+ protected void onDetachedFromWindow() {
+ super.onDetachedFromWindow();
+
if (mPreDrawRegistered) {
getViewTreeObserver().removeOnPreDrawListener(this);
mPreDrawRegistered = false;
@@ -4739,8 +4741,6 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener
resetResolvedDrawables();
if (mEditor != null) mEditor.onDetachedFromWindow();
-
- super.onDetachedFromWindowInternal();
}
@Override
diff --git a/opengl/java/android/opengl/GLSurfaceView.java b/opengl/java/android/opengl/GLSurfaceView.java
index d88a134..5a2e261 100644
--- a/opengl/java/android/opengl/GLSurfaceView.java
+++ b/opengl/java/android/opengl/GLSurfaceView.java
@@ -601,7 +601,7 @@ public class GLSurfaceView extends SurfaceView implements SurfaceHolder.Callback
* Must not be called before a renderer has been set.
*/
@Override
- protected void onDetachedFromWindowInternal() {
+ protected void onDetachedFromWindow() {
if (LOG_ATTACH_DETACH) {
Log.d(TAG, "onDetachedFromWindow");
}
@@ -609,7 +609,7 @@ public class GLSurfaceView extends SurfaceView implements SurfaceHolder.Callback
mGLThread.requestExitAndWait();
}
mDetached = true;
- super.onDetachedFromWindowInternal();
+ super.onDetachedFromWindow();
}
// ----------------------------------------------------------------------