[Kst] Re: branches/work/kst/portto4/kst/src/libkst
Barth Netterfield
netterfield at astro.utoronto.ca
Thu Nov 18 00:54:16 CET 2010
you beat me to it :-)
On Thu, Nov 18, 2010 at 12:26 PM, Peter Kümmel <syntheticpp at gmx.net> wrote:
> SVN commit 1198241 by kuemmel:
>
> assignment does not work after _file becomes d._file
> (public members are evil)
>
> M +2 -2 datamatrix.cpp
> M +4 -0 dataprimitive.cpp
> M +1 -0 dataprimitive.h
> M +2 -2 datascalar.cpp
> M +2 -2 datastring.cpp
> M +2 -2 datavector.cpp
>
>
> --- branches/work/kst/portto4/kst/src/libkst/datamatrix.cpp #1198240:1198241
> @@ -548,7 +548,7 @@
> _reqYStart = reqYStart;
> _reqNX = reqNX;
> _reqNY = reqNY;
> - _dp->dataSource() = in_file;
> + _dp->setDataSource(in_file);
> _field = field;
> _doAve = doAve;
> _doSkip = doSkip;
> @@ -625,7 +625,7 @@
> if (!in_file) {
> Debug::self()->log(i18n("Data file for vector %1 was not opened.", Name()), Debug::Warning);
> }
> - _dp->dataSource() = in_file;
> + _dp->setDataSource(in_file);
> if (_dp->dataSource()) {
> _dp->dataSource()->writeLock();
> }
> --- branches/work/kst/portto4/kst/src/libkst/dataprimitive.cpp #1198240:1198241
> @@ -150,4 +150,8 @@
> return d._file;
> }
>
> +void DataPrimitive::setDataSource(const DataSourcePtr& file) {
> + d._file = file;
> }
> +
> +}
> --- branches/work/kst/portto4/kst/src/libkst/dataprimitive.h #1198240:1198241
> @@ -57,6 +57,7 @@
>
> /** the data source */
> DataSourcePtr dataSource() const;
> + void setDataSource(const DataSourcePtr&);
>
> /** change the datasource */
> virtual void changeFile(DataSourcePtr file);
> --- branches/work/kst/portto4/kst/src/libkst/datascalar.cpp #1198240:1198241
> @@ -84,7 +84,7 @@
> Q_ASSERT(myLockStatus() == KstRWLock::WRITELOCKED);
>
> _dp->_field = in_field;
> - _dp->dataSource() = in_file;
> + _dp->setDataSource(in_file);
> }
>
> void DataScalar::changeFile(DataSourcePtr in_file) {
> @@ -93,7 +93,7 @@
> if (!in_file) {
> Debug::self()->log(i18n("Data file for scalar %1 was not opened.", Name()), Debug::Warning);
> }
> - _dp->dataSource() = in_file;
> + _dp->setDataSource(in_file);
> }
>
>
> --- branches/work/kst/portto4/kst/src/libkst/datastring.cpp #1198240:1198241
> @@ -86,7 +86,7 @@
> Q_ASSERT(myLockStatus() == KstRWLock::WRITELOCKED);
>
> _dp->_field = in_field;
> - _dp->dataSource() = in_file;
> + _dp->setDataSource(in_file);
> }
>
> void DataString::changeFile(DataSourcePtr in_file) {
> @@ -95,7 +95,7 @@
> if (!in_file) {
> Debug::self()->log(i18n("Data file for string %1 was not opened.", Name()), Debug::Warning);
> }
> - _dp->dataSource() = in_file;
> + _dp->setDataSource(in_file);
> }
>
>
> --- branches/work/kst/portto4/kst/src/libkst/datavector.cpp #1198240:1198241
> @@ -127,7 +127,7 @@
> }
>
> _dontUseSkipAccel = false;
> - _dp->dataSource() = in_file;
> + _dp->setDataSource(in_file);
> ReqF0 = in_f0;
> ReqNF = in_n;
> _dp->_field = in_field;
> @@ -168,7 +168,7 @@
> if (!in_file) {
> Debug::self()->log(i18n("Data file for vector %1 was not opened.", Name()), Debug::Warning);
> }
> - _dp->dataSource() = in_file;
> + _dp->setDataSource(in_file);
> if (_dp->dataSource()) {
> _dp->dataSource()->writeLock();
> }
> _______________________________________________
> Kst mailing list
> Kst at kde.org
> https://mail.kde.org/mailman/listinfo/kst
>
--
C. Barth Netterfield
University of Toronto
416-845-0946
More information about the Kst
mailing list