Problem/Motivation
This was handled through hook_init() within each course object type provider module.
API changes
The context setting was moved into the course object, and invoked from parent in a more structured way:
- Each module that wishes to provide course context handlers must define a context callback in
hook_course_handlers()(see @return documentation on that hook) - The context handler callback is expected to return query parameters suitable for
course_determine_context()(see @param documentation on that function) - See examples in course extension modules, included in Course (example: Course book)
Comments
Comment #1
djdevinJust wanted to note that this is difficult, moving context functionality into each course object means we have to load every single class at init, which defeats the point of auto/lazy loading.
Comment #2
scottrigbyI think we determined we're now going to define a context callback in our new hook_course_handlers()
Comment #3
djdevinSee http://drupalcode.org/project/course.git/commit/aa2e8088fccf1c63fd0d52bc...
Comment #4
scottrigbyAlso see 2e2bf1ea1f002239f42adde2fa7f66efd052473d:
Comment #5
scottrigbyUpdated issue summary with resolution, and API changes.
Comment #6.0
(not verified) commentedUpdate issue summary with resolution