I have a gradient drawable defined in xml that I use it as a background, like this:
Found the answer!. Possible duplicate Multi-gradient shapes.
Replaced:
backColor.setBounds(0, 0,0, 4); shadow.setBounds(0,98, 0, 0);
for
layerList.setLayerInset(0, 0, 0, 0, 4); layerList.setLayerInset(1, 0, 98, 0, 0);