Merge lp:~agateau/unity-2d/reason-fv into lp:unity-2d/3.0
Status: | Work in progress |
---|---|
Proposed branch: | lp:~agateau/unity-2d/reason-fv |
Merge into: | lp:unity-2d/3.0 |
Diff against target: |
396 lines (+91/-57) 12 files modified
launcher/Launcher.qml (+2/-2) launcher/LauncherList.qml (+6/-6) launcher/app/launcher.xml (+11/-0) launcher/app/launcherdbus.cpp (+4/-4) launcher/app/launcherdbus.h (+2/-2) launcher/app/visibilitycontroller.cpp (+40/-24) launcher/app/visibilitycontroller.h (+12/-6) libunity-2d-private/src/launcherclient.cpp (+6/-5) libunity-2d-private/src/launcherclient.h (+2/-2) panel/applets/homebutton/homebuttonapplet.cpp (+2/-2) places/app/dashdeclarativeview.cpp (+2/-2) spread/app/spreadcontrol.cpp (+2/-2) |
To merge this branch: | bzr merge lp:~agateau/unity-2d/reason-fv |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Ugo Riboni (community) | Needs Fixing | ||
Review via email: mp+54371@code.launchpad.net |
Commit message
[launcher] replaces the refcount method to track forced visibility requests with a "reason-based" method
Every call to beginForceVisible() must be passed a reason, and the same reason must be passed back to endForceVisible().
Also introduces an environment variable to help debugging visibility issues: UNITY2DLAUNCHER
Description of the change
This branch replaces the refcount method to track forced visibility requests with a "reason-based" method: every call to beginForceVisible() must be passed a reason, and the same reason must be passed back to endForceVisible().
It also introduces an environment variable to help debugging visibility issues: UNITY2DLAUNCHER
Unmerged revisions
- 470. By Aurélien Gâteau
-
Merged with trunk
- 469. By Aurélien Gâteau
-
Merged from trunk
- 468. By Aurélien Gâteau
-
- Document tricky parts of the code
- Avoid asking QDBusServiceWatcher to monitor an empty service (harmless but
stupid) - 467. By Aurélien Gâteau
-
Log behavior class when switching behaviors
- 466. By Aurélien Gâteau
-
Use explicit reasons instead of refcounts to implement forced visibility
This is more robust and makes it easier to debug as one only needs to set the
UNITY2DLAUNCHER_DEBUG_ VISIBILITY environment variable to get a log of the
active reasons for forced visibility.
61 + <arg type="s" name="reason"> le</dox: d>
62 + <dox:d>Reason for ending the visibility forcing. Must match
63 + with a previous call to BeginForceVisib
64 + </arg>
Please make sure to mention that you just need one call to terminate all outstanding requests for FV for that specific reason for that process.
Would be nice to say that in the commit message as well.
145 + m_forceVisibleR easonHash[ service] .insert( reason) ; isEmpty( )) { >addWatchedServ ice(service) ;
146 + if (!service.
147 + m_dbusWatcher-
148 + }
What would be the reason for service to be emtpy ? If it's indeed possible, please move the hash insert into the if, otherwise if it's not expected to happen I suggest you put an assert or a critical error message.
163 + if (m_forceVisible ReasonHash. contains( service) ) { easonHash[ service] .remove( reason) ; ReasonHash[ service] .isEmpty( )) { easonHash. remove( service) ;
164 + m_forceVisibleR
165 + if (m_forceVisible
166 + m_forceVisibleR
Why do you check if m_forceVisibleR easonHash[ service] is emtpy instead of checking if service is empty like you do in the beginFV method ?
This way you're actually checking if the reason is empty, which i don't think is what you want.