[apps] Put the method preference in container instead of in every app

Change-Id: Ib390952a6559aa847c99e3ca74c4f6995a07e909
This commit is contained in:
Émilie Feral
2017-01-31 16:15:04 +01:00
parent ab65e832ea
commit 47cec5e72b
10 changed files with 27 additions and 31 deletions

View File

@@ -3,11 +3,10 @@
namespace Graph {
App::App(Container * container, Context * context, Preferences * preferences) :
App::App(Container * container, Context * context) :
TextFieldDelegateApp(container, &m_inputViewController, "Fonctions", "FONCTIONS", ImageStore::GraphIcon),
m_functionStore(FunctionStore()),
m_xContext(VariableContext('x', context)),
m_preferences(preferences),
m_listController(ListController(&m_listHeader, &m_functionStore, &m_listHeader)),
m_listHeader(HeaderViewController(nullptr, &m_listController, &m_listController)),
m_listStackViewController(StackViewController(&m_tabViewController, &m_listHeader)),
@@ -32,8 +31,4 @@ Context * App::localContext() {
return &m_xContext;
}
Preferences * App::preferences() {
return m_preferences;
}
}