Warnings removed
This commit is contained in:
+1
-1
@@ -257,7 +257,7 @@ bool EeFsOpen() // TODO inline?
|
|||||||
fflush(stdout);
|
fflush(stdout);
|
||||||
}
|
}
|
||||||
if (eeFs.mySize != sizeof(eeFs)) {
|
if (eeFs.mySize != sizeof(eeFs)) {
|
||||||
printf("bad eeFs.mySize (%d instead of %d)\n", eeFs.mySize, sizeof(eeFs));
|
printf("bad eeFs.mySize (%u instead of %u)\n", eeFs.mySize, sizeof(eeFs));
|
||||||
fflush(stdout);
|
fflush(stdout);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
+4
-4
@@ -111,13 +111,13 @@ static uint8_t s_copyMode = 0;
|
|||||||
static int8_t s_copySrcRow;
|
static int8_t s_copySrcRow;
|
||||||
static int8_t s_copyTgtOfs;
|
static int8_t s_copyTgtOfs;
|
||||||
|
|
||||||
inline int8_t eeFindEmptyModel(uint8_t id, bool down)
|
inline uint8_t eeFindEmptyModel(uint8_t id, bool down)
|
||||||
{
|
{
|
||||||
int8_t i = id;
|
uint8_t i = id;
|
||||||
for (;;) {
|
for (;;) {
|
||||||
i = (MAX_MODELS + (down ? i+1 : i-1)) % MAX_MODELS;
|
i = (MAX_MODELS + (down ? i+1 : i-1)) % MAX_MODELS;
|
||||||
if (!eeModelExists(i)) break;
|
if (!eeModelExists(i)) break;
|
||||||
if (i == id) return -1; // no free space in directory left
|
if (i == id) return 0xff; // no free space in directory left
|
||||||
}
|
}
|
||||||
return i;
|
return i;
|
||||||
}
|
}
|
||||||
@@ -364,7 +364,7 @@ void menuProcModelSelect(uint8_t event)
|
|||||||
s_copySrcRow = oldSub;
|
s_copySrcRow = oldSub;
|
||||||
// find a hole (in the first empty slot above / below)
|
// find a hole (in the first empty slot above / below)
|
||||||
m_posVert = eeFindEmptyModel(s_copySrcRow, _event==EVT_KEY_FIRST(KEY_DOWN));
|
m_posVert = eeFindEmptyModel(s_copySrcRow, _event==EVT_KEY_FIRST(KEY_DOWN));
|
||||||
if (m_posVert == (uint8_t)-1) {
|
if (m_posVert == 0xff) {
|
||||||
// no free room for duplicating the model
|
// no free room for duplicating the model
|
||||||
AUDIO_ERROR();
|
AUDIO_ERROR();
|
||||||
m_posVert = oldSub;
|
m_posVert = oldSub;
|
||||||
|
|||||||
@@ -671,7 +671,6 @@ void eeReadAll();
|
|||||||
bool eeModelExists(uint8_t id);
|
bool eeModelExists(uint8_t id);
|
||||||
uint16_t eeLoadModelName(uint8_t id, char *name);
|
uint16_t eeLoadModelName(uint8_t id, char *name);
|
||||||
void eeLoadModel(uint8_t id);
|
void eeLoadModel(uint8_t id);
|
||||||
int8_t eeFindEmptyModel(uint8_t id, bool down);
|
|
||||||
void generalDefault();
|
void generalDefault();
|
||||||
void modelDefault(uint8_t id);
|
void modelDefault(uint8_t id);
|
||||||
void resetProto();
|
void resetProto();
|
||||||
|
|||||||
Reference in New Issue
Block a user