From e2df869b529720632a9353270fc8764cfa72d7ec Mon Sep 17 00:00:00 2001 From: "pengfei.zhou" Date: Fri, 29 Nov 2019 19:33:54 +0800 Subject: [PATCH] feat:currently remove rotationX,rotationY --- .../main/java/pub/doric/shader/ViewNode.java | 42 ------------------- iOS/Pod/Classes/Shader/DoricViewNode.m | 2 - js-framework/src/ui/view.ts | 14 ++----- 3 files changed, 3 insertions(+), 55 deletions(-) diff --git a/Android/doric/src/main/java/pub/doric/shader/ViewNode.java b/Android/doric/src/main/java/pub/doric/shader/ViewNode.java index 7af8d289..f137011e 100644 --- a/Android/doric/src/main/java/pub/doric/shader/ViewNode.java +++ b/Android/doric/src/main/java/pub/doric/shader/ViewNode.java @@ -313,28 +313,6 @@ public abstract class ViewNode extends DoricContextHolder { setRotation(prop.asNumber().toFloat()); } break; - case "rotationX": - if (isAnimating()) { - addAnimator(ObjectAnimator.ofFloat( - this, - name, - getRotationX(), - prop.asNumber().toFloat())); - } else { - setRotationX(prop.asNumber().toFloat()); - } - break; - case "rotationY": - if (isAnimating()) { - addAnimator(ObjectAnimator.ofFloat( - this, - name, - getRotationY(), - prop.asNumber().toFloat())); - } else { - setRotationY(prop.asNumber().toFloat()); - } - break; default: break; } @@ -601,26 +579,6 @@ public abstract class ViewNode extends DoricContextHolder { return getNodeView().getRotation() / 180; } - @DoricMethod - public void setRotationX(float rotation) { - getNodeView().setRotationX(rotation * 180); - } - - @DoricMethod - public float getRotationX() { - return getNodeView().getRotationX() / 180; - } - - @DoricMethod - public void setRotationY(float rotation) { - getNodeView().setRotationY(rotation * 180); - } - - @DoricMethod - public float getRotationY() { - return getNodeView().getRotationY() / 180; - } - @DoricMethod public void setPivotX(float v) { getNodeView().setPivotX(v * getNodeView().getWidth()); diff --git a/iOS/Pod/Classes/Shader/DoricViewNode.m b/iOS/Pod/Classes/Shader/DoricViewNode.m index 56e66342..f90aa868 100644 --- a/iOS/Pod/Classes/Shader/DoricViewNode.m +++ b/iOS/Pod/Classes/Shader/DoricViewNode.m @@ -73,8 +73,6 @@ @interface DoricViewNode () @property(nonatomic, copy) NSNumber *scaleX; @property(nonatomic, copy) NSNumber *scaleY; @property(nonatomic, copy) NSNumber *rotation; -@property(nonatomic, copy) NSNumber *rotationX; -@property(nonatomic, copy) NSNumber *rotationY; @property(nonatomic, copy) NSNumber *pivotX; @property(nonatomic, copy) NSNumber *pivotY; @end diff --git a/js-framework/src/ui/view.ts b/js-framework/src/ui/view.ts index 9ce21633..3901555f 100644 --- a/js-framework/src/ui/view.ts +++ b/js-framework/src/ui/view.ts @@ -59,12 +59,10 @@ export interface IView { * float [0,..1] */ pivotY?: number - + /** + * rotation*PI + */ rotation?: number - - rotationX?: number - - rotationY?: number /**----------transform----------*/ } @@ -331,12 +329,6 @@ export abstract class View implements Modeling, IView { @Property rotation?: number - - @Property - rotationX?: number - - @Property - rotationY?: number /**----------transform----------*/ }