How can I give an imageview click effect like a button on Android?

前端 未结 30 2328
情歌与酒
情歌与酒 2020-11-28 01:50

I have imageview in my Android app that I am using like a button with the onClick event given, but as you might guess it is not giving imageview a clickable effect when clic

30条回答
  •  刺人心
    刺人心 (楼主)
    2020-11-28 02:07

    I do some similar things See suitable for you or not

    View Press Effect Helper:

    • usage : do some simple press effect like iOS

      Simple Usage:

    • ImageView img = (ImageView) findViewById(R.id.img);

    • ViewPressEffectHelper.attach(img)

    https://gist.github.com/extralam/7489370

提交回复
热议问题