Here is a simple way to change the orientation of the activity in android Through java code we do this…. Through xml we do this Following are two other values that you can specify in the android:screenOrientation attribute: ➤➤ portrait — Portrait mode ➤➤ sensor — Based on the accelerometer Please leave your valuable comments.
Hello everyone, Today’s example shows how to create a custom layout for your camera preview, that is if you want a custom layout while your camera is opening. This example helps you to achieve this. First create a fresh project and name it CameraCustomLayout and copy this code to CameraCustomLayout.java file. After that create an xml file named… Read More »