mirror of
https://gitee.com/shuto/cordova-plugin-network-information.git
synced 2025-02-23 04:02:50 +08:00
Fixed docs for online/offline event being backwards
github: close apache/cordova-docs#213
This commit is contained in:
parent
c19fecc19b
commit
6869d768a1
@ -128,8 +128,7 @@ not connected to the Internet.
|
|||||||
The `offline` event fires when a previously connected device loses a
|
The `offline` event fires when a previously connected device loses a
|
||||||
network connection so that an application can no longer access the
|
network connection so that an application can no longer access the
|
||||||
Internet. It relies on the same information as the Connection API,
|
Internet. It relies on the same information as the Connection API,
|
||||||
and fires when the `connection.type` changes from `NONE` to any other
|
and fires when the value of `connection.type` becomes `NONE`.
|
||||||
value.
|
|
||||||
|
|
||||||
Applications typically should use `document.addEventListener` to
|
Applications typically should use `document.addEventListener` to
|
||||||
attach an event listener once the `deviceready` event fires.
|
attach an event listener once the `deviceready` event fires.
|
||||||
@ -166,8 +165,9 @@ becomes connected to the Internet.
|
|||||||
|
|
||||||
The `online` event fires when a previously unconnected device receives
|
The `online` event fires when a previously unconnected device receives
|
||||||
a network connection to allow an application access to the Internet.
|
a network connection to allow an application access to the Internet.
|
||||||
It relies on the same information as the Connection API, and fires
|
It relies on the same information as the Connection API,
|
||||||
when the value of `connection.type` becomes `NONE`.
|
and fires when the `connection.type` changes from `NONE` to any other
|
||||||
|
value.
|
||||||
|
|
||||||
Applications typically should use `document.addEventListener` to
|
Applications typically should use `document.addEventListener` to
|
||||||
attach an event listener once the `deviceready` event fires.
|
attach an event listener once the `deviceready` event fires.
|
||||||
|
Loading…
Reference in New Issue
Block a user