mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-01-19 00:37:25 +01:00
[code] The addScript button disappears when needed.
When there is already the maximal number of scripts or when the ScriptStore accordion buffer is full. Change-Id: I0d43d42626da7f060a2309c66f1806b35a29bf38
This commit is contained in:
@@ -99,6 +99,10 @@ void ScriptStore::deleteAllScripts() {
|
||||
m_accordion.deleteAll();
|
||||
}
|
||||
|
||||
bool ScriptStore::isFull() {
|
||||
return (m_accordion.freeSpaceSize() < k_fullFreeSpaceSizeLimit);
|
||||
}
|
||||
|
||||
const char * ScriptStore::contentOfScript(const char * name) {
|
||||
Script script = scriptNamed(name);
|
||||
if (script.isNull()) {
|
||||
@@ -107,7 +111,6 @@ const char * ScriptStore::contentOfScript(const char * name) {
|
||||
return script.content();
|
||||
}
|
||||
|
||||
|
||||
bool ScriptStore::addScriptFromTemplate(const ScriptTemplate * scriptTemplate) {
|
||||
const char autoImportationString[2] = {Script::DefaultAutoImportationMarker, 0};
|
||||
if (!m_accordion.appendBuffer(autoImportationString)) {
|
||||
|
||||
Reference in New Issue
Block a user