diff options
Diffstat (limited to 'src/entryview.cpp')
-rw-r--r-- | src/entryview.cpp | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/src/entryview.cpp b/src/entryview.cpp index ab61616..66ad116 100644 --- a/src/entryview.cpp +++ b/src/entryview.cpp @@ -26,6 +26,7 @@ #include "document.h" #include "latin1literal.h" #include "../core/drophandler.h" +#include "../tellico_debug.h" #include <kstandarddirs.h> #include <krun.h> @@ -37,10 +38,22 @@ #include <tdelocale.h> #include <tqfile.h> +#include <tqclipboard.h> using Tellico::EntryView; +using Tellico::EntryViewWidget; -EntryView::EntryView(TQWidget* parent_, const char* name_) : TDEHTMLPart(parent_, name_), +EntryViewWidget::EntryViewWidget(TDEHTMLPart* part, TQWidget* parent) + : TDEHTMLView(part, parent) {} + +// for the life of me, I could not figure out how to call the actual +// TDEHTMLPartBrowserExtension::copy() slot, so this will have to do +void EntryViewWidget::copy() { + TQString text = part()->selectedText(); + TQApplication::clipboard()->setText(text, TQClipboard::Clipboard); +} + +EntryView::EntryView(TQWidget* parent_, const char* name_) : TDEHTMLPart(new EntryViewWidget(this, parent_), parent_, name_), m_entry(0), m_handler(0), m_run(0), m_tempFile(0), m_useGradientImages(true), m_checkCommonFile(true) { setJScriptEnabled(false); setJavaEnabled(false); |