Run clang-formats for merge

This commit is contained in:
RichardG867
2022-10-15 13:38:10 -03:00
parent ac68e1f562
commit e706fffb34
34 changed files with 10714 additions and 11082 deletions

View File

@@ -31,9 +31,7 @@
#include <86box/sound.h>
#include <86box/win.h>
static uint8_t old_gain;
static uint8_t old_gain;
#if defined(__amd64__) || defined(__aarch64__)
static LRESULT CALLBACK
@@ -45,48 +43,47 @@ SoundGainDialogProcedure(HWND hdlg, UINT message, WPARAM wParam, LPARAM lParam)
HWND h;
switch (message) {
case WM_INITDIALOG:
old_gain = sound_gain;
h = GetDlgItem(hdlg, IDC_SLIDER_GAIN);
SendMessage(h, TBM_SETRANGE, (WPARAM)1, (LPARAM)MAKELONG(0, 9));
SendMessage(h, TBM_SETPOS, (WPARAM)1, 9 - (sound_gain >> 1));
SendMessage(h, TBM_SETTICFREQ, (WPARAM)1, 0);
SendMessage(h, TBM_SETLINESIZE, (WPARAM)0, 1);
SendMessage(h, TBM_SETPAGESIZE, (WPARAM)0, 2);
break;
case WM_INITDIALOG:
old_gain = sound_gain;
h = GetDlgItem(hdlg, IDC_SLIDER_GAIN);
SendMessage(h, TBM_SETRANGE, (WPARAM) 1, (LPARAM) MAKELONG(0, 9));
SendMessage(h, TBM_SETPOS, (WPARAM) 1, 9 - (sound_gain >> 1));
SendMessage(h, TBM_SETTICFREQ, (WPARAM) 1, 0);
SendMessage(h, TBM_SETLINESIZE, (WPARAM) 0, 1);
SendMessage(h, TBM_SETPAGESIZE, (WPARAM) 0, 2);
break;
case WM_VSCROLL:
h = GetDlgItem(hdlg, IDC_SLIDER_GAIN);
sound_gain = (9 - SendMessage(h, TBM_GETPOS, (WPARAM)0, 0)) << 1;
break;
case WM_VSCROLL:
h = GetDlgItem(hdlg, IDC_SLIDER_GAIN);
sound_gain = (9 - SendMessage(h, TBM_GETPOS, (WPARAM) 0, 0)) << 1;
break;
case WM_COMMAND:
switch (LOWORD(wParam)) {
case IDOK:
h = GetDlgItem(hdlg, IDC_SLIDER_GAIN);
sound_gain = (9 - SendMessage(h, TBM_GETPOS, (WPARAM)0, 0)) << 1;
config_save();
EndDialog(hdlg, 0);
return TRUE;
case WM_COMMAND:
switch (LOWORD(wParam)) {
case IDOK:
h = GetDlgItem(hdlg, IDC_SLIDER_GAIN);
sound_gain = (9 - SendMessage(h, TBM_GETPOS, (WPARAM) 0, 0)) << 1;
config_save();
EndDialog(hdlg, 0);
return TRUE;
case IDCANCEL:
sound_gain = old_gain;
config_save();
EndDialog(hdlg, 0);
return TRUE;
case IDCANCEL:
sound_gain = old_gain;
config_save();
EndDialog(hdlg, 0);
return TRUE;
default:
break;
}
break;
default:
break;
}
break;
}
return(FALSE);
return (FALSE);
}
void
SoundGainDialogCreate(HWND hwnd)
{
DialogBox(hinstance, (LPCTSTR)DLG_SND_GAIN, hwnd, SoundGainDialogProcedure);
DialogBox(hinstance, (LPCTSTR) DLG_SND_GAIN, hwnd, SoundGainDialogProcedure);
}