more verbose input(), MAXNICK reduced to 17
This commit is contained in:
parent
24965deaed
commit
793304b568
|
@ -19,7 +19,7 @@ struct CDESC {
|
||||||
#define CFG_TYPE_DEVEL 1
|
#define CFG_TYPE_DEVEL 1
|
||||||
#define CFG_TYPE_FLAME 2
|
#define CFG_TYPE_FLAME 2
|
||||||
|
|
||||||
#define MAXNICK 20
|
#define MAXNICK 17
|
||||||
extern struct CDESC the_config[];
|
extern struct CDESC the_config[];
|
||||||
extern char nickname[];
|
extern char nickname[];
|
||||||
extern char nickfont[];
|
extern char nickfont[];
|
||||||
|
|
|
@ -80,6 +80,7 @@ static void inputMove() {
|
||||||
|
|
||||||
static void inputDraw() {
|
static void inputDraw() {
|
||||||
char tmp[2]= {0,0};
|
char tmp[2]= {0,0};
|
||||||
|
int pos = 0;
|
||||||
lcdClear();
|
lcdClear();
|
||||||
DoString(0,0,s_input.prompt);
|
DoString(0,0,s_input.prompt);
|
||||||
for (int dx = 0; dx<= RESX/CHARWIDTH && s_input.pos+dx<s_input.maxlength; dx++){
|
for (int dx = 0; dx<= RESX/CHARWIDTH && s_input.pos+dx<s_input.maxlength; dx++){
|
||||||
|
@ -87,6 +88,12 @@ static void inputDraw() {
|
||||||
DoString(dx*CHARWIDTH, 30,tmp);
|
DoString(dx*CHARWIDTH, 30,tmp);
|
||||||
}
|
}
|
||||||
DoString(s_input.dcursor * CHARWIDTH, 40, "-");
|
DoString(s_input.dcursor * CHARWIDTH, 40, "-");
|
||||||
|
|
||||||
|
pos = DoString(0,60,"[");
|
||||||
|
pos = DoInt(pos,60,s_input.pos+s_input.dcursor+1);
|
||||||
|
pos = DoString(pos,60,"/");
|
||||||
|
pos = DoInt(pos,60,s_input.maxlength);
|
||||||
|
DoString(pos,60,"]");
|
||||||
}
|
}
|
||||||
|
|
||||||
static void inputClean() {
|
static void inputClean() {
|
||||||
|
|
Loading…
Reference in New Issue