mirror of
https://github.com/WinampDesktop/winamp.git
synced 2025-06-17 14:35:46 -04:00
Initial community commit
This commit is contained in:
45
Src/Plugins/General/gen_ml/skinneddlg.cpp
Normal file
45
Src/Plugins/General/gen_ml/skinneddlg.cpp
Normal file
@ -0,0 +1,45 @@
|
||||
#include "../winamp/wa_dlg.h"
|
||||
#include "./skinneddlg.h"
|
||||
|
||||
|
||||
SkinnedDialog::SkinnedDialog(void) : SkinnedWnd(TRUE)
|
||||
{
|
||||
}
|
||||
|
||||
SkinnedDialog::~SkinnedDialog(void)
|
||||
{
|
||||
}
|
||||
|
||||
BOOL SkinnedDialog::Attach(HWND hwndDialog)
|
||||
{
|
||||
if(!__super::Attach(hwndDialog)) return FALSE;
|
||||
SetType(SKINNEDWND_TYPE_DIALOG);
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
HBRUSH SkinnedDialog::OnColorDialog(HDC hdc)
|
||||
{
|
||||
if (hdc)
|
||||
{
|
||||
SetTextColor(hdc, WADlg_getColor(WADLG_WNDFG));
|
||||
SetBkColor(hdc, WADlg_getColor(WADLG_WNDBG));
|
||||
}
|
||||
return (HBRUSH)MlStockObjects_Get(WNDBCK_BRUSH);
|
||||
}
|
||||
|
||||
|
||||
LRESULT SkinnedDialog::WindowProc(UINT uMsg, WPARAM wParam, LPARAM lParam)
|
||||
{
|
||||
switch(uMsg)
|
||||
{
|
||||
case WM_NCPAINT:
|
||||
case WM_NCCALCSIZE:
|
||||
__super::WindowProc(uMsg, wParam, lParam);
|
||||
return TRUE;
|
||||
|
||||
case WM_CTLCOLORDLG:
|
||||
if (SWS_USESKINCOLORS & style) return (LRESULT)OnColorDialog((HDC)wParam);
|
||||
break;
|
||||
}
|
||||
return __super::WindowProc(uMsg, wParam, lParam);
|
||||
}
|
Reference in New Issue
Block a user