Merge lp:~fboucault/unity-2d/spread_monitor_finer_change_notification into lp:~unity-2d-team/unity-2d/unity-2d-shell

Proposed by Florian Boucault
Status: Merged
Approved by: Albert Astals Cid
Approved revision: 1000
Merged at revision: 1000
Proposed branch: lp:~fboucault/unity-2d/spread_monitor_finer_change_notification
Merge into: lp:~unity-2d-team/unity-2d/unity-2d-shell
Diff against target: 19 lines (+7/-1)
1 file modified
libunity-2d-private/src/spreadmonitor.cpp (+7/-1)
To merge this branch: bzr merge lp:~fboucault/unity-2d/spread_monitor_finer_change_notification
Reviewer Review Type Date Requested Status
Albert Astals Cid (community) Approve
Review via email: mp+92252@code.launchpad.net

Description of the change

Finer change notification for property SpreadMonitor::shown

To post a comment you must log in.
Revision history for this message
Albert Astals Cid (aacid) wrote :

Looks good

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'libunity-2d-private/src/spreadmonitor.cpp'
--- libunity-2d-private/src/spreadmonitor.cpp 2012-02-08 15:29:04 +0000
+++ libunity-2d-private/src/spreadmonitor.cpp 2012-02-09 11:45:23 +0000
@@ -42,8 +42,14 @@
42 if (available) {42 if (available) {
43 connect(dbusInterface(), SIGNAL(IsShownChanged(bool)), SIGNAL(shownChanged(bool)));43 connect(dbusInterface(), SIGNAL(IsShownChanged(bool)), SIGNAL(shownChanged(bool)));
4444
45 Q_EMIT shownChanged(shown());45 /* In SpreadMonitor::shown() we assume shown is false if the service is not
46 available therefore there is no need to emit shownChanged if it is still false */
47 if (shown()) {
48 Q_EMIT shownChanged(true);
49 }
46 } else {50 } else {
51 /* At this point we cannot know for sure that the spread was shown so
52 we emit the changed signal unconditionally */
47 Q_EMIT shownChanged(false);53 Q_EMIT shownChanged(false);
48 }54 }
49}55}

Subscribers

People subscribed via source and target branches