summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJasem Mutlaq <mutlaqja@ikarustech.com>2016-10-19 09:52:04 (GMT)
committerJasem Mutlaq <mutlaqja@ikarustech.com>2016-10-19 09:52:04 (GMT)
commit60590ccec6ec1b592e904df5779b59defad29ddb (patch)
tree9ec932557e514bfc526ead65417c09d3383b4db5
parentf05f6fd325a22415c7e1caaa7a8e329a77f49177 (diff)
Update focus DBus function calls
-rw-r--r--kstars/ekos/scheduler/scheduler.cpp11
1 files changed, 4 insertions, 7 deletions
diff --git a/kstars/ekos/scheduler/scheduler.cpp b/kstars/ekos/scheduler/scheduler.cpp
index d46a69e..1109f46 100644
--- a/kstars/ekos/scheduler/scheduler.cpp
+++ b/kstars/ekos/scheduler/scheduler.cpp
@@ -3563,16 +3563,13 @@ void Scheduler::startSlew()
void Scheduler::startFocusing()
{
- // Set focus mode to auto (1). Check if autofocus is available
- QList<QVariant> focusMode;
- focusMode.append(1);
-
+ // Check if autofocus is supported
QDBusReply<bool> focusModeReply;
- focusModeReply = focusInterface->callWithArgumentList(QDBus::AutoDetect,"setFocusMode",focusMode);
+ focusModeReply = focusInterface->call(QDBus::AutoDetect,"canAutoFocus");
if ( focusModeReply.error().type() != QDBusError::NoError)
{
- appendLogText(i18n("setFocusMode DBUS error: %1", QDBusError::errorString(focusModeReply.error().type())));
+ appendLogText(i18n("canAutoFocus DBUS error: %1", QDBusError::errorString(focusModeReply.error().type())));
return;
}
@@ -3601,7 +3598,7 @@ void Scheduler::startFocusing()
// Set autostar & use subframe
QList<QVariant> autoStar;
autoStar.append(true);
- if ( (reply = focusInterface->callWithArgumentList(QDBus::AutoDetect,"setAutoFocusStar",autoStar)).type() == QDBusMessage::ErrorMessage)
+ if ( (reply = focusInterface->callWithArgumentList(QDBus::AutoDetect,"setAutoStarEnabled",autoStar)).type() == QDBusMessage::ErrorMessage)
{
appendLogText(i18n("setAutoFocusStar DBUS error: %1", reply.errorMessage()));
return;