Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Avoid Ext.form validation scrolling to top

I have a Ext.form.Panel inside Ext.window. Form height is more than window height so I have vertical scroll on window.

On form fields validation (on validitychange event) scroll jumps to the top.

How to avoid this behaviour?

like image 765
s.webbandit Avatar asked Feb 26 '13 07:02

s.webbandit


1 Answers

I tried to figure out, why one of my forms did scroll up and other did not. Turned out, that I have forgot to explicitly specify layout manager and that default layout manager (anchor) scrolled to top on validity change, while vbox layout did not. While everything looked exactly the same (vbox with align: 'stretch'), it behaved differently when the error was either shown or hidden.

like image 172
Miisha Avatar answered Sep 28 '22 11:09

Miisha