summaryrefslogtreecommitdiffstats
path: root/examples/bluetooth/btchat
diff options
context:
space:
mode:
Diffstat (limited to 'examples/bluetooth/btchat')
-rw-r--r--examples/bluetooth/btchat/chatserver.cpp2
-rw-r--r--examples/bluetooth/btchat/remoteselector.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/examples/bluetooth/btchat/chatserver.cpp b/examples/bluetooth/btchat/chatserver.cpp
index d65bb87e..2e6c314d 100644
--- a/examples/bluetooth/btchat/chatserver.cpp
+++ b/examples/bluetooth/btchat/chatserver.cpp
@@ -109,7 +109,7 @@ void ChatServer::sendMessage(const QString &message)
{
QByteArray text = message.toUtf8() + '\n';
- for (QBluetoothSocket *socket : qAsConst(clientSockets))
+ for (QBluetoothSocket *socket : std::as_const(clientSockets))
socket->write(text);
}
//! [sendMessage]
diff --git a/examples/bluetooth/btchat/remoteselector.cpp b/examples/bluetooth/btchat/remoteselector.cpp
index d0e91509..5872cec5 100644
--- a/examples/bluetooth/btchat/remoteselector.cpp
+++ b/examples/bluetooth/btchat/remoteselector.cpp
@@ -68,7 +68,7 @@ void RemoteSelector::serviceDiscovered(const QBluetoothServiceInfo &serviceInfo)
qDebug() << "\tRFCOMM server channel:" << serviceInfo.serverChannel();
#endif
const QBluetoothAddress address = serviceInfo.device().address();
- for (const QBluetoothServiceInfo &info : qAsConst(m_discoveredServices)) {
+ for (const QBluetoothServiceInfo &info : std::as_const(m_discoveredServices)) {
if (info.device().address() == address)
return;
}