sunyatas / netstatusbus Goto Github PK
View Code? Open in Web Editor NEWNetStatusBus 简化了网络监听的流程,使代码更加简洁高效
NetStatusBus 简化了网络监听的流程,使代码更加简洁高效
网络状态从WIFI切换到NONE时会有MOBILE类型函数执行
网络状态从MOBILE切换到NONE时会有WIFI类型函数执行
不应该有上述两种函数执行
混淆后,netChange都不回调了,麻烦提供混淆文件配置
更新网络状态几十秒才反应过来
/**
* 当监听到 WIFI 连接时,会调用使用该模式的所有方法
*/
@NetSubscribe(mode = Mode.WIFI_CONNECT)
public void mobileChange() {
tvTips.setText("wifi已连接");
imgNetStatus.setImageDrawable(getResources().getDrawable(R.drawable.ic_wifi));
}
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.