1
0

settings.h 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108
  1. #ifndef NULLOSFT_MEDIALIBRARY_MLDISC_SETTINGS_HEADER
  2. #define NULLOSFT_MEDIALIBRARY_MLDISC_SETTINGS_HEADER
  3. #if defined(_MSC_VER) && (_MSC_VER >= 1020)
  4. #pragma once
  5. #endif
  6. #include <windows.h>
  7. #ifdef __cplusplus
  8. extern "C" {
  9. #endif
  10. // Groups
  11. enum
  12. {
  13. C_EXTRACT = 0,
  14. C_COPY,
  15. C_GLOBAL,
  16. C_DATAVIEW,
  17. };
  18. // Extract Group Fields
  19. enum
  20. {
  21. EF_PATH = 0,
  22. EF_TITLEFMT,
  23. EF_PLAYLISTFMT,
  24. EF_UPPEREXTENSION,
  25. EF_ADDMETADATA,
  26. EF_CALCULATERG,
  27. EF_USETOTALTRACKS,
  28. EF_ADDTOMLDB,
  29. EF_TRACKOFFSET,
  30. EF_COMMENTTEXT,
  31. EF_CREATEM3U,
  32. EF_CREATEPLS,
  33. EF_CREATEMLPL,
  34. EF_USEM3UEXT,
  35. EF_FOURCC,
  36. };
  37. // Copy Gorup fields
  38. enum
  39. {
  40. CF_PATH = 0,
  41. CF_USETITLEFMT,
  42. CF_TITLEFMT,
  43. CF_ADDTOMLDB,
  44. CF_CALCULATERG,
  45. CF_GAINMODE,
  46. };
  47. // Global group
  48. enum
  49. {
  50. GF_SHOWINFO = 0,
  51. GF_SHOWPARENT,
  52. GF_ENQUEUEBYDEFAULT,
  53. };
  54. // Data View flags
  55. enum
  56. {
  57. DVF_COLUMNLIST = 0,
  58. DVF_ORDERBY,
  59. DVF_ORDERASC,
  60. DVF_VIEWMODE,
  61. DVF_SHOWAUDIO,
  62. DVF_SHOWVIDEO,
  63. DVF_SHOWPLAYLIST,
  64. DVF_SHOWUNKNOWN,
  65. DVF_HIDEEXTENSION,
  66. DVF_IGNOREHIDDEN,
  67. DVF_LASTFOLDER,
  68. DVF_DIVIDERPOS,
  69. };
  70. HRESULT Settings_ReadValue(INT categoryId, INT fieldId, VOID *pValue, INT cbSize);
  71. HRESULT Settings_GetDefault(INT categoryId, INT fieldId, VOID *pValue);
  72. HRESULT Settings_ReadString(INT categoryId, INT fieldId, LPTSTR pszBuffer, INT cchBufferMax);
  73. HRESULT Settings_GetInt(INT categoryId, INT fieldId, INT *pnVal);
  74. HRESULT Settings_GetBool(INT categoryId, INT fieldId, BOOL *pbVal);
  75. HRESULT Settings_SetWindowText(INT categoryId, INT fieldId, HWND hwnd);
  76. HRESULT Settings_SetWindowInt(INT categoryId, INT fieldId, HWND hwnd);
  77. HRESULT Settings_SetDlgItemText(INT categoryId, INT fieldId, HWND hdlg, INT nItemId);
  78. HRESULT Settings_SetDlgItemInt(INT categoryId, INT fieldId, HWND hdlg, INT nItemId);
  79. HRESULT Settings_SetCheckBox(INT categoryId, INT fieldId, HWND hdlg, INT nItemId);
  80. HRESULT Settings_SetString(INT categoryId, INT fieldId, LPCWSTR pszBuffer);
  81. HRESULT Settings_SetInt(INT categoryId, INT fieldId, INT nValue);
  82. HRESULT Settings_SetBool(INT categoryId, INT fieldId, BOOL bValue);
  83. HRESULT Settings_FromWindowText(INT categoryId, INT fieldId, HWND hwnd);
  84. HRESULT Settings_FromDlgItemText(INT categoryId, INT fieldId, HWND hdlg, INT nItemId);
  85. HRESULT Settings_FromCheckBox(INT categoryId, INT fieldId, HWND hdlg, INT nItemId);
  86. HRESULT Settings_BrowseForFolder(INT categoryId, INT fieldId, HWND hDlg, INT nEditId);
  87. HRESULT Settings_SetDirectoryCtrl(INT categoryId, INT fieldId, HWND hdlg, INT nItemId);
  88. HRESULT Settings_FromDirectoryCtrl(INT categoryId, INT fieldId, HWND hdlg, INT nItemId);
  89. #ifdef __cplusplus
  90. }
  91. #endif
  92. #endif // NULLOSFT_MEDIALIBRARY_MLDISC_SETTINGS_HEADER