[Kstars-devel] branches/kstars/summer/kstars/kstars/comast
Prakash Mohan
prak902000 at gmail.com
Mon Jul 27 06:58:27 CEST 2009
SVN commit 1002833 by prakash:
Moving the initializations to the writeBegin() function so that writeBegin can be direclty used to start writing the logs, instead of having to call the writeLog function.
Adding a function to return the final log string.
CCMAIL: kstars-devel at kde.org
M +3 -3 log.cpp
M +1 -0 log.h
--- branches/kstars/summer/kstars/kstars/comast/log.cpp #1002832:1002833
@@ -23,6 +23,9 @@
#include "kstarsdatetime.h"
void Comast::Log::writeBegin() {
+ ks = KStars::Instance();
+ output = "";
+ m_targetList = ks->observingList()->sessionList();
writer = new QXmlStreamWriter(&output);
writer->setAutoFormatting( true );
writer->writeStartDocument();
@@ -34,9 +37,6 @@
}
QString Comast::Log::writeLog( bool _native ) {
- ks = KStars::Instance();
- output = "";
- m_targetList = ks->observingList()->sessionList();
native = _native;
writeBegin();
if( native )
--- branches/kstars/summer/kstars/kstars/comast/log.h #1002832:1002833
@@ -106,6 +106,7 @@
QHash<QString, QTime> timeHash() { return TimeHash; }
KStarsDateTime dateTime() { return dt; }
GeoLocation* geoLocation() { return geo; }
+ inline QString writtenOutput() { return output; }
private:
QList<SkyObject *> m_targetList;
QList<Comast::Observer *> m_observerList;
More information about the Kstars-devel
mailing list