UIActionSheet(操作列表)
#import "AppDelegate.h"
@interface AppDelegate ()<UIActionSheetDelegate>
@end
@implementation AppDelegate
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
// Override point for customization after application launch.
self.window.backgroundColor = [UIColor whiteColor];
UIActionSheet *sheet = [[UIActionSheet alloc] initWithTitle:@"File Action" delegate:self cancelButtonTitle:@"cancel" destructiveButtonTitle:@"load" otherButtonTitles:@"save",@"Delete", nil];
[sheet showInView:self.window];
[self.window makeKeyAndVisible];
return YES;
}
- (void)actionSheet:(UIActionSheet *)actionSheet clickedButtonAtIndex:(NSInteger)buttonIndex
{
NSLog(@"Button %ld is pressed...",buttonIndex);
}
@end
UIActionSheet(操作列表)的更多相关文章
- Python操作列表的常用方法
下面列出列表常用的方法操作列表以及小例子: 1. Append 在列表末尾添加元素,需在列表末尾添加元素,需要注意几个点: A. append中添加的参数是作为一个整体 & ...
- Python编程从入门到实践笔记——操作列表
Python编程从入门到实践笔记——操作列表 #coding=utf-8 magicians = ['alice','david','carolina'] #遍历整个列表 for magician i ...
- python入门学习:3.操作列表
python入门学习:3.操作列表 关键点:列表 3.1 遍历整个列表3.2 创建数值列表3.3 使用列表3.4 元组 3.1 遍历整个列表 循环这种概念很重要,因为它是计算机自动完成重复工作的常 ...
- 给有C或C++基础的Python入门 :Python Crash Course 4 操作列表 4.1--4.3
操作列表,也就是遍历列表.本章我们要学的就是如何遍历列表. 4.1--4.2 遍历列表 遍历列表,用for循环. 不同于C++或者C语言的for循环,Python的for循环更容易让人理解. 看一个例 ...
- Redis 操作列表数据
Redis 操作列表数据: > lpush list1 "aaa" // lpush 用于追加列表元素,默认追加到列表的最左侧(left) (integer) > lp ...
- 【Python编程:从入门到实践】chapter4 操作列表
chapter4 操作列表 4.1 遍历整个列表 magicians=['alice','david','carolina'] for magician in magicians: print(mag ...
- Python操作列表常用方法
Python操作列表的常用方法. 列表常用的方法操作列表以及小例子: 1. Append 在列表末尾添加元素,需在列表末尾添加元素,需要注意几个点: A. append中添加的参数是作为一个整体 &g ...
- 在Python中使用lambda高效操作列表的教程
在Python中使用lambda高效操作列表的教程 这篇文章主要介绍了在Python中使用lambda高效操作列表的教程,结合了包括map.filter.reduce.sorted等函数,需要的朋友可 ...
- Spark的操作列表
Action 操作1. collect() ,返回值是一个数组,返回dataframe集合所有的行2. collectAsList() 返回值是一个java类型的数组,返回dataframe集合所有的 ...
随机推荐
- axure下载及汉化
第一步:下载axure rp 6.5英文原版 axure6.5官方英文下载地址: Windows版:http://t.cn/zW7JifS 第二步:安装汉化语言包 axure6.5汉化语言包中文包下载 ...
- 14-THREE.JS 聚光灯
<!DOCTYPE html> <html> <head> <title></title> <script src="htt ...
- xss攻击的分类
1.反射型XSS 原理: 通过在页面上植入恶意链接,诱使用户点击,执行js脚本,所谓反射型XSS就是将用户输入的数据(恶意用户输入的js脚本),“反射”到浏览器执行. 实例: php源码: <? ...
- C++string类整理
string类 string类 头文件:#include<string> 名称空间:using namespace std; 初始化: string Str; String类的构造函数和析 ...
- vector map迭代器失效解决方案
vector : iter = container.erase(iter); //erase的返回值是删除元素下一个元素的迭代器 vector<int>::iterator it = ...
- LeetCode Design Compressed String Iterator
原题链接在这里:https://leetcode.com/problems/design-compressed-string-iterator/description/ 题目: Design and ...
- 【LeetCode】002 Add Two Numbers
题目: You are given two non-empty linked lists representing two non-negative integers. The digits are ...
- Yii 利用layer删除数据
一.视图 <tr id="rm_<?php echo $v->category_id;?>"> <td><?php echo $v- ...
- jq 侧边栏
HTML 侧边栏HTML代码: <div class="sidebar" id="sucaihuo"> <div class=&quo ...
- mybatis与oracle使用总结
Oracle使用总结 1.新建表删除表 新建表语句: CREATE TABLE +表名{ } create table AFA_USER ( USER_ID VARCHAR2() not null, ...