UISlider not smooth - ios

I'm developing an iPad app and using a lot of UISliders. But when I test the app on an iPad 1, the sliders are not responding very smooth. I'm not doing anything when the value of the slider changes. Only when the slider is released (touch up inside/outside).
Also the touch up inside/outside method is not always called.
Is this a common problem on iPad 1 or is it caused by my app?

If you want to get an animation with slider, you should use [slider setValue:0.5 animated:YES] method of UISlider instance.

Related

Xcode: Keyboard interrupts a timer function

One of the screens of my iOS app has a textfield and an image which is smoothly rotating around and around via a NSTimer. When I tap the textfield and the keyboard pops up, the rotating image stalls for a fraction of a second. I assume this is because the keyboard code interrupts the execution of the image-rotation code. To solve this, will I have to learn about threading? Or is there a simpler solution?

UIView Animation Freezes

I'm implementing drag-keyboard dismissal (like in the iPhone Messages app) manually because UIScrollViewKeyboardDismissModeInteractive doesn't seem to work with a text view inside a toolbar above the keyboard.
It works in portraint mode, but in landscape orientation, sometimes when I animate the toolbar (which is actually just a UIView) & keyboard, they freeze. But, they did animate because I checked using breakpoints that the animation code ran and when I tap on the screen where they're supposed to be, I get the correct reactions (like keyboard keys pop up, etc.).
I'm using the old style of animations beginAnimations:context: because this is how to mimic the keyboard animation in iOS 7.
This seems like an iOS SDK bug. How do I fix this?
I was sometimes (when the pan velocity was large) using UIViewAnimationCurveLinear instead of the curve from the keyboard notification's userInfo. I took that condition out so that I always use the curve from the keyboard notification's userInfo and things seem to be working fine now.

How can I keep UIActionSheet from being dismissed when background touched?

The default behavior for the UIActionSheet used to be that touching the background did not dismiss it, and in fact did nothing. But with iOS 7 touching the background is equivalent to pressing the cancelButton.
I'm modifying some software that needs to be kept to the iOS 6 behavior. How can I keep touches of the background from dismissing the action sheet?
You can achieve this by not using a cancel button.
Check this SO post:
UIActionSheet in iOS7 dismissing when user taps ANYWHERE on the screen on iPhone

Neither touchUpInside nor toutchUpOutside is called on palm press/lift over several buttons

I am implementing an IOS APP with a view that provides a keypad for controlling a remote device and if you push on 6 or 8 (UI) buttons at the same time by using your palm then the App gets a touchDown but does not receive a touchUpInside or touchUpOutside when you lift the palm.
Problem is I start a timer upon the touchDown to repeat keys, but I never get a callback to end key repeats. Does anybody know how to deal with this.
I realize this is an anal scenario, but if repeats don't stop on time then expensive equipment could be damaged.
I am not sure this has any bearing on the situation but I am using ios 6 on an iPhone 5.
Is touching them at the same time also a requirement? If not, set exclusiveTouch to YES on all buttons. If yes, check UIControlEventTouchCancel as well.

UISlider is not smooth on first generation iPad

I am developing an iPad application and in my application I have used UISlider and I have tested my app in Ipad1 but it is not responding very smooth. But, the same application is responding very smooth in iPad 2nd gen.
In iPad first gen, every time I move the slider the slider value changed action is called but I'm not doing anything on that function. I am doing all my actions only on touch up inside and touch up outside. It is not working fine because it is not always called. Is there is any way to overcome this issue?
Using many UIImageView with partial transparent images or glow/shadow effects on UILabels and similar can slow down the application. It can be anything different from the UISlider which slows down the displaying of the UI.
Otherwise you have made something very CPU intensive in the observer of the UISlider.

Resources