[KPhotoAlbum] problem with gps tagged images on kphotoalbum 5.2 and 5.3, possible fix proposed
Robert Krawitz
rlk at alum.mit.edu
Thu Jul 19 13:16:48 BST 2018
So it indicates a race condition between creating the thumbnail
builder and searching for new images. I can't reproduce it, but it
could be due to library (or other system) differences. This likely
would not have been a problem prior to the fast load, because in that
case thumbnails were not built until all new files were loaded (the
code did not change).
Anyway, this fix -- creating the thumbnail builder prior to any
reference to the delayed init which loads images on startup -- should
resolve the problem. We can't, unfortunately, have the thumbnail
builder created on the fly when needed, because it needs access to the
MainWindow to hook into.
diff --git a/MainWindow/Window.cpp b/MainWindow/Window.cpp
index 9b3f00c4..a7eb7247 100644
--- a/MainWindow/Window.cpp
+++ b/MainWindow/Window.cpp
@@ -216,6 +216,7 @@ MainWindow::Window::Window( QWidget* parent )
connect( m_browser, SIGNAL(imageCount(uint)), m_statusBar->mp_partial, SLOT(showBrowserMatches(uint)) );
connect(m_thumbnailView, &ThumbnailView::ThumbnailFacade::selectionChanged, this, &Window::updateContextMenuFromSelectionSize);
+ new ImageManager::ThumbnailBuilder( m_statusBar, this );
QTimer::singleShot( 0, this, SLOT(delayedInit()) );
updateContextMenuFromSelectionSize(0);
@@ -1875,7 +1876,6 @@ void MainWindow::Window::createSarchBar()
void MainWindow::Window::executeStartupActions()
{
- new ImageManager::ThumbnailBuilder( m_statusBar, this );
if ( ! Settings::SettingsData::instance()->incrementalThumbnails())
ImageManager::ThumbnailBuilder::instance()->buildMissing();
connect( Settings::SettingsData::instance(), SIGNAL(thumbnailSizeChanged(int)), this, SLOT(slotBuildThumbnailsIfWanted()) );
--
Robert Krawitz <rlk at alum.mit.edu>
*** MIT Engineers A Proud Tradition http://mitathletics.com ***
Member of the League for Programming Freedom -- http://ProgFree.org
Project lead for Gutenprint -- http://gimp-print.sourceforge.net
"Linux doesn't dictate how I work, I dictate how Linux works."
--Eric Crampton
More information about the Kphotoalbum
mailing list