Skip to content

Commit

Permalink
Modify some pictures url.
Browse files Browse the repository at this point in the history
  • Loading branch information
CharonChui committed Feb 11, 2015
1 parent 306ed0f commit 27e0c22
Show file tree
Hide file tree
Showing 12 changed files with 50 additions and 52 deletions.
2 changes: 1 addition & 1 deletion Android加强/Github个人主页绑定域名.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@

1.`repository`根目录新建`CNAME`文件, 内容为`xxx.com`(要绑定的域名),然后`commit``push`.
2. 在自己的域名管理页面中,进入域名解析.
![image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/bindhost.jpg?raw=true)
![image](https://github.com/CharonChui/Pictures/master/bindhost.jpg?raw=true)
**注意记录值 `username.github.io.` (最后面有一个.)**

---
Expand Down
2 changes: 1 addition & 1 deletion Android加强/Markdown学习手册.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ Markdown学习手册
斜体 | _斜体_ | `_斜体_` | 两边加_
中划线 | ~~中划线~~ | `~~中划线~~` | 两边加~~
单行代码 | `Log.i("Hello World!")` | \`Log.i("Hello World!")\` | 两边加`
插入图片 | ![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/rss.png?raw=true)| `![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/rss.png?raw=true)` | [] 中间为占位符,() 中间为图片链接
插入图片 | ![Image](https://github.com/CharonChui/Pictures/master/rss.png?raw=true)| `![Image](https://github.com/CharonChui/Pictures/master/rss.png?raw=true)` | [] 中间为占位符,() 中间为图片链接
链接 | [Visit Github](http://www.github.com) | `[Visit Github](http://www.github.com)` | [] 中间为显示文字,() 中间为链接


Expand Down
2 changes: 1 addition & 1 deletion Android加强/视频播放相关内容总结.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
很明显,每个`SurfaceView`创建的时候都会创建一个`MyWindow`,`new MyWindow(this)`中的`this`正是`SurfaceView`自身,因此将`SurfaceView`和`window`绑定在一起,而前面提到过每个`window`对应一个`Surface`,所以`SurfaceView`也就内嵌了一个自己的`Surface`,可以认为`SurfaceView`是来控制`Surface`的位置和尺寸。传统`View`及其派生类的更新只能在`UI`线程,然而`UI`线程还同时处理其他交互逻辑,这就无法保证`view`更新的速度和帧率了,而`SurfaceView`可以用独立的线程来进行绘制,因此可以提供更高的帧率,例如游戏,摄像头取景等场景就比较适合用`SurfaceView`来实现。
- `Surface`是纵深排序`(Z-ordered)`的,这表明它总在自己所在窗口的后面。
- `Surfaceview`提供了一个可见区域,只有在这个可见区域内的`Surface`部分内容才可见,可见区域外的部分不可见,所以可以认为**`SurfaceView`就是展示`Surface`中数据的地方**,`Surface`就是管理数据的地方,`SurfaceView`就是展示数据的地方,只有通过`SurfaceView`才能展现`Surface`中的数据。
![image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/SurfaceView.png?raw=true)
![image](https://github.com/CharonChui/Pictures/master/SurfaceView.png?raw=true)
- `Surface`的排版显示受到视图层级关系的影响,它的兄弟视图结点会在顶端显示。这意味者`Surface`的内容会被它的兄弟视图遮挡,这一特性可以用来放置遮盖物`(overlays)`(例如,文本和按钮等控件)。注意,如果`Surface`上面有透明控件,那么它的每次变化都会引起框架重新计算它和顶层控件的透明效果,这会影响性能。surfaceview变得可见时,surface被创建;surfaceview隐藏前,surface被销毁。这样能节省资源。如果你要查看 surface被创建和销毁的时机,可以重载surfaceCreated(SurfaceHolder)和 surfaceDestroyed(SurfaceHolder)。**`SurfaceView`的核心在于提供了两个线程:`UI`线程和渲染线程**,两个线程通过“双缓冲”机制来达到高效的界面适时更新。

##SurfaceHolder简介
Expand Down
14 changes: 7 additions & 7 deletions Android基础/AndroidStudio使用教程(第一弹).md
Original file line number Diff line number Diff line change
Expand Up @@ -19,32 +19,32 @@ AndroidStudio使用教程(第一弹)
- Android application modules
- 结构发生了变化,在`src`目录下有一个`main`的分组同时包含了`java`和`res`.
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_1.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_1.png?raw=true)
如图:`MyApplication`就是`Project`,而`app`就是`Module`.

- 设置
进入后你会发现字体或样式等不符合你的习惯。
`Windows`下点击左上角`File` -> `Settings`进入设置页面(`Mac`下为 `Android Studio` -> `Preferences`),在搜索框搜`Font`找到`Colors&Font`下的`Font`选项,我们会发现无法修改右侧字体大小。这里修改必须
要通过新建`Theme`进行修改的,点击`Save as`输入一个名字后,就可以修改字体了。
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_2.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_2.png?raw=true)

这里可能有些人会发现我的主题是黑色的,和`IO`大会演示的一样,但是安装后默认是白色的,有些刺眼。这里可以通过设置页面中修改`Theme`来改变,
默认是`Intellij`, 改为`Darcula`就是黑色的了.
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_3.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_3.png?raw=true)
很酷有木有.

- 运行
设置好字体后,当然要走你了。
运行和`Eclipse`中比较像,点击绿色的箭头。 可以通过箭头左边的下拉菜单选择不同的`Module`,快捷键是`Shift+F10`
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_4.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_4.png?raw=true)

`AndroidStudio`默认安装会启动模拟器,如果想让安装到真机上可以配置一下。在下拉菜单中选择`Edit Configurations`选择提示或者是`USB`设备。
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_5.png?raw=true)
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_6.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_5.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_6.png?raw=true)

- 常用快捷键介绍
`AndroidStudio`中可以将快捷键设置成`Eclipse`中的快捷键。具体方法为在设置页面搜索`keymap`然后选择为`Eclipse`就可以了.
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_7.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_7.png?raw=true)

强迫症的人伤不起,非想用默认的快捷键。
这里我整理下下个人常用的几个快捷键。 每个人的习惯不同,大家各取所需
Expand Down
24 changes: 12 additions & 12 deletions Android基础/AndroidStudio使用教程(第三弹).md
Original file line number Diff line number Diff line change
Expand Up @@ -8,45 +8,45 @@ AndroidStudio使用教程(第三弹)
- 方法一
下载地址是[Subversion](http://subversion.apache.org/packages.html)里面有不同系统的版本。
以`Windows`为例,我们采用熟悉的`VisualSVN`.
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_3_1.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_3_1.png?raw=true)
进入下载页后下载`Apache Subversion command line tools`, 解压即可。
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_3_2.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_3_2.png?raw=true)
- 方法二
`Windows`下的`Tortoise SVN`也是带有`command line`的,但是安装的时候默认是不安装这个选项的,所以安装时要注意选择一下。
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_3_5.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_3_5.png?raw=true)
选择安装即可
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_3_6.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_3_6.png?raw=true)
- 配置`SVN`
进入设置中心,搜索`Version Control`后选择`Subversion`, 将右侧的`Use command line client`设置你本地的`command line`路径即可。
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_3_3.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_3_3.png?raw=true)
如果是用第二种方式安装`Tortoise SVN`的话地址就是:
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_3_4.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_3_4.png?raw=true)
PS: 设置成自己的路径啊,不要写我的...
- `Git`
安装`Git`, [Git](http://git-scm.com/)
选择相应系统版本安装即可。
安装完成后进入`Android Studio`设置中心-> `Version Control` -> `Git`设置`Path to Git executable`即可。
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_3_7.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_3_7.png?raw=true)

- `Github`
怎么能少了它呢?哈哈
这个就不用安装了,直接配置下用户名和密码就好了。
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_3_8.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_3_8.png?raw=true)

- `Checkout`
在工具栏中点击 `VCS` 能看到相应检出和导入功能。这里以`Github`检出为例介绍一下。
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_3_9.png?raw=true)
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_3_10.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_3_9.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_3_10.png?raw=true)
确定之后就能在底部导航栏看到检出进度
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_3_11.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_3_11.png?raw=true)

完成之后会提示是否想要把刚才检出的项目导入`AndroidStudio`中。
Why not?
以`Gradle`方式导入, 然后`next`, 然后`next`然后就没有然后了。
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_3_12.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_3_12.png?raw=true)
---

Expand Down
14 changes: 7 additions & 7 deletions Android基础/AndroidStudio使用教程(第二弹).md
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,9 @@ AndroidStudio使用教程(第二弹)

- 使用`Android`项目视图
这里纯粹看个人爱好,不过对于标准的`AndroidStudio`工程,一般我们常用的部分,都在`Android`项目视图中显示出来了。
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_2_1.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_2_1.png?raw=true)
效果如下图:
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_2_2.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_2_2.png?raw=true)

- 使用布局编辑器

Expand All @@ -39,21 +39,21 @@ AndroidStudio使用教程(第二弹)
- 点击布局页面右侧的`Preview`按钮,可以进行预览。

想预览多屏幕效果时可以在预览界面设备的下拉菜单上选择`Preview All Screen Sizes`.
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_2_3.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_2_3.png?raw=true)
- 选择主题

想给应用设置一个主题,可以点击`Theme`图标![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_2_4.png?raw=true), 就会显示
想给应用设置一个主题,可以点击`Theme`图标![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_2_4.png?raw=true), 就会显示
出选择对话框。
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_2_5.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_2_5.png?raw=true)

- 国际化
对于国际化的适配选择国际化图标![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_2_6.png?raw=true),然后在弹出的列表中选择
对于国际化的适配选择国际化图标![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_2_6.png?raw=true),然后在弹出的列表中选择
需要进行国际化的国家进行适配即可。

- 常用功能
有些人进来之后可能找不到`DDMS`了.
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_2_7.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_2_7.png?raw=true)
上图中的三个图标分别为, `AVD Manager`、`SDK Manager`、`DDMS`


Expand Down
8 changes: 4 additions & 4 deletions Android基础/AndroidStudio使用教程(第五弹).md
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,11 @@ dependencies {

### Build the project in Android Studio
`Android Studio``build project`点击上面导航栏中的`Build`菜单然后选择`Make Project`, 这时窗口底部的状态栏就会显示`build`的进度。
点击窗口右边底部的![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_5_2.png?raw=true)图标来显示`Gradle Console`.
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_5_3.png?raw=true)
点击窗口右边底部的![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_5_2.png?raw=true)图标来显示`Gradle Console`.
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_5_3.png?raw=true)

在窗口右边栏点击`Gradle`窗口可以看到当前所有可用的`build tasks`, 双击里面的`task`即可执行。
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_5_4.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_5_4.png?raw=true)

### Build a release version
点击`Gradle tasks`页面, 展开`app`中的`task`然后双击`assembleRelease`即可。
Expand Down Expand Up @@ -99,7 +99,7 @@ dependencies {
`dependencies`部分是在`android`之外,该部分声明了依赖的`module`
**注意:**当修改项目中得`build files`时,`Android Studio`需要进行项目同步来导入相应的`build`配置变化, 点击`Android Studio`中黄色通知部分的`Sync Now`
来进行变化的导入。
![Image](https://github.com/CharonChui/AndroidNote/blob/master/Pic/AndroidStudio_5_5.png?raw=true)
![Image](https://github.com/CharonChui/Pictures/master/AndroidStudio_5_5.png?raw=true)

###Declare dependencies
```java
Expand Down
Loading

0 comments on commit 27e0c22

Please sign in to comment.