Code example for View

Methods: getLeft

0
    public float getX() { 
        View view = mView.get();
        if (view == null) {
            return 0; 
        } 
        return view.getLeft() + mTranslationX;
    } 
    public void setX(float x) {
        View view = mView.get();
        if (view != null) {
            setTranslationX(x - view.getLeft());
        } 
    } 
    public float getY() { 
        View view = mView.get();
        if (view == null) {
            return 0; 
        } 
        return view.getTop() + mTranslationY;
    } 
    public void setY(float y) {