{"id":19864182,"url":"https://github.com/youlookwhat/webprogress","last_synced_at":"2026-03-07T03:03:22.368Z","repository":{"id":108853864,"uuid":"208464573","full_name":"youlookwhat/WebProgress","owner":"youlookwhat","description":"🎢  An Android WebView Progress Bar.  仿微信网页进度条。","archived":false,"fork":false,"pushed_at":"2021-09-23T14:43:19.000Z","size":193,"stargazers_count":107,"open_issues_count":0,"forks_count":30,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-06-17T16:45:37.803Z","etag":null,"topics":["progress","progress-animation","progress-bar","progressbar","webview"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/youlookwhat.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2019-09-14T15:59:42.000Z","updated_at":"2025-05-28T04:37:05.000Z","dependencies_parsed_at":"2023-03-06T20:15:22.031Z","dependency_job_id":null,"html_url":"https://github.com/youlookwhat/WebProgress","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/youlookwhat/WebProgress","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/youlookwhat%2FWebProgress","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/youlookwhat%2FWebProgress/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/youlookwhat%2FWebProgress/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/youlookwhat%2FWebProgress/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/youlookwhat","download_url":"https://codeload.github.com/youlookwhat/WebProgress/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/youlookwhat%2FWebProgress/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30206339,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-06T19:07:06.838Z","status":"online","status_checked_at":"2026-03-07T02:00:06.765Z","response_time":53,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["progress","progress-animation","progress-bar","progressbar","webview"],"created_at":"2024-11-12T15:17:43.085Z","updated_at":"2026-03-07T03:03:22.361Z","avatar_url":"https://github.com/youlookwhat.png","language":"Java","readme":"## WebProgress  [![](https://jitpack.io/v/youlookwhat/WebProgress.svg)](https://jitpack.io/#youlookwhat/WebProgress)\nAn Android WebView progress bar display control, so that its loading progress smooth transition.\n\n### Gif Preview\n\n![demo](https://raw.githubusercontent.com/youlookwhat/WebProgress/master/image.gif)\n\n\nGIF may have a point card to download a WebView project using this control for viewing：[网页浏览器](https://github.com/youlookwhat/download/raw/main/ByWebView.apk)\n\n## Use\n-  Add it in your root build.gradle at the end of repositories:\n \n\t```java\n\tallprojects {\n\t\trepositories {\n\t\t\t...\n\t\t\tmaven { url \"https://jitpack.io\" }\n\t\t}\n\t}\n\t```\n\n-  Add the dependency:\n \n     ```java\n\t\tdependencies {\n\t\t    implementation 'com.github.youlookwhat:WebProgress:1.2.0'\n\t\t}\n     ```\n\n- Or just copy the class directly into the project：[WebProgress](https://github.com/youlookwhat/WebProgress/blob/master/library/src/main/java/me/jingbin/progress/WebProgress.java)\n\n- xml：\n\n\t```xml\n\t \u003cme.jingbin.progress.WebProgress\n\t        android:id=\"@+id/progress\"\n\t        android:layout_width=\"match_parent\"\n\t        android:layout_height=\"2dp\" \n\t        android:visibility=\"gone\" /\u003e\n    ```\n\n- code handle：\n\n\t```java\n\t mProgress.show();                          // 显示\n\t mProgress.setWebProgress(50);              // 设置进度\n\t mProgress.setColor(\"#D81B60\");             // 设置颜色\n\t mProgress.setColor(\"#00D81B60\",\"#D81B60\"); // 设置渐变色\n\t mProgress.hide();                          // 隐藏\n   ```\n\n### [in WebView](https://github.com/youlookwhat/ByWebView/blob/master/app/src/main/java/com/example/jingbin/webviewstudy/WebViewActivity.java)\n - show WebProgress：\n\n\t```java\n\tmWebView.loadUrl(mUrl);\n\tmProgress.show();\n\t```\n\n - onProgressChanged handle:\n\n\t```java\n\t@Override\n    public void onProgressChanged(WebView view, int newProgress) {\n        super.onProgressChanged(view, newProgress);\n        mProgress.setWebProgress(newProgress);\n    }\n\t```\n\n - onPageFinished handle:\n\n\t```java\n\t @Override\n    public void onPageFinished(WebView view, String url) {\n        // html加载完成之后，无网隐藏进度条\n        if (!CheckNetwork.isNetworkConnected(this)) {\n            mProgress.hide();\n        }\n        super.onPageFinished(view, url);\n    }\n\t```\n\n## Thanks\n此类是从项目[Justson/AgentWeb-WebIndicator](https://github.com/Justson/AgentWeb/blob/master/agentweb-core/src/main/java/com/just/agentweb/WebIndicator.java)中将处理WebView进度条剥离出来的，在此基础上进行优化后合并为一个类，便于导入到自己的项目中，感谢作者的开源精神。如果此项目帮助到你，请给一个Star，非常感谢！\n\n优化处：\n\n * 1. 增加能显示进度渐变色\n * 2. 修复progress同时返回两次100时进度条出现两次\n * 3. [2019.9.29] 修复当第一次进度返回 0 或超过 10，出现不显示进度条的问题\n * 4. 修复当一条进度没跑完，又点击其他链接开始第二次进度时，第二次进度不出现的问题\n * 5. 修改消失动画时长，使其消失时可以看到进度跑完\n * 6. 修复进度在95-100时再次开始进度条透明度问题\n\n## End\n - 有问题或更好的建议，欢迎提[Issues](https://github.com/youlookwhat/WebProgress/issues)，我会及时处理，谢谢。\n\n\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyoulookwhat%2Fwebprogress","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fyoulookwhat%2Fwebprogress","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyoulookwhat%2Fwebprogress/lists"}