Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6327963
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T17:22:25+00:00 2026-05-24T17:22:25+00:00

Full warning: Implicit conversion from enumeration type ‘UIInterfaceOrientation’ to different enumeration type ‘UIDeviceOrientation’ Getting

  • 0

Full warning:

Implicit conversion from enumeration type 'UIInterfaceOrientation' to different enumeration type 'UIDeviceOrientation'

Getting it on the line:

[self orientationChanged:interfaceOrientation];

This is the method:

- (void)orientationChanged:(UIInterfaceOrientation)interfaceOrientation 

I can’t really understand where this warning is coming from.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T17:22:26+00:00Added an answer on May 24, 2026 at 5:22 pm

    UIDeviceOrientation refers to the physical orientation of the device whereas UIInterfaceOrientation refers to the orientation of the user interface. When you call your method

    [self orientationChanged:interfaceOrientation];
    

    you are most likely passing it a UIDeviceOrientation when you should, according to the method, be using a UIInterfaceOrientation.

    Just to expand on this point a bit, UIDeviceOrientation is a property of the UIDevice class, and there are these possible values:

    UIDeviceOrientationUnknown – Can’t be determined

    UIDeviceOrientationPortrait – Home button facing down

    UIDeviceOrientationPortraitUpsideDown – Home button facing up

    UIDeviceOrientationLandscapeLeft – Home button facing right

    UIDeviceOrientationLandscapeRight – Home button facing left

    UIDeviceOrientationFaceUp – Device is flat, with screen facing up

    UIDeviceOrientationFaceDown – Device is flat, with screen facing down

    As for UIInterfaceOrientation, it is a property of UIApplication and only contains 4 possibilities which correspond to the orientation of the status bar:

    UIInterfaceOrientationPortrait = UIDeviceOrientationPortrait,
    
    UIInterfaceOrientationPortraitUpsideDown = UIDeviceOrientationPortraitUpsideDown,
    
    UIInterfaceOrientationLandscapeLeft = UIDeviceOrientationLandscapeRight,
    
    UIInterfaceOrientationLandscapeRight = UIDeviceOrientationLandscapeLeft
    

    To get UIDeviceOrientation, you use

    [[UIDevice currentDevice] orientation]
    

    and to get UIInterfaceOrientation, you use

    [[UIApplication sharedApplication] statusBarOrientation] 
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm getting this warning. '-respondsToSelector:' not found in protocol(s) It occurs on the line
I get the warning childNodes is null or not an object' with different line
The full error I'm getting is this: error: ambiguous overload for ‘operator[]’ in ‘a[boost::_bi::storage4<A1,
Having issues attaching a Database and full text catalog from server A to server
In Xcode I get a warning in the following line for FBConnect: _orientation =
I am getting Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource
I've got a full-heap core dump from a dead process on an x86 Linux
When I run mvn pmd:pmd I get an warning / error from PMD saying
My application I've recently inherited is FULL of deprecation warnings about the constructor: Date
Full disclaimer: I'm a CS student, and this question is related to a recently

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.