You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@weex.apache.org by gu...@apache.org on 2017/10/18 05:06:14 UTC
[1/3] incubator-weex git commit: * [android] if not debug level then
write console log
Repository: incubator-weex
Updated Branches:
refs/heads/release-0.16 c2f1aac35 -> db5b1e046
* [android] if not debug level then write console log
Project: http://git-wip-us.apache.org/repos/asf/incubator-weex/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-weex/commit/db5b1e04
Tree: http://git-wip-us.apache.org/repos/asf/incubator-weex/tree/db5b1e04
Diff: http://git-wip-us.apache.org/repos/asf/incubator-weex/diff/db5b1e04
Branch: refs/heads/release-0.16
Commit: db5b1e0465b494ea937b381bed3b54aaea0b40ba
Parents: ac075c7
Author: atomtong <to...@qq.com>
Authored: Wed Oct 18 10:58:06 2017 +0800
Committer: gurisxie <27...@qq.com>
Committed: Wed Oct 18 13:04:15 2017 +0800
----------------------------------------------------------------------
.../sdk/src/main/java/com/taobao/weex/utils/WXLogUtils.java | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/db5b1e04/android/sdk/src/main/java/com/taobao/weex/utils/WXLogUtils.java
----------------------------------------------------------------------
diff --git a/android/sdk/src/main/java/com/taobao/weex/utils/WXLogUtils.java b/android/sdk/src/main/java/com/taobao/weex/utils/WXLogUtils.java
index a120ad6..1f5b4b2 100644
--- a/android/sdk/src/main/java/com/taobao/weex/utils/WXLogUtils.java
+++ b/android/sdk/src/main/java/com/taobao/weex/utils/WXLogUtils.java
@@ -78,10 +78,11 @@ public class WXLogUtils {
Log.println(level.getPriority(),tag, msg);
}
- if(WXEnvironment.isApkDebugable()){
- writeConsoleLog(level.getName(), msg);
- sendLog(level, msg);
- }
+ // if not debug level then print log
+ if(WXEnvironment.isApkDebugable() && !level.getName().equals("debug")){
+ writeConsoleLog(level.getName(), msg);
+ sendLog(level, msg);
+ }
}
}
[2/3] incubator-weex git commit: * [android] delete redundancy log
print logic code
Posted by gu...@apache.org.
* [android] delete redundancy log print logic code
Project: http://git-wip-us.apache.org/repos/asf/incubator-weex/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-weex/commit/ac075c70
Tree: http://git-wip-us.apache.org/repos/asf/incubator-weex/tree/ac075c70
Diff: http://git-wip-us.apache.org/repos/asf/incubator-weex/diff/ac075c70
Branch: refs/heads/release-0.16
Commit: ac075c70e9ae68a53d66fecace1a91e336f3f39a
Parents: 247ea50
Author: atomtong <to...@qq.com>
Authored: Tue Oct 17 19:43:40 2017 +0800
Committer: gurisxie <27...@qq.com>
Committed: Wed Oct 18 13:04:15 2017 +0800
----------------------------------------------------------------------
android/sdk/src/main/java/com/taobao/weex/utils/WXLogUtils.java | 5 -----
1 file changed, 5 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/ac075c70/android/sdk/src/main/java/com/taobao/weex/utils/WXLogUtils.java
----------------------------------------------------------------------
diff --git a/android/sdk/src/main/java/com/taobao/weex/utils/WXLogUtils.java b/android/sdk/src/main/java/com/taobao/weex/utils/WXLogUtils.java
index ae6e623..a120ad6 100644
--- a/android/sdk/src/main/java/com/taobao/weex/utils/WXLogUtils.java
+++ b/android/sdk/src/main/java/com/taobao/weex/utils/WXLogUtils.java
@@ -118,13 +118,8 @@ public class WXLogUtils {
}
public static void d(String tag, String msg) {
- if (!TextUtils.isEmpty(msg) && !TextUtils.isEmpty(tag)) {
- log(tag, msg, LogLevel.DEBUG);
- }
if (WXEnvironment.isApkDebugable() && !TextUtils.isEmpty(msg) && WXEnvironment.sLogLevel.compare(LogLevel.DEBUG) >= 0) {
- Log.d(tag, msg);
-
if ("jsLog".equals(tag) && jsLogWatcher != null) {
if (msg.endsWith("__DEBUG")) {
jsLogWatcher.onJsLog(Log.DEBUG, msg.replace("__DEBUG", ""));
[3/3] incubator-weex git commit: * [android] fix bug if application
is null log not print out
Posted by gu...@apache.org.
* [android] fix bug if application is null log not print out
Project: http://git-wip-us.apache.org/repos/asf/incubator-weex/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-weex/commit/247ea50a
Tree: http://git-wip-us.apache.org/repos/asf/incubator-weex/tree/247ea50a
Diff: http://git-wip-us.apache.org/repos/asf/incubator-weex/diff/247ea50a
Branch: refs/heads/release-0.16
Commit: 247ea50a914afe24ee30d6dafb66f6f76986e7c3
Parents: c2f1aac
Author: atomtong <to...@qq.com>
Authored: Tue Oct 17 17:00:40 2017 +0800
Committer: gurisxie <27...@qq.com>
Committed: Wed Oct 18 13:04:15 2017 +0800
----------------------------------------------------------------------
android/sdk/src/main/java/com/taobao/weex/WXSDKEngine.java | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/247ea50a/android/sdk/src/main/java/com/taobao/weex/WXSDKEngine.java
----------------------------------------------------------------------
diff --git a/android/sdk/src/main/java/com/taobao/weex/WXSDKEngine.java b/android/sdk/src/main/java/com/taobao/weex/WXSDKEngine.java
index 0296379..3ea86e2 100644
--- a/android/sdk/src/main/java/com/taobao/weex/WXSDKEngine.java
+++ b/android/sdk/src/main/java/com/taobao/weex/WXSDKEngine.java
@@ -162,7 +162,11 @@ public class WXSDKEngine {
if(WXEnvironment.isApkDebugable()){
WXEnvironment.sLogLevel = LogLevel.DEBUG;
}else{
- WXEnvironment.sLogLevel = LogLevel.WARN;
+ if(WXEnvironment.sApplication != null){
+ WXEnvironment.sLogLevel = LogLevel.WARN;
+ }else {
+ WXLogUtils.e(TAG,"WXEnvironment.sApplication is " + WXEnvironment.sApplication);
+ }
}
doInitInternal(application,config);
WXEnvironment.sSDKInitInvokeTime = System.currentTimeMillis()-start;
@@ -173,6 +177,9 @@ public class WXSDKEngine {
private static void doInitInternal(final Application application,final InitConfig config){
WXEnvironment.sApplication = application;
+ if(application == null){
+ WXLogUtils.e(TAG, " doInitInternal application is null");
+ }
WXEnvironment.JsFrameworkInit = false;
WXBridgeManager.getInstance().post(new Runnable() {