* [Core] Rename layer-limit

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

Branch: refs/heads/master
Commit: 9689fae579977491c604123317141feb93c3ee71
Parents: 0d3d966
Author: miomin <691292...@qq.com>
Authored: Wed May 2 16:08:22 2018 +0800
Committer: YorkShen <shenyua...@gmail.com>
Committed: Mon May 7 15:52:09 2018 +0800

----------------------------------------------------------------------
 .../main/java/com/taobao/weex/common/Constants.java   |  2 +-
 .../com/taobao/weex/ui/component/WXComponent.java     | 11 ++++++-----
 .../main/java/com/taobao/weex/ui/component/WXDiv.java | 14 +++++++-------
 .../com/taobao/weex/ui/component/WXVContainer.java    |  4 ++--
 .../java/com/taobao/weex/ui/view/WXFrameLayout.java   |  2 +-
 5 files changed, 17 insertions(+), 16 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/9689fae5/android/sdk/src/main/java/com/taobao/weex/common/Constants.java
----------------------------------------------------------------------
diff --git a/android/sdk/src/main/java/com/taobao/weex/common/Constants.java 
b/android/sdk/src/main/java/com/taobao/weex/common/Constants.java
index cd50b3f..c423ad1 100644
--- a/android/sdk/src/main/java/com/taobao/weex/common/Constants.java
+++ b/android/sdk/src/main/java/com/taobao/weex/common/Constants.java
@@ -189,7 +189,7 @@ public class Constants {
     String ARIA_HIDDEN = "ariaHidden";
     String ROLE = "role";
 
-    String STACKSIZE_LIMIT = "stacksizeLimit";
+    String LAYER_LIMIT = "layer-limit";
 
     String DIRECTION = "direction";
     String RTL = "rtl";

http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/9689fae5/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 4f28a7f..add5921 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
@@ -63,6 +63,7 @@ import android.support.v4.view.AccessibilityDelegateCompat;
 import android.support.v4.view.ViewCompat;
 import android.support.v4.view.accessibility.AccessibilityNodeInfoCompat;
 import android.text.TextUtils;
+import android.util.Log;
 import android.util.Pair;
 import android.view.Menu;
 import android.view.View;
@@ -170,14 +171,14 @@ public abstract class WXComponent<T extends View> extends 
WXBasicComponent imple
 
   private boolean waste = false;
 
-  private boolean hasStackSizeLimit = false;
+  private boolean hasLayerLimit = false;
 
-  protected void setStackSizeLimit(boolean hasStackSizeLimit) {
-    this.hasStackSizeLimit = hasStackSizeLimit;
+  protected void setLayerLimit(boolean hasLayerLimit) {
+    this.hasLayerLimit = hasLayerLimit;
   }
 
-  public boolean isStackSizeLimit() {
-    return hasStackSizeLimit;
+  public boolean isLayerLimit() {
+    return hasLayerLimit;
   }
 
   private ContentBoxMeasurement contentBoxMeasurement;

http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/9689fae5/android/sdk/src/main/java/com/taobao/weex/ui/component/WXDiv.java
----------------------------------------------------------------------
diff --git a/android/sdk/src/main/java/com/taobao/weex/ui/component/WXDiv.java 
b/android/sdk/src/main/java/com/taobao/weex/ui/component/WXDiv.java
index b485db5..9ebd7d8 100644
--- a/android/sdk/src/main/java/com/taobao/weex/ui/component/WXDiv.java
+++ b/android/sdk/src/main/java/com/taobao/weex/ui/component/WXDiv.java
@@ -21,7 +21,7 @@ package com.taobao.weex.ui.component;
 import android.content.Context;
 import android.support.annotation.NonNull;
 import android.text.TextUtils;
-import android.widget.ImageView;
+import android.util.Log;
 
 import com.taobao.weex.WXSDKInstance;
 import com.taobao.weex.annotation.Component;
@@ -119,18 +119,18 @@ public class WXDiv extends WidgetContainer<WXFrameLayout> 
implements FlatCompone
     return !promoteToView(true);
   }
 
-  @WXComponentProp(name = Constants.Name.STACKSIZE_LIMIT)
-  public void setStackSizeLimitModle(String stackSizeLimit) {
-    setStackSizeLimit(getStackSizeLimit(stackSizeLimit));
+  @WXComponentProp(name = Constants.Name.LAYER_LIMIT)
+  public void setLayerLimitModle(String layerLimit) {
+    setLayerLimit(getLayerLimit(layerLimit));
   }
 
-  private boolean getStackSizeLimit(String stackSizeLimit) {
+  private boolean getLayerLimit(String layerLimit) {
     boolean ret = false;
-    if (TextUtils.isEmpty(stackSizeLimit)) {
+    if (TextUtils.isEmpty(layerLimit)) {
       return ret;
     }
 
-    switch (stackSizeLimit) {
+    switch (layerLimit) {
       case "true":
         ret = true;
         break;

http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/9689fae5/android/sdk/src/main/java/com/taobao/weex/ui/component/WXVContainer.java
----------------------------------------------------------------------
diff --git 
a/android/sdk/src/main/java/com/taobao/weex/ui/component/WXVContainer.java 
b/android/sdk/src/main/java/com/taobao/weex/ui/component/WXVContainer.java
index 346387c..45aa7ea 100644
--- a/android/sdk/src/main/java/com/taobao/weex/ui/component/WXVContainer.java
+++ b/android/sdk/src/main/java/com/taobao/weex/ui/component/WXVContainer.java
@@ -269,8 +269,8 @@ public abstract class WXVContainer<T extends ViewGroup> 
extends WXComponent<T> {
       mChildren.add(index, child);
     }
 
-    if (isStackSizeLimit())
-      child.setStackSizeLimit(true);
+    if (isLayerLimit())
+      child.setLayerLimit(true);
   }
 
   public final int indexOf(WXComponent comp) {

http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/9689fae5/android/sdk/src/main/java/com/taobao/weex/ui/view/WXFrameLayout.java
----------------------------------------------------------------------
diff --git 
a/android/sdk/src/main/java/com/taobao/weex/ui/view/WXFrameLayout.java 
b/android/sdk/src/main/java/com/taobao/weex/ui/view/WXFrameLayout.java
index 56dc205..ea05c7e 100644
--- a/android/sdk/src/main/java/com/taobao/weex/ui/view/WXFrameLayout.java
+++ b/android/sdk/src/main/java/com/taobao/weex/ui/view/WXFrameLayout.java
@@ -96,7 +96,7 @@ public class WXFrameLayout extends FrameLayout implements 
WXGestureObservable,IR
 
   @Override
   protected void dispatchDraw(Canvas canvas) {
-    if (getComponent() != null && getComponent().isStackSizeLimit()) {
+    if (getComponent() != null && getComponent().isLayerLimit()) {
       dispatchDrawInterval(canvas);
     } else {
       try {

Reply via email to