CtrlLib: .usc cosmetics, initial len statust in EditText

git-svn-id: svn://ultimatepp.org/upp/trunk@6827 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
cxl 2014-01-29 14:52:22 +00:00
parent 1c46bf0596
commit ee7516201e
2 changed files with 3 additions and 2 deletions

View file

@ -543,14 +543,14 @@ subctrl EditNotNull {
ctrl EditString {
>EditNotNull;
raw MaxLen;
bool TrimLeft = false;
bool TrimRight = false;
raw MaxLen;
PaintData(w) {
text = (.NotNull ? "!" : "") + "Str";
if(.MaxLen != "")
text << " < " << .MaxLen;
text << "(" << .MaxLen << ")";
PaintText(w, text);
}
}

View file

@ -147,6 +147,7 @@ bool EditText(String& s, const char *title, const char *label, int (*f)(int), in
if(maxlen) {
dlg.text.MaxLen(maxlen);
dlg.text <<= callback3(sSyncLabel, &dlg.lbl, label, &dlg.text);
dlg.text.WhenAction();
}
if(dlg.Execute() == IDOK) {
s = dlg.text;