diff options
Diffstat (limited to 'kipi-plugins/galleryexport/galleries.cpp')
-rw-r--r-- | kipi-plugins/galleryexport/galleries.cpp | 70 |
1 files changed, 35 insertions, 35 deletions
diff --git a/kipi-plugins/galleryexport/galleries.cpp b/kipi-plugins/galleryexport/galleries.cpp index c38baff..eddaba5 100644 --- a/kipi-plugins/galleryexport/galleries.cpp +++ b/kipi-plugins/galleryexport/galleries.cpp @@ -16,9 +16,9 @@ * GNU General Public License for more details. * ============================================================ */ -#include <qstring.h> +#include <tqstring.h> -#include <qwidget.h> +#include <tqwidget.h> #include <kapplication.h> #include <kdebug.h> #include <kconfig.h> @@ -34,8 +34,8 @@ namespace KIPIGalleryExportPlugin { -Gallery::Gallery(const QString& name, const QString& url, - const QString& username, const QString& password, +Gallery::Gallery(const TQString& name, const TQString& url, + const TQString& username, const TQString& password, const unsigned int version, const unsigned int galleryId) : mName(name), @@ -53,41 +53,41 @@ Gallery::~Gallery() } -QString Gallery::name() const { return mName; } -QString Gallery::url() const { return mUrl; } -QString Gallery::username() const { return mUsername; } -QString Gallery::password() const { return mPassword; } +TQString Gallery::name() const { return mName; } +TQString Gallery::url() const { return mUrl; } +TQString Gallery::username() const { return mUsername; } +TQString Gallery::password() const { return mPassword; } unsigned int Gallery::version() const { return mVersion; } unsigned int Gallery::galleryId() const { return mGalleryId; } -void Gallery::setName(QString name) { mName = name; } -void Gallery::setUrl(QString url) { mUrl = url; } -void Gallery::setUsername(QString username) { mUsername = username; } -void Gallery::setPassword(QString password) { mPassword = password; } +void Gallery::setName(TQString name) { mName = name; } +void Gallery::setUrl(TQString url) { mUrl = url; } +void Gallery::setUsername(TQString username) { mUsername = username; } +void Gallery::setPassword(TQString password) { mPassword = password; } void Gallery::setVersion(unsigned int version) { mVersion = version; } void Gallery::setGalleryId(unsigned int galleryId) { mGalleryId = galleryId; } -QListViewItem* Gallery::asQListViewItem(QListView* pParent) +TQListViewItem* Gallery::asTQListViewItem(TQListView* pParent) { - QListViewItem* p_lvi = (QListViewItem*) new GalleryQListViewItem(this, pParent); + TQListViewItem* p_lvi = (TQListViewItem*) new GalleryTQListViewItem(this, pParent); return p_lvi; } -GalleryQListViewItem::GalleryQListViewItem(Gallery* pGallery, QListView* pParent) - : QListViewItem(pParent, pGallery->name(), pGallery->url(), pGallery->username()), +GalleryTQListViewItem::GalleryTQListViewItem(Gallery* pGallery, TQListView* pParent) + : TQListViewItem(pParent, pGallery->name(), pGallery->url(), pGallery->username()), mpGallery(pGallery) { } -Gallery* GalleryQListViewItem::GetGallery() +Gallery* GalleryTQListViewItem::GetGallery() { return mpGallery; } -void GalleryQListViewItem::Refresh() +void GalleryTQListViewItem::Refresh() { setText(0, mpGallery->name()); setText(1, mpGallery->url()); @@ -144,12 +144,12 @@ void Galleries::Load() // read config KConfig config("kipirc"); config.setGroup("GallerySync Settings"); - QValueList<int> gallery_ids = config.readIntListEntry("Galleries"); + TQValueList<int> gallery_ids = config.readIntListEntry("Galleries"); config.setGroup("GallerySync Galleries"); - QString name, url, username, password = ""; + TQString name, url, username, password = ""; int version; - for (QValueList<int>::Iterator it = gallery_ids.begin(); it != gallery_ids.end(); ++it) + for (TQValueList<int>::Iterator it = gallery_ids.begin(); it != gallery_ids.end(); ++it) { unsigned int gallery_id = (*it); @@ -157,12 +157,12 @@ void Galleries::Load() mMaxGalleryId = gallery_id; // Load the gallery with this id. - name = config.readEntry(QString("Name%1").arg(gallery_id)); - url = config.readEntry(QString("URL%1").arg(gallery_id)); - username = config.readEntry(QString("Username%1").arg(gallery_id)); - version = config.readNumEntry(QString("Version%1").arg(gallery_id)); + name = config.readEntry(TQString("Name%1").tqarg(gallery_id)); + url = config.readEntry(TQString("URL%1").tqarg(gallery_id)); + username = config.readEntry(TQString("Username%1").tqarg(gallery_id)); + version = config.readNumEntry(TQString("Version%1").tqarg(gallery_id)); if (bln_use_wallet) - mpWallet->readPassword(QString("Password%1").arg(gallery_id), password); + mpWallet->readPassword(TQString("Password%1").tqarg(gallery_id), password); Gallery* p_gallery = new Gallery(name, url, username, password, version, gallery_id); mGalleries.append(p_gallery); @@ -187,7 +187,7 @@ void Galleries::Remove(Gallery* pGallery) void Galleries::Save() { - QValueList<int> gallery_ids; + TQValueList<int> gallery_ids; KConfig config("kipirc"); config.deleteGroup("GallerySync Galleries"); config.setGroup("GallerySync Galleries"); @@ -217,23 +217,23 @@ void Galleries::Save() unsigned int gallery_id = p_gallery->galleryId(); gallery_ids.append(gallery_id); - config.writeEntry(QString("Name%1").arg(gallery_id), p_gallery->name()); - config.writeEntry(QString("URL%1").arg(gallery_id), p_gallery->url()); - config.writeEntry(QString("Username%1").arg(gallery_id), p_gallery->username()); - config.writeEntry(QString("Version%1").arg(gallery_id), p_gallery->version()); + config.writeEntry(TQString("Name%1").tqarg(gallery_id), p_gallery->name()); + config.writeEntry(TQString("URL%1").tqarg(gallery_id), p_gallery->url()); + config.writeEntry(TQString("Username%1").tqarg(gallery_id), p_gallery->username()); + config.writeEntry(TQString("Version%1").tqarg(gallery_id), p_gallery->version()); if (bln_use_wallet) - mpWallet->writePassword(QString("Password%1").arg(gallery_id), p_gallery->password()); + mpWallet->writePassword(TQString("Password%1").tqarg(gallery_id), p_gallery->password()); } config.setGroup("GallerySync Settings"); config.writeEntry("Galleries", gallery_ids); } -QListView* Galleries::asQListView(QWidget* pParent) +TQListView* Galleries::asTQListView(TQWidget* pParent) { Load(); - QListView* p_lv = new QListView (pParent); + TQListView* p_lv = new TQListView (pParent); p_lv->addColumn(i18n("Gallery Name")); p_lv->addColumn(i18n("URL")); p_lv->addColumn(i18n("User")); @@ -241,7 +241,7 @@ QListView* Galleries::asQListView(QWidget* pParent) for (GalleryPtrList::iterator it = mGalleries.begin(); it != mGalleries.end(); ++it) { - (*it)->asQListViewItem(p_lv); + (*it)->asTQListViewItem(p_lv); } return p_lv; |