summaryrefslogtreecommitdiffstats
path: root/qtools
diff options
context:
space:
mode:
Diffstat (limited to 'qtools')
-rw-r--r--qtools/qcstringlist.h4
-rw-r--r--qtools/qstring.h15
-rw-r--r--qtools/qvaluelist.h16
3 files changed, 30 insertions, 5 deletions
diff --git a/qtools/qcstringlist.h b/qtools/qcstringlist.h
index 604a196..7ffd4d2 100644
--- a/qtools/qcstringlist.h
+++ b/qtools/qcstringlist.h
@@ -29,6 +29,10 @@ public:
QCStringList( const QValueList<QCString>& l ) : QValueList<QCString>(l) { }
QCStringList( const QCString& i ) { append(i); }
QCStringList( const char* i ) { append(i); }
+ QCStringList &operator=(const QCStringList &l)
+ {
+ return static_cast<QCStringList&>(QValueList<QCString>::operator=(l));
+ }
static QCStringList fromStrList(const QStrList&);
diff --git a/qtools/qstring.h b/qtools/qstring.h
index 293768f..ed56d7f 100644
--- a/qtools/qstring.h
+++ b/qtools/qstring.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+**
**
** Definition of the QString class, and related Unicode
** functions.
@@ -64,6 +64,7 @@ public:
QChar( short rc );
QChar( uint rc );
QChar( int rc );
+ QChar &operator=(const QChar &c);
QT_STATIC_CONST QChar null; // 0000
QT_STATIC_CONST QChar replacement; // FFFD
@@ -266,6 +267,15 @@ inline QChar::QChar( int rc )
#endif
}
+inline QChar &QChar::operator=(const QChar &c)
+{
+ rw = c.rw;
+ cl = c.cl;
+#ifdef QT_QSTRING_UCS_4
+ grp = 0;
+#endif
+ return *this;
+}
inline int operator==( char ch, QChar c )
{
@@ -409,7 +419,7 @@ public:
inline QString(const Null &): d(shared_null) { d->ref(); }
inline QString &operator=(const Null &) { *this = QString(); return *this; }
inline bool isNull() const { return d == shared_null; }
-
+
bool isEmpty() const;
uint length() const;
void truncate( uint pos );
@@ -603,6 +613,7 @@ class Q_EXPORT QCharRef {
QString& s;
uint p;
QCharRef(QString* str, uint pos) : s(*str), p(pos) { }
+ QCharRef(const QCharRef &ref) : s(ref.s), p(ref.p) { }
public:
// Most QChar operations repeated here...
diff --git a/qtools/qvaluelist.h b/qtools/qvaluelist.h
index eb827fe..8885bea 100644
--- a/qtools/qvaluelist.h
+++ b/qtools/qvaluelist.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+**
**
** Definition of QValueList class
**
@@ -50,7 +50,7 @@ public:
QValueListNode( const T& t ) : data( t ) { }
QValueListNode() { }
#if defined(Q_TEMPLATEDLL)
- // Workaround MS bug in memory de/allocation in DLL vs. EXE
+ // Workaround MS bug in memory de/allocation in DLL vs. EXE
virtual ~QValueListNode() { }
#endif
@@ -79,6 +79,11 @@ class Q_EXPORT QValueListIterator
QValueListIterator() : node( 0 ) {}
QValueListIterator( NodePtr p ) : node( p ) {}
QValueListIterator( const QValueListIterator<T>& it ) : node( it.node ) {}
+ QValueListIterator &operator=(const QValueListIterator &it)
+ {
+ node = it.node;
+ return *this;
+ }
bool operator==( const QValueListIterator<T>& it ) const { return node == it.node; }
bool operator!=( const QValueListIterator<T>& it ) const { return node != it.node; }
@@ -132,6 +137,11 @@ class Q_EXPORT QValueListConstIterator
QValueListConstIterator( NodePtr p ) : node( p ) {}
QValueListConstIterator( const QValueListConstIterator<T>& it ) : node( it.node ) {}
QValueListConstIterator( const QValueListIterator<T>& it ) : node( it.node ) {}
+ QValueListConstIterator &operator=(const QValueListConstIterator &it)
+ {
+ node = it.node;
+ return *this;
+ }
bool operator==( const QValueListConstIterator<T>& it ) const { return node == it.node; }
bool operator!=( const QValueListConstIterator<T>& it ) const { return node != it.node; }
@@ -195,7 +205,7 @@ public:
}
#if defined(Q_TEMPLATEDLL)
- // Workaround MS bug in memory de/allocation in DLL vs. EXE
+ // Workaround MS bug in memory de/allocation in DLL vs. EXE
virtual
#endif
~QValueListPrivate() {