iPhone 中相册取消按钮的动作事件

发布于 2024-10-08 05:33:49 字数 181 浏览 3 评论 0原文

我正在使用 tabBarBased 应用程序。单击 tabBarButton 之一时,它会打开相册。在相册中,顶部(​​导航栏)右侧有一个取消按钮?这里我想执行取消按钮的操作事件单击...在单击取消按钮时我想转到另一个 tabBar 视图...

请帮助我做到这一点...

提前感谢您的考虑和努力... 问候, 雷努加

I'm working with tabBarBased application.At the time of clicking the one of the tabBarButton it opens the photo album .In photo album there is a cancel button on top(navBar) right??Here i want to perform action event for cancel button click...while click on the cancel button i want to go to the another tabBar view...

Please help me out to do this...

Thank You in advance for your consideration and effort...
Regards,
Renuga

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

深者入戏 2024-10-15 05:33:49

这是 UIImagePickerControllerDelegate 的类定义:

@protocol UIImagePickerControllerDelegate<NSObject>
@optional
// The picker does not dismiss itself; the client dismisses it in these callbacks.
// The delegate will receive one or the other, but not both, depending whether the user
// confirms or cancels.
- (void)imagePickerController:(UIImagePickerController *)picker didFinishPickingImage:(UIImage *)image editingInfo:(NSDictionary *)editingInfo __OSX_AVAILABLE_BUT_DEPRECATED(__MAC_NA,__MAC_NA,__IPHONE_2_0,__IPHONE_3_0);
- (void)imagePickerController:(UIImagePickerController *)picker didFinishPickingMediaWithInfo:(NSDictionary *)info;
- (void)imagePickerControllerDidCancel:(UIImagePickerController *)picker;

@end

我认为上面提到的方法之一就是您所需要的:

- (void)imagePickerControllerDidCancel:(UIImagePickerController *)picker;

Here's the class definition for UIImagePickerControllerDelegate:

@protocol UIImagePickerControllerDelegate<NSObject>
@optional
// The picker does not dismiss itself; the client dismisses it in these callbacks.
// The delegate will receive one or the other, but not both, depending whether the user
// confirms or cancels.
- (void)imagePickerController:(UIImagePickerController *)picker didFinishPickingImage:(UIImage *)image editingInfo:(NSDictionary *)editingInfo __OSX_AVAILABLE_BUT_DEPRECATED(__MAC_NA,__MAC_NA,__IPHONE_2_0,__IPHONE_3_0);
- (void)imagePickerController:(UIImagePickerController *)picker didFinishPickingMediaWithInfo:(NSDictionary *)info;
- (void)imagePickerControllerDidCancel:(UIImagePickerController *)picker;

@end

I think one of the methods mentioned above is what you need:

- (void)imagePickerControllerDidCancel:(UIImagePickerController *)picker;
初懵 2024-10-15 05:33:49

将 UITabBarController 的 selectedViewController 属性设置为要切换到的视图控制器。向此属性分配新的视图控制器会更改当前显示的视图,并在选项卡栏中选择适当的选项卡。

set the selectedViewController property of UITabBarController to the view controller you want to switch to. Assigning a new view controller to this property changes the currently displayed view and also selects the appropriate tab in the tab bar.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文