From e7deefbb60882022459459a399e075d636632bd3 Mon Sep 17 00:00:00 2001 From: Keith Gardner Date: Thu, 4 Apr 2013 22:35:37 -0500 Subject: QIcon: Added a move constructor. Change-Id: Idedb935352bf8a0cd7d4293f7b8530d5b9b17616 Reviewed-by: Thiago Macieira --- src/gui/image/qicon.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/gui/image') diff --git a/src/gui/image/qicon.h b/src/gui/image/qicon.h index e81bea69d6..f1a78b508c 100644 --- a/src/gui/image/qicon.h +++ b/src/gui/image/qicon.h @@ -62,6 +62,10 @@ public: QIcon(); QIcon(const QPixmap &pixmap); QIcon(const QIcon &other); +#ifdef Q_COMPILER_RVALUE_REFS + QIcon(QIcon &&other) + :d(0) { qSwap(d, other.d); } +#endif explicit QIcon(const QString &fileName); // file or resource name explicit QIcon(QIconEngine *engine); ~QIcon(); -- cgit v1.2.3