37 #include <tdelocale.h>
57 kdDebug() <<
"konsolekalendardelete.cpp::deleteEvent()" << endl;
62 Event *
event = m_variables->getCalendar()->event( m_variables->getUID() );
64 if ( m_variables->isDryRun() ) {
65 cout << i18n(
"Delete Event <Dry Run>:" ).local8Bit().data()
69 kdDebug() <<
"konsolekalendardelete.cpp:deleteEvent() : "
70 << m_variables->getUID().local8Bit()
73 if ( m_variables->isVerbose() ) {
74 cout << i18n(
"Delete Event <Verbose>:" ).local8Bit().data()
79 m_variables->getCalendar()->deleteEvent( event );
80 cout << i18n(
"Success: \"%1\" deleted" )
81 .arg( event->summary() ).local8Bit().data()
84 m_variables->getCalendar()->save();
89 kdDebug() <<
"konsolekalendardelete.cpp::deleteEvent() | Done " << endl;
93 void KonsoleKalendarDelete::printSpecs( Event *event )
95 cout << i18n(
" UID: %1" ).
96 arg( m_variables->getUID() ).local8Bit().data()
99 cout << i18n(
" What: %1" ).
100 arg( event->summary() ).local8Bit().data()
103 cout << i18n(
" Begin: %1" ).
104 arg( event->dtStart().toString( TQt::TextDate ) ).local8Bit().data()
107 cout << i18n(
" End: %1" ).
108 arg( event->dtEnd().toString( TQt::TextDate ) ).local8Bit().data()
111 cout << i18n(
" Desc: %1" ).
112 arg( event->description() ).local8Bit().data()
115 cout << i18n(
" Location: %1" ).
116 arg( event->location() ).local8Bit().data()
bool deleteEvent()
Delete the Event.
~KonsoleKalendarDelete()
Destructor.
KonsoleKalendarDelete(KonsoleKalendarVariables *vars)
Constructs a KonsoleKalendarDelete object from command line arguments.
This class provides all the variables for the program.
Provides the KonsoleKalendarDelete class definition.