Android:滚动afterTextChanged不起作用

Android: scrolling in afterTextChanged does not work

I have an ImageView, and below it an EditText. I want to be able to write to the EditText while looking at the ImageView. The EditText is not visible at that point. Does anybody have an idea how to achieve this? I tried it with a TextWatcher, but the scrollTo in the afterTextChanged did not work.

myImageView.setImageBitmap(myImageBitmap);
TextWatcher textWatcher = new TextWatcher() {
    int xBefore;
    int yBefore;

    @Override
    public void beforeTextChanged(CharSequence s, int start, int count, int after) {
        yBefore = myScrollView.getScrollY();
        xBefore = myScrollView.getScrollX();
    }

    @Override
    public void afterTextChanged(Editable s) {
        myScrollView.scrollTo(xBefore, yBefore);
    }
};
myEditText.addTextChangedListener(textWatcher);

The xml looks as follows:

<?xml version="1.0" encoding="utf-8"?>
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/myScrollView"
android:layout_width="match_parent"
android:layout_height="wrap_content">

<LinearLayout
    android:id="@+id/activity_main"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:paddingBottom="@dimen/activity_vertical_margin"
    android:paddingLeft="@dimen/activity_horizontal_margin"
    android:paddingRight="@dimen/activity_horizontal_margin"
    android:paddingTop="@dimen/activity_vertical_margin"
    tools:context="ch.ethz.somr.smartphonebattle.FastestCameraActivity"
    android:orientation="vertical">

    <ImageView
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:id="@+id/myImageView"
        android:scaleType="fitStart"
        android:adjustViewBounds="true"/>

    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:orientation="vertical"
        android:id="@+id/container_input">

        <EditText
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:id="@+id/myEditText"
            android:inputType="number"
            android:hint="@string/my_hint"/>

    </LinearLayout>

</LinearLayout>
</ScrollView>

I found out that my code works if you wait for a short amount of time in the afterTextChanged, i.e. like that it works:

Runnable myRunnable = new Runnable() {
    @Override
    public void run() {
        findViewById(R.id.fast_scrollView).scrollTo(xBefore, yBefore);
    }
};

@Override
public void afterTextChanged(Editable s) {
    Handler handler = new Handler();
    handler.postDelayed(myRunnable, 10);
}