@Config(shadows = ShadowNestedScrollView.class) @Test public void testScrollToTop() { NestedScrollView scrollView = activity.findViewById(R.id.nested_scroll_view); scrollView.smoothScrollTo(0, 1); assertThat(customShadowOf(scrollView).getSmoothScrollY()).isEqualTo(1); activity.fragment.scrollToTop(); assertThat(customShadowOf(scrollView).getSmoothScrollY()).isEqualTo(0); }
@Override public void scrollToTop() { if (mFullscreen) { mWebView.pageUp(true); } else { mScrollableHelper.scrollToTop(); } }
WebFragment extends LazyLoadFragment implements Scrollable, KeyDelegate.BackInterceptor { @Override public void scrollToTop() { if (mFullscreen) { mWebView.pageUp(true); } else { mScrollableHelper.scrollToTop(); } } }
WebFragment extends LazyLoadFragment implements Scrollable, KeyDelegate.BackInterceptor { @Override public void scrollToTop() { if (mFullscreen) { mWebView.pageUp(true); } else { mScrollableHelper.scrollToTop(); } }  }
WebFragment extends LazyLoadFragment implements Scrollable, KeyDelegate.BackInterceptor { @Override public void scrollToTop() { if (mFullscreen) { mWebView.pageUp(true); } else { mScrollableHelper.scrollToTop(); } }  @Override void onAttach(Context context); @Override void onCreate(@Nullable Bundle savedInstanceState); @Override View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState); @Override void onViewCreated(View view, @Nullable Bundle savedInstanceState); @Override boolean onOptionsItemSelected(MenuItem item); @Override void onResume(); @Override void onStop(); @Override void onSaveInstanceState(Bundle outState); @Override void onDestroy(); @Override void onDetach(); @Override void scrollToTop(); @Override boolean scrollToNext(); @Override boolean scrollToPrevious(); @Override boolean onBackPressed(); }
WebFragment extends LazyLoadFragment implements Scrollable, KeyDelegate.BackInterceptor { @Override public void scrollToTop() { if (mFullscreen) { mWebView.pageUp(true); } else { mScrollableHelper.scrollToTop(); } }  @Override void onAttach(Context context); @Override void onCreate(@Nullable Bundle savedInstanceState); @Override View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState); @Override void onViewCreated(View view, @Nullable Bundle savedInstanceState); @Override boolean onOptionsItemSelected(MenuItem item); @Override void onResume(); @Override void onStop(); @Override void onSaveInstanceState(Bundle outState); @Override void onDestroy(); @Override void onDetach(); @Override void scrollToTop(); @Override boolean scrollToNext(); @Override boolean scrollToPrevious(); @Override boolean onBackPressed(); static final String EXTRA_ITEM; static final String PDF_LOADER_URL; }