1 Star 0 Fork 0

soip/AnimatedProgressBar

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
贡献代码
同步代码
取消
提示: 由于 Git 不支持空文件夾,创建文件夹后会生成空的 .keep 文件
Loading...
README
Apache-2.0
AnimatedProgressBar =================== A ProgressBar that animates smoothly ![](animation.gif) ####[Download Sample App](https://github.com/anthonycr/AnimatedProgressBar/releases/download/1.0.0/release.apk) #Usage ####Gradle * run `git submodule add git@github.com:anthonycr/AnimatedProgressBar.git /yourProject/subFolder` * include the library in your `settings.gradle` file - `include ':animated-progress-bar'` - `project(':animated-progress-bar').projectDir = new File(rootProject.projectDir, '/yourProject/subFolder')` * compile the project: `compile project(':animated-progress-bar')` ####Other * Copy `AnimatedProgressBar.java` and the contents of `attrs.xml` into your project and you're all set. # API ####XML Usage ```XML <com.anthonycr.progress.AnimatedProgressBar xmlns:custom="http://schemas.android.com/apk/res-auto" android:id="@+id/progress_view" android:layout_width="match_parent" android:layout_height="5dp" android:background="#424242" custom:bidirectionalAnimate="true" custom:progressColor="#2196f3" /> ``` - `progressColor`: set the progress color of the AnimatedProgressBar. - `bidirectionalAnimate`: set to true to have it animate up and down, set it to false to only have it animate up. ####Java Usage ```Java int progressNum = 50; progressBar = (AnimatedProgressBar) findViewById(R.id.progress_view); progressBar.setProgress(50); progressNum = progressBar.getProgress(); ``` - `void setProgress(int number)`: a number between 0 and 100 that sets the progress of the view. If you set it out of these bounds, the view will set it to the closest bound, i.e. setting progress to 150 will correct it to 100. - `int getProgress()`: returns an integer of the view's progress between 0 and 100. #License ``` Copyright 2014 Anthony Restaino Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. ```

简介

A ProgressBar that animates instead of jumps 展开 收起
Java
Apache-2.0
取消

发行版

暂无发行版

贡献者

全部

近期动态

加载更多
不能加载更多了
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Java
1
https://gitee.com/gjl3189/AnimatedProgressBar.git
git@gitee.com:gjl3189/AnimatedProgressBar.git
gjl3189
AnimatedProgressBar
AnimatedProgressBar
master

搜索帮助