From bf7f7b257a556da8c0e06b81264dbefb92435efe Mon Sep 17 00:00:00 2001 From: "Javier S. Pedro" Date: Sun, 7 Jul 2013 14:03:07 +0200 Subject: fix a few lv bugs --- liveview/liveview.cpp | 3 +-- liveview/liveviewplugin.cpp | 7 +++++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/liveview/liveview.cpp b/liveview/liveview.cpp index 754bf2f..06bd914 100644 --- a/liveview/liveview.cpp +++ b/liveview/liveview.cpp @@ -368,9 +368,8 @@ QByteArray LiveView::encodeImage(const QUrl& url) void LiveView::send(const Message &msg) { - Q_ASSERT(_connected); _sendingMsgs.enqueue(msg); - if (_waitingForAck == NoMessage) { + if (_connected && _waitingForAck == NoMessage) { sendMessageFromQueue(); } else { #if PROTOCOL_DEBUG diff --git a/liveview/liveviewplugin.cpp b/liveview/liveviewplugin.cpp index 1f34949..d1f7ad0 100644 --- a/liveview/liveviewplugin.cpp +++ b/liveview/liveviewplugin.cpp @@ -31,8 +31,11 @@ WatchScanner* LiveViewPlugin::getScanner(QObject *parent) QUrl LiveViewPlugin::getConfigQmlUrl(const QString &driver) { - Q_UNUSED(driver); - return QUrl(); + if (driver == "liveview") { + return QUrl::fromLocalFile(SOWATCH_QML_DIR "/liveview-config.qml"); + } else { + return QUrl(); + } } Watch* LiveViewPlugin::getWatch(const QString& driver, ConfigKey* settings, QObject *parent) -- cgit v1.2.3