summaryrefslogtreecommitdiffstats
path: root/src/widgets/kernel/qicon.cpp
diff options
context:
space:
mode:
authorJędrzej Nowacki <jedrzej.nowacki@nokia.com>2012-01-04 14:14:08 +0100
committerQt by Nokia <qt-info@nokia.com>2012-01-10 01:25:18 +0100
commit18617f2824af67a690ade336f5d27f09752c7206 (patch)
treea0b1802f39344a5e334d7385d4f2ef6863ed6ee3 /src/widgets/kernel/qicon.cpp
parentb03fa845a72ce0f4e0785c6ebeb430ded970426b (diff)
Implement QDebug stream operators for builtin classes
QDebug stream operator was added for: QPixmap, QImage, QUuid, QBitArray, QLocale, QRegExp, QCursor, QPalette, QTextFormat, QTextLength, QIcon and QSizePolicy Change-Id: Ibcf5c9b599ba322d53cb106d8e5e157427ebe757 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com> Reviewed-by: Denis Dzyubenko <denis.dzyubenko@nokia.com>
Diffstat (limited to 'src/widgets/kernel/qicon.cpp')
-rw-r--r--src/widgets/kernel/qicon.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/widgets/kernel/qicon.cpp b/src/widgets/kernel/qicon.cpp
index 1b1b490d2b..185542420e 100644
--- a/src/widgets/kernel/qicon.cpp
+++ b/src/widgets/kernel/qicon.cpp
@@ -1161,6 +1161,14 @@ QDataStream &operator>>(QDataStream &s, QIcon &icon)
#endif //QT_NO_DATASTREAM
+#ifndef QT_NO_DEBUG_STREAM
+QDebug operator<<(QDebug dbg, const QIcon &i)
+{
+ dbg.nospace() << "QIcon(" << i.name() << ')';
+ return dbg.space();
+}
+#endif
+
/*!
\fn DataPtr &QIcon::data_ptr()
\internal