1

次のプルアップは、カスタマイズされた UI 要素の下にある [プロフィール写真の設定] ですか、それともデフォルトの要素ですか? それがデフォルトの場合、iPhone アプリに追加するにはどうすればよいですか?

ここに画像の説明を入力

4

2 に答える 2

1

そのUIActionSheet

ドキュメントの読み取り: UIActionSheet

基本的には次のように機能します。

 - (void)iWantToShowAnActionSheet
{
  UIActionSheet* sheet = [[UIActionSheet alloc] initWithTitle:@"Set profile photo"
                            delegate:self
                            cancelButtonTitle:@"Cancel"
                            destructiveButtonTitle:nil
                            otherButtonTitles:@"Choose existing photo",@"Take new photo"];
  [sheet showInView:self.view];//example for using it in viewcontroller.
} 

それを表示する他の方法については、「アクション シートの提示」の下にあるデモ (上部にあるリンク) を参照してください。

于 2013-11-06T19:02:10.630 に答える
0

の新しい外観です。これはデフォルトの iOS7 UI 要素です。titleあなたのスクリーンショットでは、アクション シートの [ Set profile photo] 部分が設定されています。

initWithTitle:delegate:cancelButtonTitle:destructiveButtonTitle:otherButtonTitles:

UIActionSheet クラス リファレンス

iOS6 では、次のようになりました。

ここに画像の説明を入力

出典:apple.developer.com

于 2013-11-06T18:56:32.723 に答える