Skip to content
Advertisement

View not clickable after translate in CoordinatorLayot

I have a ConstraintLayout wrapping my FABs section in the bottom right of the app. I use a layout and not only the buttons because I have more views all around the FABs (they are omitted in the example below, the real layout is more complex). The layout has a CoordinatorLayout as main parent. I have two FABs, one near to the other, when I click the first one the second animates and move up using ViewPropertyAnimations, then I click the second one and other views should appear. ISSUE IS: the translated FAB isn’t clickable. I can click on it before the animation starts but not after translation.

not clickable fab

What I’ve found so far:

  • If I leave only CoordinatorLayout and FAbs buttons –> OK, click works after translate
  • If I leave only ConstraintLayout and FAbs buttons –> OK, click works after translate
  • If I leave CoordinatorLayout , ConstraintLayout and FAbs buttons –> KO, click doesn’t work after translate
  • If I replace ConstraintLayout with LinearLayout –> KO, click doesn’t work after translate

Can you help me to fix this?

Dependencies versions

JavaScript

Fragment layout (it’s a simplified version, the real one has many views)

JavaScript

Animation code

JavaScript

Advertisement

Answer

The issue seems solved with constraintlayout:2.1.0

User contributions licensed under: CC BY-SA
7 People found this is helpful
Advertisement