1
0

FeedBase.h 894 B

123456789101112131415161718192021222324252627282930313233
  1. #ifndef NULLSOFT_WINAMP_FEEDBASE_H
  2. #define NULLSOFT_WINAMP_FEEDBASE_H
  3. #include <api/dependency/api_dependent.h>
  4. #include <api/skin/feeds/api_textfeed.h>
  5. #include <vector>
  6. #include <bfc/multipatch.h>
  7. enum {DependentPatch = 10, TextFeedPatch = 20 };
  8. class FeedBase
  9. : public MultiPatch<DependentPatch, api_dependent>,
  10. public MultiPatch<TextFeedPatch, svc_textFeed>
  11. {
  12. private:
  13. void dependent_regViewer(api_dependentviewer *viewer, int add);
  14. void *dependent_getInterface(const GUID *classguid);
  15. virtual int hasFeed(const wchar_t *name)=0;
  16. virtual const wchar_t *getFeedText(const wchar_t *name)=0;
  17. virtual const wchar_t *getFeedDescription(const wchar_t *name)=0;
  18. api_dependent *getDependencyPtr();
  19. protected:
  20. void CallViewers(const wchar_t *feedid, const wchar_t *text, size_t length);
  21. protected:
  22. std::vector<api_dependentviewer*> viewers;
  23. protected:
  24. RECVS_MULTIPATCH;
  25. };
  26. #endif