Merge lp:~kdub/mir/msh-surface-no-builder into lp:~mir-team/mir/trunk
Status: | Work in progress |
---|---|
Proposed branch: | lp:~kdub/mir/msh-surface-no-builder |
Merge into: | lp:~mir-team/mir/trunk |
Diff against target: |
760 lines (+105/-232) 11 files modified
include/server/mir/shell/surface.h (+6/-7) include/test/mir_test_doubles/mock_surface.h (+3/-2) src/server/shell/surface.cpp (+11/-11) src/server/shell/surface_source.cpp (+8/-2) tests/behavior-tests/session_management_context.cpp (+4/-5) tests/integration-tests/cucumber/test_session_management_context.cpp (+1/-2) tests/unit-tests/frontend/test_session_mediator.cpp (+1/-1) tests/unit-tests/shell/test_application_session.cpp (+7/-11) tests/unit-tests/shell/test_session_manager.cpp (+6/-4) tests/unit-tests/shell/test_single_visibility_focus_mechanism.cpp (+1/-2) tests/unit-tests/shell/test_surface.cpp (+57/-185) |
To merge this branch: | bzr merge lp:~kdub/mir/msh-surface-no-builder |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Alexandros Frantzis (community) | Needs Information | ||
PS Jenkins bot (community) | continuous-integration | Approve | |
Review via email: mp+171933@code.launchpad.net |
Commit message
msh:: begin changes by digging the destruction of the ms::Surface out of msh::Surface. This makes the constructor for msh::Surface much simpler.
Description of the change
msh:: begin changes by digging the destruction of the ms::Surface out of msh::Surface. This makes the constructor for msh::Surface much simpler.
this is a 'stable intermediate change' from my spike on how to clean up msh::Surface to make it more mockable/
The obvious wart is in SurfaceSource, where we pass a std::function for the destruction of the ms::Surface. This will is nicely eliminated by having a complimentary "destroy_
From the spike on cleaning this area of the code, (which I've decided to land in bitesized chunks), I isolated a few problems:
1) The ms::Surface is not acquired by the shell in a good RAII way. The surface stack is passed all around shell, when really, the SessionManager in shell should be aware of the SurfaceStack, and manage the Session classes for each client
2) There are a few builder clasess that have weird lifetimes for their underlying factories. In my spike branch, I eliminated two of these.
3) SurfaceController is a bit redundant, what we have in the system today is trending towards an MVC view of the stack that's a little more fine grained than what we had planned many months ago.
Unmerged revisions
- 796. By Kevin DuBois
-
remove commented code
- 795. By Kevin DuBois
-
make a todo comment noting where we have a stable intermediate form
- 794. By Kevin DuBois
-
clean up references to the builder throughout the tests. re-enable all msh surface tests
- 793. By Kevin DuBois
-
trim the constructor from the unused params
- 792. By Kevin DuBois
-
test to pass
- 791. By Kevin DuBois
-
flip the switch on the constructor (1 failing tes)
- 790. By Kevin DuBois
-
finish adding constructor del function to move msh::Surface to more raii
- 789. By Kevin DuBois
-
wrap the destruction into a functor. this is a temporary measure
- 788. By Kevin DuBois
-
rethink approach to be gentler to compile
- 787. By Kevin DuBois
-
update surafce test so it doesnt touch builder
PASSED: Continuous integration, rev:796 jenkins. qa.ubuntu. com/job/ mir-ci/ 849/ jenkins. qa.ubuntu. com/job/ mir-android- saucy-i386- build/1076 jenkins. qa.ubuntu. com/job/ mir-clang- saucy-amd64- build/961 jenkins. qa.ubuntu. com/job/ mir-saucy- amd64-ci/ 87 jenkins. qa.ubuntu. com/job/ mir-saucy- amd64-ci/ 87/artifact/ work/output/ *zip*/output. zip jenkins. qa.ubuntu. com/job/ mir-vm- ci-build/ ./distribution= quantal, flavor= amd64/503
http://
Executed test runs:
SUCCESS: http://
SUCCESS: http://
SUCCESS: http://
deb: http://
SUCCESS: http://
Click here to trigger a rebuild: s-jenkins: 8080/job/ mir-ci/ 849/rebuild
http://