@@ -288,8 +288,8 @@ ModelsList::~ModelsList()
|
||||
void ModelsList::init()
|
||||
{
|
||||
loaded = false;
|
||||
currentCategory = NULL;
|
||||
currentModel = NULL;
|
||||
currentCategory = nullptr;
|
||||
currentModel = nullptr;
|
||||
modelsCount = 0;
|
||||
}
|
||||
|
||||
@@ -368,12 +368,12 @@ void ModelsList::save()
|
||||
f_close(&file);
|
||||
}
|
||||
|
||||
void ModelsList::setCurrentCategorie(ModelsCategory* cat)
|
||||
void ModelsList::setCurrentCategory(ModelsCategory * cat)
|
||||
{
|
||||
currentCategory = cat;
|
||||
}
|
||||
|
||||
void ModelsList::setCurrentModel(ModelCell* cell)
|
||||
void ModelsList::setCurrentModel(ModelCell * cell)
|
||||
{
|
||||
currentModel = cell;
|
||||
if (!currentModel->valid_rfData)
|
||||
|
||||
@@ -40,8 +40,8 @@ struct SimpleModuleData
|
||||
class ModelCell
|
||||
{
|
||||
public:
|
||||
char modelFilename[LEN_MODEL_FILENAME+1];
|
||||
char modelName[LEN_MODEL_NAME+1];
|
||||
char modelFilename[LEN_MODEL_FILENAME + 1];
|
||||
char modelName[LEN_MODEL_NAME + 1];
|
||||
BitmapBuffer * buffer;
|
||||
|
||||
bool valid_rfData;
|
||||
@@ -51,10 +51,10 @@ public:
|
||||
ModelCell(const char * name);
|
||||
~ModelCell();
|
||||
|
||||
void save(FIL* file);
|
||||
void save(FIL * file);
|
||||
|
||||
void setModelName(char* name);
|
||||
void setRfData(ModelData* model);
|
||||
void setModelName(char * name);
|
||||
void setRfData(ModelData * model);
|
||||
|
||||
void setModelId(uint8_t moduleIdx, uint8_t id);
|
||||
void setRfModuleData(uint8_t moduleIdx, ModuleData* modData);
|
||||
@@ -68,7 +68,7 @@ public:
|
||||
class ModelsCategory: public std::list<ModelCell *>
|
||||
{
|
||||
public:
|
||||
char name[LEN_MODEL_FILENAME+1];
|
||||
char name[LEN_MODEL_FILENAME + 1];
|
||||
|
||||
ModelsCategory(const char * name);
|
||||
~ModelsCategory();
|
||||
@@ -98,21 +98,25 @@ public:
|
||||
void save();
|
||||
void clear();
|
||||
|
||||
const std::list<ModelsCategory *>& getCategories() const {
|
||||
const std::list<ModelsCategory *> & getCategories() const
|
||||
{
|
||||
return categories;
|
||||
}
|
||||
|
||||
void setCurrentCategorie(ModelsCategory* cat);
|
||||
ModelsCategory* getCurrentCategory() const {
|
||||
void setCurrentCategory(ModelsCategory * cat);
|
||||
ModelsCategory * getCurrentCategory() const
|
||||
{
|
||||
return currentCategory;
|
||||
}
|
||||
|
||||
void setCurrentModel(ModelCell* cell);
|
||||
ModelCell* getCurrentModel() const {
|
||||
void setCurrentModel(ModelCell * cell);
|
||||
ModelCell * getCurrentModel() const
|
||||
{
|
||||
return currentModel;
|
||||
}
|
||||
|
||||
unsigned int getModelsCount() const {
|
||||
unsigned int getModelsCount() const
|
||||
{
|
||||
return modelsCount;
|
||||
}
|
||||
|
||||
@@ -133,7 +137,6 @@ public:
|
||||
|
||||
protected:
|
||||
FIL file;
|
||||
|
||||
};
|
||||
|
||||
extern ModelsList modelslist;
|
||||
|
||||
Reference in New Issue
Block a user