Changeset View
Changeset View
Standalone View
Standalone View
src/covermanager/CoverFetchQueue.h
Show First 20 Lines • Show All 77 Lines • ▼ Show 20 Line(s) | 46 | public: | |||
---|---|---|---|---|---|
78 | * @param page the page number to jump to. | 78 | * @param page the page number to jump to. | ||
79 | * @param album optional album this query is associated with | 79 | * @param album optional album this query is associated with | ||
80 | */ | 80 | */ | ||
81 | void addQuery( const QString &query, | 81 | void addQuery( const QString &query, | ||
82 | const CoverFetch::Source src = CoverFetch::LastFm, | 82 | const CoverFetch::Source src = CoverFetch::LastFm, | ||
83 | unsigned int page = 0, | 83 | unsigned int page = 0, | ||
84 | Meta::AlbumPtr album = Meta::AlbumPtr(0) ); | 84 | Meta::AlbumPtr album = Meta::AlbumPtr(0) ); | ||
85 | 85 | | |||
86 | bool contains( const Meta::AlbumPtr album ) const; | | |||
87 | int index( const Meta::AlbumPtr album ) const; | | |||
88 | int size() const; | | |||
89 | bool isEmpty() const; | | |||
90 | | ||||
91 | void clear(); | 86 | void clear(); | ||
92 | const CoverFetchUnit::Ptr take( const Meta::AlbumPtr album ); | | |||
93 | 87 | | |||
94 | public Q_SLOTS: | 88 | public Q_SLOTS: | ||
95 | void remove( const CoverFetchUnit::Ptr unit ); | 89 | void remove( const CoverFetchUnit::Ptr unit ); | ||
96 | void remove( const Meta::AlbumPtr album ); | 90 | void remove( const Meta::AlbumPtr album ); | ||
97 | 91 | | |||
98 | Q_SIGNALS: | 92 | Q_SIGNALS: | ||
99 | void fetchUnitAdded( CoverFetchUnit::Ptr ); | 93 | void fetchUnitAdded( CoverFetchUnit::Ptr ); | ||
100 | 94 | | |||
101 | private: | 95 | private: | ||
102 | void add( const CoverFetchUnit::Ptr unit ); | 96 | void add( const CoverFetchUnit::Ptr unit ); | ||
97 | bool contains( const Meta::AlbumPtr album ) const; | ||||
98 | int index( const Meta::AlbumPtr album ) const; | ||||
99 | const CoverFetchUnit::Ptr take( const Meta::AlbumPtr album ); | ||||
103 | 100 | | |||
104 | CoverFetchUnitList m_queue; | 101 | CoverFetchUnitList m_queue; | ||
105 | Q_DISABLE_COPY( CoverFetchQueue ) | 102 | Q_DISABLE_COPY( CoverFetchQueue ) | ||
106 | }; | 103 | }; | ||
107 | 104 | | |||
108 | #endif /* AMAROK_COVERFETCHQUEUE_H */ | 105 | #endif /* AMAROK_COVERFETCHQUEUE_H */ |