gpt4 book ai didi

ios - 底部共享菜单 iOS [Obj-c]

转载 作者:可可西里 更新时间:2023-11-01 17:14:15 33 4
gpt4 key购买 nike

如何在我的应用程序中像这样在一个屏幕中创建底部共享菜单
它应该带有按钮和 Collection View 的简单 View 还是外部框架?

最佳答案

代码:

NSArray * activityItems = @[@"",[NSURL URLWithString:@"http://www.example.com"]];
NSArray * applicationActivities = nil;
NSArray * excludeActivities = @[UIActivityTypePostToFacebook,UIActivityTypePostToTwitter,UIActivityTypeMail, UIActivityTypeMessage, UIActivityTypePrint, UIActivityTypeAirDrop];
UIActivityViewController * activityController = [[UIActivityViewController alloc] initWithActivityItems:activityItems applicationActivities:applicationActivities];
activityController.excludedActivityTypes = excludeActivities;
[self presentViewController:activityController animated:YES completion:nil];

关于ios - 底部共享菜单 iOS [Obj-c],我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/39271059/

33 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com