make styles.xml and place it in res/values
<style name="MyAnimation">
<item name="android:windowEnterAnimation">@anim/slide_in</item>
<item name="android:windowExitAnimation">@anim/slide_out_</item>
<style name="SlideAnim">
<item name="android:windowAnimationStyle">@style/MyAnimation</item>
<item name="android:windowNoTitle">true</item>
</style>
make these files and place both of them in res/anim
slide_in xml
<translate android:fromXDelta="-100%" android:toXDelta="0%"
android:fromYDelta="0%" android:toYDelta="0%"
android:duration="700"/>
slide_out xml
<translate
android:fromXDelta="0%" android:toXDelta="100%"
android:fromYDelta="0%" android:toYDelta="0%"
android:duration="700" />
And the last step is : inside your xml file where you have placed your LinearLayout or WebView apply style attribute the particular element. In the below example I have done it to LinearLayout.
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
style="@style/SlideAnim"
android:orientation="vertical" >
....
</LinearLayout>