每次我将此代码放入我的Android bug应用程序
private SwipeRefreshLayout swipeLayout;
....
webView.setWebViewClient(new WebViewClient() {
public void onPageFinished(WebView view, String url) {
}
});
swipeLayout = (SwipeRefreshLayout) findViewById(R.id.swipe_container);
swipeLayout.setOnRefreshListener(new SwipeRefreshLayout.OnRefreshListener(){
@Override
public void onRefresh() {
webView.reload();
}
} );