Home · All Namespaces · All Classes · Grouped Classes · Modules · Functions |
The QPhoneProfile class encapsulates a single phone profile configuration. More...
#include <QPhoneProfile>
The QPhoneProfile class encapsulates a single phone profile configuration.
The QPhoneProfile class holds data on how the phone behaves for incoming calls or messages when it is activated. When a new profile is created it plays system default tones, systemCallTone() and systemMessageTone(), which can be personalized by setCallTone() and setMessageTone().
A profile can be manually activated through the QPhoneProfileManager::activateProfile() method. Alternatively a profile may be set to auto-activate at certain times, controlled through by QPhoneProfile::schedule(), or when a phone audio profile is attached by QPhoneProfile::setAudioProfile(). For example, a profile can be automatically activated when Bluetooth hands-free is enabled.
A profile can have a number of associated settings that can be retrieved by applicationSetting() and applicationSettings(). These settings are passed to applications by SettingsService::activateSettings() to be applied when the profile is activated.
Applications that wish to add their settings to a profile can use SettingsManagerService.
See also QPhoneProfile::Schedule, QHardwareInterface, QPhoneProfileManager, QPhoneProfileProvider, SettingsManagerService, and SettingsService.
Controls how a ring or message tone is played.
Constant | Value | Description |
---|---|---|
QPhoneProfile::Off | 0 | No tone is played. |
QPhoneProfile::Once | 1 | The tone is played once, from beginning to end. |
QPhoneProfile::Continuous | 2 | The tone is played repeatedly until the user acknowledges the alert. |
QPhoneProfile::Ascending | 3 | The tone is played repeatedly with increasing volume each time. |
This is a convenience typedef to encapsulate a mapping between application names and their corresponding Setting object. The exact type is:
QMap<QString, QPhoneProfile::Setting>
Determines whether the video is turned or not for incoming or outgoing calls.
Constant | Value | Description |
---|---|---|
QPhoneProfile::AlwaysOff | 0 | The video is always off. |
QPhoneProfile::OnForIncoming | 1 | The video will be turned on for incoming calls. |
QPhoneProfile::OnForOutgoing | 2 | The video will be turned on for outgoing calls. |
QPhoneProfile::AlwaysOn | 3 | The video will be turned on for both incoming and outgoing calls. |
Constructs a null QPhoneProfile.
It is recommended to use QPhoneProfileManager::newProfile() to create a new profile.
Constructs an empty QPhoneProfile with the given id.
It is recommended to use QPhoneProfileManager::newProfile() to create a new profile.
Constructs a copy of other.
Destroys the QPhoneProfile object.
Returns the setting for application for this profile if applicable; otherwise returns a null setting.
See also setApplicationSetting().
Returns all application settings for this profile.
See also setApplicationSettings().
Returns the audio profile on which this profile should auto activate if applicable; otherwise returns an empty string.
See also setAudioProfile() and QAudioStateInfo.
Returns true if incoming calls should be automatically answered in this profile; otherwise returns false.
See also setAutoAnswer().
Returns the AlertType to use for incoming calls.
See also setCallAlert().
Returns the default ring tone to use for incoming calls.
See also setCallTone().
Returns the file name for the icon to use to identify this profile.
See also setIcon().
Returns the identifier for this profile.
See also setId().
Returns true if this profile is null; otherwise returns false. A null profile is one with an id of -1.
Returns true if this is a system profile; otherwise returns false. System profiles can typically not be deleted.
See also setIsSystemProfile().
Returns the default ring tone to use for incoming messages.
See also setMessageTone().
Returns the AlertType to use for incoming messages.
See also setMsgAlert().
Returns the duration in milliseconds to play the message tone.
See also setMsgAlertDuration().
Returns the user visible name of this profile.
See also setName().
Returns true if plane mode is on for this profile; otherwise returns false. Phone calls cannot be made in plane mode.
See also setPlaneMode().
Returns the auto activation schedule for this profile.
See also setSchedule().
Adds a single application setting if it does not exist; otherwise updates the existing setting.
See also applicationSetting().
Sets the application settings.
See also applicationSettings().
Sets the auto activation audioProfile. A phone profile is activated if
QPhoneProfile profile;
QAudioStateConfiguration config;
QAudioStateInfo info = config.currentState();
info.profile() == profile.audioProfile() //must be true
See also audioProfile(), QAudioStateConfiguration, and QAudioStateInfo.
Sets whether auto answering is enabled for this profile to autoAnswer.
See also autoAnswer().
Sets the incoming call alert type.
See also callAlert().
Sets the incoming call tone.
See also callTone() and setVideoTone().
Sets the profile's icon to fileName.
See also icon().
Sets the profile id.
See also id().
Sets whether this profile is a system profile to isSystemProfile.
See also isSystemProfile().
Sets the incoming message tone.
See also messageTone().
Sets the incoming message alert type.
See also msgAlert().
Sets the duration in milliseconds to play the message tone to ms.
See also msgAlertDuration().
Sets the profile name.
See also name().
Sets whether plane mode is enabled for this profile to planeMode. Phone calls cannot be made in plane mode.
See also planeMode().
Sets the profile's auto activation schedule.
See also schedule().
Sets the speed dial input.
See also speedDialInput().
Sets the profile vibration to vibrate.
See also vibrate().
Sets the video option to option.
See also videoOption().
Sets the incoming video ring tone.
See also videoTone() and setCallTone().
Sets the profile volume. Valid values are from 0 to 5.
See also volume().
Returns the speed dial input on which this profile should activate if applicable; otherwise returns an empty string.
See also setSpeedDialInput().
Returns the system ring tone to use for incoming calls. The system ring tone will be used when the user defined tone cannot be found.
Returns the system message tone to use for incoming messages. The system message tone will be used when the user defined tone cannot be found.
Returns true if vibration is enabled; otherwise returns false.
See also setVibrate().
Returns the VideoOption to use for calls.
See also setVideoOption().
Returns the video ring tone to use for incoming calls.
See also setVideoTone().
Returns the volume for this profile.
See also setVolume().
Returns true if this profile is not equal to other; otherwise returns false.
Assigns other to this profile and returns a reference to this profile.
Returns true if this profile is equal to other; otherwise returns false. Equality means all the profile properties are equivalent.
Copyright © 2009 Trolltech | Trademarks | Qt Extended 4.4.3 |