26 #include "Utils/typedefs.h"
28 enum class SettingKey : unsigned short
49 Lib_SplitterStateArtist,
50 Lib_SplitterStateTrack,
51 Lib_SplitterStateGenre,
52 Lib_SplitterStateDate,
56 Lib_DC_PlayImmediately,
58 Lib_DD_PlayIfStoppedAndEmpty,
70 Lib_CoverScaledPMCache,
74 Lib_UseViewClearButton,
76 Lib_SortIgnoreArtistArticle,
77 Lib_HeaderAutoResizeArtists,
78 Lib_HeaderAutoResizeAlbums,
79 Lib_HeaderAutoResizeTracks,
83 Dir_TagToFilenameExpression,
101 Player_NotifyNewVersion,
102 Player_SplitterState,
103 Player_SplitterControls,
109 PL_LastTrackBeforeStop,
112 PL_LoadSavedPlaylists,
113 PL_LoadTemporaryPlaylists,
117 PL_RememberTrackAfterStop,
125 Notification_Timeout,
130 AudioConvert_NumberThreads,
131 AudioConvert_PreferredConverter,
132 AudioConvert_QualityLameVBR,
133 AudioConvert_QualityLameCBR,
134 AudioConvert_QualityOgg,
135 Engine_CovertTargetPath,
139 Engine_CurTrackPos_s,
140 Engine_CrossFaderActive,
141 Engine_CrossFaderTime,
143 Engine_PreservePitch,
152 Engine_SR_SessionPath,
153 Engine_SR_SessionPathTemplate,
154 Engine_SR_AutoRecord,
169 Stream_SearchWindowSize,
177 Cover_SaveToSayonaraDir,
180 Icon_ForceInDarkTheme,
189 AlternativeCovers_Size,
213 enum class ViewType : quint8;
216 template<typename DataType, SettingKey keyIndex>
221 const static SettingKey key=keyIndex;
229 #define INST_ABSTR(ns, type, settingkey) \
231 using settingkey = SettingIdentifier<type, SettingKey:: settingkey>; \
234 #define INST(type, settingkey) INST_ABSTR(Set, type, settingkey)
235 #define INST_NO_DB(type, settingkey) INST_ABSTR(SetNoDB, type, settingkey)
241 INST(
bool, LFM_Active)
242 INST(
int, LFM_ScrobbleTimeSec)
244 INST(QString, LFM_Username)
245 INST(QString, LFM_Password)
247 INST(
bool, LFM_Corrections)
248 INST(
bool, LFM_ShowErrors)
249 INST(QString, LFM_SessionKey)
256 INST(QString, Lib_Path)
257 INST(QByteArray, Lib_ColStateAlbums)
258 INST(QByteArray, Lib_ColStateArtists)
259 INST(QByteArray, Lib_ColStateTracks)
260 INST(
bool, Lib_LiveSearch)
262 INST(QString, Lib_CurPlugin)
263 INST(QByteArray, Lib_SplitterStateArtist)
264 INST(QByteArray, Lib_SplitterStateTrack)
265 INST(QByteArray, Lib_SplitterStateGenre)
266 INST(QByteArray, Lib_SplitterStateDate)
267 INST(
int, Lib_OldWidth)
268 INST(
bool, Lib_DC_DoNothing)
269 INST(
bool, Lib_DC_PlayIfStopped)
270 INST(
bool, Lib_DC_PlayImmediately)
271 INST(
bool, Lib_DD_DoNothing)
272 INST(
bool, Lib_DD_PlayIfStoppedAndEmpty)
273 INST(
int, Lib_FontSize)
274 INST(
bool, Lib_FontBold)
275 INST(
int, Lib_SearchMode)
276 INST(
bool, Lib_AutoUpdate)
277 INST(
bool, Lib_ShowAlbumArtists)
278 INST(
bool, Lib_ShowAlbumCovers)
279 INST(::Library::ViewType, Lib_ViewType)
280 INST(
int, Lib_CoverZoom)
281 INST(
int, Lib_CoverOrigPMCache)
282 INST(
int, Lib_CoverScaledPMCache)
283 INST(
bool, Lib_CoverShowUtils)
284 INST(
bool, Lib_CoverShowArtist)
285 INST(
bool, Lib_GenreTree)
287 INST(
int, Lib_LastIndex)
288 INST(
bool, Lib_UseViewClearButton)
289 INST(
bool, Lib_ShowFilterExtBar)
290 INST(
bool, Lib_SortIgnoreArtistArticle)
291 INST(
bool, Lib_HeaderAutoResizeArtists)
292 INST(
bool, Lib_HeaderAutoResizeAlbums)
293 INST(
bool, Lib_HeaderAutoResizeTracks)
295 INST(
bool, Dir_ShowTracks)
296 INST(QByteArray, Dir_SplitterDirFile)
297 INST(QByteArray, Dir_SplitterTracks)
298 INST(QString, Dir_TagToFilenameExpression)
300 INST(QString, Player_Version)
301 INST(QString, Player_Language)
302 INST(
int, Player_Style)
303 INST(
int, Player_ControlStyle)
304 INST(QString, Player_FontName)
305 INST(
int, Player_FontSize)
306 INST(
bool, Player_FadingCover)
307 INST(
bool, Player_Fullscreen)
308 INST(
bool, Player_Maximized)
309 INST(QByteArray, Player_Geometry)
310 INST(QString, Player_ShownPlugin)
311 INST(
bool, Player_OneInstance)
312 INST(
bool, Player_Min2Tray)
313 INST(
bool, Player_ShowTrayIcon)
314 INST(
bool, Player_StartInTray)
315 INST(
bool, Player_514Fix)
316 INST(
bool, Player_NotifyNewVersion)
317 INST(QByteArray, Player_SplitterState)
319 INST(QByteArray, Player_SplitterControls)
320 INST(QByteArray, Player_PrivId)
321 INST(QByteArray, Player_PublicId)
323 INST(QStringList, PL_Playlist)
324 INST(
bool, PL_LoadSavedPlaylists)
325 INST(
bool, PL_LoadTemporaryPlaylists)
326 INST(
bool, PL_LoadLastTrack)
327 INST(
bool, PL_RememberTime)
328 INST(
bool, PL_StartPlaying)
329 INST(
int, PL_LastTrack)
330 INST(
int, PL_LastTrackBeforeStop)
331 INST(
int, PL_LastPlaylist)
332 INST(QString, PL_EntryLook)
333 INST(
int, PL_FontSize)
334 INST(
bool, PL_ShowClearButton)
336 INST(
bool, PL_ShowNumbers)
337 INST(
bool, PL_ShowBottomBar)
338 INST(
bool, PL_RememberTrackAfterStop)
339 INST(
bool, PL_ShowCovers)
340 INST(
bool, PL_ShowRating)
342 INST(
bool, Notification_Show)
343 INST(
int, Notification_Timeout)
344 INST(QString, Notification_Name)
346 INST(
int, AudioConvert_NumberThreads)
347 INST(QString, AudioConvert_PreferredConverter)
348 INST(
int, AudioConvert_QualityLameVBR)
349 INST(
int, AudioConvert_QualityLameCBR)
350 INST(
int, AudioConvert_QualityOgg)
352 INST(QString, Engine_Name)
353 INST(
int, Engine_Vol)
354 INST(
bool, Engine_Mute)
355 INST(
int, Engine_CurTrackPos_s)
356 INST(QString, Engine_CovertTargetPath)
357 INST(
int, Engine_SpectrumBins)
358 INST(
bool, Engine_ShowSpectrum)
359 INST(
bool, Engine_ShowLevel)
360 INST(
bool, Engine_CrossFaderActive)
361 INST(
int, Engine_CrossFaderTime)
362 INST(
int, Engine_Pitch)
363 INST(
bool, Engine_SpeedActive)
364 INST(
float, Engine_Speed)
365 INST(
bool, Engine_PreservePitch)
366 INST(QString, Engine_Sink)
367 INST(QString, Engine_AlsaDevice)
368 INST(
int, Engine_BufferSizeMS)
370 INST(
bool, Engine_SR_Active)
371 INST(
bool, Engine_SR_Warning)
372 INST(QString, Engine_SR_Path)
373 INST(
bool, Engine_SR_SessionPath)
374 INST(QString, Engine_SR_SessionPathTemplate)
375 INST(
bool, Engine_SR_AutoRecord)
377 INST(
int, Spectrum_Style)
378 INST(
int, Level_Style)
379 INST(
bool, Broadcast_Active)
380 INST(
bool, Broadcast_Prompt)
381 INST(
int, Broadcast_Port)
383 INST(
bool, Remote_Active)
384 INST(
int, Remote_Port)
385 INST(
bool, Remote_Discoverable)
386 INST(
int, Remote_DiscoverPort)
388 INST(
bool, Stream_NewTab)
389 INST(
bool, Stream_ShowHistory)
390 INST(QSize, Stream_SearchWindowSize)
392 INST(
int, Lyrics_Zoom)
393 INST(QString, Lyrics_Server)
395 INST(QStringList, Cover_Server)
396 INST(
bool, Cover_FetchFromWWW)
397 INST(
bool, Cover_SaveToDB)
398 INST(
bool, Cover_StartSearch)
399 INST(
bool, Cover_SaveToLibrary)
400 INST(
bool, Cover_SaveToSayonaraDir)
401 INST(QString, Cover_TemplatePath)
402 INST(QString, Icon_Theme)
403 INST(
bool, Icon_ForceInDarkTheme)
405 INST(
bool, Proxy_Active)
406 INST(QString, Proxy_Username)
407 INST(QString, Proxy_Password)
408 INST(QString, Proxy_Hostname)
409 INST(
int, Proxy_Port)
410 INST(
bool, Proxy_SavePw)
412 INST(
int, Speed_LastTab)
414 INST(QSize, InfoDialog_Size)
415 INST(QSize, AlternativeCovers_Size)
417 INST(
int, Settings_Revision)
419 INST(
int, Logger_Level)
421 INST_NO_DB(
bool, MP3enc_found)
422 INST_NO_DB(
bool, Pitch_found)
423 INST_NO_DB(
bool, Player_Quit)
424 INST_NO_DB(
int, Player_MetaStyle)
426 #endif // SETTINGKEY_H