summaryrefslogtreecommitdiffstats
path: root/korganizer/calendarview.cpp
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2011-12-15 15:50:21 -0600
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2011-12-15 15:50:21 -0600
commit3ca10fd9a2dc631429d3b5d5c5e42a7d211d5a12 (patch)
tree89de88213bd261e4ccaade899ab2d6ec34b3a5a7 /korganizer/calendarview.cpp
parent1dad5f662a09dfc5cc041caffe0f674044a4dcec (diff)
downloadtdepim-3ca10fd9a2dc631429d3b5d5c5e42a7d211d5a12.tar.gz
tdepim-3ca10fd9a2dc631429d3b5d5c5e42a7d211d5a12.zip
Rename a number of old tq methods that are no longer tq specific
Diffstat (limited to 'korganizer/calendarview.cpp')
-rw-r--r--korganizer/calendarview.cpp96
1 files changed, 48 insertions, 48 deletions
diff --git a/korganizer/calendarview.cpp b/korganizer/calendarview.cpp
index 5b6d94928..b45b4ae01 100644
--- a/korganizer/calendarview.cpp
+++ b/korganizer/calendarview.cpp
@@ -93,14 +93,14 @@
#include <kdirwatch.h>
#include <tqapplication.h>
-#include <tqclipboard.h>
+#include <clipboard.h>
#include <tqcursor.h>
#include <tqmultilineedit.h>
#include <tqtimer.h>
#include <tqwidgetstack.h>
#include <tqptrlist.h>
#include <tqfile.h>
-#include <tqlayout.h>
+#include <layout.h>
#ifndef KORG_NOSPLITTER
#include <tqsplitter.h>
#endif
@@ -137,7 +137,7 @@ CalendarView::CalendarView( TQWidget *parent, const char *name )
TQBoxLayout *topLayout = new TQVBoxLayout( this );
#ifndef KORG_NOSPLITTER
- // create the main tqlayout frames.
+ // create the main layout frames.
mPanner = new TQSplitter( Qt::Horizontal, this,
"CalendarView::Panner" );
topLayout->addWidget( mPanner );
@@ -177,7 +177,7 @@ CalendarView::CalendarView( TQWidget *parent, const char *name )
mDateNavigatorContainer = new KDateNavigator( leftFrame, true,
"CalendarView::DateNavigator",
- TQDate::tqcurrentDate() );
+ TQDate::currentDate() );
mTodoList = new KOTodoView( CalendarNull::self(), leftFrame, "todolist" );
mEventViewer = new KOEventViewer ( CalendarNull::self(), leftFrame, "EventViewer" );
@@ -185,7 +185,7 @@ CalendarView::CalendarView( TQWidget *parent, const char *name )
TQWidget *rightBox = new TQWidget( mainBox );
TQBoxLayout *rightLayout = new TQVBoxLayout( rightBox );
- mNavigatorBar = new NavigatorBar( TQDate::tqcurrentDate(), rightBox );
+ mNavigatorBar = new NavigatorBar( TQDate::currentDate(), rightBox );
rightLayout->addWidget( mNavigatorBar );
mRightFrame = new TQWidgetStack( rightBox );
@@ -195,7 +195,7 @@ CalendarView::CalendarView( TQWidget *parent, const char *name )
if ( KOPrefs::instance()->mVerticalScreen ) {
// mTodoList->setFixedHeight( 60 );
- mTodoList->setFixedHeight( mDateNavigatorContainer->tqsizeHint().height() );
+ mTodoList->setFixedHeight( mDateNavigatorContainer->sizeHint().height() );
}
#endif
@@ -277,7 +277,7 @@ CalendarView::CalendarView( TQWidget *parent, const char *name )
KOGlobals::self()->
setHolidays( new KHolidays( KOPrefs::instance()->mHolidays ) );
- connect( TQApplication::tqclipboard(), TQT_SIGNAL( dataChanged() ),
+ connect( TQApplication::clipboard(), TQT_SIGNAL( dataChanged() ),
TQT_SLOT( checkClipboard() ) );
connect( mTodoList, TQT_SIGNAL( incidenceSelected( Incidence *,const TQDate & ) ),
@@ -387,7 +387,7 @@ TQDate CalendarView::activeDate( bool fallbackToToday )
// When all else fails, use the navigator start date, or today.
if ( fallbackToToday ) {
- return TQDate::tqcurrentDate();
+ return TQDate::currentDate();
} else {
return mDateNavigator->selectedDates().first();
}
@@ -487,7 +487,7 @@ bool CalendarView::openCalendar(const TQString& filename, bool merge)
// have become partially populated. Clear it out.
if ( !merge ) mCalendar->close();
- KMessageBox::error(this,i18n("Could not load calendar '%1'.").tqarg(filename));
+ KMessageBox::error(this,i18n("Could not load calendar '%1'.").arg(filename));
return false;
}
@@ -547,7 +547,7 @@ void CalendarView::readSettings()
TQValueList<int> sizes = config->readIntListEntry( "Separator1" );
if ( sizes.count() != 2 ) {
- sizes << mDateNavigatorContainer->tqminimumSizeHint().width();
+ sizes << mDateNavigatorContainer->minimumSizeHint().width();
sizes << 300;
}
mPanner->setSizes( sizes );
@@ -776,18 +776,18 @@ void CalendarView::incidenceChanged( Incidence *oldIncidence,
if ( todo->isCompleted() ||
modification == KOGlobals::COMPLETION_MODIFIED_WITH_RECURRENCE ) {
TQString timeStr = KGlobal::locale()->formatTime( TQTime::currentTime() );
- TQString description = i18n( "To-do completed: %1 (%2)" ).tqarg(
- newIncidence->summary() ).tqarg( timeStr );
+ TQString description = i18n( "To-do completed: %1 (%2)" ).arg(
+ newIncidence->summary() ).arg( timeStr );
- Journal::List journals = calendar()->journals( TQDate::tqcurrentDate() );
+ Journal::List journals = calendar()->journals( TQDate::currentDate() );
Journal *journal;
if ( journals.isEmpty() ) {
journal = new Journal();
- journal->setDtStart( TQDateTime::tqcurrentDateTime() );
+ journal->setDtStart( TQDateTime::currentDateTime() );
- TQString dateStr = KGlobal::locale()->formatDate( TQDate::tqcurrentDate() );
- journal->setSummary( i18n("Journal of %1").tqarg( dateStr ) );
+ TQString dateStr = KGlobal::locale()->formatDate( TQDate::currentDate() );
+ journal->setSummary( i18n("Journal of %1").arg( dateStr ) );
journal->setDescription( description );
//TODO: recorded to-dos should save into the standard resource always
@@ -844,7 +844,7 @@ void CalendarView::checkForFilteredChange( Incidence *incidence )
// user so that he isn't surprised if his new event doesn't show up
KMessageBox::information( this, i18n("The item \"%1\" is filtered by "
"your current filter rules, so it will be hidden and not "
- "appear in the view.").tqarg( incidence->summary() ),
+ "appear in the view.").arg( incidence->summary() ),
i18n("Filter Applied"), "ChangedIncidenceFiltered" );
}
}
@@ -901,7 +901,7 @@ void CalendarView::updateUnmanagedViews()
int CalendarView::msgItemDelete( Incidence *incidence )
{
return KMessageBox::warningContinueCancel(this,
- i18n("The item \"%1\" will be permanently deleted.").tqarg( incidence->summary() ),
+ i18n("The item \"%1\" will be permanently deleted.").arg( incidence->summary() ),
i18n("KOrganizer Confirmation"), KGuiItem(i18n("&Delete"),"editdelete"));
}
@@ -925,7 +925,7 @@ void CalendarView::edit_cut()
"Do you want to cut just this item and "
"make all its sub-to-dos independent, or "
"cut the to-do with all its sub-to-dos?"
- ).tqarg( incidence->summary() ),
+ ).arg( incidence->summary() ),
i18n("KOrganizer Confirmation"),
i18n("Cut Only This"),
i18n("Cut All"));
@@ -935,7 +935,7 @@ void CalendarView::edit_cut()
incidences.append( incidence );
makeChildrenIndependent( incidence );
} else if ( km == KMessageBox::No ) { // all
- // load incidence + tqchildren + grandtqchildren...
+ // load incidence + children + grandchildren...
getIncidenceHierarchy( incidence, incidences );
}
@@ -962,7 +962,7 @@ void CalendarView::edit_copy()
i18n("The item \"%1\" has sub-to-dos. "
"Do you want to copy just this item or "
"copy the to-do with all its sub-to-dos?"
- ).tqarg( incidence->summary() ),
+ ).arg( incidence->summary() ),
i18n("KOrganizer Confirmation"),
i18n("Copy Only This"),
i18n("Copy All"));
@@ -971,7 +971,7 @@ void CalendarView::edit_copy()
if ( km == KMessageBox::Yes ) { // only one
incidences.append( incidence );
} else if ( km == KMessageBox::No ) { // all
- // load incidence + tqchildren + grandtqchildren...
+ // load incidence + children + grandchildren...
getIncidenceHierarchy( incidence, incidences );
}
@@ -1248,7 +1248,7 @@ void CalendarView::newTodo( ResourceCalendar *res, const TQString &subRes )
todoEditor->setResource( res, subRes );
if ( mViewManager->currentView()->isEventView() ) {
dtDue.setDate( mDateNavigator->selectedDates().first() );
- TQDateTime dtDummy = TQDateTime::tqcurrentDateTime();
+ TQDateTime dtDummy = TQDateTime::currentDateTime();
mViewManager->currentView()->eventDurationHint( dtDue, dtDummy, allday );
todoEditor->setDates( dtDue, allday );
}
@@ -1585,7 +1585,7 @@ void CalendarView::schedule_publish(Incidence *incidence)
KMessageBox::information( this, i18n("The item information was successfully sent."),
i18n("Publishing"), "IncidencePublishSuccess" );
} else {
- KMessageBox::error( this, i18n("Unable to publish the item '%1'").tqarg( incidence->summary() ) );
+ KMessageBox::error( this, i18n("Unable to publish the item '%1'").arg( incidence->summary() ) );
}
}
delete publishdlg;
@@ -1661,7 +1661,7 @@ void CalendarView::schedule_forward( Incidence *incidence )
} else {
KMessageBox::error(
this,
- i18n( "Unable to forward the item '%1'" ).tqarg( incidence->summary() ),
+ i18n( "Unable to forward the item '%1'" ).arg( incidence->summary() ),
i18n( "Forwarding Error" ) );
}
}
@@ -1669,7 +1669,7 @@ void CalendarView::schedule_forward( Incidence *incidence )
void CalendarView::mailFreeBusy( int daysToPublish )
{
- TQDateTime start = TQDateTime::tqcurrentDateTime();
+ TQDateTime start = TQDateTime::currentDateTime();
TQDateTime end = start.addDays(daysToPublish);
FreeBusy *freebusy = new FreeBusy(mCalendar, start, end);
@@ -1727,16 +1727,16 @@ void CalendarView::schedule(Scheduler::Method method, Incidence *incidence)
if ( scheduler.performTransaction( incidence, method ) ) {
KMessageBox::information( this, i18n("The groupware message for item '%1'"
"was successfully sent.\nMethod: %2")
- .tqarg( incidence->summary() )
- .tqarg( Scheduler::methodName( method ) ),
+ .arg( incidence->summary() )
+ .arg( Scheduler::methodName( method ) ),
i18n("Sending Free/Busy"),
"FreeBusyPublishSuccess" );
} else {
KMessageBox::error( this, i18n("Groupware message sending failed. "
"%2 is request/reply/add/cancel/counter/etc.",
"Unable to send the item '%1'.\nMethod: %2")
- .tqarg( incidence->summary() )
- .tqarg( Scheduler::methodName( method ) ) );
+ .arg( incidence->summary() )
+ .arg( Scheduler::methodName( method ) ) );
}
}
@@ -1817,7 +1817,7 @@ void CalendarView::exportICalendar()
if ( TQFile( filename ).exists() ) {
if ( KMessageBox::No == KMessageBox::warningYesNo(
this,
- i18n( "Do you want to overwrite %1?").tqarg(filename) ) ) {
+ i18n( "Do you want to overwrite %1?").arg(filename) ) ) {
return;
}
}
@@ -1845,7 +1845,7 @@ void CalendarView::exportVCalendar()
if ( TQFile( filename ).exists() ) {
if ( KMessageBox::No == KMessageBox::warningYesNo(
this,
- i18n( "Do you want to overwrite %1?").tqarg(filename ) ) ) {
+ i18n( "Do you want to overwrite %1?").arg(filename ) ) ) {
return;
}
}
@@ -1865,7 +1865,7 @@ void CalendarView::eventUpdated(Incidence *)
void CalendarView::adaptNavigationUnits()
{
if (mViewManager->currentView()->isEventView()) {
- int days = mViewManager->currentView()->tqcurrentDateCount();
+ int days = mViewManager->currentView()->currentDateCount();
if (days == 1) {
emit changeNavStringPrev(i18n("&Previous Day"));
emit changeNavStringNext(i18n("&Next Day"));
@@ -1934,7 +1934,7 @@ void CalendarView::processIncidenceSelection( Incidence *incidence, const TQDate
void CalendarView::checkClipboard()
{
#ifndef KORG_NODND
- if (ICalDrag::canDecode(TQApplication::tqclipboard()->data())) {
+ if (ICalDrag::canDecode(TQApplication::clipboard()->data())) {
kdDebug(5850) << "CalendarView::checkClipboard() true" << endl;
emit pasteEnabled(true);
} else {
@@ -2334,7 +2334,7 @@ void CalendarView::deleteTodoIncidence ( Todo *todo, bool force )
"Do you want to delete just this item and "
"make all its sub-to-dos independent, or "
"delete the to-do with all its sub-to-dos?"
- ).tqarg( todo->summary() ),
+ ).arg( todo->summary() ),
i18n("KOrganizer Confirmation"),
i18n("Delete Only This"),
i18n("Delete All"));
@@ -2367,7 +2367,7 @@ void CalendarView::deleteIncidence(Incidence *incidence, bool force)
KMessageBox::information( this, i18n("The item \"%1\" is marked read-only "
"and cannot be deleted; it probably belongs to "
"a read-only calendar resource.")
- .tqarg(incidence->summary()),
+ .arg(incidence->summary()),
i18n("Removing not possible"),
"deleteReadOnlyIncidence" );
}
@@ -2377,7 +2377,7 @@ void CalendarView::deleteIncidence(Incidence *incidence, bool force)
CanDeleteIncidenceVisitor v;
// Let the visitor do special things for special incidence types.
- // e.g. todos with tqchildren cannot be deleted, so act(..) returns false
+ // e.g. todos with children cannot be deleted, so act(..) returns false
if ( !v.act( incidence, this ) )
return;
//If it is a todo, there are specific delete function
@@ -2397,15 +2397,15 @@ void CalendarView::deleteIncidence(Incidence *incidence, bool force)
km = KMessageBox::warningContinueCancel(this,
i18n("The calendar item \"%1\" recurs over multiple dates; "
"are you sure you want to delete it "
- "and all its recurrences?").tqarg( incidence->summary() ),
+ "and all its recurrences?").arg( incidence->summary() ),
i18n("KOrganizer Confirmation"), i18n("Delete All") );
} else {
km = KOMessageBox::fourBtnMsgBox( this, TQMessageBox::Warning,
i18n("The calendar item \"%1\" recurs over multiple dates. "
"Do you want to delete only the current one on %2, only all "
"future recurrences, or all its recurrences?" )
- .tqarg( incidence->summary() )
- .tqarg( KGlobal::locale()->formatDate(itemDate)),
+ .arg( incidence->summary() )
+ .arg( KGlobal::locale()->formatDate(itemDate)),
i18n("KOrganizer Confirmation"), i18n("Delete C&urrent"),
i18n("Delete &Future"),
i18n("Delete &All"));
@@ -2524,14 +2524,14 @@ void CalendarView::purgeCompleted()
if ( aTodo && !aTodo->relatedTo() )
rootTodos.append( aTodo );
}
- // now that we have a list of all root todos, check them and their tqchildren
+ // now that we have a list of all root todos, check them and their children
for ( it = rootTodos.begin(); it != rootTodos.end(); ++it ) {
purgeCompletedSubTodos( *it, allDeleted );
}
endMultiModify();
if ( !allDeleted ) {
KMessageBox::information( this, i18n("Unable to purge to-dos with "
- "uncompleted tqchildren."), i18n("Delete To-do"),
+ "uncompleted children."), i18n("Delete To-do"),
"UncompletedChildrenPurgeTodos" );
}
}
@@ -2577,7 +2577,7 @@ void CalendarView::addIncidenceOn( Incidence *incadd, const TQDate &dt )
{
if ( !incadd || !mChanger ) {
KMessageBox::sorry(this, i18n("Unable to copy the item to %1.")
- .tqarg( dt.toString() ), i18n("Copying Failed") );
+ .arg( dt.toString() ), i18n("Copying Failed") );
return;
}
Incidence *incidence = mCalendar->incidence( incadd->uid() );
@@ -2621,7 +2621,7 @@ void CalendarView::moveIncidenceTo( Incidence *incmove, const TQDate &dt )
{
if ( !incmove || !mChanger ) {
KMessageBox::sorry( this, i18n("Unable to move the item to %1.")
- .tqarg( dt.toString() ), i18n("Moving Failed") );
+ .arg( dt.toString() ), i18n("Moving Failed") );
return;
}
Incidence *incidence = mCalendar->incidence( incmove->uid() );
@@ -2794,16 +2794,16 @@ void CalendarView::selectWeek( const TQDate &date )
}
void CalendarView::getIncidenceHierarchy( Incidence *inc,
- Incidence::List &tqchildren )
+ Incidence::List &children )
{
// protecion against looping hierarchies
- if ( inc && !tqchildren.contains( inc ) ) {
+ if ( inc && !children.contains( inc ) ) {
Incidence::List::ConstIterator it;
Incidence::List immediateChildren = inc->relations();
for ( it = immediateChildren.constBegin(); it != immediateChildren.constEnd(); ++it ) {
- getIncidenceHierarchy( *it, tqchildren );
+ getIncidenceHierarchy( *it, children );
}
- tqchildren.append( inc );
+ children.append( inc );
}
}