summaryrefslogtreecommitdiffabout
path: root/korganizer/kowhatsnextview.cpp
Side-by-side diff
Diffstat (limited to 'korganizer/kowhatsnextview.cpp') (more/less context) (show whitespace changes)
-rw-r--r--korganizer/kowhatsnextview.cpp19
1 files changed, 18 insertions, 1 deletions
diff --git a/korganizer/kowhatsnextview.cpp b/korganizer/kowhatsnextview.cpp
index 5f14bfa..219f7c3 100644
--- a/korganizer/kowhatsnextview.cpp
+++ b/korganizer/kowhatsnextview.cpp
@@ -111,7 +111,23 @@ QPtrList<Incidence> KOWhatsNextView::selectedIncidences()
return eventList;
}
-
+void KOWhatsNextView::printMe()
+{
+#ifdef DESKTOP_VERSION
+ QPrinter printer;
+ if (!printer.setup() )
+ return;
+ QTextBrowser tb;
+ tb.setFixedSize( 600, 4000 );
+ QPainter::redirect ( tb.viewport(), &printer );
+ updateView();
+ tb.setText( mText );
+ tb.show();
+ tb.repaint();
+ tb.hide();
+ KMessageBox::information( this, i18n("Printing What's Next View!\n\nPlease close after\nprinting is finished."));
+#endif
+}
void KOWhatsNextView::printPreview(CalPrinter *calPrinter, const QDate &fd,
const QDate &td)
{
@@ -674,6 +690,7 @@ void KOWhatsNextView::setEventViewer(KOEventViewerDialog* v )
// TODO: Create this function in CalendarView and remove it from here
void KOWhatsNextView::showIncidence(const QString &uid)
{
+
if ( !mEventViewer ) {
qDebug("KOWhatsNextView::showIncidence::sorry, no event viewer set ");
return;