Skip to content

Commit

Permalink
REFAC(client): Refactor the code repeated in the main.cpp
Browse files Browse the repository at this point in the history
This commit refactors the code repeated in the main.cpp file.
Three connect functions were called with same parameters.

Co-Authored-by: Abdullah Ömer Yamaç [email protected]
  • Loading branch information
mryamac committed Feb 3, 2024
1 parent c4b5858 commit 298da31
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions src/mumble/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -693,13 +693,6 @@ int main(int argc, char **argv) {
// window's frame to be included in the positioning calculation on X11 (at least using KDE Plasma)
Global::get().talkingUI->setVisible(Global::get().s.bShowTalkingUI);

QObject::connect(Global::get().mw, &MainWindow::userAddedChannelListener, Global::get().talkingUI,
&TalkingUI::on_channelListenerAdded);
QObject::connect(Global::get().mw, &MainWindow::userRemovedChannelListener, Global::get().talkingUI,
&TalkingUI::on_channelListenerRemoved);
QObject::connect(Global::get().channelListenerManager.get(), &ChannelListenerManager::localVolumeAdjustmentsChanged,
Global::get().talkingUI, &TalkingUI::on_channelListenerLocalVolumeAdjustmentChanged);

QObject::connect(Global::get().mw, &MainWindow::userAddedChannelListener, Global::get().talkingUI,
&TalkingUI::on_channelListenerAdded);
QObject::connect(Global::get().mw, &MainWindow::userRemovedChannelListener, Global::get().talkingUI,
Expand Down

0 comments on commit 298da31

Please sign in to comment.