[escher] Change dynamic view controller paradigm

Change-Id: I57fd41c9b9ad8a1e8b684b97fdf80ddffd71881d
This commit is contained in:
Émilie Feral
2017-05-03 10:26:44 +02:00
parent a1f3c21d9b
commit 70fc734f7b
61 changed files with 338 additions and 475 deletions

View File

@@ -91,11 +91,10 @@ const Container * App::container() const {
}
void App::didBecomeActive(Window * window) {
m_modalViewController.loadView();
View * view = m_modalViewController.view();
assert(m_modalViewController.app() == this);
window->setContentView(view);
m_modalViewController.viewWillAppear();
window->setContentView(view);
setFirstResponder(&m_modalViewController);
window->redraw();
}
@@ -106,5 +105,4 @@ void App::willBecomeInactive() {
}
setFirstResponder(nullptr);
m_modalViewController.viewDidDisappear();
m_modalViewController.unloadView();
}