You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@weex.apache.org by so...@apache.org on 2017/06/22 05:27:51 UTC

[46/50] [abbrv] incubator-weex git commit: * [android] fix:Repeat adding the same event @notdanger

* [android] fix:Repeat adding the same event @notdanger


Project: http://git-wip-us.apache.org/repos/asf/incubator-weex/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-weex/commit/5a4eb484
Tree: http://git-wip-us.apache.org/repos/asf/incubator-weex/tree/5a4eb484
Diff: http://git-wip-us.apache.org/repos/asf/incubator-weex/diff/5a4eb484

Branch: refs/heads/dev
Commit: 5a4eb4848826ee6d512033b774cd36adc245fd3c
Parents: b6c9d0e
Author: cairq <ru...@alibaba-inc.com>
Authored: Wed Jun 21 17:53:28 2017 +0800
Committer: cairq <ru...@alibaba-inc.com>
Committed: Wed Jun 21 19:57:32 2017 +0800

----------------------------------------------------------------------
 .../src/main/java/com/taobao/weex/ui/component/WXComponent.java    | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/5a4eb484/android/sdk/src/main/java/com/taobao/weex/ui/component/WXComponent.java
----------------------------------------------------------------------
diff --git a/android/sdk/src/main/java/com/taobao/weex/ui/component/WXComponent.java b/android/sdk/src/main/java/com/taobao/weex/ui/component/WXComponent.java
index c0d7c7a..3206c86 100644
--- a/android/sdk/src/main/java/com/taobao/weex/ui/component/WXComponent.java
+++ b/android/sdk/src/main/java/com/taobao/weex/ui/component/WXComponent.java
@@ -770,7 +770,7 @@ public abstract class  WXComponent<T extends View> implements IWXObject, IWXActi
    * @param type
    */
   public void addEvent(String type) {
-    if (TextUtils.isEmpty(type)) {
+    if (TextUtils.isEmpty(type) || mAppendEvents.contains(type)) {
       return;
     }
     mAppendEvents.add(type);