Fix default values for translateX/Y props.

Reviewed By: andreicoman11

Differential Revision: D2631186

fb-gh-sync-id: 8f898b11be31b253780474d1cf328d7d109decbb
This commit is contained in:
Krzysztof Magiera 2015-11-09 07:55:00 -08:00 committed by facebook-github-bot-7
parent 86c1375c1a
commit c6532a94a6

View File

@ -113,13 +113,13 @@ public abstract class BaseViewManager<T extends View, C extends LayoutShadowNode
}
@Deprecated
@ReactProp(name = PROP_TRANSLATE_X, defaultFloat = 1f)
@ReactProp(name = PROP_TRANSLATE_X, defaultFloat = 0f)
public void setTranslateX(T view, float translateX) {
view.setTranslationX(PixelUtil.toPixelFromDIP(translateX));
}
@Deprecated
@ReactProp(name = PROP_TRANSLATE_Y, defaultFloat = 1f)
@ReactProp(name = PROP_TRANSLATE_Y, defaultFloat = 0f)
public void setTranslateY(T view, float translateY) {
view.setTranslationY(PixelUtil.toPixelFromDIP(translateY));
}