diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-05-26 21:04:57 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-05-26 21:04:57 +0000 |
commit | bf7f88413be3831a9372d323d02fc0335b9f9188 (patch) | |
tree | 516fdef9206245b40a14f99b4e3d9ef9289196e0 /src/gvcore/slideshow.cpp | |
parent | e238aa77b1fb3c2f55aef2ef2c91ce52166d2cc8 (diff) | |
download | gwenview-bf7f88413be3831a9372d323d02fc0335b9f9188.tar.gz gwenview-bf7f88413be3831a9372d323d02fc0335b9f9188.zip |
TQt4 port Gwenview
This enables compilation under both Qt3 and Qt4
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/gwenview@1233720 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'src/gvcore/slideshow.cpp')
-rw-r--r-- | src/gvcore/slideshow.cpp | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/src/gvcore/slideshow.cpp b/src/gvcore/slideshow.cpp index a22b619..aef2a9c 100644 --- a/src/gvcore/slideshow.cpp +++ b/src/gvcore/slideshow.cpp @@ -1,5 +1,5 @@ // vim: set tabstop=4 shiftwidth=4 noexpandtab -// kate: indent-mode csands; indent-width 4; replace-tabs-save off; replace-tabs off; replace-trailing-space-save off; space-indent off; tabs-indents on; tab-width 4; +// kate: indent-mode csands; indent-width 4; tqreplace-tabs-save off; tqreplace-tabs off; tqreplace-trailing-space-save off; space-indent off; tabs-indents on; tab-width 4; /* Gwenview - A simple image viewer for KDE Copyright 2000-2004 Aur�ien G�eau @@ -23,8 +23,8 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. // STL #include <algorithm> -// Qt -#include <qtimer.h> +// TQt +#include <tqtimer.h> // KDE #include <kconfig.h> @@ -51,11 +51,11 @@ namespace Gwenview { SlideShow::SlideShow(Document* document) : mDocument(document), mStarted(false), mPrefetch( NULL ) { - mTimer=new QTimer(this); - connect(mTimer, SIGNAL(timeout()), - this, SLOT(slotTimeout()) ); - connect(mDocument, SIGNAL(loaded(const KURL&)), - this, SLOT(slotLoaded()) ); + mTimer=new TQTimer(this); + connect(mTimer, TQT_SIGNAL(timeout()), + this, TQT_SLOT(slotTimeout()) ); + connect(mDocument, TQT_SIGNAL(loaded(const KURL&)), + this, TQT_SLOT(slotLoaded()) ); } SlideShow::~SlideShow() { @@ -82,12 +82,12 @@ int SlideShow::timerInterval() { void SlideShow::start(const KURL::List& urls) { mURLs.resize(urls.size()); - qCopy(urls.begin(), urls.end(), mURLs.begin()); + tqCopy(urls.begin(), urls.end(), mURLs.begin()); if (SlideShowConfig::random()) { std::random_shuffle(mURLs.begin(), mURLs.end()); } - mStartIt=qFind(mURLs.begin(), mURLs.end(), mDocument->url()); + mStartIt=tqFind(mURLs.begin(), mURLs.end(), mDocument->url()); if (mStartIt==mURLs.end()) { kdWarning() << k_funcinfo << "Current URL not found in list, aborting.\n"; return; @@ -111,8 +111,8 @@ void SlideShow::stop() { } -QValueVector<KURL>::ConstIterator SlideShow::findNextURL() const { - QValueVector<KURL>::ConstIterator it=qFind(mURLs.begin(), mURLs.end(), mDocument->url()); +TQValueVector<KURL>::ConstIterator SlideShow::findNextURL() const { + TQValueVector<KURL>::ConstIterator it=tqFind(mURLs.begin(), mURLs.end(), mDocument->url()); if (it==mURLs.end()) { kdWarning() << k_funcinfo << "Current URL not found in list. This should not happen.\n"; return it; @@ -143,7 +143,7 @@ void SlideShow::slotTimeout() { return; } - QValueVector<KURL>::ConstIterator it=findNextURL(); + TQValueVector<KURL>::ConstIterator it=findNextURL(); if (it==mURLs.end()) { stop(); return; @@ -162,7 +162,7 @@ void SlideShow::slotLoaded() { void SlideShow::prefetch() { LOG(""); - QValueVector<KURL>::ConstIterator it=findNextURL(); + TQValueVector<KURL>::ConstIterator it=findNextURL(); if (it==mURLs.end()) { return; } @@ -175,8 +175,8 @@ void SlideShow::prefetch() { if( !mPriorityURL.isEmpty()) Cache::instance()->setPriorityURL( mPriorityURL, false ); mPriorityURL = *it; Cache::instance()->setPriorityURL( mPriorityURL, true ); // make sure it will stay in the cache - connect( mPrefetch, SIGNAL( urlKindDetermined()), SLOT( slotUrlKindDetermined())); - connect( mPrefetch, SIGNAL( imageLoaded( bool )), SLOT( prefetchDone())); + connect( mPrefetch, TQT_SIGNAL( urlKindDetermined()), TQT_SLOT( slotUrlKindDetermined())); + connect( mPrefetch, TQT_SIGNAL( imageLoaded( bool )), TQT_SLOT( prefetchDone())); if (mPrefetch->urlKind()==MimeTypeUtils::KIND_FILE) { // Prefetch is already done, and this is not a raster image |