Discussion Forums  >  Uncategorized

Replies: 17    Views: 1770

mutzy
Aspiring developer
Profile
Posts: 841
Reg: Nov 03, 2010
Medford, MA
9,860
03/11/11 03:32 PM (14 years ago)

New issue with iOS navigation bar and screen rotation

As you know from my earlier post I recently upgraded my phone to 4.3 and got xcode 4.0. I re-downloaded my app and it installed fine but now I'm noticing some new issues with the navigation bar and screen rotation. 1. Navigation bar: when the app first loads the home screen appears and the nav bar is at the top where it should be (I have a grid layout with 9 images spread equally throughout the screen). However, when I pick any of the icons the next screen loads with the navigation bar approx 2mm lower than it should... with the background color showing above and blocking the top of my menu lists. If I try going back to the home screen it stays this way. If I exit and start the app again it goes back to normal. 2. It's having issues with landscape. If I hold the phone in landscape and start the app the home screen loads fine, but then every other screen tries to load in portrait view cutting out most of the screen. Also, if I start in portrait then go to a submenu and THEN put in landscape position, all the submenus work fine but if I go back to the home screen then its the home screen that tries to load in portrait and is cut off on the sides. Weird. Is this from ios 4.3?? Same thing happens in the simulator... Josh
 
David @ buzztouch
buzztouch Evangelist
Profile
Posts: 6866
Reg: Jan 01, 2010
Monterey, CA
78,840
like
03/11/11 11:19 PM (14 years ago)
This is weird behavior. We've not experienced it on this end? I dug through the 4.3 docs to see if there were any changes to the screen's layout behvior, rotation, etc. Didn't find much. I did find a few lines of code that were commented out and noted in BT_viewUtilities.m and .h. Both of these files have been updated on the download server. To this: a) redownload the reload the app in the sim. b) If you have the same trouble, don't change ANYTHING in the control panel then nudge this post so we can see exactly how your app's configured. c) Post the app name - we'll figure it out?
 
mutzy
Aspiring developer
Profile
Posts: 841
Reg: Nov 03, 2010
Medford, MA
9,860
like
03/12/11 04:25 AM (14 years ago)
I redownloaded my app and tried running it in the iphone 4.3 simulator... it received 2 errors from the BT_screen_images.m file that say GCC 4.2 error, incompatible type for argument 1 of set frame. I tried my app again from yesterday and it loads fine but still has the weird behavior. Here are some screen shots: 1. http://erresapp.com/files/1.PNG (navigation bar too low) 2. http://erresapp.com/files/2.PNG (problems with landscape) My app's name is ERres. Thanks!
 
Torben
Lost but trying
Profile
Posts: 25
Reg: Feb 10, 2011
Denmark / Germa...
250
like
03/12/11 09:51 AM (14 years ago)
hi... same problem here. 2 errors and 2 warnings in BT_screen_images.m / line 70 and 487. i have insert :screenData in both. after that i could compile. Line 70: before: [toolbar setFrame:[BT_viewUtilities frameForToolBarAtOrientation:self]]; after: [toolbar setFrame:[BT_viewUtilities frameForToolBarAtOrientation:self:screenData]]; Line 487: before: [toolbar setFrame:[BT_viewUtilities frameForToolBarAtOrientation:self]]; after: [toolbar setFrame:[BT_viewUtilities frameForToolBarAtOrientation:self:screeenData]]; is that okay? greetings Torben PS: sorry, my english isnt that good.
 
David @ buzztouch
buzztouch Evangelist
Profile
Posts: 6866
Reg: Jan 01, 2010
Monterey, CA
78,840
like
03/12/11 12:33 PM (14 years ago)
Hmmm... it looks like both of you ended up with an older version of this file (.m, .h). It's tough to say how? We may not have uploaded the correct version last time the download server was uploaded. I have re-uploaded the latest version of the files. @Torben: Yes, the frameForToolBarAtOrientation method does NEED a screenData object to work. Good work.
 
mutzy
Aspiring developer
Profile
Posts: 841
Reg: Nov 03, 2010
Medford, MA
9,860
like
03/12/11 04:11 PM (14 years ago)
Okay, I tried re-downloading my app again and I'm still getting an error message right off the bat but now only one. This is what it says: i686-apple-darwin10-gcc-4.2.1: /Users/mutzy94/Desktop/Josh/BT_Screens/BT_screen_audio.m: No such file or directory i686-apple-darwin10-gcc-4.2.1: warning: '-x objective-c' after last input file has no effect i686-apple-darwin10-gcc-4.2.1: no input files Command /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc-4.2 failed with exit code 1 I even tried copying the BT_Screens folder from my original app into the project I just downloaded and got even more errors. Not sure what's going on.
 
David @ buzztouch
buzztouch Evangelist
Profile
Posts: 6866
Reg: Jan 01, 2010
Monterey, CA
78,840
like
03/12/11 04:33 PM (14 years ago)
'no such file or directory' Look in the BT_Screens folder in the project, does the BT_screen_audio.m AND BT_screen_audio.h file exist? Xcode says it can't find these files, they should be included in the download.
 
mutzy
Aspiring developer
Profile
Posts: 841
Reg: Nov 03, 2010
Medford, MA
9,860
like
03/12/11 04:36 PM (14 years ago)
There are no such files included in my BT_Screens folder. However, they're not in my initial project either and that compiles fine.
 
David @ buzztouch
buzztouch Evangelist
Profile
Posts: 6866
Reg: Jan 01, 2010
Monterey, CA
78,840
like
03/12/11 07:41 PM (14 years ago)
Plz see the change-log assoicated with your v1.5 application. I'll be the project has been updated since the last time you downloaded it ;-)
 
mutzy
Aspiring developer
Profile
Posts: 841
Reg: Nov 03, 2010
Medford, MA
9,860
like
03/12/11 07:36 PM (14 years ago)
I'm confused. I don't see anything in the change log associated with my problem. I tried re-downloading my app yet again just now and get the same error as before about missing the BT_screen_audio.m file. Also, as I mentioned in my last post, the version of my app that's saved on my laptop (from a few days ago) still builds properly in both the simulator and my iPhone despite not having that file either. And I never had the problem with the navigation bar or with landscape mode this past week (after downloading the new xcode and version 4.3 for my iphone).
 
mutzy
Aspiring developer
Profile
Posts: 841
Reg: Nov 03, 2010
Medford, MA
9,860
like
03/12/11 07:40 PM (14 years ago)
Wait, I can get it to build now. The BT_screen_audio.h and BT_screen_audio.m files were included in the xcode project but the actual files weren't in the BT_screen folder. I deleted them from Xcode and now it compiles fine. However, using the iphone simulator, I still have the problem of the navigation bar being offsest and problems with landscape. Just try going through the menus in landscape mode and you'll see what I mean. Josh
 
David @ buzztouch
buzztouch Evangelist
Profile
Posts: 6866
Reg: Jan 01, 2010
Monterey, CA
78,840
like
03/12/11 08:11 PM (14 years ago)
We've got some issues happening with the download server and are working hard on figuring out what the heck happened! You'll notice a message on the download screen. There are several files that are not included in the download that need to be. It looks like this has been happening for a few days and were not sure what's going on yet. I also think this issue is related to the layout-logic because so many source-code files work together to make this work. Thanks for he patience while we work this out and look for a message in the change-log soon.
 
mutzy
Aspiring developer
Profile
Posts: 841
Reg: Nov 03, 2010
Medford, MA
9,860
like
03/13/11 08:49 PM (14 years ago)
Just downloaded the newest package and it loads in the simulator perfectly. However, I'm still having the same problems as before with regards to rotating the device and the navigation bar. PLUS, something new! My background screen is now black despite the fact that my background color is set to blue in the theme. The app I have installed on my phone is blue but the simulator is black. Weird. To see what I mean with the rotation, if you view my app (ERres) in the iphone simulator, open the app and rotate the device to the right. You will see that it tries to stay in portrait and half the screen is lost. This is also when the nav bar comes down and stays that way. Not sure what else to do...
 
David @ buzztouch
buzztouch Evangelist
Profile
Posts: 6866
Reg: Jan 01, 2010
Monterey, CA
78,840
like
03/13/11 09:56 PM (14 years ago)
This is screwy - FINALLY see what you're talking about. Super strange, not something I've seen before... looking...Can't be that hard to figure out. Stay tuned.
 
David @ buzztouch
buzztouch Evangelist
Profile
Posts: 6866
Reg: Jan 01, 2010
Monterey, CA
78,840
like
03/13/11 10:05 PM (14 years ago)
Don't be surprised if you see the modified date for this app in your control panel change, I'm making some adjustments to see what I can figure out.
 
David @ buzztouch
buzztouch Evangelist
Profile
Posts: 6866
Reg: Jan 01, 2010
Monterey, CA
78,840
like
03/13/11 11:56 PM (14 years ago)
Hi again... OK, figured out lots of stuff in this marathon of a thread ;-) Firstly, yet another project-update has been prepared for download, go ahead and get it again. I'm really hoping you have your files organized so you can just drag the into Xcode each time you re-download? Hate to think you have to do something over and over. There are two issues going on here. The background color settings were really getting messed up when trying to use the WORDS you entered for colors (white, black, etc). There were lots of places in your settings (Theme, Screen advanced settings) where you had the word BLACK instead of the HEX code for black #000000 Same for WHITE. Example, you had WHITE set as the tab-background color. You aren't using a tabbed app? This was killing the Objective-C code. The project only understands HEX codes for colors with the exception of two keywords: CLEAR or STRIPES (for native ios background look). Rotations: This trouble is being caused by the combination of going from a button screen to a 'grow' transition to a menu-list. I'm thinking this is the first we've seen this used in this order. The GROW transition was / is the problem. I spent awhile trying to figure it out before I put it off for another time - have to for now. But, I did get everything working from the button menu home screen by setting the transitions to FADE instead of GROW. It looks pro and works well. I'll have to re-calculate lots of things to get the GROW transition to work from buttons to lists - not sure how yet? I'll get it evenutally. Re-download....lemme know.
 
mutzy
Aspiring developer
Profile
Posts: 841
Reg: Nov 03, 2010
Medford, MA
9,860
like
03/14/11 05:28 AM (14 years ago)
Sorry to keep you so busy! Off to a 12 hour shift at the hospital but I'll try it tonight after changing my transitions to fade. As far as background colors go, I'll make sure all of them are set to the hex format. From what I remember I only put a few of the custom html screens to use a different background since it was messing up the website. Thanks so much for your help and I'll let you know if everything worked!!
 
David @ buzztouch
buzztouch Evangelist
Profile
Posts: 6866
Reg: Jan 01, 2010
Monterey, CA
78,840
like
03/14/11 09:55 AM (14 years ago)
Go save some folks and get back to this whenever. I've already changed the transition types in your app (to fade, instead of 'grow') so you should be able to just download, compile, smile. Thanks for the kind words.
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.