Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
sxychenjing
engine
提交
5d1c1a02
E
engine
项目概览
sxychenjing
/
engine
与 Fork 源项目一致
从无法访问的项目Fork
通知
3
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
E
engine
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
未验证
提交
5d1c1a02
编写于
5月 08, 2019
作者:
D
Dan Field
提交者:
GitHub
5月 08, 2019
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Remove more asserts and fix a11y check (#8896)
上级
ac4f3c99
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
19 addition
and
15 deletion
+19
-15
shell/platform/android/io/flutter/plugin/common/BasicMessageChannel.java
...android/io/flutter/plugin/common/BasicMessageChannel.java
+3
-3
shell/platform/android/io/flutter/plugin/common/EventChannel.java
...atform/android/io/flutter/plugin/common/EventChannel.java
+3
-3
shell/platform/android/io/flutter/plugin/common/FlutterException.java
...rm/android/io/flutter/plugin/common/FlutterException.java
+5
-1
shell/platform/android/io/flutter/plugin/common/MethodChannel.java
...tform/android/io/flutter/plugin/common/MethodChannel.java
+3
-3
shell/platform/android/io/flutter/plugin/common/StandardMessageCodec.java
...ndroid/io/flutter/plugin/common/StandardMessageCodec.java
+4
-1
shell/platform/android/io/flutter/view/AccessibilityBridge.java
...platform/android/io/flutter/view/AccessibilityBridge.java
+0
-3
shell/platform/android/io/flutter/view/ResourceExtractor.java
...l/platform/android/io/flutter/view/ResourceExtractor.java
+1
-1
未找到文件。
shell/platform/android/io/flutter/plugin/common/BasicMessageChannel.java
浏览文件 @
5d1c1a02
...
...
@@ -42,13 +42,13 @@ public final class BasicMessageChannel<T> {
public
BasicMessageChannel
(
BinaryMessenger
messenger
,
String
name
,
MessageCodec
<
T
>
codec
)
{
if
(
BuildConfig
.
DEBUG
)
{
if
(
messenger
==
null
)
{
throw
new
AssertionError
(
"Parameter messenger must not be null."
);
Log
.
e
(
TAG
,
"Parameter messenger must not be null."
);
}
if
(
name
==
null
)
{
throw
new
AssertionError
(
"Parameter name must not be null."
);
Log
.
e
(
TAG
,
"Parameter name must not be null."
);
}
if
(
codec
==
null
)
{
throw
new
AssertionError
(
"Parameter codec must not be null."
);
Log
.
e
(
TAG
,
"Parameter codec must not be null."
);
}
}
this
.
messenger
=
messenger
;
...
...
shell/platform/android/io/flutter/plugin/common/EventChannel.java
浏览文件 @
5d1c1a02
...
...
@@ -59,13 +59,13 @@ public final class EventChannel {
public
EventChannel
(
BinaryMessenger
messenger
,
String
name
,
MethodCodec
codec
)
{
if
(
BuildConfig
.
DEBUG
)
{
if
(
messenger
==
null
)
{
throw
new
AssertionError
(
"Parameter messenger must not be null."
);
Log
.
e
(
TAG
,
"Parameter messenger must not be null."
);
}
if
(
name
==
null
)
{
throw
new
AssertionError
(
"Parameter name must not be null."
);
Log
.
e
(
TAG
,
"Parameter name must not be null."
);
}
if
(
codec
==
null
)
{
throw
new
AssertionError
(
"Parameter codec must not be null."
);
Log
.
e
(
TAG
,
"Parameter codec must not be null."
);
}
}
this
.
messenger
=
messenger
;
...
...
shell/platform/android/io/flutter/plugin/common/FlutterException.java
浏览文件 @
5d1c1a02
...
...
@@ -4,19 +4,23 @@
package
io.flutter.plugin.common
;
import
android.util.Log
;
import
io.flutter.BuildConfig
;
/**
* Thrown to indicate that a Flutter method invocation failed on the Flutter side.
*/
public
class
FlutterException
extends
RuntimeException
{
private
static
final
String
TAG
=
"FlutterException#"
;
public
final
String
code
;
public
final
Object
details
;
FlutterException
(
String
code
,
String
message
,
Object
details
)
{
super
(
message
);
if
(
BuildConfig
.
DEBUG
&&
code
==
null
)
{
throw
new
AssertionError
(
"Parameter code must not be null."
);
Log
.
e
(
TAG
,
"Parameter code must not be null."
);
}
this
.
code
=
code
;
this
.
details
=
details
;
...
...
shell/platform/android/io/flutter/plugin/common/MethodChannel.java
浏览文件 @
5d1c1a02
...
...
@@ -58,13 +58,13 @@ public final class MethodChannel {
public
MethodChannel
(
BinaryMessenger
messenger
,
String
name
,
MethodCodec
codec
)
{
if
(
BuildConfig
.
DEBUG
)
{
if
(
messenger
==
null
)
{
throw
new
AssertionError
(
"Parameter messenger must not be null."
);
Log
.
e
(
TAG
,
"Parameter messenger must not be null."
);
}
if
(
name
==
null
)
{
throw
new
AssertionError
(
"Parameter name must not be null."
);
Log
.
e
(
TAG
,
"Parameter name must not be null."
);
}
if
(
codec
==
null
)
{
throw
new
AssertionError
(
"Parameter codec must not be null."
);
Log
.
e
(
TAG
,
"Parameter codec must not be null."
);
}
}
this
.
messenger
=
messenger
;
...
...
shell/platform/android/io/flutter/plugin/common/StandardMessageCodec.java
浏览文件 @
5d1c1a02
...
...
@@ -4,6 +4,8 @@
package
io.flutter.plugin.common
;
import
android.util.Log
;
import
io.flutter.BuildConfig
;
import
java.io.ByteArrayOutputStream
;
...
...
@@ -60,6 +62,7 @@ import java.util.Map.Entry;
* <p>To extend the codec, overwrite the writeValue and readValueOfType methods.</p>
*/
public
class
StandardMessageCodec
implements
MessageCodec
<
Object
>
{
private
static
final
String
TAG
=
"StandardMessageCodec#"
;
public
static
final
StandardMessageCodec
INSTANCE
=
new
StandardMessageCodec
();
@Override
...
...
@@ -110,7 +113,7 @@ public class StandardMessageCodec implements MessageCodec<Object> {
*/
protected
static
final
void
writeSize
(
ByteArrayOutputStream
stream
,
int
value
)
{
if
(
BuildConfig
.
DEBUG
&&
0
>
value
)
{
throw
new
AssertionError
(
"Attempted to write a negative size."
);
Log
.
e
(
TAG
,
"Attempted to write a negative size."
);
}
if
(
value
<
254
)
{
stream
.
write
(
value
);
...
...
shell/platform/android/io/flutter/view/AccessibilityBridge.java
浏览文件 @
5d1c1a02
...
...
@@ -1330,9 +1330,6 @@ public class AccessibilityBridge extends AccessibilityNodeProvider {
if
(
object
.
scrollIndex
+
visibleChildren
>
object
.
scrollChildren
)
{
Log
.
e
(
TAG
,
"Scroll index is out of bounds."
);
}
if
(
object
.
childrenInHitTestOrder
.
get
(
object
.
scrollIndex
).
hasFlag
(
Flag
.
IS_HIDDEN
))
{
Log
.
e
(
TAG
,
"Attempted to move Accessibility Focus to hidden child."
);
}
}
// The setToIndex should be the index of the last visible child. Because we counted all
// children, including the first index we need to subtract one.
...
...
shell/platform/android/io/flutter/view/ResourceExtractor.java
浏览文件 @
5d1c1a02
...
...
@@ -172,7 +172,7 @@ class ResourceExtractor {
ResourceExtractor
start
()
{
if
(
BuildConfig
.
DEBUG
&&
mExtractTask
!=
null
)
{
throw
new
AssertionError
(
"Attempted to start resource extraction while another extraction was in progress."
);
Log
.
e
(
TAG
,
"Attempted to start resource extraction while another extraction was in progress."
);
}
mExtractTask
=
new
ExtractTask
(
mDataDirPath
,
mResources
,
mPackageName
,
mPackageManager
,
mAssetManager
);
mExtractTask
.
executeOnExecutor
(
AsyncTask
.
THREAD_POOL_EXECUTOR
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录