fixed minor code formatting errors

This commit is contained in:
ykeara
2019-01-04 13:34:52 -06:00
parent b883d2cffd
commit 15855c4564
3 changed files with 8 additions and 21 deletions
-10
View File
@@ -430,8 +430,6 @@ MyStackViewPage {
onClicked: {
if (audioProfileComboBox.currentIndex > 0) {
AudioTabController.applyAudioProfile(audioProfileComboBox.currentIndex - 1)
//TODO ?
//audioProfileComboBox.currentIndex = 0
}
}
}
@@ -464,7 +462,6 @@ MyStackViewPage {
onClicked: {
if (pttProfileComboBox.currentIndex > 0) {
AudioTabController.applyPttProfile(pttProfileComboBox.currentIndex - 1)
//pttProfileComboBox.currentIndex = 0
}
}
}
@@ -576,8 +573,6 @@ MyStackViewPage {
audioPttShowNotificationToggle.checked = AudioTabController.pttShowNotification
audioPttReverseToggle.checked = AudioTabController.micReversePtt
audioDefaultProfileToggle.checked = AudioTabController.audioProfileDefault
//audioProfileComboBox.currentIndex = AudioTabController.audioProfileDefaultIndex + 1
//AudioTabController.applyDefaultProfile()
componentCompleted = true
}
@@ -660,16 +655,11 @@ MyStackViewPage {
}
onAudioProfileAdded:{
audioProfileComboBox.currentIndex = AudioTabController.getAudioProfileCount()
//audioProfileComboBox.currentIndex = AudioTabController.audioProfileDefaultIndex+1
}
onPttProfileAdded:{
pttProfileComboBox.currentIndex = AudioTabController.getPttProfileCount()
}
//onAudioProfileDefaultIndexChanged: {
// audioProfileComboBox.currentIndex = AudioTabController.audioProfileDefaultIndex()
//}
onPlaybackDeviceListChanged: {
var devs1 = []
+7 -8
View File
@@ -57,11 +57,11 @@ void AudioTabController::initStage1()
eventLoopTick();
}
void AudioTabController::initStage2( OverlayController* parent1,
QQuickWindow* widget1 )
void AudioTabController::initStage2( OverlayController* var_parent,
QQuickWindow* var_widget )
{
this->parent = parent1;
this->widget = widget1;
this->parent = var_parent;
this->widget = var_widget;
std::string notifKey
= std::string( OverlayController::applicationKey ) + ".pptnotification";
@@ -783,7 +783,7 @@ void AudioTabController::saveAudioProfiles()
auto settings = OverlayController::appSettings();
settings->beginGroup( getSettingsName() );
settings->beginWriteArray( "audioProfiles" );
unsigned i = 0;
int i = 0;
for ( auto& p : audioProfiles )
{
settings->setArrayIndex( i );
@@ -886,7 +886,7 @@ void AudioTabController::applyAudioProfile( unsigned index )
int pInd = getPlaybackIndex( profile.playbackName );
// Needed to keep remembering when swtiching from mirror/main etc.
// TODO can possibly clean up logic to reduce overhead in future.
// TODO OPTI can possibly clean up logic to reduce overhead in future.
setMicMuted( false, false );
setMirrorMuted( false, false );
@@ -1047,7 +1047,6 @@ void AudioTabController::applyDefaultProfile()
}
/* ---------------------------*/
/*----------------*/
/*----------------------------*/
} // namespace advsettings
+1 -3
View File
@@ -69,7 +69,6 @@ private:
bool m_micProximitySensorCanMute = false;
bool m_micReversePtt = false;
bool m_isDefaultAudioProfile = false;
// int m_defaultAudioProfileIndex = 2;
std::string m_defaultProfileName;
unsigned settingsUpdateCounter = 0;
@@ -107,7 +106,7 @@ private:
public:
void initStage1();
void initStage2( OverlayController* parent1, QQuickWindow* widget1 );
void initStage2( OverlayController* var_parent, QQuickWindow* var_widget );
void reloadAudioSettings();
void saveAudioSettings();
@@ -126,7 +125,6 @@ public:
bool micProximitySensorCanMute() const;
bool micReversePtt() const;
bool audioProfileDefault() const;
// int audioProfileDefaultIndex() const;
void reloadAudioProfiles();
void saveAudioProfiles();