I am building an app with Android 2.3.3 API. I need to recognize the change in orientation and perform some action. So I added the following in Android Manifest,
android:configChanges="orientation|keyboardHidden
And I override the method
public void onConfigurationChanged(Configuration newConfig)
It works perfect on Android 2.3.3. But when I install the same app (built with 2.3.3 API) on a 4.1.2, onConfigurationChanged() is not invoked. I searched online for solution and people suggest to add the following in android manifest.
android:configChanges="orientation|keyboardHidden|screenSize"
If I build the app with above statement and built with 4.1.2 API, It works perfect on 4.1.2 device. But I cannot install it on 2.3.3. 2.3.3 API doesn't have "screenSize" option. So to support both, what should I do?
Thanks, Karthik