上一页 1 ··· 5 6 7 8 9 10 11 12 13 ··· 15 下一页
摘要: //模拟windows下 GetTickCount ////#import<mach/mach_time.h>+ (int)mxGetTickCount;{ int timeTick; mach_timebase_info_data_t info; uint64_t machineTime; mach_timebase_info(&info); machineTime =mach_absolute_time(); timeTick = machineTime * info.numer / info.denom /1000000LL; return timeTick;}// 阅读全文
posted @ 2013-03-16 14:29 李伯波 阅读(1489) 评论(0) 推荐(0)
摘要: 方法一:添加AudioToolbox.frameworkAppdelegate.m中,添加头文件#include在- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions方法中添加 AudioSessionInitialize(NULL, NULL, NULL, NULL); AudioSessionSetActive(true); AudioSessionAddPropertyListener(kAudioSessionPrope.. 阅读全文
posted @ 2013-03-16 14:09 李伯波 阅读(244) 评论(0) 推荐(0)
摘要: -(void)saveToUserDefaults:(NSString*)myString { NSUserDefaults *standardUserDefaults = [NSUserDefaults standardUserDefaults]; if (standardUserDefaults) { [standardUserDefaults setObject:myString forKey:@"Prefs"]; [standardUserDefaults synchronize]; }}-(NSString*... 阅读全文
posted @ 2013-02-28 10:24 李伯波 阅读(202) 评论(0) 推荐(0)
摘要: 1、调用 自带mail[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"mailto://admin@hzlzh.com"]];2、调用 电话phone[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"tel://8008808888"]];3、调用 SMS[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@&quo 阅读全文
posted @ 2013-02-26 12:39 李伯波 阅读(199) 评论(0) 推荐(0)
摘要: #import <SystemConfiguration/CaptiveNetwork.h>+ (id)fetchSSIDInfo{NSArray *ifs = (id)CNCopySupportedInterfaces();NSLog(@"%s: Supported interfaces: %@", __func__, ifs);id info = nil;for (NSString *ifnam in ifs) {info = (id)CNCopyCurrentNetworkInfo((CFStringRef)ifnam);if (info &&am 阅读全文
posted @ 2013-02-25 17:47 李伯波 阅读(1015) 评论(0) 推荐(0)
摘要: 在ios扫描公共区域内wifi信息中,写了实现wifi扫描的一种办法,然则那种办法扫描出来的wifi信息不全,下面是扫描全部wifi信息的实现办法: #import <CoreFoundation/CoreFoundation.h>#import <Foundation/NSTimer.h>#import <Foundation/Foundation.h>#include <dlfcn.h>#include <ifaddrs.h>#include <arpa/inet.h>@interface MSNetworksMana 阅读全文
posted @ 2013-02-25 17:41 李伯波 阅读(1370) 评论(0) 推荐(0)
摘要: 注册帐号---》开发----》发布----》等待审核----》上架发布过程1: 登录到到开发者帐户,再登录到iTunes Connect 中 设置 要发布版本的对应信息 注意:设置的信息一定要和你发布的程序对上 ,如:identifter,其他看看就知道了2:发布使用xcode 4发布app实例操作是本文介绍的内容,不多说,我们直接进入话题。1、iOS Provisioning Portal 和iTunes Connect 没有变,下载与安装.mobileprovision文件与以前一下。2、Xcode 4 整合相关的工具(All in One), 集成了Organizer与Applica.. 阅读全文
posted @ 2013-02-25 15:08 李伯波 阅读(354) 评论(0) 推荐(0)
摘要: 方法1: 在applicationDidFinishLaunching函数里添加 [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(volumeChanged:) name:@"AVSystemController_SystemVolumeDidChangeNotification" object:nil]; - (void)volumeChanged:(NSNotification *)notification{ float volume = [[[notification 阅读全文
posted @ 2013-02-25 14:32 李伯波 阅读(824) 评论(0) 推荐(0)
摘要: Android 上有一些很有趣的应用,例如《吹裙子》、《吹气球》之类的。利用的是实时获取麦克风输入音量,然后进行相应的处理。录音过程中怎样获得声音的大小呢?网上 也不少人问如何处理这个事情,也有一些解答,不过都没有实际的代码。简单摸索了一下,写了个小 Demo 试了试,果然可以。给大家共享一下。不解释代码了,大家看注释。[java] view plaincopypackagecom.xxiyy.spl;importandroid.media.AudioFormat;importandroid.media.AudioRecord;importandroid.media.MediaRecorder 阅读全文
posted @ 2013-02-25 14:27 李伯波 阅读(1699) 评论(0) 推荐(0)
摘要: 官方文档:http://developer.apple.com /library/ios/#documentation/iPhone/Conceptual/iPhoneOSProgrammingGuide/BackgroundExecution/BackgroundExecution.html中文的好文章http://www.devdiv.com/thread-47004-1-1.htmlhttp://www.cnblogs.com/haipingwu/archive/2011/03/18/1987962.htmliOS4请求更多后台时间http://blog.csdn.net/zhangao 阅读全文
posted @ 2013-02-25 13:59 李伯波 阅读(656) 评论(0) 推荐(0)
上一页 1 ··· 5 6 7 8 9 10 11 12 13 ··· 15 下一页