title: How can I dynamically change the height of a cardview?
body: <p>I'm trying to do it with using an objectanimator, like this:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;selector xmlns:android="http://schemas.android.com/apk/res/android"&gt;
      &lt;item android:state_focused="true" &gt;
          &lt;objectAnimator
              android:duration="@android:integer/config_shortAnimTime"
              android:propertyName="layout_height"
              android:valueTo="300dp"
              android:valueType="floatType" /&gt;
      &lt;/item&gt;
      &lt;item android:state_focused="false"&gt;
          &lt;objectAnimator
              android:duration="@android:integer/config_shortAnimTime"
              android:propertyName="layout_height"
              android:valueTo="100dp"
              android:valueType="floatType" /&gt;
      &lt;/item&gt;
  
  &lt;/selector&gt;
  </code></pre>
  
  <p>However, it doesn't work, because as far as I see Cardviews don't have <code>setHeight</code>, <code>setLayoutHeight</code> nor any other similar methods. So how can I change a card's height ( and similar atributes) then?</p>