- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
- 09
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
App.ns.SomeClass.prototype = {
addMessage: function(status, msg, timeDelay) {
if (status === false || status === this.STATUS_ERROR) {
status = this.STATUS_ERROR;
delay = timeDelay || 5; // default delay of msg box for error is 5 seconds.
}
if (!timeDelay) {
// 1 character - 1/7 sec
delay = msg.length / 7;
if ((delay < 3) && !(timeDelay)) {
delay = 3;
} else if ((delay > 30) && !(timeDelay)) {
delay = 30;
}
}
// показываем messagebox
}
};
|| DEFAULT_MSGBOX_DELAY ?
надо будет писать