6

デフォルトでは、iPadのモーダルフォームシートは角が丸くなっています。iTunesなどのAppleのいくつかのアプリでは、フォームシートの角が完全に正方形になっています。App Storeから拒否されないように、コーナー半径を削除する比較的簡単な方法はありますか?

4

1 に答える 1

3

これを表示しているビュー内に配置します。

//You will have to link to the QuartzCore library
#import <QuartzCore/QuartzCore.h>

- (void)viewDidLoad
{
    [super viewDidLoad]; 
    //set border radius on initial load
    self.view.layer.cornerRadius = 0;
}

- (void) didRotateFromInterfaceOrientation:(UIInterfaceOrientation)fromInterfaceOrientation {
     //for some reason the cornerRadius resets itself on orientation change
    self.view.layer.cornerRadius = 0;
 }
于 2011-07-13T02:59:04.517 に答える