[Kst] branches/work/kst/kst1kde4/kst/src/datasources
Zongyi Zhang
freebody.kst at gmail.com
Tue Apr 13 20:17:47 CEST 2010
SVN commit 1114481 by zhang:
replace kconfig with qsettings
M +4 -4 fitsimage/fitsimage.cpp
M +1 -1 fitsimage/fitsimage.h
M +3 -3 frame/frame.cpp
M +1 -1 frame/frame.h
M +4 -4 indirect/indirect.cpp
M +1 -1 indirect/indirect.h
M +3 -3 lfiio/lfiio.cpp
M +1 -1 lfiio/lfiio.h
M +3 -3 wmap/wmap.cpp
M +1 -1 wmap/wmap.h
--- branches/work/kst/kst1kde4/kst/src/datasources/fitsimage/fitsimage.cpp #1114480:1114481
@@ -24,7 +24,7 @@
-FitsimageSource::FitsimageSource(KConfig *cfg, const QString& filename, const QString& type)
+FitsimageSource::FitsimageSource(QSettings *cfg, const QString& filename, const QString& type)
: KstDataSource(cfg, filename, type) {
_fptr = 0L;
if( type.isEmpty( ) || type == "FITS" ) {
@@ -279,7 +279,7 @@
extern "C" {
-KstDataSource *create_fitsimage(KConfig *cfg, const QString& filename, const QString& type) {
+KstDataSource *create_fitsimage(QSettings *cfg, const QString& filename, const QString& type) {
return new FitsimageSource(cfg, filename, type);
}
@@ -291,7 +291,7 @@
return rc;
}
-int understands_fitsimage(KConfig*, const QString& filename) {
+int understands_fitsimage(QSettings*, const QString& filename) {
fitsfile* ffits;
int status = 0;
@@ -315,7 +315,7 @@
}
-QStringList fieldList_fitsimage(KConfig*, const QString& filename, const QString& type, QString *typeSuggestion, bool *complete) {
+QStringList fieldList_fitsimage(QSettings*, const QString& filename, const QString& type, QString *typeSuggestion, bool *complete) {
Q_UNUSED(type)
QStringList fieldList;
--- branches/work/kst/kst1kde4/kst/src/datasources/fitsimage/fitsimage.h #1114480:1114481
@@ -24,7 +24,7 @@
class FitsimageSource : public KstDataSource {
public:
- FitsimageSource(KConfig *cfg, const QString& filename, const QString& type);
+ FitsimageSource(QSettings *cfg, const QString& filename, const QString& type);
~FitsimageSource();
bool init();
--- branches/work/kst/kst1kde4/kst/src/datasources/frame/frame.cpp #1114480:1114481
@@ -31,7 +31,7 @@
#include <unistd.h>
-FrameSource::FrameSource(KConfig *cfg, const QString& filename, const QString& type)
+FrameSource::FrameSource(QSettings *cfg, const QString& filename, const QString& type)
: KstDataSource(cfg, filename, type) {
_valid = init();
}
@@ -207,7 +207,7 @@
extern "C" {
-KstDataSource *create_frame(KConfig *cfg, const QString& filename, const QString& type) {
+KstDataSource *create_frame(QSettings *cfg, const QString& filename, const QString& type) {
return new FrameSource(cfg, filename, type);
}
@@ -217,7 +217,7 @@
return rc;
}
-int understands_frame(KConfig*, const QString& filename) {
+int understands_frame(QSettings*, const QString& filename) {
int err = 0;
CReadData(filename.toLatin1(), "INDEX",
0, 0, /* 1st sframe, 1st samp */
--- branches/work/kst/kst1kde4/kst/src/datasources/frame/frame.h #1114480:1114481
@@ -23,7 +23,7 @@
class FrameSource : public KstDataSource {
public:
- FrameSource(KConfig *cfg, const QString& filename, const QString& type);
+ FrameSource(QSettings *cfg, const QString& filename, const QString& type);
~FrameSource();
--- branches/work/kst/kst1kde4/kst/src/datasources/indirect/indirect.cpp #1114480:1114481
@@ -25,7 +25,7 @@
#include <qfileinfo.h>
-IndirectSource::IndirectSource(KConfig *cfg, const QString& filename, KstDataSourcePtr child)
+IndirectSource::IndirectSource(QSettings *cfg, const QString& filename, KstDataSourcePtr child)
: KstDataSource(cfg, filename, QString::null), _child(child) {
if (child) {
_valid = true;
@@ -123,7 +123,7 @@
extern "C" {
-KstDataSource *create_indirect(KConfig *cfg, const QString& filename, const QString& type) {
+KstDataSource *create_indirect(QSettings *cfg, const QString& filename, const QString& type) {
if (!type.isEmpty() && type != "Indirect") {
return 0L;
}
@@ -159,7 +159,7 @@
}
-int understands_indirect(KConfig*, const QString& filename) {
+int understands_indirect(QSettings*, const QString& filename) {
int percent = 50;
if (filename.endsWith(".cur")) { // Do we really have to do this?
@@ -192,7 +192,7 @@
}
-QStringList fieldList_indirect(KConfig *cfg, const QString& filename, const QString& type, QString *typeSuggestion, bool *complete) {
+QStringList fieldList_indirect(QSettings *cfg, const QString& filename, const QString& type, QString *typeSuggestion, bool *complete) {
if ((!type.isEmpty() && !provides_indirect().contains(type)) || !understands_indirect(cfg, filename)) {
return QStringList();
}
--- branches/work/kst/kst1kde4/kst/src/datasources/indirect/indirect.h #1114480:1114481
@@ -23,7 +23,7 @@
class IndirectSource : public KstDataSource {
public:
- IndirectSource(KConfig *cfg, const QString& filename, KstDataSourcePtr child);
+ IndirectSource(QSettings *cfg, const QString& filename, KstDataSourcePtr child);
~IndirectSource();
--- branches/work/kst/kst1kde4/kst/src/datasources/lfiio/lfiio.cpp #1114480:1114481
@@ -27,7 +27,7 @@
#define TIME_FIELD "TIME"
-LFIIOSource::LFIIOSource( KConfig *cfg, const QString& filename, const QString& type )
+LFIIOSource::LFIIOSource( QSettings *cfg, const QString& filename, const QString& type )
: KstDataSource( cfg, filename, type )
{
_first = true;
@@ -417,7 +417,7 @@
extern "C" {
- KstDataSource *create_lfiio( KConfig *cfg, const QString& filename, const QString& type )
+ KstDataSource *create_lfiio( QSettings *cfg, const QString& filename, const QString& type )
{
return new LFIIOSource( cfg, filename, type );
}
@@ -431,7 +431,7 @@
return rc;
}
- int understands_lfiio( KConfig*, const QString& filename )
+ int understands_lfiio( QSettings*, const QString& filename )
{
fitsfile* ffits;
int iStatus = 0;
--- branches/work/kst/kst1kde4/kst/src/datasources/lfiio/lfiio.h #1114480:1114481
@@ -23,7 +23,7 @@
class LFIIOSource : public KstDataSource {
public:
- LFIIOSource(KConfig *cfg, const QString& filename, const QString& type);
+ LFIIOSource(QSettings *cfg, const QString& filename, const QString& type);
~LFIIOSource();
bool initFile();
--- branches/work/kst/kst1kde4/kst/src/datasources/wmap/wmap.cpp #1114480:1114481
@@ -113,7 +113,7 @@
static int iNumDIHKDataHeaders = sizeof(DIHKDataHeaders)/sizeof(char*);
static int iNumLOSDataHeaders = sizeof(LOSDataHeaders)/sizeof(char*);
-WMAPSource::WMAPSource( KConfig *cfg, const QString& filename, const QString& type )
+WMAPSource::WMAPSource( QSettings *cfg, const QString& filename, const QString& type )
: KstDataSource( cfg, filename, type )
{
//_fields.setAutoDelete( TRUE ); obsolete in QMultiHash class
@@ -663,7 +663,7 @@
extern "C" {
- KstDataSource *create_wmap( KConfig *cfg, const QString& filename, const QString& type )
+ KstDataSource *create_wmap( QSettings *cfg, const QString& filename, const QString& type )
{
return new WMAPSource( cfg, filename, type );
}
@@ -677,7 +677,7 @@
return rc;
}
- int understands_wmap( KConfig*, const QString& filename )
+ int understands_wmap( QSettings*, const QString& filename )
{
fitsfile* ffits;
int iStatus = 0;
--- branches/work/kst/kst1kde4/kst/src/datasources/wmap/wmap.h #1114480:1114481
@@ -34,7 +34,7 @@
class WMAPSource : public KstDataSource {
public:
- WMAPSource(KConfig *cfg, const QString& filename, const QString& type);
+ WMAPSource(QSettings *cfg, const QString& filename, const QString& type);
~WMAPSource();
bool initFile();
More information about the Kst
mailing list