Advertise here




Advertise here

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Sign In with Google Sign In with OpenID
Please do not post the same thing multiple times. The board software automatically flags certain posts as needing moderator attention. This happens the most often for new users. I'm pretty sure this is made clear at the time you attempt to post. Posting the same thing over and over again just makes that many more posts the moderators have to weed through later. This makes us sad. Don't make us sad. If your post/thread doesn't appear, just wait a while. Don't post it again. If it hasn't shown up by the next day, then you can try again. I normally go through posts in the mornings, and try to check a few times throughout the day, but I'm not here 24/7. There will typically be a significant delay before posts are approved. Just be patient.

Another Landscape thread.

Hi everyone,

I have read a bunch of threads on how to make my application landscape, but I'm having a small, but major problem.

What my requirement is to have a window in Landscape mode, that shows an image as its back ground, with an edit control where the user can type a word or two and press a button to submit the information. I don't even know if that is possible?
Since I can't activate the edit control, I don't even know if the keyboard shows up correctly when the application is in landscape mode!


Here are the steps so far:
1. I created an application using the Window-Based Application wizard.
2. I placed an edit control on the window.
3. Then I put an entry in my info.plist for UIInterfaceOrientation = UIInterfaceOrientationLandscapeRight. This caused the application to put the status bar along the right edge of the iphone, but the window was still in portrait mode.
4. I added these lines to the applicationDidFinishLaunching method to rotate the window:
window.transform = CGAffineTransformMakeRotation(M_PI/2);
window.center = window.center; //no sure what this is really going to do!

At this point the window was rotated but I couldn't see my edit control, as the window was still (0,0,320,480). There were two black area on either side of the window. Seemed like it didn't resize the window to fit the landscape mode.

5. So I added this line before the two above.
window.bounds = CGRectMake(0,0,480,320);

At this point the window is displayed correctly. But I can't interact with the edit control on the window, when I click on it to fill it in nothing happens!


Thanks
Sign In or Register to comment.