Changes view scale using view's LayoutParam.

@param verticalDragOffset used to calculate the new size.
164410
@Override public void updateScale(float verticalDragOffset) {
    layoutParams.width = (int) (getOriginalWidth() * (1 - verticalDragOffset / getXScaleFactor()));
    layoutParams.height = (int) (getOriginalHeight() * (1 - verticalDragOffset / getYScaleFactor()));

    getView().setLayoutParams(layoutParams);
  }
1308193
@Override
    protected void onLayout(boolean changed, int l, int t, int r, int b) {
        super.onLayout(changed, l, t, r, b);

        if (mAdjustViewSize) {
            if (!(getParent() instanceof RelativeLayout)) {
                throw new IllegalStateException("Only RelativeLayout is supported as parent of this view");
            }

            final int sWidth = ScreenHelper.getScreenWidth(getContext());
            final int sHeight = ScreenHelper.getScreenHeight(getContext());

            RelativeLayout.LayoutParams params = (RelativeLayout.LayoutParams) getLayoutParams();

            params.width = (int) (sWidth * mButtonMenu.getMainButtonSize());
            params.height = (int) (sWidth * mButtonMenu.getMainButtonSize());
            params.setMargins(0, 0, 0, (int) (sHeight * mButtonMenu.getBottomPadding()));
        }
    }
60367
public void setSvgIcon(final SVGIcon svgIcon) {
        if (this.svgIcon != null) {
            stack.getChildren().remove(this.svgIcon);
        }
        this.svgIcon = svgIcon;
        this.svgIcon.setSize(size);
        stack.getChildren().add(this.svgIcon);
        stack.requestLayout();
    }
133413
public void setSize(int newWidth, int newHeight) {
		this.width = newWidth;
		this.height = newHeight;

		if (helper.getRootElement() != null) {
			applyElementSize(helper.getRootElement(), newWidth, newHeight, false);
			Dom.setStyleAttribute(helper.getRootElement(), "clip", "rect(0 " + newWidth + "px " + newHeight + "px 0)");
		} else {
			SC.logWarn("problems");
		}
	}
43264
private void initLayout() {

        VerticalLayout page = new VerticalLayout();
        setContent(page);
        page.setId("page");

        page.addComponent(headerLayout);
        initLayoutHeader();

        page.addComponent(mainTab);


        initLayoutFooter();
        page.addComponent(layoutFooter);

    }
777680
public static void setDrawerVerticalPadding(View v, int level) {
        int verticalPadding = v.getContext().getResources().getDimensionPixelSize(R.dimen.material_drawer_vertical_padding);

        if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.JELLY_BEAN_MR1) {
            v.setPaddingRelative(verticalPadding * level, 0, verticalPadding, 0);
        } else {
            v.setPadding(verticalPadding * level, 0, verticalPadding, 0);
        }
    }
157398
protected final void setMeasuredDimension(View view, int width, int height) {
        final ViewProxy proxy = (ViewProxy) view;
        proxy.invokeSetMeasuredDimension(width, height);
    }
850633
public final void setPresetSize(int sizeType) {
        switch (sizeType) {
            case SMALL:
            case NORMAL:
            case LARGE:
            case CUSTOM:
                this.presetSizeType = sizeType;
                break;

            default:
                throw new IllegalArgumentException("Must use a predefined preset size");
        }

        requestLayout();
    }
1186362
public void scale(double scale) {
		this.m00 *= scale;
		this.m11 *= scale;
		this.m01 *= scale;
		this.m10 *= scale;
	}
400985
private void updateVerticalMargin() {

        int floatHeight = m_floatBox.getOffsetHeight();
        int primaryHeight = m_primary.getOffsetHeight();
        int verticalOffset = (primaryHeight - floatHeight) / 2;
        m_floatBox.getElement().getStyle().setMarginTop(verticalOffset, Unit.PX);
    }
649698
public void scaleAbsoluteHeight(float newHeight) {
		plainHeight = newHeight;
		float[] matrix = matrix();
		scaledWidth = matrix[DX] - matrix[CX];
		scaledHeight = matrix[DY] - matrix[CY];
		setWidthPercentage(0);
	}
1330771
public void updateLayout() {

        // TODO: we should not do this kind of things...
        if (!isAttached()) {
            return;
        }
        int floatBoxWidth = getFloatBoxWidth();
        m_primary.getElement().getStyle().setMarginLeft(floatBoxWidth, Unit.PX);
        updateVerticalMargin();
    }
595945
public void setScales(final double[] newScaleDenominators) {
        TreeSet<Double> sortedSet = new TreeSet<>(Collections.reverseOrder());
        for (final double newScaleDenominator: newScaleDenominators) {
            sortedSet.add(newScaleDenominator);
        }
        this.scaleDenominators = new double[sortedSet.size()];
        int i = 0;
        for (Double scaleDenominator: sortedSet) {
            this.scaleDenominators[i] = scaleDenominator;
            i++;
        }
    }
837767
@Override
    protected void onSizeChanged(int w, int h, int oldw, int oldh) {
        super.onSizeChanged(w, h, oldw, oldh);
        if (onClickedDrawable != null) {
            onClickedDrawable.setBounds(0, 0, w, h);
        }
    }
1374255
public void setDragView(View dragView) {
        if (mDragView != null) {
            mDragView.setOnClickListener(null);
        }
        mDragView = dragView;
        if (mDragView != null) {
            mDragView.setClickable(true);
            mDragView.setFocusable(false);
            mDragView.setFocusableInTouchMode(false);
            mDragView.setOnClickListener(new OnClickListener() {
                @Override
                public void onClick(View v) {
                    if (!isEnabled()) return;
                    if (!isPanelExpanded()) {
                        expandPanel(mAnchorPoint);
                    } else {
                        collapsePanel();
                    }
                }
            });;
        }
    }
1071889
public void setFooterDivider(Drawable drawable) {
        mFooterDivider = drawable;
        if (drawable != null) {
            mFooterDividerHeight = drawable.getIntrinsicHeight();
        } else {
            mFooterDividerHeight = 0;
        }
        mContentView.setWillNotDraw(drawable == null);
        mContentView.invalidate();
    }
738881
public void setSize(int size) {
        if (size != MaterialProgressDrawable.LARGE && size != MaterialProgressDrawable.DEFAULT) {
            return;
        }
        final DisplayMetrics metrics = getResources().getDisplayMetrics();
        if (size == MaterialProgressDrawable.LARGE) {
            mCircleHeight = mCircleWidth = (int) (CIRCLE_DIAMETER_LARGE * metrics.density);
        } else {
            mCircleHeight = mCircleWidth = (int) (CIRCLE_DIAMETER * metrics.density);
        }
        // force the bounds of the progress circle inside the circle view to
        // update by setting it to null before updating its size and then
        // re-setting it
        mCircleView.setImageDrawable(null);
        mProgress.updateSizes(size);
        mCircleView.setImageDrawable(mProgress);
    }