SVN commit 773530 by annma: make preview also work when URL changes via the combobox M +7 -0 configdialog.cpp M +3 -0 configdialog.h --- trunk/extragear/plasma/applets/frame/configdialog.cpp #773529:773530 @@ -17,6 +17,7 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA . * ***************************************************************************/ +#include #include #include @@ -53,6 +54,7 @@ m_preview->show(); connect(ui.picRequester, SIGNAL(urlSelected(const KUrl & )), this, SLOT(changePreview(const KUrl &))); + connect(ui.picRequester->comboBox(), SIGNAL(activated(const QString & )), this, SLOT(changePreview(const QString &))); } ConfigDialog::~ConfigDialog() @@ -121,3 +123,8 @@ previewPicture(myPicture.setPicture(path)); } +void ConfigDialog::changePreview(const QString &path) +{ + Picture myPicture; + previewPicture(myPicture.setPicture(KUrl(path))); +} \ No newline at end of file --- trunk/extragear/plasma/applets/frame/configdialog.h #773529:773530 @@ -54,7 +54,10 @@ void previewPicture(const QImage &pix); private slots: + /// Update preview when URL changes via the file dialog void changePreview(const KUrl &); + /// Update preview when URL changes via the combobox + void changePreview(const QString &); };