Summary: | KMenu discarding most used applications | ||
---|---|---|---|
Product: | [Plasma] kicker | Reporter: | Marco Martin <notmart> |
Component: | general | Assignee: | Aaron J. Seigo <aseigo> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | christian.loose |
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | openSUSE | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Attachments: | an one line patch that actually fixes the problem |
Description
Marco Martin
2006-07-04 21:37:23 UTC
Proposed solution: I digged into the code, and even if i still don't understand very well how it works I found that the list of the most/recent used apps is not always initialized after kicker start, i.e RecentlyLaunchedApps::init() of kdebase/kicker/kicker/ui/recentapps.cpp is not always called. I found that adding a call to init() in kdebase/kicker/kicker/ui/recentapps.cpp at line 51 (of the 3.5.4 version) at the end of the function RecentlyLaunchedApps::RecentlyLaunchedApps() seems to solve the problem. I don't know if there is a cleaner way to fix it but it seems work. Since It's a very annoying bug I think that a fix should make its way into 3.5.x series. Created attachment 17530 [details]
an one line patch that actually fixes the problem
I made this one line patch to show what i mean.
it's made against kde 3.5.0 but i've seen on websvn that the file
recentapps.cpp isn't changed since then.
SVN commit 578162 by aseigo: ensure that init() is always called on recentapps now that it is used by more than just the menu (e.g. applets), which may result in it getting instatiated then save()d without having first loaded the old values BUG:130263 M +0 -1 k_mnu.cpp M +1 -0 recentapps.cpp --- branches/KDE/3.5/kdebase/kicker/kicker/ui/k_mnu.cpp #578161:578162 @@ -594,7 +594,6 @@ // create and fill "recent" section at first void PanelKMenu::createRecentMenuItems() { - RecentlyLaunchedApps::the().init(); RecentlyLaunchedApps::the().m_nNumMenuItems = 0; QStringList RecentApps; --- branches/KDE/3.5/kdebase/kicker/kicker/ui/recentapps.cpp #578161:578162 @@ -48,6 +48,7 @@ m_nNumMenuItems = 0; m_bNeedToUpdate = false; m_bInitialised = false; + init(); } void RecentlyLaunchedApps::init() |