From d3aa06c2a2cc591e5a0f0370fe335c1d386b75d9 Mon Sep 17 00:00:00 2001 From: Cinder <cinder@sdf.org> Date: Sun, 22 Sep 2019 06:55:15 -0500 Subject: [PATCH] By convention, deleted functions should be public --- indra/llappearance/llavatarappearance.h | 3 +- indra/llcharacter/llmultigesture.h | 2 +- indra/llcommon/llcoros.h | 1 - indra/llcommon/lldeadmantimer.h | 2 -- indra/llcommon/llhandle.h | 2 +- indra/llcommon/llinstancetracker.h | 1 + indra/llcommon/llpounceable.h | 1 - indra/llcommon/llprocinfo.h | 2 -- indra/llcommon/llsingleton.h | 6 ++-- indra/llcorehttp/_httplibcurl.h | 4 --- indra/llcorehttp/_httpoperation.h | 8 ------ indra/llcorehttp/_httpoprequest.h | 3 -- indra/llcorehttp/_httpopsetget.h | 3 -- indra/llcorehttp/_httpopsetpriority.h | 2 -- indra/llcorehttp/_httppolicy.h | 2 -- indra/llcorehttp/_httppolicyglobal.h | 2 -- indra/llcorehttp/_httpreadyqueue.h | 11 ++------ indra/llcorehttp/_httpreplyqueue.h | 3 -- indra/llcorehttp/_httprequestqueue.h | 5 +--- indra/llcorehttp/_httpservice.h | 4 +-- indra/llcorehttp/_refcounted.h | 2 +- indra/llcorehttp/_thread.h | 3 +- indra/llcorehttp/bufferarray.cpp | 2 +- indra/llcorehttp/bufferarray.h | 3 +- indra/llcorehttp/bufferstream.h | 3 -- indra/llcorehttp/httpheaders.h | 3 -- indra/llcorehttp/httpoptions.h | 4 --- indra/llcorehttp/httprequest.h | 2 -- indra/llcorehttp/httpresponse.h | 8 +++--- indra/llmessage/llcoproceduremanager.cpp | 2 -- indra/llrender/llfontgl.h | 6 ++-- indra/llui/llview.h | 7 +++-- indra/newview/lldesktopnotifications.h | 1 - indra/newview/llfloaterpathfindingobjects.h | 5 ++-- indra/newview/llgiveinventory.h | 4 ++- indra/newview/llinventorymodel.h | 2 -- .../llinventorymodelbackgroundfetch.cpp | 2 -- indra/newview/lllandmarkactions.h | 2 +- indra/newview/llmeshrepository.cpp | 14 +--------- indra/newview/llnotificationlistitem.h | 28 ++++++++++++------- indra/newview/llselectmgr.h | 4 +-- indra/newview/llviewertexture.h | 4 +-- 42 files changed, 56 insertions(+), 122 deletions(-) diff --git a/indra/llappearance/llavatarappearance.h b/indra/llappearance/llavatarappearance.h index 7ef8d37aad..a10087b692 100644 --- a/indra/llappearance/llavatarappearance.h +++ b/indra/llappearance/llavatarappearance.h @@ -60,11 +60,10 @@ protected: ** ** ** INITIALIZATION **/ -private: +public: // Hide default constructor. LLAvatarAppearance() = delete; -public: LLAvatarAppearance(LLWearableData* wearable_data); virtual ~LLAvatarAppearance(); diff --git a/indra/llcharacter/llmultigesture.h b/indra/llcharacter/llmultigesture.h index ee06167ec1..60bed362c4 100644 --- a/indra/llcharacter/llmultigesture.h +++ b/indra/llcharacter/llmultigesture.h @@ -52,7 +52,7 @@ public: void reset(); const std::string& getTrigger() const { return mTrigger; } -protected: + LLMultiGesture(const LLMultiGesture& gest) = delete; const LLMultiGesture& operator=(const LLMultiGesture& rhs) = delete; diff --git a/indra/llcommon/llcoros.h b/indra/llcommon/llcoros.h index 2617c465d9..ed055cbb23 100644 --- a/indra/llcommon/llcoros.h +++ b/indra/llcommon/llcoros.h @@ -281,7 +281,6 @@ public: Suspending(); ~Suspending(); -protected: Suspending(const Suspending&) = delete; Suspending& operator=(const Suspending&) = delete; diff --git a/indra/llcommon/lldeadmantimer.h b/indra/llcommon/lldeadmantimer.h index 7fab13b60e..f6de0760fe 100644 --- a/indra/llcommon/lldeadmantimer.h +++ b/indra/llcommon/lldeadmantimer.h @@ -102,11 +102,9 @@ public: ~LLDeadmanTimer() = default; -private: LLDeadmanTimer(const LLDeadmanTimer &) = delete; // Not defined LLDeadmanTimer& operator=(const LLDeadmanTimer &) = delete; // Not defined -public: /// Get the current time. Zero-basis for this time /// representation is not defined and is different on /// different platforms. Do not attempt to compute diff --git a/indra/llcommon/llhandle.h b/indra/llcommon/llhandle.h index 1b8da0809e..8f242b5de5 100644 --- a/indra/llcommon/llhandle.h +++ b/indra/llcommon/llhandle.h @@ -176,8 +176,8 @@ public: } //don't allow copying of root handles, since there should only be one -private: LLRootHandle(const LLRootHandle& other) = delete; + LLRootHandle& operator=(const LLRootHandle&) = delete; }; /** diff --git a/indra/llcommon/llinstancetracker.h b/indra/llcommon/llinstancetracker.h index 20c5c9af1d..f694b7dae5 100644 --- a/indra/llcommon/llinstancetracker.h +++ b/indra/llcommon/llinstancetracker.h @@ -253,6 +253,7 @@ protected: virtual void setKey(KEY key) { remove_(); add_(key); } virtual const KEY& getKey() const { return mInstanceKey; } +public: LLInstanceTracker( const LLInstanceTracker& ) = delete; LLInstanceTracker& operator=( const LLInstanceTracker& ) = delete; diff --git a/indra/llcommon/llpounceable.h b/indra/llcommon/llpounceable.h index f54ee25979..7e828cf9ae 100644 --- a/indra/llcommon/llpounceable.h +++ b/indra/llcommon/llpounceable.h @@ -158,7 +158,6 @@ public: mEmpty(empty) {} -protected: LLPounceable(const LLPounceable&) = delete; LLPounceable& operator=(const LLPounceable&) = delete; diff --git a/indra/llcommon/llprocinfo.h b/indra/llcommon/llprocinfo.h index 7395a3626a..c173b5f4ce 100644 --- a/indra/llcommon/llprocinfo.h +++ b/indra/llcommon/llprocinfo.h @@ -50,13 +50,11 @@ public: typedef U64 time_type; /// Relative microseconds -private: LLProcInfo() = delete; // Not defined ~LLProcInfo() = delete; // Not defined LLProcInfo(const LLProcInfo &) = delete; // Not defined LLProcInfo& operator=(const LLProcInfo &) = delete; // Not defined -public: /// Get accumulated system and user CPU time in /// microseconds. Syscalls involved in every invocation. /// diff --git a/indra/llcommon/llsingleton.h b/indra/llcommon/llsingleton.h index 6fc1af975f..8a67f50f04 100644 --- a/indra/llcommon/llsingleton.h +++ b/indra/llcommon/llsingleton.h @@ -35,6 +35,9 @@ class LLSingletonBase public: class MasterList; + LLSingletonBase(const LLSingletonBase&) = delete; + LLSingletonBase& operator=(const LLSingletonBase&) = delete; + private: // All existing LLSingleton instances are tracked in this master list. typedef std::list<LLSingletonBase*> list_t; @@ -77,9 +80,6 @@ protected: LLSingletonBase(tag<DERIVED_TYPE>); virtual ~LLSingletonBase() = default; - LLSingletonBase(const LLSingletonBase&) = delete; - LLSingletonBase& operator=(const LLSingletonBase&) = delete; - // Every new LLSingleton should be added to/removed from the master list void add_master(); void remove_master(); diff --git a/indra/llcorehttp/_httplibcurl.h b/indra/llcorehttp/_httplibcurl.h index 2d9c1a9607..00c5f90fe4 100644 --- a/indra/llcorehttp/_httplibcurl.h +++ b/indra/llcorehttp/_httplibcurl.h @@ -60,11 +60,9 @@ public: HttpLibcurl(HttpService * service); virtual ~HttpLibcurl(); -private: HttpLibcurl(const HttpLibcurl &) = delete; // Not defined HttpLibcurl& operator=(const HttpLibcurl &) = delete; // Not defined -public: typedef boost::shared_ptr<HttpOpRequest> opReqPtr_t; /// Give cycles to libcurl to run active requests. Completed @@ -178,11 +176,9 @@ protected: HandleCache(); ~HandleCache(); - private: HandleCache(const HandleCache &) = delete; // Not defined HandleCache& operator=(const HandleCache &) = delete; // Not defined - public: /// Allocate a curl handle for caller. May be freed using /// either the freeHandle() method or calling curl_easy_cleanup() /// directly. diff --git a/indra/llcorehttp/_httpoperation.h b/indra/llcorehttp/_httpoperation.h index 3e1bd0ebe8..92819e6a2a 100644 --- a/indra/llcorehttp/_httpoperation.h +++ b/indra/llcorehttp/_httpoperation.h @@ -82,11 +82,9 @@ public: /// Threading: called by any thread. virtual ~HttpOperation(); // Use release() -protected: HttpOperation(const HttpOperation&) = delete; HttpOperation& operator=(const HttpOperation&) = delete; -public: /// Register a reply queue and a handler for completion notifications. /// /// Invokers of operations that want to receive notification that an @@ -227,11 +225,9 @@ public: virtual ~HttpOpStop(); -private: HttpOpStop(const HttpOpStop &) = delete; // Not defined HttpOpStop& operator=(const HttpOpStop &) = delete; // Not defined -public: void stageFromRequest(HttpService *) override; }; // end class HttpOpStop @@ -249,11 +245,9 @@ public: virtual ~HttpOpNull(); -private: HttpOpNull(const HttpOpNull &) = delete; // Not defined HttpOpNull& operator=(const HttpOpNull &) = delete; // Not defined -public: void stageFromRequest(HttpService *) override; }; // end class HttpOpNull @@ -271,11 +265,9 @@ public: virtual ~HttpOpSpin(); -private: HttpOpSpin(const HttpOpSpin &) = delete; // Not defined HttpOpSpin& operator=(const HttpOpSpin &) = delete; // Not defined -public: void stageFromRequest(HttpService *) override; protected: diff --git a/indra/llcorehttp/_httpoprequest.h b/indra/llcorehttp/_httpoprequest.h index 782d688cb4..35040d7c48 100644 --- a/indra/llcorehttp/_httpoprequest.h +++ b/indra/llcorehttp/_httpoprequest.h @@ -69,14 +69,11 @@ public: typedef boost::shared_ptr<HttpOpRequest> ptr_t; HttpOpRequest(); - virtual ~HttpOpRequest(); // Use release() -private: HttpOpRequest(const HttpOpRequest &) = delete; // Not defined HttpOpRequest& operator=(const HttpOpRequest &) = delete; // Not defined -public: enum EMethod { HOR_GET, diff --git a/indra/llcorehttp/_httpopsetget.h b/indra/llcorehttp/_httpopsetget.h index 09c0a3fae4..8a30a96239 100644 --- a/indra/llcorehttp/_httpopsetget.h +++ b/indra/llcorehttp/_httpopsetget.h @@ -56,14 +56,11 @@ public: typedef boost::shared_ptr<HttpOpSetGet> ptr_t; HttpOpSetGet(); - virtual ~HttpOpSetGet(); // Use release() -private: HttpOpSetGet(const HttpOpSetGet &) = delete; // Not defined HttpOpSetGet& operator=(const HttpOpSetGet &) = delete; // Not defined -public: /// Threading: called by application thread HttpStatus setupGet(HttpRequest::EPolicyOption opt, HttpRequest::policy_t pclass); HttpStatus setupSet(HttpRequest::EPolicyOption opt, HttpRequest::policy_t pclass, long value); diff --git a/indra/llcorehttp/_httpopsetpriority.h b/indra/llcorehttp/_httpopsetpriority.h index 8c05418e46..71e4ab4542 100644 --- a/indra/llcorehttp/_httpopsetpriority.h +++ b/indra/llcorehttp/_httpopsetpriority.h @@ -53,11 +53,9 @@ public: virtual ~HttpOpSetPriority(); -private: HttpOpSetPriority(const HttpOpSetPriority &) = delete; // Not defined HttpOpSetPriority& operator=(const HttpOpSetPriority &) = delete; // Not defined -public: void stageFromRequest(HttpService *) override; protected: diff --git a/indra/llcorehttp/_httppolicy.h b/indra/llcorehttp/_httppolicy.h index f7d4a1cb99..e9abf7893e 100644 --- a/indra/llcorehttp/_httppolicy.h +++ b/indra/llcorehttp/_httppolicy.h @@ -55,11 +55,9 @@ public: HttpPolicy(HttpService *); virtual ~HttpPolicy(); -private: HttpPolicy(const HttpPolicy &) = delete; // Not defined HttpPolicy& operator=(const HttpPolicy &) = delete; // Not defined -public: typedef boost::shared_ptr<HttpOpRequest> opReqPtr_t; /// Threading: called by init thread. diff --git a/indra/llcorehttp/_httppolicyglobal.h b/indra/llcorehttp/_httppolicyglobal.h index 21bf689926..ff78346ef2 100644 --- a/indra/llcorehttp/_httppolicyglobal.h +++ b/indra/llcorehttp/_httppolicyglobal.h @@ -54,10 +54,8 @@ public: HttpPolicyGlobal & operator=(const HttpPolicyGlobal &); -private: HttpPolicyGlobal(const HttpPolicyGlobal &) = delete; // Not defined -public: HttpStatus set(HttpRequest::EPolicyOption opt, long value); HttpStatus set(HttpRequest::EPolicyOption opt, const std::string & value); HttpStatus set(HttpRequest::EPolicyOption opt, HttpRequest::policyCallback_t value); diff --git a/indra/llcorehttp/_httpreadyqueue.h b/indra/llcorehttp/_httpreadyqueue.h index b373382cd4..5856f2ad8f 100644 --- a/indra/llcorehttp/_httpreadyqueue.h +++ b/indra/llcorehttp/_httpreadyqueue.h @@ -69,19 +69,12 @@ typedef std::priority_queue<HttpOpRequest::ptr_t, class HttpReadyQueue : public HttpReadyQueueBase { public: - HttpReadyQueue() - : HttpReadyQueueBase() - {} + HttpReadyQueue() : HttpReadyQueueBase() {} + ~HttpReadyQueue() = default; - ~HttpReadyQueue() - {} - -protected: HttpReadyQueue(const HttpReadyQueue &) = delete; // Not defined HttpReadyQueue& operator=(const HttpReadyQueue &) = delete; // Not defined -public: - #if LLCORE_HTTP_READY_QUEUE_IGNORES_PRIORITY // Types and methods needed to make a std::deque look // more like a std::priority_queue, at least for our diff --git a/indra/llcorehttp/_httpreplyqueue.h b/indra/llcorehttp/_httpreplyqueue.h index 716a724208..73d53b7a3c 100644 --- a/indra/llcorehttp/_httpreplyqueue.h +++ b/indra/llcorehttp/_httpreplyqueue.h @@ -68,12 +68,9 @@ public: HttpReplyQueue(); virtual ~HttpReplyQueue(); -protected: HttpReplyQueue(const HttpReplyQueue&) = delete; HttpReplyQueue& operator=(const HttpReplyQueue&) = delete; -public: - typedef std::vector< opPtr_t > OpContainer; /// Insert an object at the back of the reply queue. diff --git a/indra/llcorehttp/_httprequestqueue.h b/indra/llcorehttp/_httprequestqueue.h index 2fcfb12e2f..b491d05069 100644 --- a/indra/llcorehttp/_httprequestqueue.h +++ b/indra/llcorehttp/_httprequestqueue.h @@ -52,15 +52,12 @@ class HttpRequestQueue : public LLCoreInt::RefCounted protected: /// Caller acquires a Refcount on construction HttpRequestQueue(); - -protected: virtual ~HttpRequestQueue(); // Use release() -private: +public: HttpRequestQueue(const HttpRequestQueue &) = delete; // Not defined HttpRequestQueue& operator=(const HttpRequestQueue &) = delete; // Not defined -public: typedef boost::shared_ptr<HttpOperation> opPtr_t; static void init(); diff --git a/indra/llcorehttp/_httpservice.h b/indra/llcorehttp/_httpservice.h index 10597e75c4..55c9fcbb52 100644 --- a/indra/llcorehttp/_httpservice.h +++ b/indra/llcorehttp/_httpservice.h @@ -85,11 +85,11 @@ protected: HttpService(); virtual ~HttpService(); -private: +public: HttpService(const HttpService &) = delete; // Not defined HttpService& operator=(const HttpService &) = delete; // Not defined -public: +protected: enum EState { NOT_INITIALIZED = -1, diff --git a/indra/llcorehttp/_refcounted.h b/indra/llcorehttp/_refcounted.h index 7a722fe555..2a298fc999 100644 --- a/indra/llcorehttp/_refcounted.h +++ b/indra/llcorehttp/_refcounted.h @@ -43,10 +43,10 @@ namespace LLCoreInt class RefCounted { +public: RefCounted() = delete; // Not defined - may not be default constructed RefCounted& operator=(const RefCounted &) = delete; // Not defined -public: explicit RefCounted(bool const implicit) : mRefCount(implicit) {} diff --git a/indra/llcorehttp/_thread.h b/indra/llcorehttp/_thread.h index 9b0ca8cc09..15870cd74c 100644 --- a/indra/llcorehttp/_thread.h +++ b/indra/llcorehttp/_thread.h @@ -42,10 +42,11 @@ namespace LLCoreInt class HttpThread : public RefCounted { -private: +public: HttpThread() = delete; // Not defined HttpThread& operator=(const HttpThread &) = delete; // Not defined +private: void at_exit() { // the thread function has exited so we need to release our reference diff --git a/indra/llcorehttp/bufferarray.cpp b/indra/llcorehttp/bufferarray.cpp index 2c3ee795af..0176ff716d 100644 --- a/indra/llcorehttp/bufferarray.cpp +++ b/indra/llcorehttp/bufferarray.cpp @@ -60,6 +60,7 @@ public: protected: Block(size_t len); +public: Block(const Block &) = delete; // Not defined Block& operator=(const Block &) = delete; // Not defined @@ -67,7 +68,6 @@ protected: // buffered data at the end of the object. void * operator new(size_t len, size_t addl_len); -public: // Only public entry to get a block. static Block * alloc(size_t len); diff --git a/indra/llcorehttp/bufferarray.h b/indra/llcorehttp/bufferarray.h index 15adffe5e6..84017a64fb 100644 --- a/indra/llcorehttp/bufferarray.h +++ b/indra/llcorehttp/bufferarray.h @@ -79,11 +79,10 @@ public: protected: virtual ~BufferArray(); // Use release() -private: +public: BufferArray(const BufferArray &) = delete; // Not defined BufferArray& operator=(const BufferArray &) = delete; // Not defined -public: // Internal magic number, may be used by unit tests. static const size_t BLOCK_ALLOC_SIZE = 65540; diff --git a/indra/llcorehttp/bufferstream.h b/indra/llcorehttp/bufferstream.h index e3f2eaf967..5b1ffd9101 100644 --- a/indra/llcorehttp/bufferstream.h +++ b/indra/llcorehttp/bufferstream.h @@ -90,11 +90,9 @@ public: BufferArrayStreamBuf(BufferArray * array); virtual ~BufferArrayStreamBuf(); -private: BufferArrayStreamBuf(const BufferArrayStreamBuf &) = delete; // Not defined BufferArrayStreamBuf& operator=(const BufferArrayStreamBuf &) = delete; // Not defined -public: // Input interfaces from std::streambuf int_type underflow() override; int_type uflow() override; @@ -139,7 +137,6 @@ public: BufferArrayStream(BufferArray * ba); ~BufferArrayStream() = default; -protected: BufferArrayStream(const BufferArrayStream &) = delete; void operator=(const BufferArrayStream &) = delete; diff --git a/indra/llcorehttp/httpheaders.h b/indra/llcorehttp/httpheaders.h index e82532f400..837d9fac7e 100644 --- a/indra/llcorehttp/httpheaders.h +++ b/indra/llcorehttp/httpheaders.h @@ -95,12 +95,9 @@ public: virtual ~HttpHeaders(); // Use release() //typedef LLCoreInt::IntrusivePtr<HttpHeaders> ptr_t; -protected: - HttpHeaders(const HttpHeaders &) = delete; // Not defined HttpHeaders& operator=(const HttpHeaders&) = delete; // Not defined -public: // Empty the list of headers. void clear(); diff --git a/indra/llcorehttp/httpoptions.h b/indra/llcorehttp/httpoptions.h index 98fe1e8279..4047e3cad7 100644 --- a/indra/llcorehttp/httpoptions.h +++ b/indra/llcorehttp/httpoptions.h @@ -64,13 +64,9 @@ public: virtual ~HttpOptions(); // Use release() -protected: - HttpOptions(const HttpOptions &) = delete; // Not defined HttpOptions& operator=(const HttpOptions&) = delete; // Not defined -public: - // Default: false void setWantHeaders(bool wanted); bool getWantHeaders() const diff --git a/indra/llcorehttp/httprequest.h b/indra/llcorehttp/httprequest.h index ccf8c34047..a7a700c712 100644 --- a/indra/llcorehttp/httprequest.h +++ b/indra/llcorehttp/httprequest.h @@ -89,11 +89,9 @@ public: HttpRequest(); virtual ~HttpRequest(); -private: HttpRequest(const HttpRequest &) = delete; // Disallowed void operator=(const HttpRequest &) = delete; // Disallowed -public: typedef unsigned int policy_t; typedef unsigned int priority_t; diff --git a/indra/llcorehttp/httpresponse.h b/indra/llcorehttp/httpresponse.h index c430b6ddb1..05595b5d94 100644 --- a/indra/llcorehttp/httpresponse.h +++ b/indra/llcorehttp/httpresponse.h @@ -61,13 +61,13 @@ class HttpResponse : public LLCoreInt::RefCounted { public: HttpResponse(); - -protected: - virtual ~HttpResponse(); // Use release() HttpResponse(const HttpResponse &) = delete; // Not defined HttpResponse& operator=(const HttpResponse &) = delete; // Not defined - + +protected: + virtual ~HttpResponse(); // Use release() + public: /// Statistics for the HTTP struct TransferStats diff --git a/indra/llmessage/llcoproceduremanager.cpp b/indra/llmessage/llcoproceduremanager.cpp index e390654289..a7c613b665 100644 --- a/indra/llmessage/llcoproceduremanager.cpp +++ b/indra/llmessage/llcoproceduremanager.cpp @@ -50,11 +50,9 @@ public: LLCoprocedurePool(const std::string &name, size_t size); virtual ~LLCoprocedurePool(); -protected: LLCoprocedurePool(const LLCoprocedurePool&) = delete; LLCoprocedurePool& operator=(const LLCoprocedurePool&) = delete; -public: /// Places the coprocedure on the queue for processing. /// /// @param name Is used for debugging and should identify this coroutine. diff --git a/indra/llrender/llfontgl.h b/indra/llrender/llfontgl.h index 96f731a9f5..74f530e9c2 100644 --- a/indra/llrender/llfontgl.h +++ b/indra/llrender/llfontgl.h @@ -80,7 +80,8 @@ public: LLFontGL() = default; ~LLFontGL() = default; - + LLFontGL(const LLFontGL& source) = delete; + LLFontGL& operator=(const LLFontGL& source) = delete; void reset(); // Reset a font after GL cleanup. ONLY works on an already loaded font. @@ -216,9 +217,6 @@ private: friend class LLTextBillboard; friend class LLHUDText; - LLFontGL(const LLFontGL &source) = delete; - LLFontGL &operator=(const LLFontGL &source) = delete; - LLFontDescriptor mFontDescriptor; LLPointer<LLFontFreetype> mFontFreetype; diff --git a/indra/llui/llview.h b/indra/llui/llview.h index 35ce1e07ba..5780d0da3d 100644 --- a/indra/llui/llview.h +++ b/indra/llui/llview.h @@ -168,10 +168,11 @@ protected: LLView(const LLView::Params&); friend class LLUICtrlFactory; -private: - // widgets in general are not copyable - LLView(const LLView& other); public: + // widgets in general are not copyable + LLView(const LLView& other) = delete; + LLView& operator=(const LLView&) = delete; + //#if LL_DEBUG static BOOL sIsDrawing; //#endif diff --git a/indra/newview/lldesktopnotifications.h b/indra/newview/lldesktopnotifications.h index 038e5333da..c7f0defe0e 100644 --- a/indra/newview/lldesktopnotifications.h +++ b/indra/newview/lldesktopnotifications.h @@ -42,7 +42,6 @@ public: LLDesktopNotifications() {} virtual ~LLDesktopNotifications() {} -private: LLDesktopNotifications(LLDesktopNotifications const&) = delete; void operator=(LLDesktopNotifications const&) = delete; }; diff --git a/indra/newview/llfloaterpathfindingobjects.h b/indra/newview/llfloaterpathfindingobjects.h index 9215605cea..a7cb793c96 100644 --- a/indra/newview/llfloaterpathfindingobjects.h +++ b/indra/newview/llfloaterpathfindingobjects.h @@ -51,6 +51,9 @@ public: void onClose(bool pIsAppQuitting) override; void draw() final override; + LLFloaterPathfindingObjects(const LLFloaterPathfindingObjects& pOther) = delete; + LLFloaterPathfindingObjects& operator=(const LLFloaterPathfindingObjects&) = delete; + protected: friend class LLFloaterReg; @@ -105,8 +108,6 @@ protected: EMessagingState getMessagingState() const; private: - LLFloaterPathfindingObjects(const LLFloaterPathfindingObjects &pOther) = delete; - void setMessagingState(EMessagingState pMessagingState); void onRefreshObjectsClicked(); diff --git a/indra/newview/llgiveinventory.h b/indra/newview/llgiveinventory.h index fe567fe16a..67dd833a93 100644 --- a/indra/newview/llgiveinventory.h +++ b/indra/newview/llgiveinventory.h @@ -27,6 +27,8 @@ #ifndef LL_LLGIVEINVENTORY_H #define LL_LLGIVEINVENTORY_H +#include "lluuid.h" + class LLInventoryItem; class LLInventoryCategory; @@ -70,10 +72,10 @@ public: // give inventory item functionality static bool handleCopyProtectedItem(const LLSD& notification, const LLSD& response); -private: // this class is not intended to be instantiated. LLGiveInventory() = delete; +private: /** * logs "Inventory item offered" to IM */ diff --git a/indra/newview/llinventorymodel.h b/indra/newview/llinventorymodel.h index bc30a3adf0..5c1fe9d36e 100644 --- a/indra/newview/llinventorymodel.h +++ b/indra/newview/llinventorymodel.h @@ -88,11 +88,9 @@ public: FetchItemHttpHandler(const LLSD & request_sd); virtual ~FetchItemHttpHandler(); - protected: FetchItemHttpHandler(const FetchItemHttpHandler &) = delete; // Not defined FetchItemHttpHandler& operator=(const FetchItemHttpHandler &) = delete; // Not defined - public: void onCompleted(LLCore::HttpHandle handle, LLCore::HttpResponse * response) override; private: diff --git a/indra/newview/llinventorymodelbackgroundfetch.cpp b/indra/newview/llinventorymodelbackgroundfetch.cpp index 5b7adda77f..14b2b00477 100644 --- a/indra/newview/llinventorymodelbackgroundfetch.cpp +++ b/indra/newview/llinventorymodelbackgroundfetch.cpp @@ -120,7 +120,6 @@ public: LLInventoryModelBackgroundFetch::instance().incrFetchCount(-1); } -protected: BGItemHttpHandler(const BGItemHttpHandler &) = delete; // Not defined BGItemHttpHandler& operator=(const BGItemHttpHandler &) = delete; // Not defined }; @@ -153,7 +152,6 @@ public: LLInventoryModelBackgroundFetch::instance().incrFetchCount(-1); } -protected: BGFolderHttpHandler(const BGFolderHttpHandler &) = delete; // Not defined BGFolderHttpHandler& operator=(const BGFolderHttpHandler &) = delete; // Not defined diff --git a/indra/newview/lllandmarkactions.h b/indra/newview/lllandmarkactions.h index 8ac61d6af4..2524c97e8f 100644 --- a/indra/newview/lllandmarkactions.h +++ b/indra/newview/lllandmarkactions.h @@ -122,10 +122,10 @@ public: */ static void copySLURLtoClipboard(const LLUUID& landmarkInventoryItemID); -private: LLLandmarkActions() = delete; LLLandmarkActions(const LLLandmarkActions&) = delete; +private: static void onRegionResponseSLURL(slurl_callback_t cb, const LLVector3d& global_pos, bool escaped, diff --git a/indra/newview/llmeshrepository.cpp b/indra/newview/llmeshrepository.cpp index 4be064f4c6..b6769a2e77 100644 --- a/indra/newview/llmeshrepository.cpp +++ b/indra/newview/llmeshrepository.cpp @@ -585,10 +585,8 @@ public: mRequestedBytes(requested_bytes) {} - virtual ~LLMeshHandlerBase() - {} + virtual ~LLMeshHandlerBase() = default; -protected: LLMeshHandlerBase(const LLMeshHandlerBase &) = delete; // Not defined LLMeshHandlerBase& operator=(const LLMeshHandlerBase &) = delete; // Not defined @@ -621,11 +619,9 @@ public: } virtual ~LLMeshHeaderHandler(); -protected: LLMeshHeaderHandler(const LLMeshHeaderHandler &) = delete; // Not defined LLMeshHeaderHandler& operator=(const LLMeshHeaderHandler &) = delete; // Not defined -public: void processData(LLCore::BufferArray * body, S32 body_offset, U8 * data, S32 data_size) override; void processFailure(LLCore::HttpStatus status) override; }; @@ -647,11 +643,9 @@ public: } virtual ~LLMeshLODHandler(); -protected: LLMeshLODHandler(const LLMeshLODHandler &) = delete; // Not defined LLMeshLODHandler& operator=(const LLMeshLODHandler &) = delete; // Not defined -public: void processData(LLCore::BufferArray * body, S32 body_offset, U8 * data, S32 data_size) override; void processFailure(LLCore::HttpStatus status) override; @@ -673,11 +667,9 @@ public: {} virtual ~LLMeshSkinInfoHandler(); -protected: LLMeshSkinInfoHandler(const LLMeshSkinInfoHandler &) = delete; // Not defined LLMeshSkinInfoHandler& operator=(const LLMeshSkinInfoHandler &) = delete; // Not defined -public: void processData(LLCore::BufferArray * body, S32 body_offset, U8 * data, S32 data_size) override; void processFailure(LLCore::HttpStatus status) override; @@ -699,11 +691,9 @@ public: {} virtual ~LLMeshDecompositionHandler(); -protected: LLMeshDecompositionHandler(const LLMeshDecompositionHandler &) = delete; // Not defined LLMeshDecompositionHandler& operator=(const LLMeshDecompositionHandler &) = delete; // Not defined -public: void processData(LLCore::BufferArray * body, S32 body_offset, U8 * data, S32 data_size) override; void processFailure(LLCore::HttpStatus status) override; @@ -725,11 +715,9 @@ public: {} virtual ~LLMeshPhysicsShapeHandler(); -protected: LLMeshPhysicsShapeHandler(const LLMeshPhysicsShapeHandler &) = delete; // Not defined LLMeshPhysicsShapeHandler operator=(const LLMeshPhysicsShapeHandler &) = delete; // Not defined -public: void processData(LLCore::BufferArray * body, S32 body_offset, U8 * data, S32 data_size) override; void processFailure(LLCore::HttpStatus status) override; diff --git a/indra/newview/llnotificationlistitem.h b/indra/newview/llnotificationlistitem.h index 45fed93af8..d20199e60f 100644 --- a/indra/newview/llnotificationlistitem.h +++ b/indra/newview/llnotificationlistitem.h @@ -144,6 +144,9 @@ public: // LLGroupMgrObserver observer trigger void changed(LLGroupChange gc) override; + LLGroupNotificationListItem(const LLGroupNotificationListItem&) = delete; + LLGroupNotificationListItem& operator=(LLGroupNotificationListItem&) = delete; + friend class LLNotificationListItem; protected: LLGroupNotificationListItem(const Params& p); @@ -156,8 +159,6 @@ protected: LLTextBox* mGroupNameBoxExp; private: - LLGroupNotificationListItem(const LLGroupNotificationListItem&) = delete; - LLGroupNotificationListItem& operator=(LLGroupNotificationListItem&) = delete; void setGroupName(std::string name); bool updateFromCache(); @@ -172,11 +173,12 @@ public: bool showPopup() override { return false; } + LLGroupInviteNotificationListItem(const LLGroupInviteNotificationListItem&) = delete; + LLGroupInviteNotificationListItem& operator=(LLGroupInviteNotificationListItem&) = delete; + private: friend class LLNotificationListItem; LLGroupInviteNotificationListItem(const Params& p); - LLGroupInviteNotificationListItem(const LLGroupInviteNotificationListItem&) = delete; - LLGroupInviteNotificationListItem& operator=(LLGroupInviteNotificationListItem&) = delete; void setFee(S32 fee); @@ -200,11 +202,12 @@ public: bool showPopup() override { return false; } + LLGroupNoticeNotificationListItem(const LLGroupNoticeNotificationListItem&) = delete; + LLGroupNoticeNotificationListItem& operator=(LLGroupNoticeNotificationListItem&) = delete; + private: friend class LLNotificationListItem; LLGroupNoticeNotificationListItem(const Params& p); - LLGroupNoticeNotificationListItem(const LLGroupNoticeNotificationListItem&) = delete; - LLGroupNoticeNotificationListItem& operator=(LLGroupNoticeNotificationListItem&) = delete; void setSender(std::string sender); void onClickAttachment(); @@ -224,11 +227,13 @@ class LLTransactionNotificationListItem final : public LLNotificationListItem public: static std::set<std::string> getTypes(); BOOL postBuild() override; + + LLTransactionNotificationListItem(const LLTransactionNotificationListItem&) = delete; + LLTransactionNotificationListItem& operator=(LLTransactionNotificationListItem&) = delete; + private: friend class LLNotificationListItem; LLTransactionNotificationListItem(const Params& p); - LLTransactionNotificationListItem(const LLTransactionNotificationListItem&) = delete; - LLTransactionNotificationListItem& operator=(LLTransactionNotificationListItem&) = delete; LLAvatarIconCtrl* mAvatarIcon; LLAvatarIconCtrl* mAvatarIconExp; }; @@ -237,11 +242,14 @@ class LLSystemNotificationListItem final : public LLNotificationListItem { public: BOOL postBuild() override; + + LLSystemNotificationListItem(const LLSystemNotificationListItem &) = delete; + LLSystemNotificationListItem & operator=(LLSystemNotificationListItem &) = delete; + private: friend class LLNotificationListItem; LLSystemNotificationListItem(const Params& p); - LLSystemNotificationListItem(const LLSystemNotificationListItem &) = delete; - LLSystemNotificationListItem & operator=(LLSystemNotificationListItem &) = delete; + LLIconCtrl* mSystemNotificationIcon; LLIconCtrl* mSystemNotificationIconExp; bool mIsCaution; diff --git a/indra/newview/llselectmgr.h b/indra/newview/llselectmgr.h index dfba2b269a..3c307552a5 100644 --- a/indra/newview/llselectmgr.h +++ b/indra/newview/llselectmgr.h @@ -365,6 +365,8 @@ public: ESelectType getSelectType() const { return mSelectType; } + LLObjectSelection& operator=(const LLObjectSelection&) = delete; + private: void addNode(LLSelectNode *nodep); void addNodeAtEnd(LLSelectNode *nodep); @@ -374,8 +376,6 @@ private: void cleanupNodes(); list_t mList; - const LLObjectSelection& operator=(const LLObjectSelection&) = delete; - LLPointer<LLViewerObject> mPrimaryObject; std::map<LLPointer<LLViewerObject>, LLSelectNode*> mSelectNodeMap; ESelectType mSelectType; diff --git a/indra/newview/llviewertexture.h b/indra/newview/llviewertexture.h index 6076cd9bb8..8acefd8775 100644 --- a/indra/newview/llviewertexture.h +++ b/indra/newview/llviewertexture.h @@ -627,11 +627,9 @@ private: //just an interface class, do not create instance from this class. class LLViewerTextureManager { -private: - //make the constructor private to preclude creating instances from this class. +public: LLViewerTextureManager() = delete; -public: //texture pipeline tester static LLTexturePipelineTester* sTesterp ; -- GitLab