Hey guys i have a problem. I made a button flashing animation by coding
button7.setOnTouchListener(new View.OnTouchListener() {
public boolean onTouch(View v, MotionEvent me) {
try{ button7.setCompoundDrawablesWithIntrinsicBounds(0,R.drawable.white,0,0);
} else if (me.getAction() == MotionEvent.ACTION_UP) {
button7.setCompoundDrawablesWithIntrinsicBounds(0,R.drawable.neun,0,0);
Which was very simple. Now the thing is, that this just works on one screen size, because the pictures dont get stretched. I made different layout XMLs for the different screen so can I just set the "android:onclick" (or something like that) in the XMLs so I can set a different picture for every size?
Thanks
I just tried messing around with "android:onClick" but achieved nothing.