mirror of
https://github.com/pppscn/SmsForwarder
synced 2024-11-08 01:10:23 +00:00
优化:仅当有WIFI网络时自动检查更新/获取提示
This commit is contained in:
parent
66e324bbbb
commit
ff2be5553f
@ -47,6 +47,7 @@ import com.xuexiang.xui.widget.dialog.materialdialog.DialogAction
|
|||||||
import com.xuexiang.xui.widget.dialog.materialdialog.GravityEnum
|
import com.xuexiang.xui.widget.dialog.materialdialog.GravityEnum
|
||||||
import com.xuexiang.xui.widget.dialog.materialdialog.MaterialDialog
|
import com.xuexiang.xui.widget.dialog.materialdialog.MaterialDialog
|
||||||
import com.xuexiang.xutil.file.FileUtils
|
import com.xuexiang.xutil.file.FileUtils
|
||||||
|
import com.xuexiang.xutil.net.NetworkUtils
|
||||||
import frpclib.Frpclib
|
import frpclib.Frpclib
|
||||||
import io.reactivex.CompletableObserver
|
import io.reactivex.CompletableObserver
|
||||||
import io.reactivex.android.schedulers.AndroidSchedulers
|
import io.reactivex.android.schedulers.AndroidSchedulers
|
||||||
@ -118,8 +119,11 @@ class MainActivity : BaseActivity<ActivityMainBinding?>(),
|
|||||||
}
|
}
|
||||||
|
|
||||||
private fun initData() {
|
private fun initData() {
|
||||||
showTips(this)
|
//仅当有WIFI网络时自动检查更新/获取提示
|
||||||
XUpdateInit.checkUpdate(this, false)
|
if (NetworkUtils.isWifi() && NetworkUtils.isHaveInternet()) {
|
||||||
|
showTips(this)
|
||||||
|
XUpdateInit.checkUpdate(this, false)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
fun initListeners() {
|
fun initListeners() {
|
||||||
|
Loading…
Reference in New Issue
Block a user