QPowerSource Class Reference
|
Constant | Value | Description |
---|---|---|
QPowerSource::Available | 0 | The power source is available. |
QPowerSource::NotAvailable | 1 | The power source is not available. |
QPowerSource::Failed | 2 | The power source has failed. |
Describes the type of the power source.
Constant | Value | Description |
---|---|---|
QPowerSource::Wall | 0 | This is a wall power source. Wall power sources are generally considered to provide infinite power, but are "unreliable" in that they may be disconnected at any time. |
QPowerSource::Battery | 1 | This is a battery power source. Battery power sources provide a finite amount of power, but are considered "reliable". |
QPowerSource::Virtual | 2 | This is a virtual power source. Virtual power sources do not correspond directly to a physical entity, but might, for example, be a virtual battery that consists of a weighted combination of other physical batteries. |
Construct a new power source object for id with the specified parent.
If id is empty, this class will use the default provider that supports the power source interface.
Destroys the QPowerSource instance.
Returns the power source availability.
This signal is emitted whenever the availability of the power source changes. The new value is passed along via availability.
See also QPowerSource::availability() and QPowerSourceProvider::setAvailability().
Returns the capacity, in milliamp-hours of the power source of -1 if the capacity is unavailable or invalid.
This signal is emitted whenever the power source capacity changes.
See also QPowerSource::capacity() and QPowerSourceProvider::setCapacity().
Returns the current charge of the source in percentage, or -1 if the charge is unavailable or invalid.
This signal is emitted whenever the power source charge changes.
See also QPowerSource::charge() and QPowerSourceProvider::setCharge().
Returns true if the power source is charging, false if not.
This signal is emitted whenever the power source changes the charging state. The new state is represented by isCharging.
See also QPowerSource::charging() and QPowerSourceProvider::setCharging().
Returns the time remaining, in minutes, of the power source, or -1 if the time remaining is unavailable or invalid.
This signal is emitted whenever the time remaining, in minutes, changes .
See also QPowerSource::timeRemaining() and QPowerSourceProvider::setTimeRemaining().
Returns the power source type.
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 qtextended4.4 | |
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