Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
android_flowbox
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
android
android_flowbox
Commits
d9f5c143
Commit
d9f5c143
authored
Jul 07, 2021
by
mengcuiguang
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
http://39.97.65.143:81/android/android_flowbox
parents
e3a373da
10de110d
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
21 additions
and
1 deletion
+21
-1
AboutusActivity.kt
...in/java/com/mints/flowbox/ui/activitys/AboutusActivity.kt
+3
-0
NumAnimUtil.java
...c/main/java/com/mints/flowbox/ui/widgets/NumAnimUtil.java
+18
-1
No files found.
app/src/main/java/com/mints/flowbox/ui/activitys/AboutusActivity.kt
View file @
d9f5c143
...
...
@@ -11,6 +11,7 @@ import com.mints.flowbox.R
import
com.mints.flowbox.common.AppConfig
import
com.mints.flowbox.common.Constant
import
com.mints.flowbox.ui.activitys.base.BaseActivity
import
com.mints.flowbox.ui.widgets.NumAnimUtil
import
com.mints.flowbox.utils.ToastUtil
import
com.mints.library.utils.CommonUtils
import
com.mints.library.utils.ConstantUtil
...
...
@@ -50,6 +51,8 @@ class AboutusActivity : BaseActivity(), View.OnClickListener {
MintsApplication
.
getContext
(),
"CHANNEL_NAME"
)
+
"\n 头条渠道:"
+
HumeSDK
.
getChannel
(
context
)
)
// NumAnimUtil.startAnim(tvAboutasVersion,100f)
true
}
...
...
app/src/main/java/com/mints/flowbox/ui/widgets/NumAnimUtil.java
View file @
d9f5c143
...
...
@@ -14,10 +14,26 @@ public class NumAnimUtil {
//每秒刷新多少次
private
static
final
int
COUNTPERS
=
100
;
/**
* 进度100 时间2秒
* @param textV
*/
public
static
void
startAnim
(
TextView
textV
)
{
startAnim
(
textV
,
100
,
2000
);
}
/**
* 进度随意 时间2秒
* @param textV
*/
public
static
void
startAnim
(
TextView
textV
,
float
num
)
{
startAnim
(
textV
,
num
,
2000
);
}
/**
* 进度随意 时间随意
* @param textV
*/
public
static
void
startAnim
(
TextView
textV
,
float
num
,
long
time
)
{
if
(
num
==
0
)
{
textV
.
setText
(
NumAnimUtil
.
NumberFormat
(
num
,
2
));
...
...
@@ -81,7 +97,8 @@ public class NumAnimUtil {
}
public
static
String
NumberFormat
(
float
f
,
int
m
)
{
return
String
.
format
(
"%."
+
m
+
"f"
,
f
);
return
String
.
format
(
"%."
+
0
+
"f"
,
f
);
// return String.format("%" + f);
}
public
static
float
NumberFormatFloat
(
float
f
,
int
m
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment