title: Android: Notify Scrollview that it's child's size has changed: how?
body: <p>When I enlarge the size of the content of a scrollview, the scrollview takes a while to get to "know" this size change of it's child. How can I order the ScrollView to check it's child immediately?</p>
  
  <p>I have an ImageView in a LinearLayout in a ScrollView.</p>
  
  <p>In my ScaleListener.onScale, I change the size of my LinearLayout. I then try to order a scroll on the scrollview. In the ScaleListener.onScale:</p>
  
  <pre><code>LinearLayout.LayoutParams params = (LinearLayout.LayoutParams) imageView.getLayoutParams();
  params.width = (int) (startX * scaleFactor);
  params.height = (int) (startY * scaleFactor);
  imageView.setLayoutParams(params);
  
  (...)
  
  scrollView.scrollBy(scrollX, scrollY);
  </code></pre>
  
  <p>However, no scrolling occurs when in the situation before the scaling scrolling was not possible because the view was too small to scroll. After the setLayoutParams, the view should be larger, but no scrolling occurs because the scrollview thinks the child is still small.</p>
  
  <p>When a fes ms later the onScroll is called again, it does scroll fine, it somehow found out that the child is larger and scrollable.</p>
  
  <p>How can I notify the scrollview immediately, that the child's size has changed? So that scrollBy will work right after setLayoutParams on it's child?</p>