1
0

wintheme.h 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. #ifndef NULLOSFT_WINAMP_WINTHEME_HEADER
  2. #define NULLOSFT_WINAMP_WINTHEME_HEADER
  3. #if defined(_MSC_VER) && (_MSC_VER >= 1020)
  4. #pragma once
  5. #endif
  6. #include <wtypes.h>
  7. #define E_LIBRARY_NOTLOADED MAKE_HRESULT(0, FACILITY_ITF, 0x0201) // library not loaded (you just need to call MlDwm_LoadLibrary)
  8. #define E_LIBRARY_LOADFAILED MAKE_HRESULT(1, FACILITY_ITF, 0x0202) // library load failed (probably not vista?)
  9. #define E_LIBRARY_BADFUNCTION MAKE_HRESULT(1, FACILITY_ITF, 0x0203) // function was not loaded
  10. // XP UxTheme
  11. HRESULT UxTheme_LoadLibrary(void);
  12. HRESULT UxTheme_GetLoadResult(void);
  13. HRESULT SetWindowTheme(HWND hwnd, LPCWSTR pszSubAppName, LPCWSTR pszSubIdList);
  14. BOOL IsAppThemed(void);
  15. // Vista DWM
  16. HRESULT Dwm_LoadLibrary(void);
  17. HRESULT Dwm_GetLoadResult(void);
  18. #ifndef WM_DWMCOMPOSITIONCHANGED
  19. #define WM_DWMCOMPOSITIONCHANGED 0x031E
  20. #define WM_DWMNCRENDERINGCHANGED 0x031F
  21. #define WM_DWMCOLORIZATIONCOLORCHANGED 0x0320
  22. #define WM_DWMWINDOWMAXIMIZEDCHANGE 0x0321
  23. #endif // !WM_DWMCOMPOSITIONCHANGED
  24. typedef enum _DWMWINDOWATTRIBUTE {
  25. DWMWA_NCRENDERING_ENABLED = 1,
  26. DWMWA_NCRENDERING_POLICY,
  27. DWMWA_TRANSITIONS_FORCEDISABLED,
  28. DWMWA_ALLOW_NCPAINT,
  29. DWMWA_CAPTION_BUTTON_BOUNDS,
  30. DWMWA_NONCLIENT_RTL_LAYOUT,
  31. DWMWA_FORCE_ICONIC_REPRESENTATION,
  32. DWMWA_FLIP3D_POLICY,
  33. DWMWA_EXTENDED_FRAME_BOUNDS,
  34. DWMWA_HAS_ICONIC_BITMAP, // [set] Indicates an available bitmap when there is no better thumbnail representation.
  35. DWMWA_DISALLOW_PEEK, // [set] Don't invoke Peek on the window.
  36. DWMWA_EXCLUDED_FROM_PEEK,
  37. DWMWA_LAST
  38. } DWMWINDOWATTRIBUTE;
  39. typedef enum _DWMNCRENDERINGPOLICY {
  40. DWMNCRP_USEWINDOWSTYLE,
  41. DWMNCRP_DISABLED,
  42. DWMNCRP_ENABLED,
  43. DWMNCRP_LAST
  44. } DWMNCRENDERINGPOLICY;
  45. HRESULT DwmSetWindowAttribute(HWND hwnd, DWORD dwAttribute, LPCVOID pvAttribute, DWORD cbAttribute);
  46. HRESULT DwmIsCompositionEnabled(BOOL *pfEnabled);
  47. #endif //NULLOSFT_WINAMP_WINTHEME_HEADER