diff options
author | James Cook <james@lindenlab.com> | 2009-11-25 12:31:24 -0800 |
---|---|---|
committer | James Cook <james@lindenlab.com> | 2009-11-25 12:31:24 -0800 |
commit | 957055396d2ffa3a76b09c60cb9c3e1f73870cbf (patch) | |
tree | 632ecbdc0c21b0e14eb72f74faa8c04765f54489 /indra/newview/llmediadataclient.h | |
parent | ef46d4077ca4aad322aabfe545885be136577c8a (diff) | |
parent | 59eb8a43a467ecaa5a8c2b58bf1abfb8350c0202 (diff) |
merge in changes from viewer-2-0, manually fixed conflict in llviewermessages.cpp
Diffstat (limited to 'indra/newview/llmediadataclient.h')
-rwxr-xr-x | indra/newview/llmediadataclient.h | 31 |
1 files changed, 9 insertions, 22 deletions
diff --git a/indra/newview/llmediadataclient.h b/indra/newview/llmediadataclient.h index d5dd050111..812e9cbdec 100755 --- a/indra/newview/llmediadataclient.h +++ b/indra/newview/llmediadataclient.h @@ -195,30 +195,14 @@ protected: private: - // Comparator for PriorityQueue - class Comparator - { - public: - bool operator() (const request_ptr_t &o1, const request_ptr_t &o2) const; - private: - static F64 getObjectScore(const LLMediaDataClientObject::ptr_t &obj); - }; + typedef std::list<request_ptr_t> request_queue_t; - // PriorityQueue - class PriorityQueue : public std::priority_queue< - request_ptr_t, - std::vector<request_ptr_t>, - Comparator > - { - public: - // Return whether the given object is in the queue - bool find(const LLMediaDataClientObject::ptr_t &obj) const; - - friend std::ostream& operator<<(std::ostream &s, const PriorityQueue &q); - }; + // Comparator for sorting + static bool compareRequests(const request_ptr_t &o1, const request_ptr_t &o2); + static F64 getObjectScore(const LLMediaDataClientObject::ptr_t &obj); friend std::ostream& operator<<(std::ostream &s, const Request &q); - friend std::ostream& operator<<(std::ostream &s, const PriorityQueue &q); + friend std::ostream& operator<<(std::ostream &s, const request_queue_t &q); class QueueTimer : public LLEventTimer { @@ -232,6 +216,9 @@ private: LLPointer<LLMediaDataClient> mMDC; }; + // Return whether the given object is in the queue + bool find(const LLMediaDataClientObject::ptr_t &obj) const; + void startQueueTimer(); void stopQueueTimer(); void setIsRunning(bool val) { mQueueTimerIsRunning = val; } @@ -242,7 +229,7 @@ private: bool mQueueTimerIsRunning; - PriorityQueue *pRequestQueue; + request_queue_t *pRequestQueue; }; |