[PATCH] juk: save collection list cache on exit

Γιώργος Κυλάφας (Giorgos Kylafas) gekylafas at gmail.com
Fri Jun 3 00:35:16 BST 2011


Hi all,

I have noticed a problem about the collection list cache saving,
depending on how JuK is terminated. There are three possibilities:

1. File->Quit
In that case, methods JuK::slotQuit and JuK::queryExit are called.
This means that Cache::save is called once (from slotQuit) and
JuK::saveConfig twice (from slotQuit and queryExit).

2. Close window
Only queryExit gets called, so saveConfig is called once and the cache
is not saved.

3. RMB in System Tray->Quit
Same as 2.

Since only queryExit is called in every case, the obvious solution
would be to move JuK::saveConfig and Cache::save there and only there,
as per the attached file.
However, maybe the rest of the code in slotQuit should be called in
all three case as well, which means there need to be additional
changes. Or I am missing something else entirely. :-)

The origins of this problem seem to lie in
http://websvn.kde.org/?view=revision&revision=921339, where
Cache::save was moved to slotQuit and
http://websvn.kde.org/?view=revision&revision=1025472, where selecting
"Quit" from SystemTray does not call slotQuit anymore.

Regards,

-- 
Γιώργος Κυλάφας (Giorgos Kylafas)
http://en.wikipedia.org/wiki/Posting_style#Inline_replying
-------------- next part --------------
A non-text attachment was scrubbed...
Name: save-cache-on-quit.patch
Type: text/x-diff
Size: 1370 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-multimedia/attachments/20110603/713fb769/attachment.patch>
-------------- next part --------------
_______________________________________________
kde-multimedia mailing list
kde-multimedia at kde.org
https://mail.kde.org/mailman/listinfo/kde-multimedia


More information about the kde-multimedia mailing list