title: ImageView in LinearLayout is displayed on wrong place
body: <p>I have a layout with one row:</p>
  
  <pre class="lang-xml prettyprint-override"><code>&lt;LinearLayout
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_gravity="center_horizontal"
      android:gravity="center_horizontal"
      android:orientation="horizontal" &gt;
  
      &lt;TextView
          android:layout_width="match_parent"
          android:layout_height="wrap_content"
          android:paddingRight="@dimen/total_sales_page_summary_text_distance"
          android:text="test2"
          android:textSize="@dimen/total_sales_page_info_font_size" /&gt;
  
      &lt;TextView
          android:id="@+id/year_on_year"
          android:layout_width="match_parent"
          android:layout_height="wrap_content"
          android:textColor="@color/total_sales_info_text_color"
          android:textSize="@dimen/total_sales_page_info_font_size" /&gt;
  
      &lt;ImageView
          android:id="@+id/tradeGreen"
          android:layout_width="match_parent"
          android:layout_height="wrap_content"
          android:layout_marginLeft="5dp"
          android:layout_gravity="center_vertical"
          android:contentDescription=""/&gt;
  
  &lt;/LinearLayout&gt;
  </code></pre>
  
  <p>In source code I just set different number and visibility (GONE/VISIBLE) of imageview (clicking on different buttons).</p>
  
  <p>as result:</p>
  
  <ol>
  <li>image is not visible (button1 was clicked)</li>
  </ol>
  
  <p><img src="https://i.stack.imgur.com/SOht9.png" alt="enter image description here"></p>
  
  <p>2.image and some long number are vivible (button2 was clicked)</p>
  
  <p><img src="https://i.stack.imgur.com/POosv.png" alt="enter image description here"></p>
  
  <p>3.image and other little shorter number are visible (button3)</p>
  
  <p><img src="https://i.stack.imgur.com/LshES.png" alt="enter image description here"></p>
  
  <p>You can compare how it looks like. Text becomes visible but image is on the previous place. Why? Why image is not moved to left.</p>
  
  <p>By the way. When screen is rotated - image becomes visible on correct place.</p>