1
0

config.h 8.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188
  1. #ifndef _CONFIG_H_
  2. #define _CONFIG_H_
  3. #ifdef CONFIG_IMPL
  4. #define CONFIG_EXT
  5. #define DEF_VAL(x) =( x )
  6. #else
  7. #define CONFIG_EXT extern
  8. #define DEF_VAL(x)
  9. #endif // CONFIG_IMPL
  10. /* --- This lets us change the registry strings at compile-time, for special builds --- */
  11. #ifndef WINAMP_FILE
  12. #define REGISTRY_PREFIX "Winamp"
  13. #endif
  14. #define WIDEN2(x) L ## x
  15. #define WIDEN(x) WIDEN2(x)
  16. #define WINAMP_FILE REGISTRY_PREFIX ".File"
  17. #define WINAMP_FILEW WIDEN(REGISTRY_PREFIX) L".File"
  18. #define WINAMP_PLAYLIST REGISTRY_PREFIX ".PlayList"
  19. #define WINAMP_PLAYLISTW WIDEN(REGISTRY_PREFIX) L".PlayList"
  20. #define WINAMP_SKINZIP REGISTRY_PREFIX ".SkinZip"
  21. #define WINAMP_SKINZIPW WIDEN(REGISTRY_PREFIX) L".SkinZip"
  22. #define WINAMP_LANGZIP REGISTRY_PREFIX ".LangZip"
  23. #define WINAMP_LANGZIPW WIDEN(REGISTRY_PREFIX) L".LangZip"
  24. #define WINAMP_PLAY REGISTRY_PREFIX ".Play"
  25. #define WINAMP_PLAYW WIDEN(REGISTRY_PREFIX) L".Play"
  26. #define WINAMP_ENQUEUE REGISTRY_PREFIX ".Enqueue"
  27. #define WINAMP_ENQUEUEW WIDEN(REGISTRY_PREFIX) L".Enqueue"
  28. #define WINAMP_BOOKMARK REGISTRY_PREFIX ".Bookmark"
  29. #define WINAMP_BOOKMARKW WIDEN(REGISTRY_PREFIX) L".Bookmark"
  30. /* -------------------------------------------------------------------------------- --- */
  31. extern void _r_s(char *name,char *data, int mlen);
  32. extern void _w_s(char *name, char *data);
  33. void _w_sW(const char *name, const wchar_t *data);
  34. void _r_sW(const char *name, wchar_t *data, int mlen);
  35. extern int _r_i(char *name, int def);
  36. extern void _w_i(char *name, intptr_t d);
  37. CONFIG_EXT int config_utf8 DEF_VAL(1);
  38. CONFIG_EXT wchar_t M3UDIR[MAX_PATH] DEF_VAL(L"");
  39. CONFIG_EXT wchar_t M3UBASE[MAX_PATH] DEF_VAL(L"");
  40. CONFIG_EXT wchar_t CONFIGDIR[MAX_PATH] DEF_VAL(L"");
  41. CONFIG_EXT wchar_t SHAREDDIR[MAX_PATH] DEF_VAL(L"");
  42. CONFIG_EXT wchar_t PROGDIR[MAX_PATH] DEF_VAL(L"");
  43. CONFIG_EXT wchar_t ML_INI_FILE[MAX_PATH] DEF_VAL(L"");
  44. CONFIG_EXT wchar_t INI_FILE[MAX_PATH] DEF_VAL(L"");
  45. CONFIG_EXT char INI_FILEA[MAX_PATH] DEF_VAL("");
  46. CONFIG_EXT wchar_t M3U_FILE[MAX_PATH] DEF_VAL(L"");
  47. CONFIG_EXT wchar_t OLD_M3U_FILE[MAX_PATH] DEF_VAL(L"");
  48. CONFIG_EXT wchar_t EQDIR1[MAX_PATH] DEF_VAL(L"");
  49. CONFIG_EXT wchar_t EQDIR2[MAX_PATH] DEF_VAL(L"");
  50. CONFIG_EXT wchar_t TEMP_FILE[MAX_PATH] DEF_VAL(L"");
  51. CONFIG_EXT wchar_t PLUGINDIR[MAX_PATH] DEF_VAL(L"");
  52. CONFIG_EXT wchar_t SYSPLUGINDIR[MAX_PATH] DEF_VAL(L"");
  53. CONFIG_EXT wchar_t VISDIR[MAX_PATH] DEF_VAL(L"");
  54. CONFIG_EXT wchar_t DSPDIR[MAX_PATH] DEF_VAL(L"");
  55. CONFIG_EXT wchar_t SKINDIR[MAX_PATH] DEF_VAL(L"");
  56. CONFIG_EXT wchar_t DEMOMP3[MAX_PATH] DEF_VAL(L"");
  57. CONFIG_EXT wchar_t SKINTEMPDIR[MAX_PATH] DEF_VAL(L"");
  58. CONFIG_EXT wchar_t LANGTEMPDIR[MAX_PATH] DEF_VAL(L"");
  59. CONFIG_EXT wchar_t BOOKMARKFILE[MAX_PATH] DEF_VAL(L"");
  60. CONFIG_EXT wchar_t BOOKMARKFILE8[MAX_PATH] DEF_VAL(L"");
  61. CONFIG_EXT wchar_t LANGDIR[MAX_PATH] DEF_VAL(L"");
  62. CONFIG_EXT wchar_t JSAPI2_INIFILE[MAX_PATH] DEF_VAL(L"");
  63. #define PE_FONTSIZE 12
  64. CONFIG_EXT int config_pe_fontsize DEF_VAL(PE_FONTSIZE);
  65. #define PE_DIRECTION_AUTO 0
  66. #define PE_DIRECTION_LTR 1
  67. #define PE_DIRECTION_RTL 2
  68. CONFIG_EXT int config_pe_direction DEF_VAL(PE_DIRECTION_LTR);
  69. CONFIG_EXT wchar_t config_langpack[MAX_PATH] DEF_VAL(L""), config_langpack2[MAX_PATH] DEF_VAL(L""), lang_directory[MAX_PATH] DEF_VAL(L"");
  70. CONFIG_EXT unsigned char config_wlz_menu DEF_VAL(0);
  71. CONFIG_EXT int config_skin_prompt DEF_VAL(1);
  72. CONFIG_EXT int config_wlz_prompt DEF_VAL(1);
  73. CONFIG_EXT char config_proxy[256], config_inet_mode DEF_VAL(0);
  74. CONFIG_EXT char config_defext[32] DEF_VAL("mp3");
  75. CONFIG_EXT wchar_t config_titlefmt[1024] DEF_VAL(L"[%artist% - ]$if2(%title%,$filepart(%filename%))");
  76. CONFIG_EXT int config_useexttitles DEF_VAL(1);
  77. CONFIG_EXT wchar_t config_visplugin_name[MAX_PATH] DEF_VAL(L"");
  78. CONFIG_EXT char config_visplugin_num, config_visplugin_priority DEF_VAL(2), config_visplugin_autoexec;
  79. CONFIG_EXT unsigned char config_shuffle_morph_rate DEF_VAL(50);
  80. CONFIG_EXT unsigned char config_playlist_recyclebin DEF_VAL(1);
  81. CONFIG_EXT unsigned char config_ospb DEF_VAL(0), config_eqdsize DEF_VAL(1);
  82. CONFIG_EXT char config_outname[128] DEF_VAL("out_ds.dll");
  83. CONFIG_EXT wchar_t config_dspplugin_name[MAX_PATH] DEF_VAL(L"");
  84. CONFIG_EXT unsigned char config_dspplugin_num;
  85. CONFIG_EXT unsigned char config_sticon,config_usecursors DEF_VAL(1);
  86. CONFIG_EXT unsigned char config_splash DEF_VAL(0) ,config_minst;
  87. CONFIG_EXT unsigned char config_taskbar,config_fixtitles DEF_VAL(3);
  88. CONFIG_EXT unsigned char config_ascb_new DEF_VAL(1),config_ttips DEF_VAL(1), config_priority DEF_VAL(1);
  89. CONFIG_EXT unsigned char config_riol DEF_VAL(4);
  90. CONFIG_EXT unsigned char config_whichicon DEF_VAL(1),config_whichicon2 DEF_VAL(1),config_addtolist;
  91. CONFIG_EXT unsigned char config_snap DEF_VAL(1), config_snaplen DEF_VAL(10), config_parent DEF_VAL(1);
  92. CONFIG_EXT unsigned char config_hilite DEF_VAL(1);
  93. CONFIG_EXT unsigned char config_disvis DEF_VAL(1), config_pladv DEF_VAL(1);
  94. CONFIG_EXT unsigned char config_shownumsinpl DEF_VAL(1),config_zeropadplnum DEF_VAL(0),config_keeponscreen DEF_VAL(1);
  95. CONFIG_EXT unsigned char config_dropaotfs DEF_VAL(1);
  96. CONFIG_EXT unsigned char config_nomwheel DEF_VAL(0);
  97. CONFIG_EXT unsigned char config_autoload_eq;
  98. CONFIG_EXT unsigned char config_use_eq;
  99. CONFIG_EXT int config_wx DEF_VAL(26), config_wy DEF_VAL(29);
  100. CONFIG_EXT unsigned char config_minimized;
  101. CONFIG_EXT unsigned char config_aot;
  102. CONFIG_EXT unsigned char config_shuffle, config_repeat;
  103. CONFIG_EXT unsigned char config_volume DEF_VAL(200), config_easymove DEF_VAL(1);
  104. CONFIG_EXT char config_pan;
  105. CONFIG_EXT unsigned char config_dsize;
  106. CONFIG_EXT unsigned char config_timeleftmode;
  107. CONFIG_EXT unsigned char config_autoscrollname DEF_VAL(1), config_sa DEF_VAL(1), config_safire DEF_VAL(4),
  108. config_saref DEF_VAL(2), config_safalloff DEF_VAL(2),config_sa_peaks DEF_VAL(1),
  109. config_sa_peak_falloff DEF_VAL(1);
  110. CONFIG_EXT int config_eq_wx DEF_VAL(26), config_eq_wy DEF_VAL(145), config_eq_open DEF_VAL(1), config_mw_open DEF_VAL(1);
  111. CONFIG_EXT int config_pe_wx DEF_VAL(26), config_pe_wy DEF_VAL(261), config_pe_open DEF_VAL(1), config_pe_width DEF_VAL(275),
  112. config_pe_height DEF_VAL(116), config_pe_height_ws;
  113. /*
  114. CONFIG_EXT int config_si_wx DEF_VAL(0), config_si_wy DEF_VAL(0), config_si_width DEF_VAL(100), config_si_height DEF_VAL(100),
  115. config_si_autoshow DEF_VAL(1), config_si_autosize DEF_VAL(1), config_si_autohide DEF_VAL(1), config_si_open DEF_VAL(0);
  116. */
  117. CONFIG_EXT int config_plscrollsize DEF_VAL(1), config_plmw2xscroll DEF_VAL(1);
  118. CONFIG_EXT unsigned char config_windowshade,config_rofiob,config_eq_ws;
  119. CONFIG_EXT unsigned char config_preamp DEF_VAL(31);
  120. CONFIG_EXT int config_pilp;
  121. CONFIG_EXT unsigned char config_randskin;
  122. CONFIG_EXT wchar_t config_cwd[MAX_PATH] DEF_VAL(L"");
  123. CONFIG_EXT int config_newverchk DEF_VAL(1);
  124. CONFIG_EXT int config_newverchk_rc DEF_VAL(0);
  125. CONFIG_EXT int config_user_consent_join_channels DEF_VAL(-1);
  126. CONFIG_EXT int config_newverchk2 DEF_VAL(1);
  127. CONFIG_EXT int config_newverchk3 DEF_VAL(0);
  128. CONFIG_EXT int config_embedwnd_freesize;
  129. CONFIG_EXT wchar_t config_skin[MAX_PATH] DEF_VAL(L""), skin_directory[MAX_PATH] DEF_VAL(L"");
  130. CONFIG_EXT int config_dotitlenum DEF_VAL(1);
  131. CONFIG_EXT int config_dotasknum DEF_VAL(1);
  132. CONFIG_EXT char config_check_ft_startup DEF_VAL(0), config_updated_ft_startup DEF_VAL(0), config_uid_ft DEF_VAL(0);
  133. CONFIG_EXT char config_bifont DEF_VAL(0); // bitmapped font (off by default)
  134. CONFIG_EXT char config_bifont_alt DEF_VAL(0); // non-bitmapped font alternative option (off by default)
  135. CONFIG_EXT char config_browserbrand[16] DEF_VAL("");
  136. /* --- video --- */
  137. CONFIG_EXT int config_video_wx DEF_VAL(26), config_video_wy DEF_VAL(145),
  138. config_video_open DEF_VAL(0),
  139. config_video_width DEF_VAL(275), config_video_height DEF_VAL(232),
  140. config_video_ratio1 DEF_VAL(4), config_video_ratio2 DEF_VAL(3),
  141. config_video_useratio;
  142. CONFIG_EXT int config_video_aspectadj DEF_VAL(1);
  143. CONFIG_EXT int config_video_updsize DEF_VAL(0);
  144. CONFIG_EXT int config_video_noss DEF_VAL(1);
  145. CONFIG_EXT int config_video_logo DEF_VAL(1);
  146. CONFIG_EXT int config_video_osd DEF_VAL(1);
  147. CONFIG_EXT int config_video_stopclose DEF_VAL(1);
  148. //CONFIG_EXT int config_video_auto_fs DEF_VAL(0); // plague> moved to WinampAttributes.h
  149. //#define EXPERIMENTAL_CONTRAST
  150. #ifdef EXPERIMENTAL_CONTRAST
  151. CONFIG_EXT int config_video_contrast DEF_VAL(128);
  152. CONFIG_EXT int config_video_brightness DEF_VAL(128);
  153. #endif
  154. CONFIG_EXT int config_video_remove_fs_on_stop DEF_VAL(1);
  155. CONFIG_EXT int config_video_fliprgb DEF_VAL(0);
  156. CONFIG_EXT int config_wav_do_header DEF_VAL(1);
  157. CONFIG_EXT int config_wav_convert DEF_VAL(0);
  158. CONFIG_EXT char config_wav_ext[8] DEF_VAL("WAV");
  159. CONFIG_EXT int config_no_visseh;
  160. CONFIG_EXT int config_no_registry DEF_VAL(0);
  161. CONFIG_EXT int config_last_classic_skin_page DEF_VAL(0);
  162. CONFIG_EXT int config_last_playback_page DEF_VAL(0);
  163. CONFIG_EXT int config_last_fileinfo_page DEF_VAL(0);
  164. CONFIG_EXT int config_upd_mode DEF_VAL(0);
  165. CONFIG_EXT wchar_t config_artwork_filter[64] DEF_VAL(L"cover");
  166. CONFIG_EXT int config_noml_ratings_prompt DEF_VAL(1);
  167. CONFIG_EXT int config_noml_ratings DEF_VAL(0);
  168. CONFIG_EXT int config_jtf_check DEF_VAL(0);
  169. CONFIG_EXT int config_block_img DEF_VAL(1);
  170. #endif // config.h