uiwindow

Automatically Sizing UIView after Adding to Window

Note: This may be a duplicate of Subview Doesnt AutoSize When Added to Root View Controller I have an iPad app that switches between different views in its main window. The view-switching code looks like this: - (void)switchToViewController:(UIViewController*)viewController { if (currentViewController != viewController) { ...

Using UIScreen to drive a VGA display - doesn't seem to show the UIWindow?

HI there, I'm trying to use UIScreen to drive a separate screen with the VGA dongle on my iPad. Here's what I've got in my root view controller's viewDidLoad: //Code to detect if an external display is connected to the iPad. NSLog(@"Number of screens: %d", [[UIScreen screens]count]); //Now, if there's an external screen, we need to...

Get name of current view residing in a UIWindow

Hello experts! Let's say I add a new view to my UIWindow [windowRoot addSubview:MyNewView.view]; Is it possible to retrieve the name of that view later on if I have reference to windowRoot? Something like: [windowRoot getCurrentViewName] Thank You ...

Begning iPhone dev. help - UIBarButton onclick goto ordre Window?

Hello all. i need help to get over my trobel, i a'm relly begninger to Apple iPhone App Dev. soe now i what to learn it. First troble i have its how can i make my ToolBar UIBarButton to go to a ordre pages, its becures i need to load a ordre data into this plase. i hove i can be help here. :) ...

Recommended Way To Go Full Screen

I want to have a UIView take over the whole screen to display an image from time to time, but most of the time I'm using a UISplitViewController for the main app functionality. Is there a recommended/best practice way to do this? Right now, I have a pointer to the main window and am just adding the UIView as a sub view and bringing it to...

Getting x/y coordinate of a UITouch...

HI, I have been trying to get the x/y coordinates from a touch on any iDevice. When getting the touch locations, everything looks ok if the touch is in the middle of the screen. But if I drag my finger to the bottom of the screen, I can only get a y coordinate of 1015. It should be getting to 1023. Same thing for dragging my finger to ...

UIVIewController wrong position before rotate

I have the starter point of my application this window (white background): - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { mainScreen = [[MainScreenController alloc] initWithNibName:@"MainScreenController" bundle:[NSBundle mainBundle]]; // add it to the main window ...

iPhone: force from subview to remove itself

Hello In appdidfinishlaunch I'm loading a tabbarcontroller as subview and after that im loading an other view MySubView * mySubView = [[MySubView alloc] init]; [window addSubview:mySubView]; [mySubView release]; I want to close that toplayer with a buttonclick in the subview, so I set up an IBAction and tried diffrent things to force...

Convert a UIView origin point to its Window coordinate system

Hi, I want to get the origin of scrollView in the window coordinate system. For Example, presently, scollView origin is (0,51). But in window coordinate system it should be 51 + 44(navigation bar height)+20(status bar height) = 115. Means in window coordinate system the scrollView.frame.origin should be (0,115). I tried with convertPoint...

How to hide kewwindow from view .

Hi, I am trying to hide UIWindow from view controller , NSArray *windows = [[UIApplication sharedApplication] windows]; if ([windows count] > 1) { UIWindow *moviePlayerWindow = [[UIApplication sharedApplication] keyWindow]; [moviePlayerWindow addSubview:CustomButton]; } But come back to view controller i am not able to h...

Views, View Controllers, Windows.. Huh?

Starting from the base OpenGL ES iPhone project in XCode, I am creating an app which is nearly completed. What I don't understand is the use of views, view controllers, and windows which I apparently need to implement to use iAds (for the iPhone) and AdMob (for the iPad). I was able to follow the AdMob tutorial using the Interface Buil...

iAds with tab bar applications...

Hello. I've been able to incorporate all of Apple's code, delegation, etc related to iAds... in simple view based applications. Tab bar type applications seem more difficult... perhaps I don't understand the overall architecture of those apps. It seems that say if there are 3 tabs and views corresponding to those tabs that the other t...

custom UIWindow orientation

I needed to see touch events on my window, so I subclassed UIWindow to make my a MYWindow class. I am overriding the sentEvent function to receive the touch events on the window and all of that is working just fine. I did the following to achieve this: self.window = [[MYWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]]; [win...

Only direct subviews of the MainWindow view gets orientation set by iOS?

Hey guys, Whenever my app is rotated, only the viewController of which I've added his view as a subview to the mainwindow gets his interfaceOrientation property updated, the rest remains ignorant of the fact the device has been rotated. Is it my responsibilty to notify other objects of the change, and if so, what's a nice way to do it?...

iphone keyboard touch events

I need to be able to detect touch events on the keyboard. I have an app which shows a screen which occurs after a certain period of inactivity (i.e. no touch events) To solve this issue, I have subclassed my UIWindow and implemented the sendEvent function, which allows me to get touch events on the whole application by implementing the...

Shake Gesture detection in UIWindow subclass takes over default text undo manager

What I want is having my iPhone app aware of shaking gesture all the time except when any UITextfield or UITextview become firstResponder. (I followed this: http://stackoverflow.com/questions/150446/how-do-i-detect-when-someone-shakes-an-iphone/1351486#1351486I) I subclass UIWindow and implemented motionEnded:withEvent: method and it w...

Multiple Windows Rotation Problem - iPhone / iPad

My app uses 2 UIWindows. The first shown has a TabBar controller with ViewControllers that only rotate to Portrait orientations. Up to here everything woks fine. - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation { return (UIInterfaceOrientationIsPortrait(interfaceOrientation)); } On the othe...

two sub UIwindow in one UIWindow?

hi, when we create iphone project, one UIWindow is created automatically.In that UIwindow UIViewcontroller's view is added on that window.but i want to create one parent UIWindow on which i have to add two sub window .In that sub windows i have add UIview controllers as normal...is it possible? any help please? ...

more UIwindow is possible in iphone sdk?

hi, My UIWindow has twoviewcontroller in pad .(for example ,tableview and imageviewcontrller ) I have done flipanimation when user presses the tableview, i called the method which is in appdeleagte from didSelectRowAtIndexPath ..(LIKE SPLITVIEWCONTROLLER) the method in t didSelectRowAtIndexPath iPadButtonsAppDelegate *mainDelega...

touch on UIwindow?

i have four viewcontroller in my UIwindow.i want to interchange my viewcontroller's view among four through UItouch in UIWindow?is it possible to handle touchmoved in appdelegate.m file to change the frame origins of those viewcontrollers? ...