import: forward motion events to activity regardless

This commit is contained in:
Vincent Breitmoser 2014-06-20 22:25:13 +02:00 committed by Dominik Schürmann
parent 0a790c7aa2
commit 0d644e37b1

View File

@ -24,7 +24,9 @@ import android.support.v4.app.ListFragment;
import android.support.v4.app.LoaderManager;
import android.support.v4.content.Loader;
import android.support.v4.util.LongSparseArray;
import android.view.MotionEvent;
import android.view.View;
import android.view.View.OnTouchListener;
import android.widget.ListView;
import org.sufficientlysecure.keychain.Constants;
@ -163,6 +165,16 @@ public class ImportKeysListFragment extends ListFragment implements
mLoaderState = new KeyserverLoaderState(query, keyserver);
}
getListView().setOnTouchListener(new OnTouchListener() {
@Override
public boolean onTouch(View v, MotionEvent event) {
if (!mAdapter.isEmpty()) {
mActivity.onTouchEvent(event);
}
return false;
}
});
restartLoaders();
}