@Override
            public void onClick(View view) {
                // Remove the row from its parent (the container view).
                // Because mContainerView has android:animateLayoutChanges set to true,
                // this removal is automatically animated.
                mContainerView.removeView(newView);

                // If there are no rows remaining, show the empty view.
                if (mContainerView.getChildCount() == 0) {
                    findViewById(android.R.id.empty).setVisibility(View.VISIBLE);
                }
            }
The container view which has layout change animations turned on. In this sample, this view
is a {@link android.widget.LinearLayout}.
app/src/main/java/home/smart/fly/animations/ui/activity/demos/LayoutChangesActivity.java