Loading api/current.xml +49 −19 Original line number Diff line number Diff line Loading @@ -93901,7 +93901,7 @@ <method name="glPointSizePointerOES" return="void" abstract="false" native="true" native="false" synchronized="false" static="true" final="false" Loading Loading @@ -96924,7 +96924,7 @@ <method name="glMatrixIndexPointerOES" return="void" abstract="false" native="true" native="false" synchronized="false" static="true" final="false" Loading Loading @@ -97482,7 +97482,7 @@ <method name="glWeightPointerOES" return="void" abstract="false" native="true" native="false" synchronized="false" static="true" final="false" Loading Loading @@ -166662,6 +166662,21 @@ <parameter name="direction" type="int"> </parameter> </method> <method name="dispatchVisibilityChanged" return="void" abstract="false" native="false" synchronized="false" static="false" final="false" deprecated="not deprecated" visibility="protected" > <parameter name="changedView" type="android.view.View"> </parameter> <parameter name="visibility" type="int"> </parameter> </method> <method name="dispatchWindowFocusChanged" return="void" abstract="false" Loading Loading @@ -168522,6 +168537,21 @@ <parameter name="event" type="android.view.MotionEvent"> </parameter> </method> <method name="onVisibilityChanged" return="void" abstract="false" native="false" synchronized="false" static="false" final="false" deprecated="not deprecated" visibility="protected" > <parameter name="changedView" type="android.view.View"> </parameter> <parameter name="visibility" type="int"> </parameter> </method> <method name="onWindowFocusChanged" return="void" abstract="false" Loading Loading @@ -286854,7 +286884,7 @@ deprecated="not deprecated" visibility="public" > <parameter name="array" type="short[]"> <parameter name="array" type="java.lang.Object[]"> </parameter> </method> <method name="sort" Loading @@ -286867,7 +286897,7 @@ deprecated="not deprecated" visibility="public" > <parameter name="array" type="short[]"> <parameter name="array" type="java.lang.Object[]"> </parameter> <parameter name="start" type="int"> </parameter> Loading @@ -286884,7 +286914,13 @@ deprecated="not deprecated" visibility="public" > <parameter name="array" type="java.lang.Object[]"> <parameter name="array" type="T[]"> </parameter> <parameter name="start" type="int"> </parameter> <parameter name="end" type="int"> </parameter> <parameter name="comparator" type="java.util.Comparator<? super T>"> </parameter> </method> <method name="sort" Loading @@ -286897,11 +286933,9 @@ deprecated="not deprecated" visibility="public" > <parameter name="array" type="java.lang.Object[]"> </parameter> <parameter name="start" type="int"> <parameter name="array" type="T[]"> </parameter> <parameter name="end" type="int"> <parameter name="comparator" type="java.util.Comparator<? super T>"> </parameter> </method> <method name="sort" Loading @@ -286914,13 +286948,7 @@ deprecated="not deprecated" visibility="public" > <parameter name="array" type="T[]"> </parameter> <parameter name="start" type="int"> </parameter> <parameter name="end" type="int"> </parameter> <parameter name="comparator" type="java.util.Comparator<? super T>"> <parameter name="array" type="short[]"> </parameter> </method> <method name="sort" Loading @@ -286933,9 +286961,11 @@ deprecated="not deprecated" visibility="public" > <parameter name="array" type="T[]"> <parameter name="array" type="short[]"> </parameter> <parameter name="comparator" type="java.util.Comparator<? super T>"> <parameter name="start" type="int"> </parameter> <parameter name="end" type="int"> </parameter> </method> <method name="toString" core/java/android/test/InstrumentationTestCase.java +0 −36 Original line number Diff line number Diff line Loading @@ -147,42 +147,6 @@ public class InstrumentationTestCase extends TestCase { } } @Override public void runBare() throws Throwable { runMethod("setUp"); try { runTest(); } finally { runMethod("tearDown"); } } private Throwable[] runMethod(String name) throws Throwable { final Throwable[] exceptions = new Throwable[1]; final Method m = getClass().getMethod(name, (Class[]) null); if (m.isAnnotationPresent(UiThreadTest.class)) { getInstrumentation().runOnMainSync(new Runnable() { public void run() { try { m.invoke(InstrumentationTestCase.this); } catch (Throwable throwable) { exceptions[0] = throwable; } } }); if (exceptions[0] != null) { throw exceptions[0]; } exceptions[0] = null; } else { m.invoke(this); } return exceptions; } /** * Runs the current unit test. If the unit test is annotated with * {@link android.test.UiThreadTest}, the test is run on the UI thread. Loading core/java/android/view/View.java +24 −0 Original line number Diff line number Diff line Loading @@ -3770,6 +3770,26 @@ public class View implements Drawable.Callback, KeyEvent.Callback, Accessibility return mAttachInfo != null && mAttachInfo.mHasWindowFocus; } /** * Dispatch a view visibility change down the view hierarchy. * ViewGroups should override to route to their children. * @param changedView The view whose visibility changed. Could be 'this' or * an ancestor view. * @param visibility The new visibility of changedView. */ protected void dispatchVisibilityChanged(View changedView, int visibility) { onVisibilityChanged(changedView, visibility); } /** * Called when the visibility of the view or an ancestor of the view is changed. * @param changedView The view whose visibility changed. Could be 'this' or * an ancestor view. * @param visibility The new visibility of changedView. */ protected void onVisibilityChanged(View changedView, int visibility) { } /** * Dispatch a window visibility change down the view hierarchy. * ViewGroups should override to route to their children. Loading Loading @@ -4349,6 +4369,10 @@ public class View implements Drawable.Callback, KeyEvent.Callback, Accessibility } } if ((changed & VISIBILITY_MASK) != 0) { dispatchVisibilityChanged(this, (flags & VISIBILITY_MASK)); } if ((changed & WILL_NOT_CACHE_DRAWING) != 0) { destroyDrawingCache(); } Loading core/java/android/view/ViewGroup.java +13 −0 Original line number Diff line number Diff line Loading @@ -680,6 +680,19 @@ public abstract class ViewGroup extends View implements ViewParent, ViewManager } } /** * {@inheritDoc} */ @Override protected void dispatchVisibilityChanged(View changedView, int visibility) { super.dispatchVisibilityChanged(changedView, visibility); final int count = mChildrenCount; final View[] children = mChildren; for (int i = 0; i < count; i++) { children[i].dispatchVisibilityChanged(changedView, visibility); } } /** * {@inheritDoc} */ Loading tests/FrameworkTest/AndroidManifest.xml +7 −0 Original line number Diff line number Diff line Loading @@ -377,6 +377,13 @@ </intent-filter> </activity> <activity android:name=".view.VisibilityCallback" android:label="VisibilityCallback"> <intent-filter> <action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.FRAMEWORK_INSTRUMENTATION_TEST" /> </intent-filter> </activity> <activity android:name=".view.BigCache" android:label="BigCache"> <intent-filter> <action android:name="android.intent.action.MAIN" /> Loading Loading
api/current.xml +49 −19 Original line number Diff line number Diff line Loading @@ -93901,7 +93901,7 @@ <method name="glPointSizePointerOES" return="void" abstract="false" native="true" native="false" synchronized="false" static="true" final="false" Loading Loading @@ -96924,7 +96924,7 @@ <method name="glMatrixIndexPointerOES" return="void" abstract="false" native="true" native="false" synchronized="false" static="true" final="false" Loading Loading @@ -97482,7 +97482,7 @@ <method name="glWeightPointerOES" return="void" abstract="false" native="true" native="false" synchronized="false" static="true" final="false" Loading Loading @@ -166662,6 +166662,21 @@ <parameter name="direction" type="int"> </parameter> </method> <method name="dispatchVisibilityChanged" return="void" abstract="false" native="false" synchronized="false" static="false" final="false" deprecated="not deprecated" visibility="protected" > <parameter name="changedView" type="android.view.View"> </parameter> <parameter name="visibility" type="int"> </parameter> </method> <method name="dispatchWindowFocusChanged" return="void" abstract="false" Loading Loading @@ -168522,6 +168537,21 @@ <parameter name="event" type="android.view.MotionEvent"> </parameter> </method> <method name="onVisibilityChanged" return="void" abstract="false" native="false" synchronized="false" static="false" final="false" deprecated="not deprecated" visibility="protected" > <parameter name="changedView" type="android.view.View"> </parameter> <parameter name="visibility" type="int"> </parameter> </method> <method name="onWindowFocusChanged" return="void" abstract="false" Loading Loading @@ -286854,7 +286884,7 @@ deprecated="not deprecated" visibility="public" > <parameter name="array" type="short[]"> <parameter name="array" type="java.lang.Object[]"> </parameter> </method> <method name="sort" Loading @@ -286867,7 +286897,7 @@ deprecated="not deprecated" visibility="public" > <parameter name="array" type="short[]"> <parameter name="array" type="java.lang.Object[]"> </parameter> <parameter name="start" type="int"> </parameter> Loading @@ -286884,7 +286914,13 @@ deprecated="not deprecated" visibility="public" > <parameter name="array" type="java.lang.Object[]"> <parameter name="array" type="T[]"> </parameter> <parameter name="start" type="int"> </parameter> <parameter name="end" type="int"> </parameter> <parameter name="comparator" type="java.util.Comparator<? super T>"> </parameter> </method> <method name="sort" Loading @@ -286897,11 +286933,9 @@ deprecated="not deprecated" visibility="public" > <parameter name="array" type="java.lang.Object[]"> </parameter> <parameter name="start" type="int"> <parameter name="array" type="T[]"> </parameter> <parameter name="end" type="int"> <parameter name="comparator" type="java.util.Comparator<? super T>"> </parameter> </method> <method name="sort" Loading @@ -286914,13 +286948,7 @@ deprecated="not deprecated" visibility="public" > <parameter name="array" type="T[]"> </parameter> <parameter name="start" type="int"> </parameter> <parameter name="end" type="int"> </parameter> <parameter name="comparator" type="java.util.Comparator<? super T>"> <parameter name="array" type="short[]"> </parameter> </method> <method name="sort" Loading @@ -286933,9 +286961,11 @@ deprecated="not deprecated" visibility="public" > <parameter name="array" type="T[]"> <parameter name="array" type="short[]"> </parameter> <parameter name="comparator" type="java.util.Comparator<? super T>"> <parameter name="start" type="int"> </parameter> <parameter name="end" type="int"> </parameter> </method> <method name="toString"
core/java/android/test/InstrumentationTestCase.java +0 −36 Original line number Diff line number Diff line Loading @@ -147,42 +147,6 @@ public class InstrumentationTestCase extends TestCase { } } @Override public void runBare() throws Throwable { runMethod("setUp"); try { runTest(); } finally { runMethod("tearDown"); } } private Throwable[] runMethod(String name) throws Throwable { final Throwable[] exceptions = new Throwable[1]; final Method m = getClass().getMethod(name, (Class[]) null); if (m.isAnnotationPresent(UiThreadTest.class)) { getInstrumentation().runOnMainSync(new Runnable() { public void run() { try { m.invoke(InstrumentationTestCase.this); } catch (Throwable throwable) { exceptions[0] = throwable; } } }); if (exceptions[0] != null) { throw exceptions[0]; } exceptions[0] = null; } else { m.invoke(this); } return exceptions; } /** * Runs the current unit test. If the unit test is annotated with * {@link android.test.UiThreadTest}, the test is run on the UI thread. Loading
core/java/android/view/View.java +24 −0 Original line number Diff line number Diff line Loading @@ -3770,6 +3770,26 @@ public class View implements Drawable.Callback, KeyEvent.Callback, Accessibility return mAttachInfo != null && mAttachInfo.mHasWindowFocus; } /** * Dispatch a view visibility change down the view hierarchy. * ViewGroups should override to route to their children. * @param changedView The view whose visibility changed. Could be 'this' or * an ancestor view. * @param visibility The new visibility of changedView. */ protected void dispatchVisibilityChanged(View changedView, int visibility) { onVisibilityChanged(changedView, visibility); } /** * Called when the visibility of the view or an ancestor of the view is changed. * @param changedView The view whose visibility changed. Could be 'this' or * an ancestor view. * @param visibility The new visibility of changedView. */ protected void onVisibilityChanged(View changedView, int visibility) { } /** * Dispatch a window visibility change down the view hierarchy. * ViewGroups should override to route to their children. Loading Loading @@ -4349,6 +4369,10 @@ public class View implements Drawable.Callback, KeyEvent.Callback, Accessibility } } if ((changed & VISIBILITY_MASK) != 0) { dispatchVisibilityChanged(this, (flags & VISIBILITY_MASK)); } if ((changed & WILL_NOT_CACHE_DRAWING) != 0) { destroyDrawingCache(); } Loading
core/java/android/view/ViewGroup.java +13 −0 Original line number Diff line number Diff line Loading @@ -680,6 +680,19 @@ public abstract class ViewGroup extends View implements ViewParent, ViewManager } } /** * {@inheritDoc} */ @Override protected void dispatchVisibilityChanged(View changedView, int visibility) { super.dispatchVisibilityChanged(changedView, visibility); final int count = mChildrenCount; final View[] children = mChildren; for (int i = 0; i < count; i++) { children[i].dispatchVisibilityChanged(changedView, visibility); } } /** * {@inheritDoc} */ Loading
tests/FrameworkTest/AndroidManifest.xml +7 −0 Original line number Diff line number Diff line Loading @@ -377,6 +377,13 @@ </intent-filter> </activity> <activity android:name=".view.VisibilityCallback" android:label="VisibilityCallback"> <intent-filter> <action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.FRAMEWORK_INSTRUMENTATION_TEST" /> </intent-filter> </activity> <activity android:name=".view.BigCache" android:label="BigCache"> <intent-filter> <action android:name="android.intent.action.MAIN" /> Loading