Skip to content

Commit

Permalink
Merge pull request #383 from chenglu/master
Browse files Browse the repository at this point in the history
[sync] 2019/7/1
  • Loading branch information
chenglu authored Jul 1, 2019
2 parents f2b3b9b + f24943d commit 261e15e
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 15 deletions.
15 changes: 8 additions & 7 deletions src/docs/codelabs/layout-basics.md
Original file line number Diff line number Diff line change
Expand Up @@ -186,9 +186,10 @@ children 如何在垂直方向排列。默认值是 `CrossAxisAlignment.center`
* `CrossAxisAlignment.start`<br>
Children are aligned at the start of the `Row`'s vertical space
(by default, the top is considered to be the start,
though you can change that via the `verticalDirection` propert).

将所有的 children 向 `Row` 竖直方向的 start 方向排列(如果是从上到下,你可以修改 `verticalDirection` 来改变)。
though you can change that via the `verticalDirection` property).

将所有的 children 向 `Row` 竖直方向的 start 方向排列
(如果是从上到下,你可以修改 `verticalDirection` 来改变)。

* `CrossAxisAlignment.end`<br>
Children are aligned at the end of the `Row`'s
Expand Down Expand Up @@ -301,7 +302,7 @@ their children:

然后它把剩下的空间根据 children 的 flex 值分给它的可伸缩的 children,
这些可伸缩的 children 可以使用他们提供的部分或者全部的空间。

1. At that point, the `Row` knows how big all of its
children are, and can align them using the same axis
size and alignment properties you've seen so far.
Expand Down Expand Up @@ -577,9 +578,9 @@ Now you can add the `Icon`:

你可以使用任何 icon resource, `Icons.account_circle`看起来就不错。

* Set the `Icon`'s `size`.
* Set the `Icon`'s `size` to 50.

设置 `Icon` 的大小
`Icon` 的大小设置为 50

<iframe src="{{site.dartpad}}/experimental/embed-new.html?id=684e599476eef2ec4b4508e6b2186c03&fw=true&split=60" width="100%" height="800px"></iframe>

Expand All @@ -603,7 +604,7 @@ Then, finish up your new `Column` with these steps:

然后按照以下步骤完成你的新 `Column`

* Set the `Column`'s mainAxisSize to min
* Set the `Column`'s `mainAxisSize` to min

设置 `Column` 的 mainAxisSize 为最小

Expand Down
17 changes: 10 additions & 7 deletions src/docs/deployment/android.md
Original file line number Diff line number Diff line change
Expand Up @@ -364,14 +364,16 @@ are correct, especially:
`application`:编辑 [`application`][applicationtag]
标签中的 `android:label` 来设置 app 的最终名字。

* `uses-permission`: Remove the `android.permission.INTERNET`
[permission][permissiontag] if your application code does not need
Internet access. The standard template includes this tag to enable
communication between Flutter tools and a running app.
* `uses-permission`: Add the `android.permission.INTERNET`
[permission][permissiontag] if your application code needs Internet
access. The standard template does not include this tag but allows
Internet access during development to enable communication between
Flutter tools and a running app.

`uses-permission`:如果 app 不需要访问 Internet,移除
`android.permission.INTERNET`[权限][permissiontag]
标准模版里包含了这个权限,是为了允许 Flutter 工具和正在运行的 app 之间的通信。
`uses-permission`:如果你的代码需要互联网交互,请加入
`android.permission.INTERNET` [权限标签][permissiontag]
标准开发模版里并未加入这个权限(但是 Flutter debug 模版加入了这个权限),
加入这个权限是为了允许 Flutter 工具和正在运行的 app 之间的通信,详情见 [Issue 22139]()

## Reviewing the build configuration

Expand Down Expand Up @@ -707,3 +709,4 @@ This doc need to assign to a new translator.
[fat APK]: https://en.wikipedia.org/wiki/Fat_binary
[Issue 9253]: {{site.github}}/flutter/flutter/issues/9253
[Issue 18494]: {{site.github}}/flutter/flutter/issues/18494
[Issue 22139]: {{site.github}}/flutter/flutter/issues/22139
2 changes: 1 addition & 1 deletion src/docs/development/data-and-backend/json.md
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ itself. With this new approach, you can decode a user easily.
<!-- skip -->
```dart
Map userMap = jsonDecode(jsonString);
var user = new User.fromJson(userMap);
var user = User.fromJson(userMap);
print('Howdy, ${user.name}!');
print('We sent the verification link to ${user.email}.');
Expand Down

0 comments on commit 261e15e

Please sign in to comment.