From c2db825b071974369ab40300210f5ecb933744a6 Mon Sep 17 00:00:00 2001 From: Christian Gmeiner Date: Thu, 19 Feb 2009 21:08:24 +0100 Subject: make more use of Uncopyable --- dxr3output.h | 35 ++++++++--------------------------- 1 file changed, 8 insertions(+), 27 deletions(-) (limited to 'dxr3output.h') diff --git a/dxr3output.h b/dxr3output.h index 7afccc2..9b8d408 100644 --- a/dxr3output.h +++ b/dxr3output.h @@ -24,25 +24,19 @@ #include "dxr3syncbuffer.h" #include "dxr3audiodecoder.h" +#include "Uncopyable.h" // ================================== -class cDxr3OutputThread : public cThread -{ +class cDxr3OutputThread : public cThread, private Uncopyable { public: cDxr3OutputThread(cDxr3Interface& dxr3Device, cDxr3SyncBuffer& buffer); virtual ~cDxr3OutputThread() { - m_buffer.Stop(); - Cancel(3); + m_buffer.Stop(); + Cancel(3); }; - bool NeedResync() - { - return m_bNeedResync; - }; - void ClearResyncRequest() - { - m_bNeedResync = false; - }; + bool NeedResync() const { return m_bNeedResync; } + void ClearResyncRequest() { m_bNeedResync = false; } protected: virtual void Action() = 0; @@ -50,37 +44,24 @@ protected: cDxr3Interface& m_dxr3Device; cDxr3SyncBuffer& m_buffer; bool m_bNeedResync; - -private: - cDxr3OutputThread(cDxr3OutputThread&); // no copy constructor }; // ================================== -class cDxr3AudioOutThread : public cDxr3OutputThread -{ +class cDxr3AudioOutThread : public cDxr3OutputThread { public: cDxr3AudioOutThread(cDxr3Interface& dxr3Device, cDxr3SyncBuffer& buffer); protected: void Action(); - -private: - //cDxr3AudioOutThread(); // no standard constructor - cDxr3AudioOutThread(cDxr3AudioOutThread&); // no copy constructor }; // ================================== -class cDxr3VideoOutThread : public cDxr3OutputThread -{ +class cDxr3VideoOutThread : public cDxr3OutputThread { public: cDxr3VideoOutThread(cDxr3Interface& dxr3Device, cDxr3SyncBuffer& buffer); protected: void Action(); - -private: - //cDxr3VideoOutThread(); // no standard constructor - cDxr3VideoOutThread(cDxr3VideoOutThread&); // no copy constructor }; #endif /*_DXR3OUTPUTTHREAD_H_*/ -- cgit v1.2.3