summaryrefslogtreecommitdiff
path: root/noncore
Side-by-side diff
Diffstat (limited to 'noncore') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/graphics/drawpad/importdialog.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/noncore/graphics/drawpad/importdialog.cpp b/noncore/graphics/drawpad/importdialog.cpp
index 0783ed8..1c447cb 100644
--- a/noncore/graphics/drawpad/importdialog.cpp
+++ b/noncore/graphics/drawpad/importdialog.cpp
@@ -67,7 +67,9 @@ ImportDialog::~ImportDialog()
const DocLnk* ImportDialog::selected()
{
- return m_pFileSelector->selected();
+ // FIXME change from pointer to reference -zecke
+ DocLnk *lnk = new DocLnk( m_pFileSelector->selectedDocument() );
+ return lnk;
}
void ImportDialog::fileChanged()
@@ -79,7 +81,7 @@ void ImportDialog::fileChanged()
void ImportDialog::preview()
{
- const DocLnk* docLnk = m_pFileSelector->selected();
+ const DocLnk* docLnk = selected();
if (docLnk) {
QImage image(docLnk->file());