summaryrefslogtreecommitdiffstats
path: root/examples/bluetooth/chat/chat.qml
diff options
context:
space:
mode:
Diffstat (limited to 'examples/bluetooth/chat/chat.qml')
-rw-r--r--examples/bluetooth/chat/chat.qml16
1 files changed, 12 insertions, 4 deletions
diff --git a/examples/bluetooth/chat/chat.qml b/examples/bluetooth/chat/chat.qml
index 6614d53c..ecac39fc 100644
--- a/examples/bluetooth/chat/chat.qml
+++ b/examples/bluetooth/chat/chat.qml
@@ -1,7 +1,7 @@
/****************************************************************************
**
-** Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies).
-** Contact: http://www.qt-project.org/legal
+** Copyright (C) 2015 The Qt Company Ltd.
+** Contact: http://www.qt.io/licensing/
**
** This file is part of the examples of the QtBluetooth module.
**
@@ -17,8 +17,8 @@
** notice, this list of conditions and the following disclaimer in
** the documentation and/or other materials provided with the
** distribution.
-** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
-** of its contributors may be used to endorse or promote products derived
+** * Neither the name of The Qt Company Ltd nor the names of its
+** contributors may be used to endorse or promote products derived
** from this software without specific prior written permission.
**
**
@@ -57,10 +57,18 @@ Item {
//! [BtDiscoveryModel-1]
onRunningChanged : {
if (!btModel.running && top.state == "begin" && !serviceFound) {
+ searchBox.animationRunning = false;
searchBox.appendText("\nNo service found. \n\nPlease start server\nand restart app.")
}
}
+ onErrorChanged: {
+ if (error != BluetoothDiscoveryModel.NoError && !btModel.running) {
+ searchBox.animationRunning = false
+ searchBox.appendText("\n\nDiscovery failed.\nPlease ensure Bluetooth is available.")
+ }
+ }
+
//! [BtDiscoveryModel-2]
onServiceDiscovered: {
if (serviceFound)