From b2cb8fdee255ddabee15e102a80ee720378d901d Mon Sep 17 00:00:00 2001 From: Michele Calgaro Date: Wed, 17 Oct 2018 23:25:45 +0900 Subject: [PATCH] Removed obsolete Qt2's TQList/TQListIterator classes and replaced with TQt3's TQPtrList/TQPtrListIterator ones. Signed-off-by: Michele Calgaro --- qtinterface/interface_tqt3/tqlistiterator.cpp | 6 +++--- qtinterface/interface_tqt3/tqlistiterator.h | 12 ++++++------ qtinterface/tqt.h.cmake | 1 - 3 files changed, 9 insertions(+), 10 deletions(-) diff --git a/qtinterface/interface_tqt3/tqlistiterator.cpp b/qtinterface/interface_tqt3/tqlistiterator.cpp index 86255d0..ffc97ec 100644 --- a/qtinterface/interface_tqt3/tqlistiterator.cpp +++ b/qtinterface/interface_tqt3/tqlistiterator.cpp @@ -25,18 +25,18 @@ Boston, MA 02110-1301, USA. #ifdef USE_QT4 // template -// TQListIterator::TQListIterator(const QList &t) { +// TQPtrListIterator::TQPtrListIterator(const QList &t) { // index = 0; // list = t; // } // // template -// TQListIterator::~TQListIterator() { +// TQPtrListIterator::~TQPtrListIterator() { // // // } // template -// T TQListIterator::current() { +// T TQPtrListIterator::current() { // if ((index >= 0) && (index < list->size())) { // return list->at(index); // } diff --git a/qtinterface/interface_tqt3/tqlistiterator.h b/qtinterface/interface_tqt3/tqlistiterator.h index c4a0e60..fbe7c9d 100644 --- a/qtinterface/interface_tqt3/tqlistiterator.h +++ b/qtinterface/interface_tqt3/tqlistiterator.h @@ -26,7 +26,7 @@ Boston, MA 02110-1301, USA. #ifdef USE_QT4 -// Implement the TQListIterator class +// Implement the TQPtrListIterator class // For Qt4, this is a combination of the QList::iterator and QMutableListIterator classes, // with the constructor from QMutableListIterator used primarily @@ -34,13 +34,13 @@ Boston, MA 02110-1301, USA. #include template -//class TQListIterator : public QList::iterator -//class TQListIterator : public QMutableListIterator -class TQListIterator +//class TQPtrListIterator : public QList::iterator +//class TQPtrListIterator : public QMutableListIterator +class TQPtrListIterator { public: - inline TQListIterator(const QList &t) {index = 0; list = &t;} - inline ~TQListIterator() {} + inline TQPtrListIterator(const QList &t) {index = 0; list = &t;} + inline ~TQPtrListIterator() {} inline T current() { if ((index >= 0) && (index < list->size())) { diff --git a/qtinterface/tqt.h.cmake b/qtinterface/tqt.h.cmake index 69a7acc..9b2cbb5 100644 --- a/qtinterface/tqt.h.cmake +++ b/qtinterface/tqt.h.cmake @@ -575,7 +575,6 @@ Boston, MA 02110-1301, USA. #define TQLineEdit QLineEdit #define TQValidator QValidator #define TQListBox QListBox -#define TQList QList #define TQComboBoxData QComboBoxData #define TQComboTableItem QComboTableItem #define TQWheelEvent QWheelEvent