Changeset View
Changeset View
Standalone View
Standalone View
kstars/ekos/observatory/observatory.cpp
1 | /* Ekos Observatory Module | 1 | /* Ekos Observatory Module | ||
---|---|---|---|---|---|
2 | Copyright (C) Wolfgang Reissenberger <sterne-jaeger@t-online.de> | 2 | Copyright (C) Wolfgang Reissenberger <sterne-jaeger@t-online.de> | ||
3 | 3 | | |||
4 | This application is free software; you can redistribute it and/or | 4 | This application is free software; you can redistribute it and/or | ||
5 | modify it under the terms of the GNU General Public | 5 | modify it under the terms of the GNU General Public | ||
6 | License as published by the Free Software Foundation; either | 6 | License as published by the Free Software Foundation; either | ||
7 | version 2 of the License, or (at your option) any later version. | 7 | version 2 of the License, or (at your option) any later version. | ||
8 | */ | 8 | */ | ||
9 | 9 | | |||
10 | #include "kstarsdata.h" | ||||
11 | | ||||
10 | #include "observatory.h" | 12 | #include "observatory.h" | ||
11 | 13 | | |||
12 | #include "ekos_observatory_debug.h" | 14 | #include "ekos_observatory_debug.h" | ||
13 | 15 | | |||
14 | namespace Ekos | 16 | namespace Ekos | ||
15 | { | 17 | { | ||
16 | Observatory::Observatory() | 18 | Observatory::Observatory() | ||
17 | { | 19 | { | ||
▲ Show 20 Lines • Show All 608 Lines • ▼ Show 20 Line(s) | 624 | { | |||
626 | control.useWeather = useWeatherCB->isChecked(); | 628 | control.useWeather = useWeatherCB->isChecked(); | ||
627 | mObservatoryModel->setStatusControl(control); | 629 | mObservatoryModel->setStatusControl(control); | ||
628 | } | 630 | } | ||
629 | 631 | | |||
630 | 632 | | |||
631 | void Observatory::appendLogText(const QString &text) | 633 | void Observatory::appendLogText(const QString &text) | ||
632 | { | 634 | { | ||
633 | m_LogText.insert(0, i18nc("log entry; %1 is the date, %2 is the text", "%1 %2", | 635 | m_LogText.insert(0, i18nc("log entry; %1 is the date, %2 is the text", "%1 %2", | ||
634 | QDateTime::currentDateTime().toString("yyyy-MM-ddThh:mm:ss"), text)); | 636 | KStarsData::Instance()->lt().toString("yyyy-MM-ddThh:mm:ss"), text)); | ||
635 | 637 | | |||
636 | qCInfo(KSTARS_EKOS_OBSERVATORY) << text; | 638 | qCInfo(KSTARS_EKOS_OBSERVATORY) << text; | ||
637 | 639 | | |||
638 | emit newLog(text); | 640 | emit newLog(text); | ||
639 | } | 641 | } | ||
640 | 642 | | |||
641 | void Observatory::clearLog() | 643 | void Observatory::clearLog() | ||
642 | { | 644 | { | ||
643 | m_LogText.clear(); | 645 | m_LogText.clear(); | ||
644 | emit newLog(QString()); | 646 | emit newLog(QString()); | ||
645 | } | 647 | } | ||
646 | 648 | | |||
647 | } | 649 | } |