appcelerator/titanium_mobile — pull request #584 by vishalduggal (2011-10-25 21:06:03+00:00)
Title: [TIMOB-5803]Button background image does not scale correctly on click

[TIMOB-5803] TiUIButton now mimics Android behavior in setting of background images for various control states.

Added test case button_states.js to Kitchen Sink under controls
This tests the four button states (NORMAL, DISABLED, SELECTED, FOCUSED) by using the corresponding properties of the Titanium.UI.Button class.

Setting of backgroundImage or backgroundDisabledImage sets the image for all 4 states.
Setting of backgroundFocusedColor or backgroundSelectedImage sets the image for those states only.

ClickMe Button toggles the enabled state of Button B2.