Version: (using KDE Devel) Installed from: Compiled sources The cdarchiving plugin calls KIPI::ImageCollectionShared::category and KIPI::ImageCollectionShared::date even though the KIPI::Features AlbumsHaveCategory and AlbumsHaveCreationDate are not present. This is the case for KimDaBa, so you may use that as test case to check if it is fixed.
CVS commit by pahlibar: respect host app settings and check for features before actually accessing them BUG: 88883 M +37 -15 cdarchiving.cpp 1.38 --- kdeextragear-libs-1/kipi-plugins/cdarchiving/cdarchiving.cpp #1.37:1.38 @@ -312,7 +312,19 @@ bool CDArchiving::prepare(void) albumIt != albumsList.end() ; ++albumIt ) { - AlbumData data((*albumIt).name(), (*albumIt).category(), - (*albumIt).comment(), (*albumIt).date(), - (*albumIt).path(), (*albumIt).images()); + AlbumData data((*albumIt).name(), + + m_interface->hasFeature(KIPI::AlbumsHaveCategory) ? + (*albumIt).category() : QString(), + + m_interface->hasFeature(KIPI::AlbumsHaveComments) ? + (*albumIt).comment() : QString(), + + m_interface->hasFeature(KIPI::AlbumsHaveCreationDate) ? + (*albumIt).date() : QDate(), + + (*albumIt).isDirectory() ? + (*albumIt).path() : QString(), + + (*albumIt).images()); m_albumsMap->insert( (*albumIt).path().prettyURL(), data ); @@ -583,7 +595,10 @@ bool CDArchiving::buildHTMLInterface (vo m_AlbumTitle = data.albumName(); - m_AlbumComments = data.albumComments(); - m_AlbumCollection = data.albumCategory(); - m_AlbumDate = data.albumDate().toString(); + m_AlbumComments = m_interface->hasFeature(KIPI::AlbumsHaveComments) ? + data.albumComments() : QString(); + m_AlbumCollection = m_interface->hasFeature(KIPI::AlbumsHaveCategory) ? + data.albumCategory() : QString(); + m_AlbumDate = m_interface->hasFeature(KIPI::AlbumsHaveCreationDate) ? + data.albumDate().toString() : QString(); Path = data.albumUrl().path(); @@ -807,8 +822,11 @@ void CDArchiving::createBody(QTextStream stream << "<tr valign=top><td align=left>\n" << endl; + if (m_interface->hasFeature(KIPI::AlbumsHaveComments)) stream << i18n("<i>Comment:</i>") << "<br>\n" << endl; + if (m_interface->hasFeature(KIPI::AlbumsHaveCategory)) stream << i18n("<i>Collection:</i>") << "<br>\n" << endl; + if (m_interface->hasFeature(KIPI::AlbumsHaveCreationDate)) stream << i18n("<i>Date:</i>") << "<br>\n" << endl; @@ -817,9 +835,13 @@ void CDArchiving::createBody(QTextStream stream << "</td><td align=left>\n" << endl; - stream << EscapeSgmlText(QTextCodec::codecForLocale(), m_AlbumComments, true, true) + if (m_interface->hasFeature(KIPI::AlbumsHaveComments)) + stream << EscapeSgmlText(QTextCodec::codecForLocale(), + m_AlbumComments, true, true) << "<br>\n" << endl; + if (m_interface->hasFeature(KIPI::AlbumsHaveCategory)) stream << m_AlbumCollection << "<br>\n" << endl; + if (m_interface->hasFeature(KIPI::AlbumsHaveCreationDate)) stream << m_AlbumDate << "<br>\n" << endl;