| Summary: | batch cration of thumbails | ||
|---|---|---|---|
| Product: | [Applications] digikam | Reporter: | Daniel Bauer <linux> |
| Component: | Maintenance-Thumbs | Assignee: | Digikam Developers <digikam-bugs-null> |
| Status: | RESOLVED FIXED | ||
| Severity: | wishlist | CC: | caulier.gilles |
| Priority: | NOR | ||
| Version First Reported In: | 0.8.0 | ||
| Target Milestone: | --- | ||
| Platform: | openSUSE | ||
| OS: | Linux | ||
| Latest Commit: | Version Fixed/Implemented In: | 0.9.0 | |
| Sentry Crash Report: | |||
|
Description
Daniel Bauer
2006-01-17 14:33:46 UTC
great idea !!! Daniel,
A new batch thumbnails generator have been added to svn trunk (will be availalbe for the next digiKam 0.9.0-beta2). I don't know why the commit in svn have not notified this B.K.O file.
This is the resume of my commit :
SVN commit 578791 by cgilles:
digikam from trunk : new batch tool to re-generate all albums items thumbnails for all icon sizes. Use the new Tools/Rebuild all Thumbnails option for that.
This tool can take a while on slow computers (you can take a coffee (:=)). Note : you cannot use digiKam during thumbnails processing.
BUG : 128308
CCBUGS : 110658, 127179
M +1 -1 Makefile.am
A batchthumbsgenerator.cpp [License: GPL]
A batchthumbsgenerator.h [License: GPL]
M +28 -7 digikamapp.cpp
M +1 -0 digikamapp.h
M +8 -7 digikamui.rc
--- trunk/extragear/graphics/digikam/digikam/Makefile.am #578790:578791
@@ -49,7 +49,7 @@
kdatepickerpopup.cpp folderview.cpp folderitem.cpp \
upgradedb_sqlite2tosqlite3.cpp \
ratingwidget.cpp digikamfirstrun.cpp imageattributeswatch.cpp \
- albumthumbnailloader.cpp \
+ albumthumbnailloader.cpp batchthumbsgenerator.cpp \
dcopiface.cpp dcopiface.skel
libdigikam_la_LIBADD = $(LIB_KIO) $(LIB_SQLITE3) $(LIB_KABC) \
--- trunk/extragear/graphics/digikam/digikam/digikamapp.cpp #578790:578791
@@ -62,30 +62,31 @@
// Local includes.
-#include "kipiinterface.h"
#include "albummanager.h"
+#include "album.h"
#include "albumlister.h"
-#include "album.h"
-#include "themeengine.h"
+#include "albumsettings.h"
+#include "albumthumbnailloader.h"
#include "cameralist.h"
#include "cameratype.h"
#include "cameraui.h"
-#include "albumsettings.h"
#include "setup.h"
#include "setupplugins.h"
#include "setupeditor.h"
#include "setupimgplugins.h"
-#include "digikamview.h"
#include "imagepluginloader.h"
#include "imagewindow.h"
#include "splashscreen.h"
#include "thumbnailsize.h"
+#include "themeengine.h"
+#include "kipiinterface.h"
#include "scanlib.h"
#include "loadingcacheinterface.h"
#include "imageattributeswatch.h"
#include "dcrawbinary.h"
+#include "batchthumbsgenerator.h"
+#include "digikamview.h"
#include "digikamapp.h"
-#include "albumthumbnailloader.h"
using KIO::Job;
using KIO::UDSEntryList;
@@ -94,6 +95,8 @@
namespace Digikam
{
+DigikamApp* DigikamApp::m_instance = 0;
+
DigikamApp::DigikamApp()
: KMainWindow( 0, "Digikam" )
{
@@ -753,6 +756,10 @@
this, SLOT(slotDatabaseRescan()), actionCollection(),
"database_rescan");
+ new KAction(i18n("Rebuild all Thumbnails..."), "reload_page", 0,
+ this, SLOT(slotRebuildAllThumbs()), actionCollection(),
+ "thumbs_rebuild");
+
// -----------------------------------------------------------
// Provides a menu entry that allows showing/hiding the toolbar(s)
@@ -1582,8 +1589,22 @@
sLib.startScan();
}
-DigikamApp* DigikamApp::m_instance = 0;
+void DigikamApp::slotRebuildAllThumbs()
+{
+ QString msg = i18n("Rebuild all album item thumbnails can take a while.\n"
+ "Do you want to continue?");
+ int result = KMessageBox::warningContinueCancel(this, msg);
+ if (result != KMessageBox::Continue)
+ return;
+ BatchThumbsGenerator *thumbsGenerator = new BatchThumbsGenerator(this);
+
+ connect(thumbsGenerator, SIGNAL(signalRebuildAllThumbsDone()),
+ mView, SLOT(slot_albumRefresh()));
+
+ thumbsGenerator->exec();
+}
+
} // namespace Digikam
#include "digikamapp.moc"
--- trunk/extragear/graphics/digikam/digikam/digikamapp.h #578790:578791
@@ -155,6 +155,7 @@
void slotConfToolbars();
void slotToggleFullScreen();
void slotDatabaseRescan();
+ void slotRebuildAllThumbs();
void slotChangeTheme(const QString& theme);
--- trunk/extragear/graphics/digikam/digikam/digikamui.rc #578790:578791
@@ -1,5 +1,5 @@
<!DOCTYPE kpartgui SYSTEM "kpartgui.dtd">
-<kpartgui version="9" name="digikam" >
+<kpartgui version="10" name="digikam" >
<MenuBar>
@@ -65,15 +65,16 @@
</Menu>
<Menu name="Tools"><text>&Tools</text>
- <action name="search_quick" />
- <action name="search_advanced" />
+ <action name="search_quick" />
+ <action name="search_advanced" />
<Separator/>
- <action name="database_rescan" />
+ <action name="database_rescan" />
+ <action name="thumbs_rebuild" />
<Separator/>
- <actionList name="album_actions"/>
+ <actionList name="album_actions"/>
<Separator/>
- <action name="gamma_adjustment" />
- <actionList name="tool_actions"/>
+ <action name="gamma_adjustment" />
+ <actionList name="tool_actions"/>
<Menu name="BatchProcesses"><text>&Batch Processes</text>
<actionList name="batch_actions"/>
</Menu>
-------------------------------------------------------------------------------------------------------
I close this file now.
Gilles
|