How can I make my android app to work only when user holds app vertical position?
I already read StackOverflow posts implement what being said there but no success.
Below is my login code where I have implemented portrait orientation:
 public class LoginActivity extends AppCompatActivity implements View.OnClickListener {
        private static final String TAG = "Login Success";
        private static final int RC_SIGN_IN = 9001;
        LoginButton login_button;
        CallbackManager callbackManager;
        GoogleSignInClient mGoogleSignInClient;
        private EditText inputEmail, inputPassword;
        private FirebaseAuth auth;
        private ProgressBar progressBar;
        private Button btnSignup, btnLogin, btnReset;
        private TextView mStatusTextView;
        private Handler fontHandler;
        @Override
        protected void onCreate(Bundle savedInstanceState) {
            setRequestedOrientation (ActivityInfo.SCREEN_ORIENTATION_PORTRAIT);
            super.onCreate(savedInstanceState);
        }
}
Is it possible to achieve what I want or it is impossible?
 
    