When I rotate my phone, my Activity restarts. I have a video view playing video, I rotate and the video restarts. Now I found adding this to my activity in the manifest fixed it
<activity android:name="Vforum" android:configChanges="orientation"></activity>
The problem now is the video controls aren't being redrawn until they disappear and come back, thus leaving either really long controls going from landscape to portrait mode or really short controls going from portrait to landscape. Once they disappear and then I tap to make them come back, then they are correctly sized. Is there a better method of doing this?
add
android:configChanges="orientation"
to your Activity in AndroidManifest.xml.
If your target API level 13 or higher, you must include the screenSize
value in addition to the orientation
value as described here. So your tag may look like
android:configChanges="orientation|screenSize"
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With