Language

EmbeddedPhotoPickerUiCustomizationParams.Builder.SetAspectRatio Method

Definition

Sets the desired aspect ratio for the media grid thumbnails within the Photo Picker UI.

[Android.Runtime.Register("setAspectRatio", "(I)Landroid/widget/photopicker/EmbeddedPhotoPickerUiCustomizationParams$Builder;", "", ApiSince=37)]
public Android.Widget.PhotoPicker.EmbeddedPhotoPickerUiCustomizationParams.Builder SetAspectRatio(Android.Widget.PhotoPicker.AspectRatio aspectRatio);
[<Android.Runtime.Register("setAspectRatio", "(I)Landroid/widget/photopicker/EmbeddedPhotoPickerUiCustomizationParams$Builder;", "", ApiSince=37)>]
member this.SetAspectRatio : Android.Widget.PhotoPicker.AspectRatio -> Android.Widget.PhotoPicker.EmbeddedPhotoPickerUiCustomizationParams.Builder

Parameters

aspectRatio
AspectRatio

The aspect ratio constant. Value is one of the following: EmbeddedPhotoPickerUiCustomizationParams.ASPECT_RATIO_UNDEFINED; EmbeddedPhotoPickerUiCustomizationParams.ASPECT_RATIO_SQUARE_1_1; EmbeddedPhotoPickerUiCustomizationParams.ASPECT_RATIO_PORTRAIT_9_16

Returns

Attributes

Remarks

Sets the desired aspect ratio for the media grid thumbnails within the Photo Picker UI.

The value must be one of the following constants: EmbeddedPhotoPickerUiCustomizationParams.ASPECT_RATIO_UNDEFINED; EmbeddedPhotoPickerUiCustomizationParams.ASPECT_RATIO_SQUARE_1_1; EmbeddedPhotoPickerUiCustomizationParams.ASPECT_RATIO_PORTRAIT_9_16. Any other value will result in throwing IllegalArgumentException.

If not set, the EmbeddedPhotoPickerUiCustomizationParams.ASPECT_RATIO_UNDEFINED will be used.

Android reference for android.widget.photopicker.EmbeddedPhotoPickerUiCustomizationParams.Builder.setAspectRatio.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to