Rename parameters shadowing class members
Parameters with the same name as class members are ripe for introducing bugs. The fact that the "this->" syntax is optional creates confusion for maintaining programmers who can only guess at the intention.
This commit is contained in:
@@ -19,9 +19,9 @@ void AccessibilityTabController::initStage1() {
|
||||
reloadPttConfig();
|
||||
}
|
||||
|
||||
void AccessibilityTabController::initStage2(OverlayController * parent, QQuickWindow * widget) {
|
||||
this->parent = parent;
|
||||
this->widget = widget;
|
||||
void AccessibilityTabController::initStage2(OverlayController * var_parent, QQuickWindow * var_widget) {
|
||||
this->parent = var_parent;
|
||||
this->widget = var_widget;
|
||||
}
|
||||
|
||||
void AccessibilityTabController::setTrackingUniverse(int value) {
|
||||
|
||||
@@ -44,9 +44,9 @@ namespace advsettings {
|
||||
}
|
||||
|
||||
|
||||
void AudioTabController::initStage2(OverlayController * parent, QQuickWindow * widget) {
|
||||
this->parent = parent;
|
||||
this->widget = widget;
|
||||
void AudioTabController::initStage2(OverlayController * var_parent, QQuickWindow * var_widget) {
|
||||
this->parent = var_parent;
|
||||
this->widget = var_widget;
|
||||
|
||||
std::string notifKey = std::string(OverlayController::applicationKey) + ".pptnotification";
|
||||
vr::VROverlayError overlayError = vr::VROverlay()->CreateOverlay(notifKey.c_str(), notifKey.c_str(), &m_ulNotificationOverlayHandle);
|
||||
|
||||
@@ -32,9 +32,9 @@ void ChaperoneTabController::initStage1() {
|
||||
}
|
||||
|
||||
|
||||
void ChaperoneTabController::initStage2(OverlayController * parent, QQuickWindow * widget) {
|
||||
this->parent = parent;
|
||||
this->widget = widget;
|
||||
void ChaperoneTabController::initStage2(OverlayController * var_parent, QQuickWindow * var_widget) {
|
||||
this->parent = var_parent;
|
||||
this->widget = var_widget;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -9,9 +9,9 @@ namespace advsettings {
|
||||
void FixFloorTabController::initStage1() {
|
||||
}
|
||||
|
||||
void FixFloorTabController::initStage2(OverlayController * parent, QQuickWindow * widget) {
|
||||
this->parent = parent;
|
||||
this->widget = widget;
|
||||
void FixFloorTabController::initStage2(OverlayController * var_parent, QQuickWindow * var_widget) {
|
||||
this->parent = var_parent;
|
||||
this->widget = var_widget;
|
||||
}
|
||||
|
||||
void FixFloorTabController::eventLoopTick(vr::TrackedDevicePose_t* devicePoses) {
|
||||
|
||||
@@ -57,9 +57,9 @@ void MoveCenterTabController::initStage1() {
|
||||
lastMoveButtonClick[0] = lastMoveButtonClick[1] = clock::now();
|
||||
}
|
||||
|
||||
void MoveCenterTabController::initStage2(OverlayController * parent, QQuickWindow * widget) {
|
||||
this->parent = parent;
|
||||
this->widget = widget;
|
||||
void MoveCenterTabController::initStage2(OverlayController * var_parent, QQuickWindow * var_widget) {
|
||||
this->parent = var_parent;
|
||||
this->widget = var_widget;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -167,9 +167,9 @@ namespace advsettings {
|
||||
}
|
||||
}
|
||||
|
||||
void ReviveTabController::initStage2(OverlayController * parent, QQuickWindow * widget) {
|
||||
this->parent = parent;
|
||||
this->widget = widget;
|
||||
void ReviveTabController::initStage2(OverlayController * var_parent, QQuickWindow * var_widget) {
|
||||
this->parent = var_parent;
|
||||
this->widget = var_widget;
|
||||
}
|
||||
|
||||
void ReviveTabController::eventLoopTick() {
|
||||
|
||||
@@ -17,9 +17,9 @@ void SettingsTabController::initStage1() {
|
||||
}
|
||||
}
|
||||
|
||||
void SettingsTabController::initStage2(OverlayController * parent, QQuickWindow * widget) {
|
||||
this->parent = parent;
|
||||
this->widget = widget;
|
||||
void SettingsTabController::initStage2(OverlayController * var_parent, QQuickWindow * var_widget) {
|
||||
this->parent = var_parent;
|
||||
this->widget = var_widget;
|
||||
}
|
||||
|
||||
void SettingsTabController::eventLoopTick() {
|
||||
|
||||
@@ -8,9 +8,9 @@ namespace advsettings {
|
||||
void StatisticsTabController::initStage1() {
|
||||
}
|
||||
|
||||
void StatisticsTabController::initStage2(OverlayController * parent, QQuickWindow * widget) {
|
||||
this->parent = parent;
|
||||
this->widget = widget;
|
||||
void StatisticsTabController::initStage2(OverlayController * var_parent, QQuickWindow * var_widget) {
|
||||
this->parent = var_parent;
|
||||
this->widget = var_widget;
|
||||
}
|
||||
|
||||
void StatisticsTabController::eventLoopTick(vr::TrackedDevicePose_t* devicePoses, float leftSpeed, float rightSpeed) {
|
||||
|
||||
@@ -24,9 +24,9 @@ void SteamVRTabController::initStage1() {
|
||||
}
|
||||
|
||||
|
||||
void SteamVRTabController::initStage2(OverlayController * parent, QQuickWindow * widget) {
|
||||
this->parent = parent;
|
||||
this->widget = widget;
|
||||
void SteamVRTabController::initStage2(OverlayController * var_parent, QQuickWindow * var_widget) {
|
||||
this->parent = var_parent;
|
||||
this->widget = var_widget;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -48,9 +48,9 @@ namespace advsettings {
|
||||
|
||||
}
|
||||
|
||||
void UtilitiesTabController::initStage2(OverlayController * parent, QQuickWindow * widget) {
|
||||
this->parent = parent;
|
||||
this->widget = widget;
|
||||
void UtilitiesTabController::initStage2(OverlayController * var_parent, QQuickWindow * var_widget) {
|
||||
this->parent = var_parent;
|
||||
this->widget = var_widget;
|
||||
}
|
||||
|
||||
void UtilitiesTabController::sendKeyboardInput(QString input) {
|
||||
|
||||
@@ -31,7 +31,7 @@ AudioManagerWindows::~AudioManagerWindows() {
|
||||
audioDeviceEnumerator->Release();
|
||||
}
|
||||
|
||||
void AudioManagerWindows::init(AudioTabController* controller) {
|
||||
void AudioManagerWindows::init(AudioTabController* var_controller) {
|
||||
std::lock_guard<std::recursive_mutex> lock(_mutex);
|
||||
audioDeviceEnumerator = getAudioDeviceEnumerator();
|
||||
if (!audioDeviceEnumerator) {
|
||||
@@ -47,7 +47,7 @@ void AudioManagerWindows::init(AudioTabController* controller) {
|
||||
} else {
|
||||
LOG(WARNING) << "Could not find a default recording device.";
|
||||
}
|
||||
this->controller = controller;
|
||||
this->controller = var_controller;
|
||||
audioDeviceEnumerator->RegisterEndpointNotificationCallback((IMMNotificationClient*)this);
|
||||
policyConfig = getPolicyConfig();
|
||||
if (!policyConfig) {
|
||||
|
||||
Reference in New Issue
Block a user