Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
lib_base
Overview
Overview
Details
Activity
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
sikang
lib_base
Commits
dbbce67b
Commit
dbbce67b
authored
Dec 12, 2018
by
sikang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bug修复
parent
152a71f0
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
1 deletions
+8
-1
src/main/java/tech/starwin/base/BaseActivity.java
+7
-1
src/main/java/tech/starwin/widget/ProgressDialog.java
+1
-0
No files found.
src/main/java/tech/starwin/base/BaseActivity.java
View file @
dbbce67b
...
...
@@ -128,6 +128,7 @@ public abstract class BaseActivity extends AppCompatActivity implements IView {
@Override
protected
void
onStop
()
{
super
.
onStop
();
progressDialog
.
setEnable
(
false
);
lifecycleSubject
.
onNext
(
ActivityEvent
.
STOP
);
}
...
...
@@ -171,7 +172,12 @@ public abstract class BaseActivity extends AppCompatActivity implements IView {
if
(
isShowLoading
&&
!
progressDialog
.
isShowing
())
{
//500ms后如果还没有收到返回数据,显示loading
progressDialog
.
setEnable
(
true
);
rootLayout
.
postDelayed
(()
->
progressDialog
.
showLoading
(),
500
);
rootLayout
.
postDelayed
(
new
Runnable
()
{
@Override
public
void
run
()
{
progressDialog
.
showLoading
();
}
},
500
);
}
}
...
...
src/main/java/tech/starwin/widget/ProgressDialog.java
View file @
dbbce67b
package
tech
.
starwin
.
widget
;
import
android.annotation.SuppressLint
;
import
android.app.Activity
;
import
android.app.Dialog
;
import
android.content.Context
;
import
android.support.annotation.NonNull
;
...
...
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