Code example for WebChromeClient

Methods: onProgressChanged

        super.setWebChromeClient(new WebChromeClient() {
            public void onProgressChanged(WebView webview, int progress) {
                mProgress = progress;
                mWebChromeClient.onProgressChanged(webview, progress);
                if (mProgress >= 40 && !mIsHalfFinished) {
                    mIsHalfFinished = true;
            public boolean onJsAlert(WebView webview, String url, String message, android.webkit.JsResult result) {
                if (mWebChromeClient.onJsAlert(webview, url, message, result)) {
                    return true; 
                return mWebViewExClient.onJsAlert(webview, url, message, result);
Connect your IDE to all the code out there  Get Codota for Java