From 7be55ffa061c026e35e2d6a0effe1161ddb0d41f Mon Sep 17 00:00:00 2001 From: tpearson Date: Sat, 31 Jul 2010 19:53:50 +0000 Subject: Trinity Qt initial conversion git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdepim@1157655 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- korganizer/kowhatsnextview.cpp | 50 +++++++++++++++++++++--------------------- 1 file changed, 25 insertions(+), 25 deletions(-) (limited to 'korganizer/kowhatsnextview.cpp') diff --git a/korganizer/kowhatsnextview.cpp b/korganizer/kowhatsnextview.cpp index d4b6618aa..351972199 100644 --- a/korganizer/kowhatsnextview.cpp +++ b/korganizer/kowhatsnextview.cpp @@ -22,11 +22,11 @@ without including the source code for Qt in the source distribution. */ -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include #include #include @@ -44,7 +44,7 @@ using namespace KOrg; -void WhatsNextTextBrowser::setSource(const QString& n) +void WhatsNextTextBrowser::setSource(const TQString& n) { kdDebug(5850) << "WhatsNextTextBrowser::setSource(): " << n << endl; @@ -55,23 +55,23 @@ void WhatsNextTextBrowser::setSource(const QString& n) emit showIncidence(n); return; } else { - QTextBrowser::setSource(n); + TQTextBrowser::setSource(n); } } -KOWhatsNextView::KOWhatsNextView(Calendar *calendar, QWidget *parent, +KOWhatsNextView::KOWhatsNextView(Calendar *calendar, TQWidget *parent, const char *name) : KOrg::BaseView(calendar, parent, name) { -// QLabel *dateLabel = -// new QLabel(KGlobal::locale()->formatDate(QDate::currentDate()),this); +// TQLabel *dateLabel = +// new TQLabel(KGlobal::locale()->formatDate(TQDate::currentDate()),this); // dateLabel->setMargin(2); // dateLabel->setAlignment(AlignCenter); mView = new WhatsNextTextBrowser(this); - connect(mView,SIGNAL(showIncidence(const QString &)),SLOT(showIncidence(const QString &))); + connect(mView,TQT_SIGNAL(showIncidence(const TQString &)),TQT_SLOT(showIncidence(const TQString &))); - QBoxLayout *topLayout = new QVBoxLayout(this); + TQBoxLayout *topLayout = new TQVBoxLayout(this); // topLayout->addWidget(dateLabel); topLayout->addWidget(mView); } @@ -88,7 +88,7 @@ int KOWhatsNextView::currentDateCount() void KOWhatsNextView::updateView() { KIconLoader kil("kdepim"); - QString *ipath = new QString(); + TQString *ipath = new TQString(); kil.loadIcon("kdepim",KIcon::NoGroup,32,KIcon::DefaultState,ipath); mText = "\n"; @@ -111,7 +111,7 @@ void KOWhatsNextView::updateView() mText+="\n"; Event::List events; - for ( QDate date = mStartDate; date <= mEndDate; date = date.addDays( 1 ) ) + for ( TQDate date = mStartDate; date <= mEndDate; date = date.addDays( 1 ) ) events += calendar()->events(date, EventSortStartDate, SortDirectionAscending); if (events.count() > 0) { @@ -133,9 +133,9 @@ void KOWhatsNextView::updateView() // given time span. Recurrence *recur = ev->recurrence(); int duration = ev->dtStart().secsTo( ev->dtEnd() ); - QDateTime start = recur->getPreviousDateTime( - QDateTime( mStartDate, QTime() ) ); - QDateTime end = start.addSecs( duration ); + TQDateTime start = recur->getPreviousDateTime( + TQDateTime( mStartDate, TQTime() ) ); + TQDateTime end = start.addSecs( duration ); if ( end.date() >= mStartDate ) { appendEvent( ev, start, end ); } @@ -180,9 +180,9 @@ void KOWhatsNextView::updateView() mText += "\n"; } - QStringList myEmails( KOPrefs::instance()->allEmails() ); + TQStringList myEmails( KOPrefs::instance()->allEmails() ); int replies = 0; - events = calendar()->events( QDate::currentDate(), QDate(2975,12,6) ); + events = calendar()->events( TQDate::currentDate(), TQDate(2975,12,6) ); Event::List::ConstIterator it2; for( it2 = events.begin(); it2 != events.end(); ++it2 ) { Event *ev = *it2; @@ -237,7 +237,7 @@ void KOWhatsNextView::updateView() mView->setText(mText); } -void KOWhatsNextView::showDates( const QDate &start, const QDate &end ) +void KOWhatsNextView::showDates( const TQDate &start, const TQDate &end ) { mStartDate = start; mEndDate = end; @@ -261,8 +261,8 @@ void KOWhatsNextView::changeIncidenceDisplay(Incidence *, int action) } } -void KOWhatsNextView::appendEvent( Incidence *ev, const QDateTime &start, - const QDateTime &end ) +void KOWhatsNextView::appendEvent( Incidence *ev, const TQDateTime &start, + const TQDateTime &end ) { kdDebug(5850) << "KOWhatsNextView::appendEvent(): " << ev->uid() << endl; @@ -270,10 +270,10 @@ void KOWhatsNextView::appendEvent( Incidence *ev, const QDateTime &start, // if (!ev->doesFloat()) { if (ev->type()=="Event") { Event *event = static_cast(ev); - QDateTime starttime( start ); + TQDateTime starttime( start ); if ( !starttime.isValid() ) starttime = event->dtStart(); - QDateTime endtime( end ); + TQDateTime endtime( end ); if ( !endtime.isValid() ) endtime = starttime.addSecs( event->dtStart().secsTo( event->dtEnd() ) ); @@ -319,7 +319,7 @@ void KOWhatsNextView::appendTodo( Incidence *ev ) mText += "\n"; } -void KOWhatsNextView::showIncidence( const QString &uid ) +void KOWhatsNextView::showIncidence( const TQString &uid ) { kdDebug(5850) << "KOWhatsNextView::showIncidence(): " << uid << endl; Incidence *incidence = 0; -- cgit v1.2.1