2021-01-27 12:38:03 +01:00
|
|
|
#pragma once
|
2021-04-13 20:31:51 +02:00
|
|
|
#include <helper/audio/audio.hpp>
|
2021-02-22 11:43:19 +01:00
|
|
|
#if defined(__linux__)
|
2021-05-04 17:25:43 +02:00
|
|
|
#include <helper/audio/linux/backend.hpp>
|
2021-02-22 11:43:19 +01:00
|
|
|
#endif
|
2021-04-13 20:31:51 +02:00
|
|
|
#include <core/config/config.hpp>
|
|
|
|
#include <core/hotkeys/hotkeys.hpp>
|
2021-05-22 16:41:36 +02:00
|
|
|
#include <core/objects/data.hpp>
|
|
|
|
#include <core/objects/objects.hpp>
|
|
|
|
#include <core/objects/settings.hpp>
|
2021-04-13 20:31:51 +02:00
|
|
|
#include <helper/icons/icons.hpp>
|
2021-05-22 16:41:36 +02:00
|
|
|
#include <helper/queue/queue.hpp>
|
2021-04-13 20:31:51 +02:00
|
|
|
#include <helper/ytdl/youtube-dl.hpp>
|
2021-01-27 12:38:03 +01:00
|
|
|
#include <memory>
|
2021-04-13 20:31:51 +02:00
|
|
|
#include <ui/ui.hpp>
|
2021-05-21 20:23:24 +02:00
|
|
|
#include <var_guard.hpp>
|
2021-01-27 12:38:03 +01:00
|
|
|
|
|
|
|
namespace Soundux
|
|
|
|
{
|
|
|
|
namespace Globals
|
|
|
|
{
|
|
|
|
inline Objects::Data gData;
|
2021-01-27 17:33:49 +01:00
|
|
|
inline Objects::Audio gAudio;
|
2021-02-22 11:43:19 +01:00
|
|
|
#if defined(__linux__)
|
2021-05-22 16:41:36 +02:00
|
|
|
inline std::optional<Objects::IconFetcher> gIcons;
|
2021-05-04 17:25:43 +02:00
|
|
|
inline std::shared_ptr<Objects::AudioBackend> gAudioBackend;
|
2021-02-22 11:43:19 +01:00
|
|
|
#endif
|
2021-05-22 16:41:36 +02:00
|
|
|
inline Objects::Queue gQueue;
|
2021-01-27 12:38:03 +01:00
|
|
|
inline Objects::Config gConfig;
|
2021-03-18 20:52:30 +01:00
|
|
|
inline Objects::YoutubeDl gYtdl;
|
2021-02-09 18:46:39 +01:00
|
|
|
inline Objects::Hotkeys gHotKeys;
|
2021-01-27 12:38:03 +01:00
|
|
|
inline Objects::Settings gSettings;
|
2021-02-15 21:11:13 +01:00
|
|
|
inline std::unique_ptr<Objects::Window> gGui;
|
2021-01-27 12:38:03 +01:00
|
|
|
|
|
|
|
/* Allows for fast & easy sound access, is populated on start up */
|
2021-05-21 20:23:24 +02:00
|
|
|
inline sxl::var_guard<std::map<std::uint32_t, std::reference_wrapper<Objects::Sound>>> gSounds;
|
|
|
|
inline sxl::var_guard<std::map<std::uint32_t, std::reference_wrapper<Objects::Sound>>> gFavorites;
|
2021-01-27 12:38:03 +01:00
|
|
|
} // namespace Globals
|
|
|
|
} // namespace Soundux
|