From 375a5d3a930a38d17fe101d4f395bbc2921c8b67 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Fri, 8 Aug 2008 02:37:56 +0000 Subject: [PATCH 1/1] add DECLARE_NO_COPY_TEMPLATE_CLASS git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@55018 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- include/wx/defs.h | 5 +++++ interface/wx/defs.h | 12 ++++++++++++ 2 files changed, 17 insertions(+) diff --git a/include/wx/defs.h b/include/wx/defs.h index 7c89f53ef7..56c4929537 100644 --- a/include/wx/defs.h +++ b/include/wx/defs.h @@ -3203,6 +3203,11 @@ typedef const void* WXWidget; classname(const classname&); \ classname& operator=(const classname&); +#define DECLARE_NO_COPY_TEMPLATE_CLASS(classname, arg) \ + private: \ + classname(const classname&); \ + classname& operator=(const classname&); + #define DECLARE_NO_ASSIGN_CLASS(classname) \ private: \ classname& operator=(const classname&); diff --git a/interface/wx/defs.h b/interface/wx/defs.h index b1b2c9536e..cdfa5d7ac5 100644 --- a/interface/wx/defs.h +++ b/interface/wx/defs.h @@ -290,6 +290,18 @@ enum wxPaperSize */ #define DECLARE_NO_COPY_CLASS(classname) +/** + Equivalent of DECLARE_NO_COPY_CLASS() for template classes. + + This macro can be used for template classes (with a single template + parameter) for the same purpose as DECLARE_NO_COPY_CLASS() is used with the + non-template classes. + + @param classname The name of the template class. + @param arg The name of the template parameter. + */ +#define DECLARE_NO_COPY_TEMPLATE_CLASS(classname, arg) + /** This macro can be used around a function declaration to generate warnings indicating that this function is deprecated (i.e. obsolete and planned to -- 2.47.2