Commit f73e3669 authored by Thomas Haller's avatar Thomas Haller

examples: fix qt demo to work without STL support

The function toStdString() is only available when QT was
compiled with STL support. The configure script does
not check STL support and might build the QT examples
even if toStdString() is not available.

Fix this, by not using the function.

https://bugzilla.gnome.org/show_bug.cgi?id=727608Signed-off-by: Thomas Haller's avatarThomas Haller <thaller@redhat.com>
parent b25c227e
......@@ -51,13 +51,13 @@ class NMWatcher: public QObject {
void NMWatcher::serviceRegistered(const QString& name)
{
std::cout << "Name '" << name.toStdString() << "' registered"
std::cout << "Name '" << name.constData() << "' registered"
<< " => NM is running" << std::endl;
}
void NMWatcher::serviceUnregistered(const QString& name)
{
std::cout << "Name '" << name.toStdString() << "' unregistered"
std::cout << "Name '" << name.constData() << "' unregistered"
<< " => NM is not running" << std::endl;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment