summaryrefslogtreecommitdiffstats
path: root/quanta/parts/preview/whtmlpart.h
diff options
context:
space:
mode:
authortoma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2009-11-25 17:56:58 +0000
committertoma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2009-11-25 17:56:58 +0000
commite9ae80694875f869892f13f4fcaf1170a00dea41 (patch)
treeaa2f8d8a217e2d376224c8d46b7397b68d35de2d /quanta/parts/preview/whtmlpart.h
downloadtdewebdev-e9ae80694875f869892f13f4fcaf1170a00dea41.tar.gz
tdewebdev-e9ae80694875f869892f13f4fcaf1170a00dea41.zip
Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features.
BUG:215923 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdewebdev@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'quanta/parts/preview/whtmlpart.h')
-rw-r--r--quanta/parts/preview/whtmlpart.h76
1 files changed, 76 insertions, 0 deletions
diff --git a/quanta/parts/preview/whtmlpart.h b/quanta/parts/preview/whtmlpart.h
new file mode 100644
index 00000000..1c0c83c0
--- /dev/null
+++ b/quanta/parts/preview/whtmlpart.h
@@ -0,0 +1,76 @@
+/***************************************************************************
+ whtmlpart.h - description
+ -------------------
+ begin : Fri Aug 18 2000
+ copyright : (C) 2000 by Dmitry Poplavsky & Alexander Yakovlev & Eric Laffoon <pdima@users.sourceforge.net,yshurik@linuxfan.com,sequitur@easystreet.com>
+ (C) 2002, 2004, 2005 Andras Mantia <amantia@kde.org>
+ ***************************************************************************/
+
+/***************************************************************************
+ * *
+ * 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. *
+ * *
+ ***************************************************************************/
+
+#ifndef WHTMLPART_H
+#define WHTMLPART_H
+
+#include <qstrlist.h>
+
+#include <khtml_part.h>
+
+class KPopupMenu;
+/**
+ *@author Dmitry Poplavsky & Alexander Yakovlev & Eric Laffoon
+ */
+
+class WHTMLPart : public KHTMLPart {
+ Q_OBJECT
+public:
+ WHTMLPart(QWidget *parentWidget = 0, const char *widgetname = 0, bool enableViewSource = false,
+ QObject *parent = 0, const char *name = 0, GUIProfile prof = DefaultGUI );
+ virtual ~WHTMLPart();
+
+ /** Specify the URL where the preview was started */
+ void setPreviewedURL(const KURL &url);
+ bool backEnable();
+ bool forwardEnable();
+ virtual bool openURL(const KURL &url);
+
+public slots:
+
+/** back(), forward() - navigation, using history.
+ */
+ void forward();
+ void back();
+ void popupMenu(const QString &url, const QPoint &point);
+ void slotViewSource();
+
+ void addToHistory(const QString &url);
+ virtual bool eventFilter(QObject *watched, QEvent *e);
+
+signals:
+ void updateStatus( bool back, bool forward );
+ void previewHasFocus(bool focus);
+ void showPreview(bool show);
+ void openFile(const KURL&, const QString&, bool);
+
+protected:
+ virtual void urlSelected( const QString &url, int button, int state, const QString &_target, KParts::URLArgs args = KParts::URLArgs());
+ virtual KParts::ReadOnlyPart *createPart( QWidget *parentWidget, const char *widgetName,
+ QObject *parent, const char *name,
+ const QString &mimetype, QString &serviceName,
+ QStringList &serviceTypes, const QStringList &params);
+
+private:
+ KURL m_previewedURL;
+ KPopupMenu *m_contextMenu;
+ QStrList history;
+ unsigned int hpos;
+ bool m_enableViewSource;
+};
+
+#endif