[code] Cleaned Script and ScriptStore classes, created accordion.h

A Script object now contains its AutoImport marker, its name and its
content. The ScripStore methods have better names and the optimization
is cleaner.

Change-Id: I1b21af2d23f1c9a34f984309512b0c01b2f1c320
This commit is contained in:
Léa Saviot
2017-10-25 18:02:01 +02:00
committed by Romain Goyet
parent a14cfd0aea
commit fbb5c70339
15 changed files with 498 additions and 419 deletions

View File

@@ -18,7 +18,7 @@ const Image * App::Descriptor::icon() {
}
App::Snapshot::Snapshot() {
m_scriptStore.addFactorialScript();
m_scriptStore.addNewScript(ScriptStore::DefaultScript::Factorial);
}
App * App::Snapshot::unpack(Container * container) {
@@ -26,7 +26,7 @@ App * App::Snapshot::unpack(Container * container) {
}
void App::Snapshot::reset() {
m_scriptStore.deleteAll();
m_scriptStore.deleteAllScripts();
}
App::Descriptor * App::Snapshot::descriptor() {