Gaia GPS
  • 7-Day Free Trial Gaia GPS Premium
  • Out and Back Podcast
    • Adventures

      How to Avoid Another Deadly Avalanche Season

      January 21, 2022

      Gaia GPS

      The Best Advice We Received in 2021

      December 26, 2021

      Gaia GPS

      Avalanche Safety with Snow Science Expert Bruce Tremper

      November 30, 2021

      Gaia GPS

      Everything You Need to Know About Satellite Communicators

      November 10, 2021

      Gaia GPS

      Planning a Thru-Hike Next Year? Here’s What You…

      October 21, 2021

      Gaia GPS

      A Definitive Guide to the Best Camp Coffee

      September 30, 2021

      Gaia GPS

      Owls and UFOs with Ultralight Expert Mike Clelland

      September 9, 2021

  • Offroad Podcast
    • Gaia GPS

      Monique Song: How a City Girl Became the…

      April 7, 2022

      Gaia GPS

      TrailRecon Explains How to Become an Overlander Overnight

      March 9, 2022

      Adventures

      How to Stay Married on a Long-Distance Adventure

      February 9, 2022

      Adventures

      How to Go From ‘Desk to Glory’ in…

      January 12, 2022

      Gaia GPS

      The Best Advice We Received in 2021

      December 26, 2021

      Gaia GPS

      Gaia GPS’s Best New Overlanding Maps and Features…

      December 23, 2021

      Gaia GPS

      Inside the Never-Ending Road Trip with Dan Grec

      November 20, 2021

  • Adventures
    • User Stories
  • Activities
    • Backcountry Skiing
    • Boating
    • Emergency Response
    • Fishing
    • Offroading
  • New Features
    • Gaia GPS

      Meet Map Packs: A Totally New Way to…

      May 9, 2022

      Gaia GPS

      Top 10 Ways to Use Waypoints

      April 14, 2022

      Gaia GPS

      Discover & Reserve Campsites Right From Gaia GPS

      February 22, 2022

      Gaia GPS

      Navigate from the Dashboard with Improved Android Auto

      February 4, 2022

      Gaia GPS

      Trailforks Mountain Bike Trails now in Gaia GPS

      January 13, 2022

      Android

      Gaia GPS Year in Review: Best New Maps…

      December 28, 2021

      Gaia GPS

      Gaia GPS’s Best New Overlanding Maps and Features…

      December 23, 2021

  • New Maps
    • Featured

      Find Phone Signal With Cell Phone Coverage Maps

      May 2, 2022

      Adventures

      Using Gaia GPS to Find Free Camping in…

      March 9, 2022

      Gaia GPS

      Discover Snowmobile Trails Across the Globe

      February 9, 2022

      Gaia GPS

      Get Worldwide Ski Resort Reports in Gaia GPS

      January 25, 2022

      Gaia GPS

      Trailforks Mountain Bike Trails now in Gaia GPS

      January 13, 2022

      Android

      Gaia GPS Year in Review: Best New Maps…

      December 28, 2021

      Gaia GPS

      Gaia GPS’s Best New Overlanding Maps and Features…

      December 23, 2021

  • Home
Gaia GPS
  • 7-Day Free Trial Gaia GPS Premium
  • Out and Back Podcast
    • Adventures

      How to Avoid Another Deadly Avalanche Season

      January 21, 2022

      Gaia GPS

      The Best Advice We Received in 2021

      December 26, 2021

      Gaia GPS

      Avalanche Safety with Snow Science Expert Bruce Tremper

      November 30, 2021

      Gaia GPS

      Everything You Need to Know About Satellite Communicators

      November 10, 2021

      Gaia GPS

      Planning a Thru-Hike Next Year? Here’s What You…

      October 21, 2021

      Gaia GPS

      A Definitive Guide to the Best Camp Coffee

      September 30, 2021

      Gaia GPS

      Owls and UFOs with Ultralight Expert Mike Clelland

      September 9, 2021

  • Offroad Podcast
    • Gaia GPS

      Monique Song: How a City Girl Became the…

      April 7, 2022

      Gaia GPS

      TrailRecon Explains How to Become an Overlander Overnight

      March 9, 2022

      Adventures

      How to Stay Married on a Long-Distance Adventure

      February 9, 2022

      Adventures

      How to Go From ‘Desk to Glory’ in…

      January 12, 2022

      Gaia GPS

      The Best Advice We Received in 2021

      December 26, 2021

      Gaia GPS

      Gaia GPS’s Best New Overlanding Maps and Features…

      December 23, 2021

      Gaia GPS

      Inside the Never-Ending Road Trip with Dan Grec

      November 20, 2021

  • Adventures
    • User Stories
  • Activities
    • Backcountry Skiing
    • Boating
    • Emergency Response
    • Fishing
    • Offroading
  • New Features
    • Gaia GPS

      Meet Map Packs: A Totally New Way to…

      May 9, 2022

      Gaia GPS

      Top 10 Ways to Use Waypoints

      April 14, 2022

      Gaia GPS

      Discover & Reserve Campsites Right From Gaia GPS

      February 22, 2022

      Gaia GPS

      Navigate from the Dashboard with Improved Android Auto

      February 4, 2022

      Gaia GPS

      Trailforks Mountain Bike Trails now in Gaia GPS

      January 13, 2022

      Android

      Gaia GPS Year in Review: Best New Maps…

      December 28, 2021

      Gaia GPS

      Gaia GPS’s Best New Overlanding Maps and Features…

      December 23, 2021

  • New Maps
    • Featured

      Find Phone Signal With Cell Phone Coverage Maps

      May 2, 2022

      Adventures

      Using Gaia GPS to Find Free Camping in…

      March 9, 2022

      Gaia GPS

      Discover Snowmobile Trails Across the Globe

      February 9, 2022

      Gaia GPS

      Get Worldwide Ski Resort Reports in Gaia GPS

      January 25, 2022

      Gaia GPS

      Trailforks Mountain Bike Trails now in Gaia GPS

      January 13, 2022

      Android

      Gaia GPS Year in Review: Best New Maps…

      December 28, 2021

      Gaia GPS

      Gaia GPS’s Best New Overlanding Maps and Features…

      December 23, 2021

  • Home

Technical Post: UISegmentedControl subclass for iOS5

by Andrew Johnson September 6, 2011
by Andrew Johnson September 6, 2011

Lately, we have been tweaking our apps to be compatible with iOS5.

One thing we noticed is that the UISegmentedControl, which shows a bar of menu options, no longer works exactly as it did under iOS4. Specifically, when you programatically set the selectedSegmentIndex property, it no longer calls the associated method. Under iOS4, when the user pressed the menu option, or you set the index, the method would run. But under iOS5, it only gets run if the user presses the button. You can see this bug popping up on the internet here.

Rather than put a bunch of logic throughout my code to deal with this, I developed this subclass of UISegmentedControl on the advice of Anna, which works as expected. Download it from GitHub here.

iOS5technical post
0
FacebookTwitterRedditEmail
Andrew Johnson

Andrew founded Gaia GPS. He writes code and manages the business.

previous post
Download iBurn 2011 for Android
next post
Board Member’s Business

You may also like

Meet Map Packs: A Totally New Way to...

May 9, 2022

Fastpacking 101: What You Need for This Running-Backpacking...

May 5, 2022

Natural Navigation Clues: How to Find Your Way...

May 4, 2022

Find Phone Signal With Cell Phone Coverage Maps

May 2, 2022

Top 10 Ways to Use Waypoints

April 14, 2022

Monique Song: How a City Girl Became the...

April 7, 2022

How to Air Down Off-Road Tires for Overlanding

March 23, 2022

How to Check for Snow on the Trail

March 10, 2022

TrailRecon Explains How to Become an Overlander Overnight

March 9, 2022

Using Gaia GPS to Find Free Camping in...

March 9, 2022

Keep in touch

Facebook Twitter Instagram Youtube

Popular Posts

  • 1

    How to Read Topographic Maps

    July 1, 2021
  • 2

    How to Save Phone Battery Life in the Backcountry

    March 25, 2021
  • 3

    How to Download an Entire State Map with Gaia Topo

    August 19, 2021
  • 4

    Unlock Adventure with Gaia GPS on Outside+

    September 30, 2021
  • 5

    Using Gaia GPS to Find Free Camping in National Forests

    March 9, 2022

Categories

  • Adventures
  • Android
  • App Comparisons
  • App Updates
  • Backcountry Skiing
  • Boating
  • Company News
  • Emergency Response
  • Featured
  • Fishing
  • Gaia GPS
  • Gaia GPS Offroad Podcast
  • GaiaCloud
  • Hikes
  • How-To
  • Hunting
  • iOS
  • New Features
  • New Maps
  • Newsletter
  • Offroading
  • Out and Back Podcast
  • User Profiles
  • Facebook
  • Twitter
  • Instagram
  • Youtube
  • RSS

@2022 - All Right Reserved. Gaia GPS


Back To Top