Using some of the methods, I am able to check the orientations to which I am rotating my device. But how can I know the orientation in which I am in when the app is loaded? I want to write the code to rearrange the views in the viewDidLoad method by checking the way my orientation is in?
...
SignView *tempVC = [[SignView alloc] initWithNibName:@"SignView" bundle:Nil];
[UIView beginAnimations:nil context:nil];
[UIView setAnimationTransition: UIViewAnimationTransitionCurlUp forView:self.view cache:YES];
[UIView setAnimationDelay:0.5f];
[UIView setAnimationDuration:2.0f];
[UIView commitAnimations];
[self presentModalViewCon...
In my iPhone OS application I want (need) to watch for chances in the device orientation in order to rearrange certain portions of the screen. The approach I used was to use GRect frame = [UIScreen mainScreen].applicationFrame to get the screen size, and from there calculate the size and / or positioning of other controls. (I also tried ...
I have a UIView with another UIView inside it. On the inside UIView there is a textbox which I want to fill in. When I try to fill it in the keyboard blocks my view:
The UIViewController has the following
containerView = [[UIView alloc] initWithFrame:[UIScreen mainScreen].bounds];
self.view=containerView;
//The apropriate releases etc ...
I was surprised not to find an answer to this question, maybe is something very simple I somehow overlook :
How to get the real size of an UIView after I apply a CGAffineTransform to it?
eg.
my UIView has size 300 x 200, I apply a scaling transform let's say factor 2 both horizontal and vertical, so the UIView now takes 600 x 400 on...
Hi
I have one main view where I display an image, in the method viewDidLoad:
ballRect = CGRectMake(posBallX, 144, 32.0f, 32.0f);
theBall = [[UIImageView alloc] initWithFrame:ballRect];
[theBall setImage:[UIImage imageNamed:@"ball.png"]];
[self.view addSubview:theBall];
[laPalla release];
Obviously, the value of posBallX is defined...
hi,
is it possible to design a view in interfacebuilder and use it dynamically a few times?
the view structure is
- UIScrollView
- UIView
- UIImageView
- UILabel
now i want to dynamically create multiple instances of the UIView in a for loop with different UILabels and UIImageViews. I want to give them side-by-side in the...
How to create a pop up animation on iPhone? I want show my uiview as a popup view, like uialertview design.
...
I have iPhone (iPhoneOS 3.x) OpenGL ES app that:
can be in landscape/portrait orientation
can be with/without status bar shown
I do this by changing status bar orientation and hidden state, then updating OpenGL view frame so it won't overlap status bar and setting projection matrix appropriately.
OpenGL view is in portrait ori...
Hi. I'm afraid no amount of Googling has been able to save my hyde on this. I seem to be getting SIGABRT error anytime I touch the screen of the phone, on any UIView. The debugger console posts this error before the SIGABRT:
.... [310:207] *** -[UIView _exclusiveTouchView]: unrecognized selector sent to instance 0x14c0c0
.... [310:2...
hi,
i made a second uiview in mei .xib file. the first view is landscape and i get it by following code
ItemController *newItem;
newItem = [[ItemController alloc] init];
newItem.view.....
how can i "activate" the second view, so i can use it with
newItem.view2...
is that possible? the second view is portait mode, so it should be h...
is there a way to get the current UIView object, which i defined in
- (void)viewDidLoad
to use/change them in another method in the same .m file?
thanks
...
Hello, all.
I've got next problem: i've got 3 UIViewController and need to switch controllers by UIModalTransitionStyleFlipHorizontal.
Next code working fine:
testController.modalTransitionStyle = UIModalTransitionStyleFlipHorizontal;
[self presentModalViewController:testController animated:YES];
where testController - next control...
Hello,
I want to create 25 buttons in my view. Should I create 25 buttons(UIbutton butonwithtype) individually or is there any other alternative ? Please comment if the Question is not understood by you.
...
I found this post on Beveled UITableViewCells from http://news.selectstartstudios.com/beveled-uitableviewcells/. I'm using the technique to reduce the width of the cells, and for the most part it works great.
However, I have a small problem. Sometimes the cells are not redrawn properly. For example, even though a cell is supposed to be ...
Hello,
I added a table view into a view in interface builder and now I need to wire it up to some pre-made classes that you can generate in xcode. I set the tableview controller's class to the class in xcode and wired the dataSource and delegate to my table view but the app just crashes. Im not sure how to get data to properly load into...
Hi all,
I subclassed UIImageView for controlling touch events.
The problem is that when i do userInteractionEnabled = NO, it doesn't work, i can still touch it and the touch methods response.
Even if i add big subview over it the touches happen.
Any suggest?
...
I have some custom UITableViewCells that are made programmatically as needed, I want these to resize. However, when I add autoresizingMasks to the UILabels in the cells, they all seem to stretch wider while anchoring to the left side.
// This works fine
UILabel *aField = [[UILabel alloc] initWithFrame:CGRectMake(60, 2, tableView.frame.s...
Short & sweet version of my last question in light of new information.
I have a UIVIew with an init and a drawrect method (and another thread and a bunch of other stuff, but I'll keep it short & sweet).
All of the class variables that I alloc and init in the -(id)init method are out of scope/nil/0x0 in the drawRect method, and I am una...
I have a uiview class and i want to switch to other uiview class but without using addsubview
is there any other way to do that except the one (addSubView)
...