0

I have the following situation:

A form with 3 fields where a field's top-margin is -1 and bottom margin is 0. Therefore, there is only a single pixel of border between the fields (since the border is 1px). The border color changes upon selection but since the field on the bottom is on top of it, the bottom border is not changed since it is the one of the element below. One solution I thought of is changing the z-index of the focused element but I don't know precisely how to do it.

enter image description here

ziGi
  • 828
  • 8
  • 28

1 Answers1

1

Use z-index to bring it to the front: obj.getEl().setStyle('z-index','10000');

Or check bringToFront(): Ext.WindowManager.bringToFront( obj );

Shlomo
  • 3,880
  • 8
  • 50
  • 82
  • bringToFront() seems a bit more object oriented to me so I would prefer it. Nevertheless, I thought that it is only possible for floating layouts. How would that work with the form, can you give a sample code snippet? – ziGi Jul 16 '13 at 16:21