Commit b012ea1a authored by Sanjiban Bairagya's avatar Sanjiban Bairagya Committed by Sanjiban Bairagya

Assume speaker to be always enabled, during turn-by-turn navigation

parent 97787dff
......@@ -93,27 +93,13 @@ Item {
Navigation {
id: navigation
marbleQuickItem: marbleItem
soundEnabled: false
onVoiceNavigationAnnouncementChanged: {
if (!parent.visible) {
return "";
}
switch (voiceNavigationAnnouncement) {
case "ListEnd":
audioPlayer.source = "assets:/data/audio/KDE-Sys-List-End.ogg";
audioPlayer.stop();
audioPlayer.play();
break;
case "AppPositive":
audioPlayer.source = "assets:/data/audio/KDE-Sys-App-Positive.ogg";
audioPlayer.stop();
audioPlayer.play();
break;
default:
textToSpeechClient.readText(voiceNavigationAnnouncement);
}
textToSpeechClient.readText(voiceNavigationAnnouncement);
}
}
}
......@@ -214,16 +214,6 @@ void Navigation::setSpeaker( const QString &speaker )
d->m_voiceNavigation.setSpeaker( speaker );
}
bool Navigation::soundEnabled() const
{
return !d->m_voiceNavigation.isSpeakerEnabled();
}
void Navigation::setSoundEnabled( bool soundEnabled )
{
d->m_voiceNavigation.setSpeakerEnabled( !soundEnabled );
}
bool Navigation::deviated() const
{
if ( d->m_marbleQuickItem ) {
......
......@@ -28,7 +28,6 @@ class Navigation : public QObject
Q_PROPERTY(Marble::MarbleQuickItem * marbleQuickItem READ marbleQuickItem WRITE setMarbleQuickItem NOTIFY marbleQuickItemChanged)
Q_PROPERTY(bool guidanceModeEnabled READ guidanceModeEnabled WRITE setGuidanceModeEnabled NOTIFY guidanceModeEnabledChanged)
Q_PROPERTY(bool muted READ muted WRITE setMuted NOTIFY mutedChanged)
Q_PROPERTY(bool soundEnabled READ soundEnabled WRITE setSoundEnabled NOTIFY soundEnabledChanged)
Q_PROPERTY(QString speaker READ speaker WRITE setSpeaker NOTIFY speakerChanged)
Q_PROPERTY(QString nextInstructionText READ nextInstructionText NOTIFY nextInstructionTextChanged)
Q_PROPERTY(QString nextRoad READ nextRoad NOTIFY nextRoadChanged)
......@@ -69,10 +68,6 @@ public:
void setSpeaker( const QString &speaker );
bool soundEnabled() const;
void setSoundEnabled( bool soundEnabled );
bool deviated() const;
Marble::MarbleQuickItem * marbleQuickItem() const;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment