摘要: Xcode 9.0 新建工程报错 xcode Safe Area Layout Guide Before IOS 9.0 如下图,在Builds for 选择iOS9.0 and Later,不勾选Use Safe Area Layout Guides,否则会导致用不了iOS的这个新功能了。 阅读全文
posted @ 2018-05-12 11:09 chihbun 阅读(181) 评论(0) 推荐(0) 编辑
摘要: 最近用到JS和OC原生方法调用的问题,查了许多资料都语焉不详,自己记录一下吧,如果有误欢迎联系我指出。 JS中调用OC方法有三种方式: 先上OC代码 // 设置javaScriptContext上下文 self.jsContext = [self.webView valueForKeyPath:@" 阅读全文
posted @ 2018-05-10 11:14 chihbun 阅读(715) 评论(0) 推荐(1) 编辑
摘要: 第一步: 在Github上创建自己的repository 第二步:建立本地仓库cd到你的本地项目根目录下,执行git命令 1:$ cd 到你的项目目录下 2:$ git init 第三步:将本地项目工作区的所有文件添加到暂存区 3:$ git add . 第三步:将暂存区的文件提交到本地仓库 4:$ 阅读全文
posted @ 2018-05-08 11:43 chihbun 阅读(3292) 评论(0) 推荐(0) 编辑
摘要: #import "ViewController.h" #import "FirstViewController.h" #import "SecondViewController.h" #import "MiddleViewController.h" #import "ThirdViewController.h" #import "FourViewController.h" @interfac... 阅读全文
posted @ 2018-05-07 18:15 chihbun 阅读(547) 评论(0) 推荐(0) 编辑
摘要: 效果图: 操作 先github下载<YYText>文件导入, 代码如下: 阅读全文
posted @ 2018-04-28 16:52 chihbun 阅读(6762) 评论(0) 推荐(0) 编辑
摘要: 年少的心总有些轻狂!蜗牛只要爬到山顶,和雄鹰所看到的景色就是一样的。加油! 阅读全文
posted @ 2018-04-28 15:24 chihbun 阅读(88) 评论(0) 推荐(0) 编辑
摘要: /* 建立中心设备 扫描外设(Discover Peripheral) 连接外设(Connect Peripheral) 扫描外设中的服务和特征(Discover Services And Charateristics) 利用特征与外设做数据交互(Explore And Interact) 断开连接(Disconnect) */ #import "ViewController.h... 阅读全文
posted @ 2018-04-28 10:02 chihbun 阅读(773) 评论(0) 推荐(0) 编辑
摘要: /* 1.设置UI界面 2.引入框架 3.点击选择照片 4.连接蓝牙设备 5.实现蓝牙的代理方法 6.发送照片 */ #import "ViewController.h" #import @interface ViewController () @property (nonatomic, strong) UIImageView *imgView; @property (no... 阅读全文
posted @ 2018-04-27 17:59 chihbun 阅读(399) 评论(0) 推荐(0) 编辑
摘要: 步骤如下: 1、安装HomeBrew,命令如下: 在终端输入命令:$ ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" 等待安装成功后验证一下brew的版本:$ brew 阅读全文
posted @ 2018-04-27 14:39 chihbun 阅读(360) 评论(0) 推荐(0) 编辑
摘要: 为什么不直接编写class文件?class文件,只能被JVM所识别,程序员看不懂。 1:编译之后会生成与平台无关的字码文件。 2:得依赖不同平台的虚拟机(JVM)。 JVM是不跨平台的。 阅读全文
posted @ 2018-04-26 15:53 chihbun 阅读(111) 评论(0) 推荐(0) 编辑