Merge lp:~mterry/unity/742695 into lp:unity

Proposed by Michael Terry
Status: Merged
Merged at revision: 1045
Proposed branch: lp:~mterry/unity/742695
Merge into: lp:unity
Diff against target: 22 lines (+12/-0)
1 file modified
src/LauncherController.cpp (+12/-0)
To merge this branch: bzr merge lp:~mterry/unity/742695
Reviewer Review Type Date Requested Status
Mikkel Kamstrup Erlandsen (community) Approve
Review via email: mp+54919@code.launchpad.net

Description of the change

See bug 742695 for details.

To post a comment you must log in.
Revision history for this message
Mikkel Kamstrup Erlandsen (kamstrup) wrote :

I think your analysis in the bug report sounds correct and the code looks good; so approved!

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/LauncherController.cpp'
2--- src/LauncherController.cpp 2011-03-23 20:33:39 +0000
3+++ src/LauncherController.cpp 2011-03-25 19:36:38 +0000
4@@ -235,6 +235,18 @@
5 LauncherController::RegisterIcon (LauncherIcon *icon)
6 {
7 _model->AddIcon (icon);
8+
9+ BamfLauncherIcon *bamf_icon = dynamic_cast<BamfLauncherIcon *> (icon);
10+ if (bamf_icon)
11+ {
12+ LauncherEntryRemote *entry = NULL;
13+ const char *path;
14+ path = bamf_icon->DesktopFile ();
15+ if (path)
16+ entry = _remote_model->LookupByDesktopFile (path);
17+ if (entry)
18+ icon->InsertEntryRemote (entry);
19+ }
20 }
21
22 /* static private */