One option is to tell android that you will handle when the screen changes orientation, so that onCreate()
is not called again when the screen changes orientations. To do this, add an entry for the specific activity in your manifest file. It should look something like this:
<activity
android:name="com.package.name.Activity"
android:configChanges="orientation"
android:label="@string/title_activity"
android:parentActivityName="com.package.name.Parent" >
<meta-data
android:name="android.support.PARENT_ACTIVITY"
android:value="com.package.name.Parent" />
</activity>
the line android:configChanges
is what I'm referring to