With Instagram when a user clicks on an EditText view the next scenario occurs:
For my case when I used ADJUST_RESIZE
I got the view displayed properly but ImageView of story must have scaleType [fitXY or centerCrop] which has a bad UI with some images, if I did not make it with these scaleTypes ImageView will be resized and have margins beside it.
The solution is to make ImageView with a fixed size.
private fun makeViewFullWidth(view: View) {
val point = Point()
// point will be populated with screen width and height
activity?.windowManager?.defaultDisplay?.getSize(point)
val param = view.layoutParams
param.width = point.x
param.height = point.y
view.layoutParams = param
}
you can also check this article