summaryrefslogtreecommitdiffstats
path: root/kshowmail/kshowmaildoc.cpp
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2013-07-24 15:57:00 -0500
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2013-07-24 15:57:00 -0500
commitb888c7edb54e483ec0e3c2e2ce0eafd73acdcc65 (patch)
tree7ca76d42f66fb21ea08142de9a8d3bf16e597404 /kshowmail/kshowmaildoc.cpp
downloadkshowmail-b888c7edb54e483ec0e3c2e2ce0eafd73acdcc65.tar.gz
kshowmail-b888c7edb54e483ec0e3c2e2ce0eafd73acdcc65.zip
Initial import from kshowmail 3.3.1 sources
Diffstat (limited to 'kshowmail/kshowmaildoc.cpp')
-rw-r--r--kshowmail/kshowmaildoc.cpp81
1 files changed, 81 insertions, 0 deletions
diff --git a/kshowmail/kshowmaildoc.cpp b/kshowmail/kshowmaildoc.cpp
new file mode 100644
index 0000000..05516ac
--- /dev/null
+++ b/kshowmail/kshowmaildoc.cpp
@@ -0,0 +1,81 @@
+/***************************************************************************
+ kshowmaildoc.cpp - description
+ -------------------
+ begin : Fre Sep 28 23:29:54 CEST 2001
+ copyright : (C) 2001 by Eggert Ehmke
+ email : eggert.ehmke@berlin.de
+ ***************************************************************************/
+
+/***************************************************************************
+ * *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or *
+ * (at your option) any later version. *
+ * *
+ ***************************************************************************/
+
+// include files for Qt
+#include <qdir.h>
+#include <qwidget.h>
+
+// include files for KDE
+#include <klocale.h>
+#include <kmessagebox.h>
+#include <kio/job.h>
+#include <kio/netaccess.h>
+
+// application specific includes
+#include "kshowmaildoc.h"
+#include "kshowmail.h"
+#include "kshowmailview.h"
+
+KshowmailView *KshowmailDoc::pView = 0L;
+
+KshowmailDoc::KshowmailDoc(QWidget *parent, const char *name) : QObject(parent, name)
+{
+}
+
+KshowmailDoc::~KshowmailDoc()
+{
+}
+
+void KshowmailDoc::addView(KshowmailView *view)
+{
+ pView = view;
+}
+
+void KshowmailDoc::removeView(KshowmailView*)
+{
+ delete pView;
+}
+
+void KshowmailDoc::setURL(const KURL &url)
+{
+ doc_url=url;
+}
+
+const KURL& KshowmailDoc::URL() const
+{
+ return doc_url;
+}
+
+// this could be deleted; perhaps we build a tree view sometime ?
+void KshowmailDoc::slotUpdateAllViews(KshowmailView *sender)
+{
+ if(pView)
+ {
+ if(pView!=sender)
+ pView->repaint();
+ }
+}
+
+bool KshowmailDoc::newDocument()
+{
+ /////////////////////////////////////////////////
+ // TODO: Add your document initialization code here
+ /////////////////////////////////////////////////
+ doc_url.setFileName(i18n("Untitled"));
+
+ return true;
+}