QML NetworkInfo ElementThe NetworkInfo element allows you to get information and receive notifications from the network. More... Properties
Signals
MethodsDetailed DescriptionThis element is part of the QtMobility.systeminfo 1.1 module. It is a convience class to make QML usage easier. Note: To use notification signals, you need to set the monitor* properties to true. In QtMobility 1.2, the NetworkInfo Element was changed to work in one network mode at a time. You use the property mode to set which network mode it is in. The following table lists the incompatible changes made to the start* functions between QtMobility 1.1 and 1.2, where they became Q_PROPERTY:
Example new usage: QtMobility 1.2: NetworkInfo { id: wlaninfo mode: NetworkInfo.WlanMode; monitorNameChanges: true; monitorSignalStrengthChanges: true monitorStatusChanges: true monitorModeChanges: true onStatusChanged : { img = getImage(newStatus) } } To use this in a mode other than the default mode given by currentMode, set the mode with mode. import Qt 4.7 import QtMobility.systeminfo 1.1 Rectangle { NetworkInfo { id: wlaninfo mode: NetworkInfo.WlanMode; monitorNameChanges: true monitorSignalStrengthChanges: true } Text { id: signame color: "white" text: wlaninfo.networkName +" "+wlaninfo.networkSignalStrength; anchors.horizontalCenter: parent.horizontalCenter; anchors.verticalCenter: parent.verticalCenter; } } See also QSystemNetworkInfo. Property DocumentationReturns this NetworkInfo's network interface's MAC address. This documentation was introduced in Qt Mobility Mobility 1.1. Sets this NetworkInfo to use QSystemNetworkInfo::NetworkModes. Does not set the mode of the underlaying system. If not set, the default is whatever defaultMode is. This documentation was introduced in Qt Mobility Mobility 1.1. This documentation was introduced in Qt Mobility Mobility 1.2. See also QSystemNetworkInfo::cellDataTechnologyChanged. This documentation was introduced in Qt Mobility Mobility 1.2. This documentation was introduced in Qt Mobility Mobility 1.2. This documentation was introduced in Qt Mobility Mobility 1.2. This documentation was introduced in Qt Mobility Mobility 1.2. This documentation was introduced in Qt Mobility Mobility 1.2. This documentation was introduced in Qt Mobility Mobility 1.2. This documentation was introduced in Qt Mobility Mobility 1.2. Returns this NetworkInfo's network name. This documentation was introduced in Qt Mobility Mobility 1.1. Returns this NetworkInfo's network signal strength. This documentation was introduced in Qt Mobility Mobility 1.1. Returns this NetworkInfo's network status. The following table shows the mapping between the NetworkInfo NetworkStatus property and the QSystemNetworkInfo::NetworkStatus enum.
This documentation was introduced in Qt Mobility Mobility 1.1. Signal DocumentationThis handler is called when network MCC has changed. Note: To receive this notification, you must first call startCurrentMobileCountryCodeChanged. This documentation was introduced in Qt Mobility Mobility 1.1. This handler is called when network MNC has changed. Note: To receive this notification, you must first call startCurrentMobileNetworkCodeChanged. This documentation was introduced in Qt Mobility Mobility 1.1. This handler is called when the systems default network mode has changed. Note: To receive this notification, you must first call startModeChanged. This documentation was introduced in Qt Mobility Mobility 1.1. This handler is called when network name has changed. Note: To receive this notification, you must first call startNameChanged. This documentation was introduced in Qt Mobility Mobility 1.1. This handler is called when network signal strength has changed. Note: To receive this notification, you must first call startSignalStrengthChanged. This documentation was introduced in Qt Mobility Mobility 1.1. This handler is called when network status has changed. Note: To receive this notification, you must first call startStatusChanged. This documentation was introduced in Qt Mobility Mobility 1.1. Method DocumentationReturns the QNetworkInterface for this NetworkInfo. This documentation was introduced in Qt Mobility Mobility 1.1. |
Publicité
Best OfActualités les plus luesSemaine
Mois
Année
![]()
![]() Le Qt Quarterly au hasard![]() Utiliser CMake pour compiler des projets QtQt Quarterly est la revue trimestrielle proposée par Nokia et à destination des développeurs Qt. Ces articles d'une grande qualité technique sont rédigés par des experts Qt. Lire l'article.
CommunautéRessources
Liens utilesContact
Qt dans le magazine |
Cette page est une traduction d'une page de la documentation de Qt, écrite par Nokia Corporation and/or its subsidiary(-ies). Les éventuels problèmes résultant d'une mauvaise traduction ne sont pas imputables à Nokia. | Qt qtmobility-1.2 | |
Copyright © 2012 Developpez LLC. Tous droits réservés Developpez LLC. Aucune reproduction, même partielle, ne peut être faite de ce site et de l'ensemble de son contenu : textes, documents et images sans l'autorisation expresse de Developpez LLC. Sinon, vous encourez selon la loi jusqu'à 3 ans de prison et jusqu'à 300 000 E de dommages et intérêts. Cette page est déposée à la SACD. | ||
Vous avez déniché une erreur ? Un bug ? Une redirection cassée ? Ou tout autre problème, quel qu'il soit ? Ou bien vous désirez participer à ce projet de traduction ? N'hésitez pas à nous contacter ou par MP ! |
Copyright © 2000-2012 - www.developpez.com