Android Utililty Methods Dimension Resize

List of utility methods to do Dimension Resize

Description

The list of methods to do Dimension Resize are organized into topic(s).

Method

intgetResizedDimension(int maxPrimary, int maxSecondary, int actualPrimary, int actualSecondary)
get Resized Dimension
if (maxPrimary == 0 && maxSecondary == 0) {
    return actualPrimary;
if (maxPrimary == 0) {
    double ratio = (double) maxSecondary / (double) actualSecondary;
    return (int) (actualPrimary * ratio);
if (maxSecondary == 0) {
...