Android Question AppCompat : ACSwitch flashing when pressed ?

Discussion in 'Android Questions' started by lemonisdead, Apr 14, 2015.

  1. lemonisdead

    lemonisdead Well-Known Member Licensed User

    Hello,

    Please do you have already used the ACSwitch and could you please confirm that the flashing is a normal behavior while pressing the switch ?

    The problem is that it does show the whole dimension of the control : I mean the flashing is the whole view (even the borders).

    Many thanks
     
  2. shashkiranr

    shashkiranr Active Member Licensed User

    it is happening in my application also.
     
    lemonisdead likes this.
  3. Peter Simpson

    Peter Simpson Expert Licensed User

    Hmm I'm might be getting this wrong but I don't see a flashing as such. The whole view changed colour instantly then animates, the colour changing might look like a flash to some people but not to me, it's just a colour change. So depending on ones point of view, I would say that it's not flashing but just changing colour quickly only N5 and S4 devices.

    Not unless you are actually seeing the view flash off and then back on again, but I'm not seeing that either...
     
    lemonisdead likes this.
  4. shashkiranr

    shashkiranr Active Member Licensed User

    @Peter - Thank you for your reply. When the switch is pressed, the background color changes like a pressed drawable.
     
    lemonisdead likes this.
  5. lemonisdead

    lemonisdead Well-Known Member Licensed User

    @Peter Simpson : on Moto G XT1032 and Nexus 6 I do see a ugly flash with all the borders of the view changing their colors. That's not the same behavior as the other apps I tried. Reason why I had asked.
     
  6. shashkiranr

    shashkiranr Active Member Licensed User

    @lemonisdead Keep the switch view width as 50dip. the effect is much reduced.
     
    lemonisdead likes this.
  7. lemonisdead

    lemonisdead Well-Known Member Licensed User

    I do thank you for your advice @shashkiranr. You are absolutely right. It is better so. Many thanks
     
  8. LucianDesign

    LucianDesign Member Licensed User

    Hello,
    I have the same issue. Maybe I'm just being picky, but can we just remove the flash effect just by editing some xml?
     
  9. corwin42

    corwin42 Expert Licensed User

    Do you all mean with "flashing" the ripple effect? Or are you running pre Lollipop Android versions?

    I haven't tried it but a possible solution may be to set the color of the ACSwitch to Colors.Transparent.
     
  10. LucianDesign

    LucianDesign Member Licensed User

    Thanks! That works perfectly
     
Loading...
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice