Skip to content

Commit 0007422

Browse files
committed
Tidy - Fix indentation and log messages
1 parent 9c2bae1 commit 0007422

File tree

2 files changed

+19
-13
lines changed

2 files changed

+19
-13
lines changed

app/gui/qt/mainwindow.cpp

Lines changed: 17 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1776,7 +1776,7 @@ void MainWindow::changeGUITransparency(int val)
17761776

17771777
void MainWindow::changeSystemPreAmp(int val, int silent)
17781778
{
1779-
std::cout << "[GUI] Change Volume to " << val << std::endl;
1779+
std::cout << "[GUI] - Change Volume to " << val << std::endl;
17801780
float v = (float)val;
17811781
v = (v / 100.0) * 2.0;
17821782
Message msg("/mixer-amp");
@@ -3311,25 +3311,29 @@ SonicPiScintilla* MainWindow::filenameToWorkspace(std::string filename)
33113311

33123312
void MainWindow::onExitCleanup()
33133313
{
3314-
if (scopeWindow)
3314+
std::cout << "[GUI] - initiating Shutdown..." << std::endl;
3315+
3316+
if (scopeWindow)
33153317
{
3318+
std::cout << "[GUI] - shutting down scope..." << std::endl;
33163319
scopeWindow->ShutDown();
33173320
}
33183321

3319-
if (m_spClient)
3322+
if (m_spClient)
33203323
{
3321-
if (loaded_workspaces)
3324+
if (loaded_workspaces)
33223325
{
33233326
// this should be a synchorous call to avoid the following sleep
33243327
saveWorkspaces();
33253328
}
3326-
std::this_thread::sleep_for(1s);
33273329

3328-
// Do this before closing the client, so the io redirect happens after
3329-
std::cout << "[GUI] - exiting. Cheerio :-)" << std::endl;
3330+
std::this_thread::sleep_for(1s);
3331+
3332+
// Do this before closing the client, so the io redirect happens after
3333+
std::cout << "[GUI] - exiting. Cheerio :-)" << std::endl;
33303334

3331-
// Shuts down the client/server connection
3332-
m_spAPI->Shutdown();
3335+
// Shuts down the client/server connection
3336+
m_spAPI->Shutdown();
33333337
}
33343338
}
33353339

@@ -3340,17 +3344,18 @@ void MainWindow::restartApp() {
33403344
// Save settings and perform some cleanup
33413345
writeSettings();
33423346
onExitCleanup();
3343-
std::cout << "Performing application restart..." << std::endl;
3347+
3348+
std::cout << "[GUI] - performing application restart..." << std::endl;
33443349

33453350
// Create new process
33463351
QStringList args = qApp->arguments();
33473352
args.removeFirst();
33483353
QProcess process;
33493354
bool restart_success = process.startDetached(qApp->arguments()[0], args);
33503355
if (restart_success) {
3351-
std::cout << "Successfully restarted sonic-pi" << std::endl;
3356+
std::cout << "[GUI] - successfully restarted sonic-pi" << std::endl;
33523357
} else {
3353-
std::cout << "Failed to restart sonic-pi" << std::endl;
3358+
std::cout << "[GUI] - failed to restart sonic-pi" << std::endl;
33543359
}
33553360

33563361
// Quit

app/gui/qt/widgets/settingswidget.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -763,7 +763,8 @@ void SettingsWidget::updateVersionInfo( QString info_string, QString visit, bool
763763
}
764764

765765
void SettingsWidget::updateSettings() {
766-
std::cout << "[GUI] - Update Settings" << std::endl;
766+
767+
std::cout << "[GUI] - update settings" << std::endl;
767768
piSettings->language = available_languages[language_combo->currentIndex()];
768769
piSettings->mixer_invert_stereo = mixer_invert_stereo->isChecked();
769770
piSettings->mixer_force_mono = mixer_force_mono->isChecked();

0 commit comments

Comments
 (0)