草庐IT

UIActionsheet

全部标签

ios - swift 中的 UIActionSheet 将取消按钮放在 iOS 7 的顶部

我正在将我的应用程序从objective-c重写为Swift,我注意到UIActionSheet在Swift版本中的行为与在obj-c版本中的行为不同。Obj-c版本快速版本这仅在iOS7上存在问题,它在iOS8上对于Swift和Obj-c版本都工作正常(意味着取消在底部)这是一段相关的代码:varsheet=UIActionSheet(title:nil,delegate:self,cancelButtonTitle:"Cancel",destructiveButtonTitle:nil)sheet.addButtonWithTitle("Camera")sheet.addButto

ios - 代码 : sharing content via Action Sheet

我想复制这种行为(见下图)并使用这种操作表分享我的应用中的内容。问题是:这真的是行动表吗?我在任何地方都找不到适用于iOS7或8的教程。不确定如何继续。共享选项是否取决于用户的配置?将不胜感激。 最佳答案 它不在UIActionSheet中,它在UIActivityController中,这是iOS中的默认函数。objective-C-(void)presentActivityController:(UIActivityViewController*)controller{//foriPad:makethepresentationa

ios - 代码 : sharing content via Action Sheet

我想复制这种行为(见下图)并使用这种操作表分享我的应用中的内容。问题是:这真的是行动表吗?我在任何地方都找不到适用于iOS7或8的教程。不确定如何继续。共享选项是否取决于用户的配置?将不胜感激。 最佳答案 它不在UIActionSheet中,它在UIActivityController中,这是iOS中的默认函数。objective-C-(void)presentActivityController:(UIActivityViewController*)controller{//foriPad:makethepresentationa

ios - UIActionSheet block View Controller dealloc

在我的Viewcontroller中,我点击一个按钮启动这个简单的代码-(IBAction)tapOnButton:(UIButton*)sender{UIActionSheet*act=[[UIActionSheetalloc]initWithTitle:@"test"delegate:selfcancelButtonTitle:@"aa"destructiveButtonTitle:@"bb"otherButtonTitles:@"cc",nil];[actshowFromRect:CGRectMake(50,50,100,100)inView:self.viewanimated:

iphone - UIActionSheet 在 3.5 英寸设备上的高度为 4 英寸

我目前正在更新我的应用程序以支持4英寸iPhone5屏幕。在那次尝试中,我被困在打开UIActionSheet的这一点上,它工作正常并在iPhone54英寸屏幕上显示所有按钮,但在3.5英寸设备上最后一个按钮被切断。这表明UIActionSheet无法识别较小的屏幕。这就是我在代码中所做的。有什么想法吗?UIActionSheet*popupQuery;//CodetoinitializeUIActionSheetpopupQuery.actionSheetStyle=UIActionSheetStyleBlackTranslucent;[popupQueryshowInView:[U

iphone - 将 UIPickerView 添加到 UIActionSheet(底部的按钮)

我要显示选择器View(向上滑动)在背景可见时停用背景在底部(而不是顶部)显示(UIActionSheet)按钮起初在我看来这是一个简单的解决方案,因为您可以在网络上的任何地方找到用于将选择器View添加到操作表的代码,但所有解决方案都将按钮放在顶部,我需要将按钮放在操作表底部(对齐?)。这可能吗?我想如果我看一下:Example问候杰文已编辑(我的解决方案基于编码爸爸解决方案)UIActionSheet*actionSheet=[[UIActionSheetalloc]initWithTitle:nildelegate:nilcancelButtonTitle:nildestruct

ios - 在 IOS8 Xamarin 替换中使用 Datepicker 的 UIActionSheet

我准备对XamarinIOS项目(我是全新的)进行一些更改,但我很快发现,我们的项目无法正常工作。//saveouruiviewownerthis._owner=owner;//configurethetitlelabel_titleLabel.BackgroundColor=UIColor.Clear;_titleLabel.TextColor=Colors.backgroundcolor;_titleLabel.Font=Fonts.HelveticaNeueLight();//configurethedonebutton_doneButton.SetTitle("OK",UICo

ios - Xcode4.3 UIActionSheet 导致错误信息

该应用程序在测试时运行良好,但在delegate:self旁边我得到...Sending'ViewController*const__strong'toparameterofincompatibletype'id'非常感谢任何帮助,因为我已经处理了好几天了!我的Viewcontroller.h是...#import#import#import"Accounts/Accounts.h"#import@interfaceViewController:UIViewController{UIAlertView*objresponseAlert;}@property(weak,nonatomic

iphone - UIActionSheet 委托(delegate)方法未被调用

我有一个操作表,它似乎只在我单击"is"按钮时调用clickedButtonAtIndex委托(delegate)方法,而不是在“否”按钮上...这是代码:self.myActionSheet=[[UIActionSheetalloc]initWithTitle:@"Test"delegate:selfcancelButtonTitle:@"No"destructiveButtonTitle:@"Yes"otherButtonTitles:nil];[self.myActionSheetshowInView:self.view];[myActionSheetrelease];然后是委托

iphone - iPad 上 UIActionSheet 的问题

我正在制作一个与iPhone和iPad兼容的应用程序,并且我在操作表中显示了一个选择器,如下所示:actionSheet=[[UIActionSheetalloc]initWithTitle:@"Day/Month"delegate:selfcancelButtonTitle:nildestructiveButtonTitle:nilotherButtonTitles:nil];picker=[[UIPickerViewalloc]initWithFrame:CGRectMake(0,40,0,0)];picker.delegate=self;picker.showsSelection