summaryrefslogtreecommitdiffabout
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--bin/kdepim/WhatsNew.txt1
-rw-r--r--kaddressbook/imagewidget.cpp21
-rw-r--r--kaddressbook/imagewidget.h2
3 files changed, 5 insertions, 19 deletions
diff --git a/bin/kdepim/WhatsNew.txt b/bin/kdepim/WhatsNew.txt
index 93edc59..6e3b886 100644
--- a/bin/kdepim/WhatsNew.txt
+++ b/bin/kdepim/WhatsNew.txt
@@ -11,6 +11,7 @@ Addressee view is now using the formatted name, if defined.
That makes it possible to display "lastname, firstname" in that view now.
To set the formatted name for all contacts, please use menu:
Edit->Change->Set formatted name.
+Fixed the bug in KA/Pi that is was not possible to add images to a contact on Windows.
********** VERSION 2.1.4 ************
diff --git a/kaddressbook/imagewidget.cpp b/kaddressbook/imagewidget.cpp
index d0f52ea..eec5e08 100644
--- a/kaddressbook/imagewidget.cpp
+++ b/kaddressbook/imagewidget.cpp
@@ -281,29 +281,14 @@ void ImageWidget::updateGUI()
mUseLogoUrl->setEnabled( true );
}
-QPixmap ImageWidget::loadPixmap( const KURL &url )
+QPixmap ImageWidget::loadPixmap( const QString &url )
{
- QString tempFile;
+
QPixmap pixmap;
if ( url.isEmpty() )
return pixmap;
-
- if ( url.isLocalFile() )
- pixmap = QPixmap( url.path() );
- else
- {
-#ifndef KAB_EMBEDDED
- if ( KIO::NetAccess::download( url, tempFile ) ) {
- pixmap = QPixmap( tempFile );
- KIO::NetAccess::removeTempFile( tempFile );
- }
-#else //KAB_EMBEDDED
- qDebug("ImageWidget::loadPixmap : only local pixmaps are allowed");
-#endif //KAB_EMBEDDED
-
- }
-
+ pixmap.load( url );
return pixmap;
}
diff --git a/kaddressbook/imagewidget.h b/kaddressbook/imagewidget.h
index afb9aa7..bbfba58 100644
--- a/kaddressbook/imagewidget.h
+++ b/kaddressbook/imagewidget.h
@@ -74,7 +74,7 @@ class ImageWidget : public QWidget
void updateGUI();
private:
- QPixmap loadPixmap( const KURL &url );
+ QPixmap loadPixmap( const QString &url );
KURLRequester *mPhotoUrl;
KURLRequester *mLogoUrl;