https://git.reactos.org/?p=reactos.git;a=commitdiff;h=9cdd53ffebd1df0e07916…
commit 9cdd53ffebd1df0e079165f62562197ef4ae9d2c
Author: Eric Kohl <eric.kohl(a)reactos.org>
AuthorDate: Sun Apr 25 19:04:11 2021 +0200
Commit: Eric Kohl <eric.kohl(a)reactos.org>
CommitDate: Sun Apr 25 19:04:35 2021 +0200
[MMSYS] Implement ShowAudioPropertySheet() and ShowFullControlPanel()
---
dll/cpl/mmsys/mmsys.c | 81 +++++++++++++++++++++++++++++++++++++++------------
1 file changed, 63 insertions(+), 18 deletions(-)
diff --git a/dll/cpl/mmsys/mmsys.c b/dll/cpl/mmsys/mmsys.c
index b77b390c25d..9662476b686 100644
--- a/dll/cpl/mmsys/mmsys.c
+++ b/dll/cpl/mmsys/mmsys.c
@@ -163,15 +163,6 @@ ShowMMCPLPropertySheet(HWND hwnd,
return TRUE;
}
-VOID WINAPI
-ShowAudioPropertySheet(HWND hwnd,
- HINSTANCE hInstance,
- LPTSTR lpszCmd,
- int nCmdShow)
-{
- DPRINT1("ShowAudioPropertySheet() stubs\n");
-}
-
VOID WINAPI
mmseRunOnceW(HWND hwnd,
HINSTANCE hInstance,
@@ -208,15 +199,6 @@ MediaPropPageProvider(LPVOID Info,
return TRUE;
}
-VOID WINAPI
-ShowFullControlPanel(HWND hwnd,
- HINSTANCE hInstance,
- LPSTR lpszCmd,
- int nCmdShow)
-{
- DPRINT1("ShowFullControlPanel() stubs\n");
-}
-
VOID
InstallSystemSoundLabels(HKEY hKey)
{
@@ -807,6 +789,69 @@ CPlApplet(HWND hwndCpl,
return FALSE;
}
+VOID WINAPI
+ShowAudioPropertySheet(HWND hwnd,
+ HINSTANCE hInstance,
+ LPTSTR lpszCmd,
+ int nCmdShow)
+{
+ PROPSHEETPAGE psp[1];
+ PROPSHEETHEADER psh;
+ TCHAR Caption[256];
+
+ DPRINT("ShowAudioPropertySheet()\n");
+
+ LoadString(hApplet, IDS_CPLNAME, Caption, _countof(Caption));
+
+ psh.dwSize = sizeof(PROPSHEETHEADER);
+ psh.dwFlags = PSH_PROPSHEETPAGE | PSH_PROPTITLE | PSH_USEICONID | PSH_USECALLBACK;
+ psh.hwndParent = hwnd;
+ psh.hInstance = hInstance;
+ psh.pszIcon = MAKEINTRESOURCEW(IDI_CPLICON);
+ psh.pszCaption = Caption;
+ psh.nPages = sizeof(psp) / sizeof(PROPSHEETPAGE);
+ psh.nStartPage = 0;
+ psh.ppsp = psp;
+ psh.pfnCallback = PropSheetProc;
+
+ InitPropSheetPage(&psp[0], IDD_AUDIO,AudioDlgProc);
+
+ PropertySheet(&psh);
+}
+
+VOID WINAPI
+ShowFullControlPanel(HWND hwnd,
+ HINSTANCE hInstance,
+ LPSTR lpszCmd,
+ int nCmdShow)
+{
+ PROPSHEETPAGE psp[5];
+ PROPSHEETHEADER psh;
+ TCHAR Caption[256];
+
+ DPRINT("ShowFullControlPanel()\n");
+
+ LoadString(hApplet, IDS_CPLNAME, Caption, _countof(Caption));
+
+ psh.dwSize = sizeof(PROPSHEETHEADER);
+ psh.dwFlags = PSH_PROPSHEETPAGE | PSH_PROPTITLE | PSH_USEICONID | PSH_USECALLBACK;
+ psh.hwndParent = hwnd;
+ psh.hInstance = hInstance;
+ psh.pszIcon = MAKEINTRESOURCEW(IDI_CPLICON);
+ psh.pszCaption = Caption;
+ psh.nPages = sizeof(psp) / sizeof(PROPSHEETPAGE);
+ psh.nStartPage = 0;
+ psh.ppsp = psp;
+ psh.pfnCallback = PropSheetProc;
+
+ InitPropSheetPage(&psp[0], IDD_VOLUME,VolumeDlgProc);
+ InitPropSheetPage(&psp[1], IDD_SOUNDS,SoundsDlgProc);
+ InitPropSheetPage(&psp[2], IDD_AUDIO,AudioDlgProc);
+ InitPropSheetPage(&psp[3], IDD_VOICE,VoiceDlgProc);
+ InitPropSheetPage(&psp[4], IDD_HARDWARE,HardwareDlgProc);
+
+ PropertySheet(&psh);
+}
BOOL WINAPI
DllMain(HINSTANCE hinstDLL,