I want to make an activity that allows orientation changes on some condition, but not otherwise. More exactly I want to prevent restarting the activity when a background thread is busy.
I have put the configChanges attribute on the activity manifest, and onConfigurationChanged is called when the orientation changes. However I want to al...
One of our views has a ScrollView as its root layout. When the device is rotated and onConfigurationChanged() is called, we'd like to be able to get the ScrollView's new width/height. Our code looks like this:
@Override
public void onConfigurationChanged(Configuration newConfig) {
Log.d(TAG, "Width: '" + findViewById(R.id.scrollview...
Hi!
I need to apply different layouts for portrait and landscape orientations of my activity. Besides, I need to show alert if orientation is portrait.
I have specified android:configChanges="orientation|keyboardHidden" in AndroidManifest. I also override onConfigurationChanged method like this:
@Override
public void onConfigurationCh...