Fluctuation in iPhone Screen when trying to open mapview - iphone

I have an app which has a functionality such that when a certain button is pressed, an alert view pops up asking for certain login credentials. When submitted, a web is called which returns that latitude and longitude which are then plotted on the mapview. In case the lat and long are not available, the user sees an alert. Till this stage all goes well. But when I press the cancel button on the second alert the iphone screen fluctuates. After that whenever I navigate to any other page, the screen fluctuates. When the sent to background and then brought to foreground again, it starts working fine. what can be the problem?

Related

is there a way to manage the duration of the remote notification to be displayed longer on the banner?

I am working on an App which I want the Playload notification to remain presented in the banner until the user clicks on it.
I have two cases:
App in background, after opening the app (not through the notification) the notification disappears.
App in foreground, the notification will be presented on the banner (I used: UNUserNotificationCenterDelegate for that) but after few seconds it disappears.
is there a way to manage the notification duration, I want it to be presented until the user clicks on it.
This is known as a Banner Style. It can be set to either Temporary or Persistent with persistent banners requiring user interaction to disappear. You can not manipulate the duration of your notifications being displayed on screen. The banner style for the application can only be changed by the user in the notification settings for your application:

Weird glitch with disappearing status bar / nav bar

I have an app that is similar to the photos app in that when a picture is displayed, it takes up the full 320x480 of the screen. Also like the photos app, when the user taps the screen, the status bar / nav bar fade out to provide extra space. Everything works fine, except I noticed one weird glitch. If I push the home button to exit the app (when the status bar / nav bar invisible), and then I push the apps logo to reenter the app, when the app reopens, the application frame gets screwed up, and the view that holds my picture gets pushed down 20 pixels (seemingly to make way for the status bar). Like I've said, it all works fine when I'm switching between views in my app, but when I push the home button to exit out, it messes up. Anyone ever have this problem before?
Perhaps you have to re-set your interface code in this App delegate method:
(void)applicationDidBecomeActive:(UIApplication )application {
/
Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface.
*/
}
In viewDidAppear method try the following :
self.navigationController.navigationBarHidden = TRUE;

how to display 2 different buttons instead of the notification close and view button in iphone

i am creating an alarm app by making of use of local notification.when i select a particular time from my date picker and click on the save button my notification gets set at that particular time.This has been done and i get the notification at proper time that i have set.but the problem is when my app is not running i get notification with 2 buttons i.e one for close and other for view details .when i click on close button my notification close and when the view details button is clicked it takes me to my app.But actually i dont't need this. i want in place of close button snooze button should be present and in place of view button stop button should appear. i.e when my alarm notification is fired i want that in place of close and view button stop and snooze button should appear.When i click on stop button alarm should get stopped and when the snooze button is clicked the alarm is delayed for 5 mins.Please help me in solving my problem.Thanks
The alert displayed by a push/local notification has either one (OK) button, or two buttons - the left button is always "Close" and the right button is either "View" or a string (for action-loc-key) you supply in the dictionary for the alert key of your payload.
The functionality you require isn't available using the notification alerts directly. Maybe your app could "snooze" by default (i.e. when the close button is pressed - so unless the app is started the alarm plays again after 5 minutes). If the user presses the View button (maybe re-titled "Cancel Alarm") the app starts and the alarm is cancelled.
See The Notification Payload in
http://developer.apple.com/library/ios/#documentation/NetworkingInternet/Conceptual/RemoteNotificationsPG/ApplePushService/ApplePushService.html

Detecting when 'Home' is pressed or app is resumed (Keyboard is covering View when it resumes)

In my iPhone app, if the user presses the Home button while the keyboard is up, then returns to the app, the keyboard is still up but my view behind is hidden behind it!
I have some code that normally would rise and lower the view as necessary, but I can't see how to call it in this situation. How can I either detect when Home has been pressed so I can lower the keyboard, or detect when the app has been resumed so that I can rise my view?
Your application delegate is sent the applicationDidEnterBackground: message:
You should perform any tasks relating to adjusting your user interface before this method exits
you can check with some notification and try this

Kal Calendar in Navigation Based Project - Crash with back button?

Here's the deal:
I have a navigation-based project with a menu screen as the root view. When I tap a button on the menu screen, the navigation controller pops a KalViewController onto the stack (kal calendar).
The calendar appears, and for about a 6 second period the calendar is downloading JSON data from the internet to populate the calendar with events. However, if the user taps Back (to go back to the main menu) during this time, the app crashes or the calendar continues to load the data even when I am on the main screen. (evidenced by the network activity indicator continuing to spin)
1-- I was wondering if there is any way, when I tap the Back button, to cancel that download process so that my objects will release properly? (maybe using threads??)
OR
2-- Somehow prevent the user from tapping the back button while the data is still downloading. (Similar to how a UIAlertView prevents a user from clicking anything on the screen except for 'OK' to dismiss the alert message)
PLEASE help! Thank you very much in advance!