diff options
author | Montel Laurent <laurent.montel@kdab.com> | 2014-11-28 11:40:30 +0100 |
---|---|---|
committer | Laurent Montel <laurent.montel@kdab.com> | 2014-12-01 15:32:28 +0100 |
commit | 022318b8baa9d1977c5a374995936615772253a8 (patch) | |
tree | 72ba5665a4eadfc28a339da36492e55149486e79 /examples | |
parent | 03f96de7bdd126acedb2b25770546df2d6fbc17d (diff) |
Add support for const'ref in SIGNAL/SLOT arguments
Change-Id: I526147fe51e1ca100de483a3a9feea8cebd5d8bf
Reviewed-by: Brett Stottlemyer <bstottle@ford.com>
Reviewed-by: Björn Breitmeyer <bjoern.breitmeyer@kdab.com>
Diffstat (limited to 'examples')
-rw-r--r-- | examples/RemoteObjects/TimeModel.rep | 4 | ||||
-rw-r--r-- | examples/RemoteObjects/server/TimeModel.cpp | 2 | ||||
-rw-r--r-- | examples/RemoteObjects/server/TimeModel.h | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/examples/RemoteObjects/TimeModel.rep b/examples/RemoteObjects/TimeModel.rep index 18d4262..893007a 100644 --- a/examples/RemoteObjects/TimeModel.rep +++ b/examples/RemoteObjects/TimeModel.rep @@ -7,8 +7,8 @@ class MinuteTimer PROP(int hour=1); PROP(int minute=51); SIGNAL(timeChanged()); - SIGNAL(timeChanged2(QTime t)); + SIGNAL(timeChanged2(const QTime &t)); SIGNAL(sendCustom(PresetInfo info)); SIGNAL(foo(QMap<QString, QString> foo)); - SLOT(SetTimeZone(int)); + SLOT(SetTimeZone(const int &)); }; diff --git a/examples/RemoteObjects/server/TimeModel.cpp b/examples/RemoteObjects/server/TimeModel.cpp index 1654a1a..0df9aa0 100644 --- a/examples/RemoteObjects/server/TimeModel.cpp +++ b/examples/RemoteObjects/server/TimeModel.cpp @@ -71,7 +71,7 @@ void MinuteTimer::timerEvent(QTimerEvent *) static PresetInfo bla(3, 93.9f, "Best Station"); emit sendCustom(bla); } -void MinuteTimer::SetTimeZone(int zn) +void MinuteTimer::SetTimeZone(const int &zn) { qDebug()<<"SetTimeZone"<<zn; if (zn != zone) diff --git a/examples/RemoteObjects/server/TimeModel.h b/examples/RemoteObjects/server/TimeModel.h index 67c87c0..61b2a58 100644 --- a/examples/RemoteObjects/server/TimeModel.h +++ b/examples/RemoteObjects/server/TimeModel.h @@ -50,7 +50,7 @@ public: virtual ~MinuteTimer(); public slots: - virtual void SetTimeZone(int zn); + virtual void SetTimeZone(const int &zn); protected: void timerEvent(QTimerEvent *); |