Advertise Mobile SDKs Books Events Forum News Social Networking Support Us
Follow @iphonedevsdk on Twitter

Mockup & CodeGen, iPhone & iPad
($9.99)

Make your own iPhone apps
and run them live!
(free)

Manu
($0.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum > iPhone SDK Development Forums > iPhone SDK Development

Reply
 
LinkBack Thread Tools Display Modes
Old 06-26-2009, 12:12 AM   #1 (permalink)
Registered Member
 
Join Date: Feb 2009
Posts: 109
Default Urgent help needed. Modal View Controller inside navigation controller

Hi all,

I seem to have encountered possibly the strangest bug. When I use the presentModalViewController:animated method inside of a navigation controller with OS 3.0, when the controller is dismissed, it moves the navigation bar and any views I have inside the navigation controller.

I tried to compensate for this by calling a method that reset the frames of my objects, and that seemed to resolve it. However, as I was getting ready to submit my app, I came across an even stranger issue. When I present the UIImagePickerController with the photo library, or with the source being a camera on an iPhone 3G, everything works. However, the camera on my new 3GS moves the view differently than the iPhone 3G, or even the photo library source on the same phone! this, therefore makes it impossible to compensate for the view moving, which it probably shouldn't do at all.

Am I doing something wrong? It seems to me the view shouldn't move at all but it does. I would use my Apple code level assistance on this one, but I am leaving for a trip in a few days, without my computer.
brian515 is offline   Reply With Quote
Old 08-21-2009, 08:06 AM   #2 (permalink)
Registered Member
 
Join Date: Aug 2009
Posts: 1
Default

This is because you are trying to dismiss modal view and at the same time to push another view controller to the navigation controller. Just push the next view controller within a delayed method after modal view dismiss method call.

Quote:
Originally Posted by brian515 View Post
Hi all,

I seem to have encountered possibly the strangest bug. When I use the presentModalViewController:animated method inside of a navigation controller with OS 3.0, when the controller is dismissed, it moves the navigation bar and any views I have inside the navigation controller.

I tried to compensate for this by calling a method that reset the frames of my objects, and that seemed to resolve it. However, as I was getting ready to submit my app, I came across an even stranger issue. When I present the UIImagePickerController with the photo library, or with the source being a camera on an iPhone 3G, everything works. However, the camera on my new 3GS moves the view differently than the iPhone 3G, or even the photo library source on the same phone! this, therefore makes it impossible to compensate for the view moving, which it probably shouldn't do at all.

Am I doing something wrong? It seems to me the view shouldn't move at all but it does. I would use my Apple code level assistance on this one, but I am leaving for a trip in a few days, without my computer.
coderman is offline   Reply With Quote
Old 10-01-2009, 10:26 AM   #3 (permalink)
Registered Member
 
Join Date: Jun 2009
Posts: 6
Default

I think I'm having the same problem.
I just present the modalvc and when it is dismissed, the navigationbar moves down.

Did you find the solution?


Hami

Quote:
Originally Posted by brian515 View Post
Hi all,

I seem to have encountered possibly the strangest bug. When I use the presentModalViewController:animated method inside of a navigation controller with OS 3.0, when the controller is dismissed, it moves the navigation bar and any views I have inside the navigation controller.

I tried to compensate for this by calling a method that reset the frames of my objects, and that seemed to resolve it. However, as I was getting ready to submit my app, I came across an even stranger issue. When I present the UIImagePickerController with the photo library, or with the source being a camera on an iPhone 3G, everything works. However, the camera on my new 3GS moves the view differently than the iPhone 3G, or even the photo library source on the same phone! this, therefore makes it impossible to compensate for the view moving, which it probably shouldn't do at all.

Am I doing something wrong? It seems to me the view shouldn't move at all but it does. I would use my Apple code level assistance on this one, but I am leaving for a trip in a few days, without my computer.
hamiseixas is offline   Reply With Quote
Old 10-01-2009, 10:15 PM   #4 (permalink)
Registered Member
 
Join Date: Feb 2009
Posts: 109
Default

Quote:
Originally Posted by hamiseixas View Post
I think I'm having the same problem.
I just present the modalvc and when it is dismissed, the navigationbar moves down.

Did you find the solution?


Hami
I just compensated for the moving nav bar by resetting the frame when I dismiss the controller. I created my nav controller in the app delegate, so I call a method in the delegate that moves the bar to the original position.
brian515 is offline   Reply With Quote
Reply

Bookmarks

Tags
move, navigation bar, navigation controller, uiimagepickercontroller, view

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



» Advertisements
» Online Users: 259
18 members and 241 guests
14DEV, @sandris, ADY, ArtieFufkin10, bookesp, ckgni, Dani77, DarkAn, HemiMG, iDifferent, jakerocheleau, JasonR, prchn4christ, Rudy, ryantcb, Speed, theone8one
Most users ever online was 1,187, 10-11-2011 at 08:09 AM.
» Stats
Members: 158,885
Threads: 89,230
Posts: 380,767
Top Poster: BrianSlick (7,129)
Welcome to our newest member, bookesp
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 02:47 PM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0