Mercurial > minori
view src/services/services.cc @ 266:1a6a5d3a94cd
dep/animone: make bsd.cc and x11.cc actually work
apparently I broke these, and even now the x11 code *still* doesn't want
to work correctly (at least on FreeBSD). half of the PID response codes
are just 0 or the PID for the X server itself... wtf?
maybe dwm just doesn't support the XRes extension, or I'm just stupid.
i don't know.
author | Paper <paper@paper.us.eu.org> |
---|---|
date | Thu, 11 Apr 2024 22:05:41 -0400 |
parents | c130f47f6f48 |
children | 657fda1b9cac |
line wrap: on
line source
#include "services/services.h" #include "core/session.h" #include "gui/dialog/settings.h" #include "services/anilist.h" namespace Services { void Synchronize() { switch (session.config.service) { case Anime::Services::ANILIST: AniList::GetAnimeList(); break; default: break; } } std::vector<int> Search(const std::string& search) { switch (session.config.service) { case Anime::Services::ANILIST: return AniList::Search(search); default: return {}; } } void UpdateAnimeEntry(int id) { switch (session.config.service) { case Anime::Services::ANILIST: AniList::UpdateAnimeEntry(id); break; default: break; } } bool Authorize() { switch (session.config.service) { case Anime::Services::ANILIST: return AniList::AuthorizeUser(); default: return true; } } }; // namespace Services