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

  • SEARCH
  • Home
  • 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 842547
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T05:58:50+00:00 2026-05-15T05:58:50+00:00

Problem: My app must run on iPhone OS 3.0. However, there are some features

  • 0

Problem: My app must run on iPhone OS 3.0.

However, there are some features of iPhone OS 3.2 which I really want to use. Just as a little add-on for free. But I don’t want to cut off my user base by doing this.

Imagine you’re an iPhone OS 3.0 thing, and someone gives you a book to read. It has iPhone OS 3.2 instructions. You never learned those. So what do you do? Crash? They would have to be hidden, so you’re not bothered.

Someone wrote recently on SO:

keep in mind that you have to check
the version at places in the source
code where you like to use the new
features and provide alternatives for
older os versions

So how could I do that? Wouldn’t Xcode throw warnings when it finds stuff that isn’t linkable from anything anywhere? Would I just check for the OS version and dynamically link – somehow – to whatever stuff I think is cool?

  • 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-15T05:58:51+00:00Added an answer on May 15, 2026 at 5:58 am

    The two must common ways to detect features are respondsToSelector and NSClassFromString. With these you can tell if an old class has a new method, or if a new class exists.

    For example, 3.2 added gesture recognizers. You could use either one of these methods to decide if you want to add gesture recognizers to a view:

    if ( [myView respondsToSelector:@selector(addGestureRecognizer:)] ) {
      // assume gesture recognizers exist, create and add some
    }
    

    or

    if ( NSClassFromString( @"UIGestureRecognizer" ) ) {
      // assume gesture recognizers exist, create and use some
    }
    

    In both cases, you would build for 3.2 but only use 3.2 features if they are detected at runtime. If you build against 3.0 and all the warnings show up in places where you are checking things correctly, then you are good to go.

    In the case of 3.2 a new processor was also added, so either build a universal binary or build for the older architecture.

    Also, in some cases Apple provides support for detecting version. A good example of that is UI_USER_INTERFACE_IDIOM in UIDevice.h where it calls respondsToSelector for you.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

No related questions found

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.