Bug 220800 - changing the ps output file name for create calendar tool does not work
Summary: changing the ps output file name for create calendar tool does not work
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: Plugin-Generic-Calendar (show other bugs)
Version: unspecified
Platform: Ubuntu Unspecified
: NOR normal
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-12-31 13:21 UTC by bert
Modified: 2016-02-19 09:01 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In: 2.3.0


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description bert 2009-12-31 13:21:32 UTC
Version:            (using KDE 4.3.2)
Installed from:    Ubuntu Packages

While trying to create new calendar in digikam I am printing to a postscript file.
I ran into some trouble with the postscript file and used the back button to try and print again.
This time I specified a different output file name. However, the new filename was not used.
Digikam still printed to the original filename.
Comment 1 Andi Clemens 2011-10-25 20:56:25 UTC
I can confirm this, something is cached, even when the kipiplugin has been restarted.

I added 12 images from album "a" to the calendar, generated the PDF and closed the kipiplugin (from within digiKam). 
I then chose 2 other images from album "b" and started the kipiplugin. These two images are shown in the calendar wizard, but when I generate the PDF, not only the two images are shown, but the rest of the old images from album "a", although the plugin has been closed before.

So we definitely have some weird caching issues here.
Comment 2 Andi Clemens 2011-10-25 21:23:39 UTC
I figured out that the calendarSettings object is a singleton and it doesn't seem to get killed when the kipiplugin is closed (that's why I hate singleton classes :-))

I will try to fix this, I guess I will make it a normal class, no need to have a singleton here.
Comment 3 Andi Clemens 2011-10-25 22:07:46 UTC
Git commit 96c607cef93b411f3e9040b6e1dbfd702ea1c2c0 by Andi Clemens.
Committed on 26/10/2011 at 00:05.
Pushed by aclemens into branch 'master'.

Quick fix: Assign a pointer to the parent in the CalSettings::instance()
method. This way the singleton class will be destroyed when the calendar wizard
is closed.

BUG: 220800

M  +4    -3    calendar/print/calsettings.cpp
M  +2    -2    calendar/print/calsettings.h
M  +1    -1    calendar/wizard/calwizard.cpp

http://commits.kde.org/kipi-plugins/96c607cef93b411f3e9040b6e1dbfd702ea1c2c0