You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

library.hpp 961B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. #pragma once
  2. #include <common.hpp>
  3. #include <map>
  4. namespace rack {
  5. /** Synchronizes plugins with the VCV Library and updates Rack itself
  6. */
  7. namespace library {
  8. struct Update {
  9. std::string name;
  10. std::string version;
  11. std::string changelogUrl;
  12. float progress = 0.f;
  13. };
  14. void init();
  15. void destroy();
  16. void checkAppUpdate();
  17. bool isAppUpdateAvailable();
  18. bool isLoggedIn();
  19. void logIn(const std::string& email, const std::string& password);
  20. void logOut();
  21. void checkUpdates();
  22. bool hasUpdates();
  23. void syncUpdate(const std::string& slug);
  24. void syncUpdates();
  25. bool isSyncing();
  26. extern std::string appVersion;
  27. extern std::string appDownloadUrl;
  28. extern std::string appChangelogUrl;
  29. extern std::string loginStatus;
  30. // plugin slug -> Update
  31. extern std::map<std::string, Update> updates;
  32. extern std::string updateStatus;
  33. extern std::string updatingSlug;
  34. extern bool updatingPlugins;
  35. extern bool restartRequested;
  36. } // namespace library
  37. } // namespace rack