rem
stringlengths
0
126k
add
stringlengths
0
441k
context
stringlengths
15
136k
this.map.setCenter(olCenter, yZoom - 1);
this.map.setCenter(olCenter, 16 - yZoom);
catchPanZoom: function(e) { var olCenter = this.getYMapCenter(); var yZoom = this.ymap.getZoomLevel(); this.map.setCenter(olCenter, yZoom - 1); },
var gCenter = this.gmap.getCenter(); var gZoom = this.gmap.getZoom(); var olCenter = this.getOLLonLatFromGLatLng(gCenter); var olZoom = this.getOLZoomFromGZoom(gZoom); this.map.setCenter(olCenter, olZoom);
var gCenter = this.gmap.getCenter(); var gZoom = this.gmap.getZoom(); var olCenter = this.getOLLonLatFromGLatLng(gCenter); var olZoom = this.getOLZoomFromGZoom(gZoom); this.map.setCenter(olCenter, olZoom, this.dragging); }
catchPanZoom: function(e) { var gCenter = this.gmap.getCenter(); var gZoom = this.gmap.getZoom(); var olCenter = this.getOLLonLatFromGLatLng(gCenter); var olZoom = this.getOLZoomFromGZoom(gZoom); this.map.setCenter(olCenter, olZoom); },
Calendar.removeClass(cal.currentDateEl, "selected"); Calendar.addClass(el, "selected"); closing = (cal.currentDateEl == el); if (!closing) { cal.currentDateEl = el;
if (cal.currentDateEl) { Calendar.removeClass(cal.currentDateEl, "selected"); Calendar.addClass(el, "selected"); closing = (cal.currentDateEl == el); if (!closing) { cal.currentDateEl = el; }
Calendar.cellClick = function(el, ev) { var cal = el.calendar; var closing = false; var newdate = false; var date = null; if (typeof el.navtype == "undefined") { Calendar.removeClass(cal.currentDateEl, "selected"); Calendar.addClass(el, "selected"); closing = (cal.currentDateEl == el); if (!closing) { cal.currentDateEl = el; } cal.date = new Date(el.caldate); date = cal.date; newdate = true; // a date was clicked if (!(cal.dateClicked = !el.otherMonth)) cal._init(cal.firstDayOfWeek, date); } else { if (el.navtype == 200) { Calendar.removeClass(el, "hilite"); cal.callCloseHandler(); return; } date = (el.navtype == 0) ? new Date() : new Date(cal.date); // unless "today" was clicked, we assume no date was clicked so // the selected handler will know not to close the calenar when // in single-click mode. // cal.dateClicked = (el.navtype == 0); cal.dateClicked = false; var year = date.getFullYear(); var mon = date.getMonth(); function setMonth(m) { var day = date.getDate(); var max = date.getMonthDays(m); if (day > max) { date.setDate(max); } date.setMonth(m); }; switch (el.navtype) { case 400: Calendar.removeClass(el, "hilite"); var text = Calendar._TT["ABOUT"]; if (typeof text != "undefined") { text += cal.showsTime ? Calendar._TT["ABOUT_TIME"] : ""; } else { // FIXME: this should be removed as soon as lang files get updated! text = "Help and about box text is not translated into this language.\n" + "If you know this language and you feel generous please update\n" + "the corresponding file in \"lang\" subdir to match calendar-en.js\n" + "and send it back to <[email protected]> to get it into the distribution ;-)\n\n" + "Thank you!\n" + "http://dynarch.com/mishoo/calendar.epl\n"; } alert(text); return; case -2: if (year > cal.minYear) { date.setFullYear(year - 1); } break; case -1: if (mon > 0) { setMonth(mon - 1); } else if (year-- > cal.minYear) { date.setFullYear(year); setMonth(11); } break; case 1: if (mon < 11) { setMonth(mon + 1); } else if (year < cal.maxYear) { date.setFullYear(year + 1); setMonth(0); } break; case 2: if (year < cal.maxYear) { date.setFullYear(year + 1); } break; case 100: cal.setFirstDayOfWeek(el.fdow); return; case 50: var range = el._range; var current = el.firstChild.data; for (var i = range.length; --i >= 0;) if (range[i] == current) break; if (ev && ev.shiftKey) { if (--i < 0) i = range.length - 1; } else if ( ++i >= range.length ) i = 0; var newval = range[i]; el.firstChild.data = newval; cal.onUpdateTime(); return; case 0: // TODAY will bring us here if ((typeof cal.getDateStatus == "function") && cal.getDateStatus(date, date.getFullYear(), date.getMonth(), date.getDate())) { // remember, "date" was previously set to new // Date() if TODAY was clicked; thus, it // contains today date. return false; } break; } if (!date.equalsTo(cal.date)) { cal.setDate(date); newdate = true; } } if (newdate) { cal.callHandler(); } if (closing) { Calendar.removeClass(el, "hilite"); cal.callCloseHandler(); }};
cal.date = new Date(el.caldate);
cal.date.setDateOnly(el.caldate);
Calendar.cellClick = function(el, ev) { var cal = el.calendar; var closing = false; var newdate = false; var date = null; if (typeof el.navtype == "undefined") { Calendar.removeClass(cal.currentDateEl, "selected"); Calendar.addClass(el, "selected"); closing = (cal.currentDateEl == el); if (!closing) { cal.currentDateEl = el; } cal.date = new Date(el.caldate); date = cal.date; newdate = true; // a date was clicked if (!(cal.dateClicked = !el.otherMonth)) cal._init(cal.firstDayOfWeek, date); } else { if (el.navtype == 200) { Calendar.removeClass(el, "hilite"); cal.callCloseHandler(); return; } date = (el.navtype == 0) ? new Date() : new Date(cal.date); // unless "today" was clicked, we assume no date was clicked so // the selected handler will know not to close the calenar when // in single-click mode. // cal.dateClicked = (el.navtype == 0); cal.dateClicked = false; var year = date.getFullYear(); var mon = date.getMonth(); function setMonth(m) { var day = date.getDate(); var max = date.getMonthDays(m); if (day > max) { date.setDate(max); } date.setMonth(m); }; switch (el.navtype) { case 400: Calendar.removeClass(el, "hilite"); var text = Calendar._TT["ABOUT"]; if (typeof text != "undefined") { text += cal.showsTime ? Calendar._TT["ABOUT_TIME"] : ""; } else { // FIXME: this should be removed as soon as lang files get updated! text = "Help and about box text is not translated into this language.\n" + "If you know this language and you feel generous please update\n" + "the corresponding file in \"lang\" subdir to match calendar-en.js\n" + "and send it back to <[email protected]> to get it into the distribution ;-)\n\n" + "Thank you!\n" + "http://dynarch.com/mishoo/calendar.epl\n"; } alert(text); return; case -2: if (year > cal.minYear) { date.setFullYear(year - 1); } break; case -1: if (mon > 0) { setMonth(mon - 1); } else if (year-- > cal.minYear) { date.setFullYear(year); setMonth(11); } break; case 1: if (mon < 11) { setMonth(mon + 1); } else if (year < cal.maxYear) { date.setFullYear(year + 1); setMonth(0); } break; case 2: if (year < cal.maxYear) { date.setFullYear(year + 1); } break; case 100: cal.setFirstDayOfWeek(el.fdow); return; case 50: var range = el._range; var current = el.firstChild.data; for (var i = range.length; --i >= 0;) if (range[i] == current) break; if (ev && ev.shiftKey) { if (--i < 0) i = range.length - 1; } else if ( ++i >= range.length ) i = 0; var newval = range[i]; el.firstChild.data = newval; cal.onUpdateTime(); return; case 0: // TODAY will bring us here if ((typeof cal.getDateStatus == "function") && cal.getDateStatus(date, date.getFullYear(), date.getMonth(), date.getDate())) { // remember, "date" was previously set to new // Date() if TODAY was clicked; thus, it // contains today date. return false; } break; } if (!date.equalsTo(cal.date)) { cal.setDate(date); newdate = true; } } if (newdate) { cal.callHandler(); } if (closing) { Calendar.removeClass(el, "hilite"); cal.callCloseHandler(); }};
newdate = true;
var other_month = !(cal.dateClicked = !el.otherMonth); if (!other_month && !cal.currentDateEl) cal._toggleMultipleDate(new Date(date)); else newdate = !el.disabled;
Calendar.cellClick = function(el, ev) { var cal = el.calendar; var closing = false; var newdate = false; var date = null; if (typeof el.navtype == "undefined") { Calendar.removeClass(cal.currentDateEl, "selected"); Calendar.addClass(el, "selected"); closing = (cal.currentDateEl == el); if (!closing) { cal.currentDateEl = el; } cal.date = new Date(el.caldate); date = cal.date; newdate = true; // a date was clicked if (!(cal.dateClicked = !el.otherMonth)) cal._init(cal.firstDayOfWeek, date); } else { if (el.navtype == 200) { Calendar.removeClass(el, "hilite"); cal.callCloseHandler(); return; } date = (el.navtype == 0) ? new Date() : new Date(cal.date); // unless "today" was clicked, we assume no date was clicked so // the selected handler will know not to close the calenar when // in single-click mode. // cal.dateClicked = (el.navtype == 0); cal.dateClicked = false; var year = date.getFullYear(); var mon = date.getMonth(); function setMonth(m) { var day = date.getDate(); var max = date.getMonthDays(m); if (day > max) { date.setDate(max); } date.setMonth(m); }; switch (el.navtype) { case 400: Calendar.removeClass(el, "hilite"); var text = Calendar._TT["ABOUT"]; if (typeof text != "undefined") { text += cal.showsTime ? Calendar._TT["ABOUT_TIME"] : ""; } else { // FIXME: this should be removed as soon as lang files get updated! text = "Help and about box text is not translated into this language.\n" + "If you know this language and you feel generous please update\n" + "the corresponding file in \"lang\" subdir to match calendar-en.js\n" + "and send it back to <[email protected]> to get it into the distribution ;-)\n\n" + "Thank you!\n" + "http://dynarch.com/mishoo/calendar.epl\n"; } alert(text); return; case -2: if (year > cal.minYear) { date.setFullYear(year - 1); } break; case -1: if (mon > 0) { setMonth(mon - 1); } else if (year-- > cal.minYear) { date.setFullYear(year); setMonth(11); } break; case 1: if (mon < 11) { setMonth(mon + 1); } else if (year < cal.maxYear) { date.setFullYear(year + 1); setMonth(0); } break; case 2: if (year < cal.maxYear) { date.setFullYear(year + 1); } break; case 100: cal.setFirstDayOfWeek(el.fdow); return; case 50: var range = el._range; var current = el.firstChild.data; for (var i = range.length; --i >= 0;) if (range[i] == current) break; if (ev && ev.shiftKey) { if (--i < 0) i = range.length - 1; } else if ( ++i >= range.length ) i = 0; var newval = range[i]; el.firstChild.data = newval; cal.onUpdateTime(); return; case 0: // TODAY will bring us here if ((typeof cal.getDateStatus == "function") && cal.getDateStatus(date, date.getFullYear(), date.getMonth(), date.getDate())) { // remember, "date" was previously set to new // Date() if TODAY was clicked; thus, it // contains today date. return false; } break; } if (!date.equalsTo(cal.date)) { cal.setDate(date); newdate = true; } } if (newdate) { cal.callHandler(); } if (closing) { Calendar.removeClass(el, "hilite"); cal.callCloseHandler(); }};
if (!(cal.dateClicked = !el.otherMonth))
if (other_month)
Calendar.cellClick = function(el, ev) { var cal = el.calendar; var closing = false; var newdate = false; var date = null; if (typeof el.navtype == "undefined") { Calendar.removeClass(cal.currentDateEl, "selected"); Calendar.addClass(el, "selected"); closing = (cal.currentDateEl == el); if (!closing) { cal.currentDateEl = el; } cal.date = new Date(el.caldate); date = cal.date; newdate = true; // a date was clicked if (!(cal.dateClicked = !el.otherMonth)) cal._init(cal.firstDayOfWeek, date); } else { if (el.navtype == 200) { Calendar.removeClass(el, "hilite"); cal.callCloseHandler(); return; } date = (el.navtype == 0) ? new Date() : new Date(cal.date); // unless "today" was clicked, we assume no date was clicked so // the selected handler will know not to close the calenar when // in single-click mode. // cal.dateClicked = (el.navtype == 0); cal.dateClicked = false; var year = date.getFullYear(); var mon = date.getMonth(); function setMonth(m) { var day = date.getDate(); var max = date.getMonthDays(m); if (day > max) { date.setDate(max); } date.setMonth(m); }; switch (el.navtype) { case 400: Calendar.removeClass(el, "hilite"); var text = Calendar._TT["ABOUT"]; if (typeof text != "undefined") { text += cal.showsTime ? Calendar._TT["ABOUT_TIME"] : ""; } else { // FIXME: this should be removed as soon as lang files get updated! text = "Help and about box text is not translated into this language.\n" + "If you know this language and you feel generous please update\n" + "the corresponding file in \"lang\" subdir to match calendar-en.js\n" + "and send it back to <[email protected]> to get it into the distribution ;-)\n\n" + "Thank you!\n" + "http://dynarch.com/mishoo/calendar.epl\n"; } alert(text); return; case -2: if (year > cal.minYear) { date.setFullYear(year - 1); } break; case -1: if (mon > 0) { setMonth(mon - 1); } else if (year-- > cal.minYear) { date.setFullYear(year); setMonth(11); } break; case 1: if (mon < 11) { setMonth(mon + 1); } else if (year < cal.maxYear) { date.setFullYear(year + 1); setMonth(0); } break; case 2: if (year < cal.maxYear) { date.setFullYear(year + 1); } break; case 100: cal.setFirstDayOfWeek(el.fdow); return; case 50: var range = el._range; var current = el.firstChild.data; for (var i = range.length; --i >= 0;) if (range[i] == current) break; if (ev && ev.shiftKey) { if (--i < 0) i = range.length - 1; } else if ( ++i >= range.length ) i = 0; var newval = range[i]; el.firstChild.data = newval; cal.onUpdateTime(); return; case 0: // TODAY will bring us here if ((typeof cal.getDateStatus == "function") && cal.getDateStatus(date, date.getFullYear(), date.getMonth(), date.getDate())) { // remember, "date" was previously set to new // Date() if TODAY was clicked; thus, it // contains today date. return false; } break; } if (!date.equalsTo(cal.date)) { cal.setDate(date); newdate = true; } } if (newdate) { cal.callHandler(); } if (closing) { Calendar.removeClass(el, "hilite"); cal.callCloseHandler(); }};
date = (el.navtype == 0) ? new Date() : new Date(cal.date);
date = new Date(cal.date); if (el.navtype == 0) date.setDateOnly(new Date());
Calendar.cellClick = function(el, ev) { var cal = el.calendar; var closing = false; var newdate = false; var date = null; if (typeof el.navtype == "undefined") { Calendar.removeClass(cal.currentDateEl, "selected"); Calendar.addClass(el, "selected"); closing = (cal.currentDateEl == el); if (!closing) { cal.currentDateEl = el; } cal.date = new Date(el.caldate); date = cal.date; newdate = true; // a date was clicked if (!(cal.dateClicked = !el.otherMonth)) cal._init(cal.firstDayOfWeek, date); } else { if (el.navtype == 200) { Calendar.removeClass(el, "hilite"); cal.callCloseHandler(); return; } date = (el.navtype == 0) ? new Date() : new Date(cal.date); // unless "today" was clicked, we assume no date was clicked so // the selected handler will know not to close the calenar when // in single-click mode. // cal.dateClicked = (el.navtype == 0); cal.dateClicked = false; var year = date.getFullYear(); var mon = date.getMonth(); function setMonth(m) { var day = date.getDate(); var max = date.getMonthDays(m); if (day > max) { date.setDate(max); } date.setMonth(m); }; switch (el.navtype) { case 400: Calendar.removeClass(el, "hilite"); var text = Calendar._TT["ABOUT"]; if (typeof text != "undefined") { text += cal.showsTime ? Calendar._TT["ABOUT_TIME"] : ""; } else { // FIXME: this should be removed as soon as lang files get updated! text = "Help and about box text is not translated into this language.\n" + "If you know this language and you feel generous please update\n" + "the corresponding file in \"lang\" subdir to match calendar-en.js\n" + "and send it back to <[email protected]> to get it into the distribution ;-)\n\n" + "Thank you!\n" + "http://dynarch.com/mishoo/calendar.epl\n"; } alert(text); return; case -2: if (year > cal.minYear) { date.setFullYear(year - 1); } break; case -1: if (mon > 0) { setMonth(mon - 1); } else if (year-- > cal.minYear) { date.setFullYear(year); setMonth(11); } break; case 1: if (mon < 11) { setMonth(mon + 1); } else if (year < cal.maxYear) { date.setFullYear(year + 1); setMonth(0); } break; case 2: if (year < cal.maxYear) { date.setFullYear(year + 1); } break; case 100: cal.setFirstDayOfWeek(el.fdow); return; case 50: var range = el._range; var current = el.firstChild.data; for (var i = range.length; --i >= 0;) if (range[i] == current) break; if (ev && ev.shiftKey) { if (--i < 0) i = range.length - 1; } else if ( ++i >= range.length ) i = 0; var newval = range[i]; el.firstChild.data = newval; cal.onUpdateTime(); return; case 0: // TODAY will bring us here if ((typeof cal.getDateStatus == "function") && cal.getDateStatus(date, date.getFullYear(), date.getMonth(), date.getDate())) { // remember, "date" was previously set to new // Date() if TODAY was clicked; thus, it // contains today date. return false; } break; } if (!date.equalsTo(cal.date)) { cal.setDate(date); newdate = true; } } if (newdate) { cal.callHandler(); } if (closing) { Calendar.removeClass(el, "hilite"); cal.callCloseHandler(); }};
"and send it back to <[email protected]> to get it into the distribution ;-)\n\n" +
"and send it back to <[email protected]> to get it into the distribution ;-)\n\n" +
Calendar.cellClick = function(el, ev) { var cal = el.calendar; var closing = false; var newdate = false; var date = null; if (typeof el.navtype == "undefined") { Calendar.removeClass(cal.currentDateEl, "selected"); Calendar.addClass(el, "selected"); closing = (cal.currentDateEl == el); if (!closing) { cal.currentDateEl = el; } cal.date = new Date(el.caldate); date = cal.date; newdate = true; // a date was clicked if (!(cal.dateClicked = !el.otherMonth)) cal._init(cal.firstDayOfWeek, date); } else { if (el.navtype == 200) { Calendar.removeClass(el, "hilite"); cal.callCloseHandler(); return; } date = (el.navtype == 0) ? new Date() : new Date(cal.date); // unless "today" was clicked, we assume no date was clicked so // the selected handler will know not to close the calenar when // in single-click mode. // cal.dateClicked = (el.navtype == 0); cal.dateClicked = false; var year = date.getFullYear(); var mon = date.getMonth(); function setMonth(m) { var day = date.getDate(); var max = date.getMonthDays(m); if (day > max) { date.setDate(max); } date.setMonth(m); }; switch (el.navtype) { case 400: Calendar.removeClass(el, "hilite"); var text = Calendar._TT["ABOUT"]; if (typeof text != "undefined") { text += cal.showsTime ? Calendar._TT["ABOUT_TIME"] : ""; } else { // FIXME: this should be removed as soon as lang files get updated! text = "Help and about box text is not translated into this language.\n" + "If you know this language and you feel generous please update\n" + "the corresponding file in \"lang\" subdir to match calendar-en.js\n" + "and send it back to <[email protected]> to get it into the distribution ;-)\n\n" + "Thank you!\n" + "http://dynarch.com/mishoo/calendar.epl\n"; } alert(text); return; case -2: if (year > cal.minYear) { date.setFullYear(year - 1); } break; case -1: if (mon > 0) { setMonth(mon - 1); } else if (year-- > cal.minYear) { date.setFullYear(year); setMonth(11); } break; case 1: if (mon < 11) { setMonth(mon + 1); } else if (year < cal.maxYear) { date.setFullYear(year + 1); setMonth(0); } break; case 2: if (year < cal.maxYear) { date.setFullYear(year + 1); } break; case 100: cal.setFirstDayOfWeek(el.fdow); return; case 50: var range = el._range; var current = el.firstChild.data; for (var i = range.length; --i >= 0;) if (range[i] == current) break; if (ev && ev.shiftKey) { if (--i < 0) i = range.length - 1; } else if ( ++i >= range.length ) i = 0; var newval = range[i]; el.firstChild.data = newval; cal.onUpdateTime(); return; case 0: // TODAY will bring us here if ((typeof cal.getDateStatus == "function") && cal.getDateStatus(date, date.getFullYear(), date.getMonth(), date.getDate())) { // remember, "date" was previously set to new // Date() if TODAY was clicked; thus, it // contains today date. return false; } break; } if (!date.equalsTo(cal.date)) { cal.setDate(date); newdate = true; } } if (newdate) { cal.callHandler(); } if (closing) { Calendar.removeClass(el, "hilite"); cal.callCloseHandler(); }};
var current = el.firstChild.data;
var current = el.innerHTML;
Calendar.cellClick = function(el, ev) { var cal = el.calendar; var closing = false; var newdate = false; var date = null; if (typeof el.navtype == "undefined") { Calendar.removeClass(cal.currentDateEl, "selected"); Calendar.addClass(el, "selected"); closing = (cal.currentDateEl == el); if (!closing) { cal.currentDateEl = el; } cal.date = new Date(el.caldate); date = cal.date; newdate = true; // a date was clicked if (!(cal.dateClicked = !el.otherMonth)) cal._init(cal.firstDayOfWeek, date); } else { if (el.navtype == 200) { Calendar.removeClass(el, "hilite"); cal.callCloseHandler(); return; } date = (el.navtype == 0) ? new Date() : new Date(cal.date); // unless "today" was clicked, we assume no date was clicked so // the selected handler will know not to close the calenar when // in single-click mode. // cal.dateClicked = (el.navtype == 0); cal.dateClicked = false; var year = date.getFullYear(); var mon = date.getMonth(); function setMonth(m) { var day = date.getDate(); var max = date.getMonthDays(m); if (day > max) { date.setDate(max); } date.setMonth(m); }; switch (el.navtype) { case 400: Calendar.removeClass(el, "hilite"); var text = Calendar._TT["ABOUT"]; if (typeof text != "undefined") { text += cal.showsTime ? Calendar._TT["ABOUT_TIME"] : ""; } else { // FIXME: this should be removed as soon as lang files get updated! text = "Help and about box text is not translated into this language.\n" + "If you know this language and you feel generous please update\n" + "the corresponding file in \"lang\" subdir to match calendar-en.js\n" + "and send it back to <[email protected]> to get it into the distribution ;-)\n\n" + "Thank you!\n" + "http://dynarch.com/mishoo/calendar.epl\n"; } alert(text); return; case -2: if (year > cal.minYear) { date.setFullYear(year - 1); } break; case -1: if (mon > 0) { setMonth(mon - 1); } else if (year-- > cal.minYear) { date.setFullYear(year); setMonth(11); } break; case 1: if (mon < 11) { setMonth(mon + 1); } else if (year < cal.maxYear) { date.setFullYear(year + 1); setMonth(0); } break; case 2: if (year < cal.maxYear) { date.setFullYear(year + 1); } break; case 100: cal.setFirstDayOfWeek(el.fdow); return; case 50: var range = el._range; var current = el.firstChild.data; for (var i = range.length; --i >= 0;) if (range[i] == current) break; if (ev && ev.shiftKey) { if (--i < 0) i = range.length - 1; } else if ( ++i >= range.length ) i = 0; var newval = range[i]; el.firstChild.data = newval; cal.onUpdateTime(); return; case 0: // TODAY will bring us here if ((typeof cal.getDateStatus == "function") && cal.getDateStatus(date, date.getFullYear(), date.getMonth(), date.getDate())) { // remember, "date" was previously set to new // Date() if TODAY was clicked; thus, it // contains today date. return false; } break; } if (!date.equalsTo(cal.date)) { cal.setDate(date); newdate = true; } } if (newdate) { cal.callHandler(); } if (closing) { Calendar.removeClass(el, "hilite"); cal.callCloseHandler(); }};
el.firstChild.data = newval;
el.innerHTML = newval;
Calendar.cellClick = function(el, ev) { var cal = el.calendar; var closing = false; var newdate = false; var date = null; if (typeof el.navtype == "undefined") { Calendar.removeClass(cal.currentDateEl, "selected"); Calendar.addClass(el, "selected"); closing = (cal.currentDateEl == el); if (!closing) { cal.currentDateEl = el; } cal.date = new Date(el.caldate); date = cal.date; newdate = true; // a date was clicked if (!(cal.dateClicked = !el.otherMonth)) cal._init(cal.firstDayOfWeek, date); } else { if (el.navtype == 200) { Calendar.removeClass(el, "hilite"); cal.callCloseHandler(); return; } date = (el.navtype == 0) ? new Date() : new Date(cal.date); // unless "today" was clicked, we assume no date was clicked so // the selected handler will know not to close the calenar when // in single-click mode. // cal.dateClicked = (el.navtype == 0); cal.dateClicked = false; var year = date.getFullYear(); var mon = date.getMonth(); function setMonth(m) { var day = date.getDate(); var max = date.getMonthDays(m); if (day > max) { date.setDate(max); } date.setMonth(m); }; switch (el.navtype) { case 400: Calendar.removeClass(el, "hilite"); var text = Calendar._TT["ABOUT"]; if (typeof text != "undefined") { text += cal.showsTime ? Calendar._TT["ABOUT_TIME"] : ""; } else { // FIXME: this should be removed as soon as lang files get updated! text = "Help and about box text is not translated into this language.\n" + "If you know this language and you feel generous please update\n" + "the corresponding file in \"lang\" subdir to match calendar-en.js\n" + "and send it back to <[email protected]> to get it into the distribution ;-)\n\n" + "Thank you!\n" + "http://dynarch.com/mishoo/calendar.epl\n"; } alert(text); return; case -2: if (year > cal.minYear) { date.setFullYear(year - 1); } break; case -1: if (mon > 0) { setMonth(mon - 1); } else if (year-- > cal.minYear) { date.setFullYear(year); setMonth(11); } break; case 1: if (mon < 11) { setMonth(mon + 1); } else if (year < cal.maxYear) { date.setFullYear(year + 1); setMonth(0); } break; case 2: if (year < cal.maxYear) { date.setFullYear(year + 1); } break; case 100: cal.setFirstDayOfWeek(el.fdow); return; case 50: var range = el._range; var current = el.firstChild.data; for (var i = range.length; --i >= 0;) if (range[i] == current) break; if (ev && ev.shiftKey) { if (--i < 0) i = range.length - 1; } else if ( ++i >= range.length ) i = 0; var newval = range[i]; el.firstChild.data = newval; cal.onUpdateTime(); return; case 0: // TODAY will bring us here if ((typeof cal.getDateStatus == "function") && cal.getDateStatus(date, date.getFullYear(), date.getMonth(), date.getDate())) { // remember, "date" was previously set to new // Date() if TODAY was clicked; thus, it // contains today date. return false; } break; } if (!date.equalsTo(cal.date)) { cal.setDate(date); newdate = true; } } if (newdate) { cal.callHandler(); } if (closing) { Calendar.removeClass(el, "hilite"); cal.callCloseHandler(); }};
}
} else if (el.navtype == 0) newdate = closing = true;
Calendar.cellClick = function(el, ev) { var cal = el.calendar; var closing = false; var newdate = false; var date = null; if (typeof el.navtype == "undefined") { Calendar.removeClass(cal.currentDateEl, "selected"); Calendar.addClass(el, "selected"); closing = (cal.currentDateEl == el); if (!closing) { cal.currentDateEl = el; } cal.date = new Date(el.caldate); date = cal.date; newdate = true; // a date was clicked if (!(cal.dateClicked = !el.otherMonth)) cal._init(cal.firstDayOfWeek, date); } else { if (el.navtype == 200) { Calendar.removeClass(el, "hilite"); cal.callCloseHandler(); return; } date = (el.navtype == 0) ? new Date() : new Date(cal.date); // unless "today" was clicked, we assume no date was clicked so // the selected handler will know not to close the calenar when // in single-click mode. // cal.dateClicked = (el.navtype == 0); cal.dateClicked = false; var year = date.getFullYear(); var mon = date.getMonth(); function setMonth(m) { var day = date.getDate(); var max = date.getMonthDays(m); if (day > max) { date.setDate(max); } date.setMonth(m); }; switch (el.navtype) { case 400: Calendar.removeClass(el, "hilite"); var text = Calendar._TT["ABOUT"]; if (typeof text != "undefined") { text += cal.showsTime ? Calendar._TT["ABOUT_TIME"] : ""; } else { // FIXME: this should be removed as soon as lang files get updated! text = "Help and about box text is not translated into this language.\n" + "If you know this language and you feel generous please update\n" + "the corresponding file in \"lang\" subdir to match calendar-en.js\n" + "and send it back to <[email protected]> to get it into the distribution ;-)\n\n" + "Thank you!\n" + "http://dynarch.com/mishoo/calendar.epl\n"; } alert(text); return; case -2: if (year > cal.minYear) { date.setFullYear(year - 1); } break; case -1: if (mon > 0) { setMonth(mon - 1); } else if (year-- > cal.minYear) { date.setFullYear(year); setMonth(11); } break; case 1: if (mon < 11) { setMonth(mon + 1); } else if (year < cal.maxYear) { date.setFullYear(year + 1); setMonth(0); } break; case 2: if (year < cal.maxYear) { date.setFullYear(year + 1); } break; case 100: cal.setFirstDayOfWeek(el.fdow); return; case 50: var range = el._range; var current = el.firstChild.data; for (var i = range.length; --i >= 0;) if (range[i] == current) break; if (ev && ev.shiftKey) { if (--i < 0) i = range.length - 1; } else if ( ++i >= range.length ) i = 0; var newval = range[i]; el.firstChild.data = newval; cal.onUpdateTime(); return; case 0: // TODAY will bring us here if ((typeof cal.getDateStatus == "function") && cal.getDateStatus(date, date.getFullYear(), date.getMonth(), date.getDate())) { // remember, "date" was previously set to new // Date() if TODAY was clicked; thus, it // contains today date. return false; } break; } if (!date.equalsTo(cal.date)) { cal.setDate(date); newdate = true; } } if (newdate) { cal.callHandler(); } if (closing) { Calendar.removeClass(el, "hilite"); cal.callCloseHandler(); }};
cal.callHandler();
ev && cal.callHandler();
Calendar.cellClick = function(el, ev) { var cal = el.calendar; var closing = false; var newdate = false; var date = null; if (typeof el.navtype == "undefined") { Calendar.removeClass(cal.currentDateEl, "selected"); Calendar.addClass(el, "selected"); closing = (cal.currentDateEl == el); if (!closing) { cal.currentDateEl = el; } cal.date = new Date(el.caldate); date = cal.date; newdate = true; // a date was clicked if (!(cal.dateClicked = !el.otherMonth)) cal._init(cal.firstDayOfWeek, date); } else { if (el.navtype == 200) { Calendar.removeClass(el, "hilite"); cal.callCloseHandler(); return; } date = (el.navtype == 0) ? new Date() : new Date(cal.date); // unless "today" was clicked, we assume no date was clicked so // the selected handler will know not to close the calenar when // in single-click mode. // cal.dateClicked = (el.navtype == 0); cal.dateClicked = false; var year = date.getFullYear(); var mon = date.getMonth(); function setMonth(m) { var day = date.getDate(); var max = date.getMonthDays(m); if (day > max) { date.setDate(max); } date.setMonth(m); }; switch (el.navtype) { case 400: Calendar.removeClass(el, "hilite"); var text = Calendar._TT["ABOUT"]; if (typeof text != "undefined") { text += cal.showsTime ? Calendar._TT["ABOUT_TIME"] : ""; } else { // FIXME: this should be removed as soon as lang files get updated! text = "Help and about box text is not translated into this language.\n" + "If you know this language and you feel generous please update\n" + "the corresponding file in \"lang\" subdir to match calendar-en.js\n" + "and send it back to <[email protected]> to get it into the distribution ;-)\n\n" + "Thank you!\n" + "http://dynarch.com/mishoo/calendar.epl\n"; } alert(text); return; case -2: if (year > cal.minYear) { date.setFullYear(year - 1); } break; case -1: if (mon > 0) { setMonth(mon - 1); } else if (year-- > cal.minYear) { date.setFullYear(year); setMonth(11); } break; case 1: if (mon < 11) { setMonth(mon + 1); } else if (year < cal.maxYear) { date.setFullYear(year + 1); setMonth(0); } break; case 2: if (year < cal.maxYear) { date.setFullYear(year + 1); } break; case 100: cal.setFirstDayOfWeek(el.fdow); return; case 50: var range = el._range; var current = el.firstChild.data; for (var i = range.length; --i >= 0;) if (range[i] == current) break; if (ev && ev.shiftKey) { if (--i < 0) i = range.length - 1; } else if ( ++i >= range.length ) i = 0; var newval = range[i]; el.firstChild.data = newval; cal.onUpdateTime(); return; case 0: // TODAY will bring us here if ((typeof cal.getDateStatus == "function") && cal.getDateStatus(date, date.getFullYear(), date.getMonth(), date.getDate())) { // remember, "date" was previously set to new // Date() if TODAY was clicked; thus, it // contains today date. return false; } break; } if (!date.equalsTo(cal.date)) { cal.setDate(date); newdate = true; } } if (newdate) { cal.callHandler(); } if (closing) { Calendar.removeClass(el, "hilite"); cal.callCloseHandler(); }};
cal.callCloseHandler();
ev && cal.callCloseHandler();
Calendar.cellClick = function(el, ev) { var cal = el.calendar; var closing = false; var newdate = false; var date = null; if (typeof el.navtype == "undefined") { Calendar.removeClass(cal.currentDateEl, "selected"); Calendar.addClass(el, "selected"); closing = (cal.currentDateEl == el); if (!closing) { cal.currentDateEl = el; } cal.date = new Date(el.caldate); date = cal.date; newdate = true; // a date was clicked if (!(cal.dateClicked = !el.otherMonth)) cal._init(cal.firstDayOfWeek, date); } else { if (el.navtype == 200) { Calendar.removeClass(el, "hilite"); cal.callCloseHandler(); return; } date = (el.navtype == 0) ? new Date() : new Date(cal.date); // unless "today" was clicked, we assume no date was clicked so // the selected handler will know not to close the calenar when // in single-click mode. // cal.dateClicked = (el.navtype == 0); cal.dateClicked = false; var year = date.getFullYear(); var mon = date.getMonth(); function setMonth(m) { var day = date.getDate(); var max = date.getMonthDays(m); if (day > max) { date.setDate(max); } date.setMonth(m); }; switch (el.navtype) { case 400: Calendar.removeClass(el, "hilite"); var text = Calendar._TT["ABOUT"]; if (typeof text != "undefined") { text += cal.showsTime ? Calendar._TT["ABOUT_TIME"] : ""; } else { // FIXME: this should be removed as soon as lang files get updated! text = "Help and about box text is not translated into this language.\n" + "If you know this language and you feel generous please update\n" + "the corresponding file in \"lang\" subdir to match calendar-en.js\n" + "and send it back to <[email protected]> to get it into the distribution ;-)\n\n" + "Thank you!\n" + "http://dynarch.com/mishoo/calendar.epl\n"; } alert(text); return; case -2: if (year > cal.minYear) { date.setFullYear(year - 1); } break; case -1: if (mon > 0) { setMonth(mon - 1); } else if (year-- > cal.minYear) { date.setFullYear(year); setMonth(11); } break; case 1: if (mon < 11) { setMonth(mon + 1); } else if (year < cal.maxYear) { date.setFullYear(year + 1); setMonth(0); } break; case 2: if (year < cal.maxYear) { date.setFullYear(year + 1); } break; case 100: cal.setFirstDayOfWeek(el.fdow); return; case 50: var range = el._range; var current = el.firstChild.data; for (var i = range.length; --i >= 0;) if (range[i] == current) break; if (ev && ev.shiftKey) { if (--i < 0) i = range.length - 1; } else if ( ++i >= range.length ) i = 0; var newval = range[i]; el.firstChild.data = newval; cal.onUpdateTime(); return; case 0: // TODAY will bring us here if ((typeof cal.getDateStatus == "function") && cal.getDateStatus(date, date.getFullYear(), date.getMonth(), date.getDate())) { // remember, "date" was previously set to new // Date() if TODAY was clicked; thus, it // contains today date. return false; } break; } if (!date.equalsTo(cal.date)) { cal.setDate(date); newdate = true; } } if (newdate) { cal.callHandler(); } if (closing) { Calendar.removeClass(el, "hilite"); cal.callCloseHandler(); }};
this.layerContainerDiv.style.left = (originPx.x - newPx.x) + "px"; this.layerContainerDiv.style.top = (originPx.y - newPx.y) + "px";
if ((originPx != null) && (newPx != null)) { this.layerContainerDiv.style.left = (originPx.x - newPx.x) + "px"; this.layerContainerDiv.style.top = (originPx.y - newPx.y) + "px"; }
centerLayerContainer: function (lonlat) { var originPx = this.getViewPortPxFromLonLat(this.layerContainerOrigin); var newPx = this.getViewPortPxFromLonLat(lonlat); this.layerContainerDiv.style.left = (originPx.x - newPx.x) + "px"; this.layerContainerDiv.style.top = (originPx.y - newPx.y) + "px"; },
} else { log.debug("ignoring change event: tagName=" + tagName);
change: function(event) { var tagName = event.target.tagName.toLowerCase(); var type = event.target.type; if ('select' == tagName) { var label = event.target.options[event.target.selectedIndex].innerHTML; var value = "label=" + label; self.listener.addCommand("select", getLocator(window, event.target), value, window); } else if ('text' == type || 'password' == type || 'file' == type) { self.listener.addCommand("type", getLocator(window, event.target), event.target.value, window); } },
var name=child.getAttribute('name'); if (name) { newname=name.replace(/__lodel_wildcard/gi,index); child.setAttribute('id',newname); child.setAttribute('name',newname);
var content=child.innerHTML; if (content) { newcontent=content.replace(/__lodel_wildcard/gi,index); child.innerHTML = newcontent;
function changeNameAttributes(obj,index){ for(i=0; i<obj.childNodes.length; i++) { var child=obj.childNodes[i]; if (child.getAttribute) { var name=child.getAttribute('name'); if (name) { newname=name.replace(/__lodel_wildcard/gi,index); child.setAttribute('id',newname); child.setAttribute('name',newname); } } }}
this.tmplist = new Array(); this.tmplist[CHANMODE_OP] = new Array(); this.tmplist[CHANMODE_OP][false] = new Array(); this.tmplist[CHANMODE_OP][true] = new Array(); this.tmplist[CHANMODE_VOICE] = new Array(); this.tmplist[CHANMODE_VOICE][false] = new Array(); this.tmplist[CHANMODE_VOICE][true] = new Array(); this.tmplist[CHANMODE_BAN] = new Array(); this.tmplist[CHANMODE_BAN][false] = new Array(); this.tmplist[CHANMODE_BAN][true] = new Array(); this.state_arg = new Array();
this.tmplist = new Object; this.tmplist[CHANMODE_OP] = new Object; this.tmplist[CHANMODE_OP][false] = new Object; this.tmplist[CHANMODE_OP][true] = new Object; this.tmplist[CHANMODE_VOICE] = new Object; this.tmplist[CHANMODE_VOICE][false] = new Object; this.tmplist[CHANMODE_VOICE][true] = new Object; this.tmplist[CHANMODE_BAN] = new Object; this.tmplist[CHANMODE_BAN][false] = new Object; this.tmplist[CHANMODE_BAN][true] = new Object; this.state_arg = new Object;
function ChanMode(chan,user) { this.tmplist = new Array(); this.tmplist[CHANMODE_OP] = new Array(); this.tmplist[CHANMODE_OP][false] = new Array(); //deop this.tmplist[CHANMODE_OP][true] = new Array(); //op this.tmplist[CHANMODE_VOICE] = new Array(); this.tmplist[CHANMODE_VOICE][false] = new Array(); //devoice this.tmplist[CHANMODE_VOICE][true] = new Array(); //voice this.tmplist[CHANMODE_BAN] = new Array(); this.tmplist[CHANMODE_BAN][false] = new Array(); //unban this.tmplist[CHANMODE_BAN][true] = new Array(); //ban this.state_arg = new Array(); this.state_arg[CHANMODE_KEY] = ""; this.state_arg[CHANMODE_LIMIT] = ""; this.addbits = 0; this.delbits = 0; this.addmodes = ""; this.addmodeargs = ""; this.delmodes = ""; this.delmodeargs = ""; this.chan = chan; this.user = user; // Functions. this.tweaktmpmodelist = ChanMode_tweaktmpmodelist; this.tweaktmpmode = ChanMode_tweaktmpmode; this.affect_mode_list = ChanMode_affect_mode_list;}
this.tmplist[CHANMODE_OP] = new Array;
this.tmplist[CHANMODE_OP] = new Object;
function ChanMode(chan,user) { this.tmplist = new Object; this.tmplist[CHANMODE_OP] = new Array; this.tmplist[CHANMODE_OP][false] = new Array; //deop this.tmplist[CHANMODE_OP][true] = new Array; //op this.tmplist[CHANMODE_VOICE] = new Array; this.tmplist[CHANMODE_VOICE][false] = new Array; //devoice this.tmplist[CHANMODE_VOICE][true] = new Array; //voice this.tmplist[CHANMODE_BAN] = new Array; this.tmplist[CHANMODE_BAN][false] = new Array; //unban this.tmplist[CHANMODE_BAN][true] = new Array; //ban this.state_arg = new Object; this.state_arg[CHANMODE_KEY] = ""; this.state_arg[CHANMODE_LIMIT] = ""; this.addbits = 0; this.delbits = 0; this.addmodes = ""; this.addmodeargs = ""; this.delmodes = ""; this.delmodeargs = ""; this.chan = chan; this.user = user; // Functions. this.tweaktmpmodelist = ChanMode_tweaktmpmodelist; this.tweaktmpmode = ChanMode_tweaktmpmode; this.affect_mode_list = ChanMode_affect_mode_list;}
this.tmplist[CHANMODE_VOICE] = new Array;
this.tmplist[CHANMODE_VOICE] = new Object;
function ChanMode(chan,user) { this.tmplist = new Object; this.tmplist[CHANMODE_OP] = new Array; this.tmplist[CHANMODE_OP][false] = new Array; //deop this.tmplist[CHANMODE_OP][true] = new Array; //op this.tmplist[CHANMODE_VOICE] = new Array; this.tmplist[CHANMODE_VOICE][false] = new Array; //devoice this.tmplist[CHANMODE_VOICE][true] = new Array; //voice this.tmplist[CHANMODE_BAN] = new Array; this.tmplist[CHANMODE_BAN][false] = new Array; //unban this.tmplist[CHANMODE_BAN][true] = new Array; //ban this.state_arg = new Object; this.state_arg[CHANMODE_KEY] = ""; this.state_arg[CHANMODE_LIMIT] = ""; this.addbits = 0; this.delbits = 0; this.addmodes = ""; this.addmodeargs = ""; this.delmodes = ""; this.delmodeargs = ""; this.chan = chan; this.user = user; // Functions. this.tweaktmpmodelist = ChanMode_tweaktmpmodelist; this.tweaktmpmode = ChanMode_tweaktmpmode; this.affect_mode_list = ChanMode_affect_mode_list;}
this.tmplist[CHANMODE_BAN] = new Array;
this.tmplist[CHANMODE_BAN] = new Object;
function ChanMode(chan,user) { this.tmplist = new Object; this.tmplist[CHANMODE_OP] = new Array; this.tmplist[CHANMODE_OP][false] = new Array; //deop this.tmplist[CHANMODE_OP][true] = new Array; //op this.tmplist[CHANMODE_VOICE] = new Array; this.tmplist[CHANMODE_VOICE][false] = new Array; //devoice this.tmplist[CHANMODE_VOICE][true] = new Array; //voice this.tmplist[CHANMODE_BAN] = new Array; this.tmplist[CHANMODE_BAN][false] = new Array; //unban this.tmplist[CHANMODE_BAN][true] = new Array; //ban this.state_arg = new Object; this.state_arg[CHANMODE_KEY] = ""; this.state_arg[CHANMODE_LIMIT] = ""; this.addbits = 0; this.delbits = 0; this.addmodes = ""; this.addmodeargs = ""; this.delmodes = ""; this.delmodeargs = ""; this.chan = chan; this.user = user; // Functions. this.tweaktmpmodelist = ChanMode_tweaktmpmodelist; this.tweaktmpmode = ChanMode_tweaktmpmode; this.affect_mode_list = ChanMode_affect_mode_list;}
this.match_list_mask=Channel_match_list_mask;
function Channel(nam) { this.nam=nam; this.mode=CHANMODE_NONE; this.topic=""; this.topictime=0; this.topicchangedby=""; this.arg = new Array; this.arg[CHANMODE_LIMIT] = 0; this.arg[CHANMODE_KEY] = ""; this.users=new Array; this.modelist=new Array; this.modelist[CHANLIST_OP]=new Array; this.modelist[CHANLIST_VOICE]=new Array; this.modelist[CHANLIST_BAN]=new Array; this.bantime=new Array; this.bancreator=new Array; this.created=time(); this.ismode=Channel_ismode; this.add_modelist=Channel_add_modelist; this.del_modelist=Channel_del_modelist; this.locate_on_list=Channel_locate_on_list; this.count_users=Channel_count_users; this.chanmode=Channel_chanmode; this.isbanned=Channel_isbanned; this.count_modelist=Channel_count_modelist; this.occupants=Channel_occupants;}
this.arg = new Array;
this.arg = new Object;
function Channel(nam) { this.nam=nam; this.mode=CHANMODE_NONE; this.topic=""; this.topictime=0; this.topicchangedby=""; this.arg = new Array; this.arg[CHANMODE_LIMIT] = 0; this.arg[CHANMODE_KEY] = ""; this.users=new Array; this.modelist=new Array; this.modelist[CHANMODE_OP]=new Array; this.modelist[CHANMODE_VOICE]=new Array; this.modelist[CHANMODE_BAN]=new Array; this.bantime=new Array; this.bancreator=new Array; this.created=time(); this.chanmode=Channel_chanmode; this.isbanned=Channel_isbanned; this.count_modelist=Channel_count_modelist; this.occupants=Channel_occupants; this.match_list_mask=Channel_match_list_mask;}
this.users=new Array; this.modelist=new Array; this.modelist[CHANMODE_OP]=new Array; this.modelist[CHANMODE_VOICE]=new Array; this.modelist[CHANMODE_BAN]=new Array; this.bantime=new Array; this.bancreator=new Array;
this.users=new Object; this.modelist=new Object; this.modelist[CHANMODE_OP]=new Object; this.modelist[CHANMODE_VOICE]=new Object; this.modelist[CHANMODE_BAN]=new Array; this.bantime=new Object; this.bancreator=new Object;
function Channel(nam) { this.nam=nam; this.mode=CHANMODE_NONE; this.topic=""; this.topictime=0; this.topicchangedby=""; this.arg = new Array; this.arg[CHANMODE_LIMIT] = 0; this.arg[CHANMODE_KEY] = ""; this.users=new Array; this.modelist=new Array; this.modelist[CHANMODE_OP]=new Array; this.modelist[CHANMODE_VOICE]=new Array; this.modelist[CHANMODE_BAN]=new Array; this.bantime=new Array; this.bancreator=new Array; this.created=time(); this.chanmode=Channel_chanmode; this.isbanned=Channel_isbanned; this.count_modelist=Channel_count_modelist; this.occupants=Channel_occupants; this.match_list_mask=Channel_match_list_mask;}
this.limit=0; this.key="";
this.arg = new Array; this.arg[CHANMODE_LIMIT] = 0; this.arg[CHANMODE_KEY] = "";
function Channel(nam) { this.nam=nam; this.mode=CHANMODE_NONE; this.topic=""; this.topictime=0; this.topicchangedby=""; this.limit=0; this.key=""; this.users=new Array; this.modelist=new Array; this.modelist[CHANLIST_OP]=new Array; this.modelist[CHANLIST_VOICE]=new Array; this.modelist[CHANLIST_BAN]=new Array; this.bantime=new Array; this.bancreator=new Array; this.created=time(); this.ismode=Channel_ismode; this.add_modelist=Channel_add_modelist; this.del_modelist=Channel_del_modelist; this.locate_on_list=Channel_locate_on_list; this.count_users=Channel_count_users; this.chanmode=Channel_chanmode; this.isbanned=Channel_isbanned; this.count_modelist=Channel_count_modelist; this.occupants=Channel_occupants;}
this.modelist[CHANLIST_OP]=new Array; this.modelist[CHANLIST_VOICE]=new Array; this.modelist[CHANLIST_BAN]=new Array;
this.modelist[CHANMODE_OP]=new Array; this.modelist[CHANMODE_VOICE]=new Array; this.modelist[CHANMODE_BAN]=new Array;
function Channel(nam) { this.nam=nam; this.mode=CHANMODE_NONE; this.topic=""; this.topictime=0; this.topicchangedby=""; this.arg = new Array; this.arg[CHANMODE_LIMIT] = 0; this.arg[CHANMODE_KEY] = ""; this.users=new Array; this.modelist=new Array; this.modelist[CHANLIST_OP]=new Array; this.modelist[CHANLIST_VOICE]=new Array; this.modelist[CHANLIST_BAN]=new Array; this.bantime=new Array; this.bancreator=new Array; this.created=time(); this.ismode=Channel_ismode; this.add_modelist=Channel_add_modelist; this.del_modelist=Channel_del_modelist; this.locate_on_list=Channel_locate_on_list; this.count_users=Channel_count_users; this.chanmode=Channel_chanmode; this.isbanned=Channel_isbanned; this.count_modelist=Channel_count_modelist; this.occupants=Channel_occupants; this.match_list_mask=Channel_match_list_mask;}
pushed = this.modelist[list_bit].push(tmp_nickid); return pushed-1;
var pushed = this.modelist[list_bit].push(tmp_nickid); return pushed;
function Channel_add_modelist(tmp_nickid,list_bit) { if (this.ismode(tmp_nickid,list_bit)) return 0; pushed = this.modelist[list_bit].push(tmp_nickid); return pushed-1;}
tmp_mode = "+"; tmp_extras = "";
var tmp_mode = "+"; var tmp_extras = "";
function Channel_chanmode(show_args) { tmp_mode = "+"; tmp_extras = ""; if (this.mode&CHANMODE_INVITE) tmp_mode += "i"; if (this.mode&CHANMODE_KEY) { tmp_mode += "k"; if(show_args) tmp_extras += " " + this.arg[CHANMODE_KEY]; } if (this.mode&CHANMODE_LIMIT) { tmp_mode += "l"; if(show_args) tmp_extras += " " + this.arg[CHANMODE_LIMIT]; } if (this.mode&CHANMODE_MODERATED) tmp_mode += "m"; if (this.mode&CHANMODE_NOOUTSIDE) tmp_mode += "n"; if (this.mode&CHANMODE_PRIVATE) tmp_mode += "p"; if (this.mode&CHANMODE_SECRET) tmp_mode += "s"; if (this.mode&CHANMODE_TOPIC) tmp_mode += "t"; if (!tmp_extras) tmp_extras = " "; return tmp_mode + tmp_extras;}
tmp_extras += " " + this.key;
tmp_extras += " " + this.arg[CHANMODE_KEY];
function Channel_chanmode(show_args) { tmp_mode = "+"; tmp_extras = ""; if (this.mode&CHANMODE_INVITE) tmp_mode += "i"; if (this.mode&CHANMODE_KEY) { tmp_mode += "k"; if(show_args) tmp_extras += " " + this.key; } if (this.mode&CHANMODE_LIMIT) { tmp_mode += "l"; if(show_args) tmp_extras += " " + this.limit; } if (this.mode&CHANMODE_MODERATED) tmp_mode += "m"; if (this.mode&CHANMODE_NOOUTSIDE) tmp_mode += "n"; if (this.mode&CHANMODE_PRIVATE) tmp_mode += "p"; if (this.mode&CHANMODE_SECRET) tmp_mode += "s"; if (this.mode&CHANMODE_TOPIC) tmp_mode += "t"; if (!tmp_extras) tmp_extras = " "; return tmp_mode + tmp_extras;}
tmp_extras += " " + this.limit;
tmp_extras += " " + this.arg[CHANMODE_LIMIT];
function Channel_chanmode(show_args) { tmp_mode = "+"; tmp_extras = ""; if (this.mode&CHANMODE_INVITE) tmp_mode += "i"; if (this.mode&CHANMODE_KEY) { tmp_mode += "k"; if(show_args) tmp_extras += " " + this.key; } if (this.mode&CHANMODE_LIMIT) { tmp_mode += "l"; if(show_args) tmp_extras += " " + this.limit; } if (this.mode&CHANMODE_MODERATED) tmp_mode += "m"; if (this.mode&CHANMODE_NOOUTSIDE) tmp_mode += "n"; if (this.mode&CHANMODE_PRIVATE) tmp_mode += "p"; if (this.mode&CHANMODE_SECRET) tmp_mode += "s"; if (this.mode&CHANMODE_TOPIC) tmp_mode += "t"; if (!tmp_extras) tmp_extras = " "; return tmp_mode + tmp_extras;}
tmp_counter=0;
var tmp_counter=0;
function Channel_count_modelist(list_bit) { tmp_counter=0; for (tmp_count in this.modelist[list_bit]) { if (this.modelist[list_bit][tmp_count]) tmp_counter++; } return tmp_counter;}
tmp_counter=0;
var tmp_counter=0;
function Channel_count_users() { tmp_counter=0; for (tmp_count in this.users) { if (this.users[tmp_count]) tmp_counter++; } return tmp_counter;}
delete_index = this.locate_on_list(tmp_nickid,list_bit);
var delete_index = this.locate_on_list(tmp_nickid,list_bit);
function Channel_del_modelist(tmp_nickid,list_bit) { if (!this.ismode(tmp_nickid,list_bit)) return 0; delete_index = this.locate_on_list(tmp_nickid,list_bit); delete this.modelist[list_bit][delete_index]; return delete_index;}
for (this_ban in this.modelist[CHANLIST_BAN]) { if (match_irc_mask(banned_nuh,this.modelist[CHANLIST_BAN][this_ban]))
for (this_ban in this.modelist[CHANMODE_BAN]) { if (match_irc_mask(banned_nuh,this.modelist[CHANMODE_BAN][this_ban]))
function Channel_isbanned(banned_nuh) { for (this_ban in this.modelist[CHANLIST_BAN]) { if (match_irc_mask(banned_nuh,this.modelist[CHANLIST_BAN][this_ban])) return 1; } return 0;}
if (this.count_users() < parseInt(mask.slice(1)))
if (true_array_len(this.users) < parseInt(mask.slice(1)))
function Channel_match_list_mask(mask) { if (mask[0] == ">") { // Chan has more than X people? if (this.count_users() < parseInt(mask.slice(1))) return 0; } else if (mask[0] == "<") { // Chan has less than X people? if (this.count_users() >= parseInt(mask.slice(1))) return 0; } else if (mask[0].toUpperCase() == "C") { //created X mins ago? if ((mask[1] == ">") && (this.created < (time() - (parseInt(mask.slice(2)) * 60)) ) ) return 0; else if ((mask[1] == "<") && (this.created > (time() - (parseInt(mask.slice(2)) * 60)) ) ) return 0; } else if (mask[0].toUpperCase() == "T") { //topics older than X mins? if ((mask[1] == ">") && (this.topictime < (time() - (parseInt(mask.slice(2)) * 60)) ) ) return 0; else if ((mask[1] == "<") && (this.topictime > (time() - (parseInt(mask.slice(2)) * 60)) ) ) return 0; } else if (mask[0] == "!") { // doesn't match mask X if (IRC_match(this.nam,mask.slice(1).toUpperCase())) return 0; } else { // if all else fails, we're matching a generic channel mask. if (!IRC_match(this.nam,mask)) return 0; } return 1; // if we made it here, we matched something.}
if (this.count_users() >= parseInt(mask.slice(1)))
if (true_array_len(this.users) >= parseInt(mask.slice(1)))
function Channel_match_list_mask(mask) { if (mask[0] == ">") { // Chan has more than X people? if (this.count_users() < parseInt(mask.slice(1))) return 0; } else if (mask[0] == "<") { // Chan has less than X people? if (this.count_users() >= parseInt(mask.slice(1))) return 0; } else if (mask[0].toUpperCase() == "C") { //created X mins ago? if ((mask[1] == ">") && (this.created < (time() - (parseInt(mask.slice(2)) * 60)) ) ) return 0; else if ((mask[1] == "<") && (this.created > (time() - (parseInt(mask.slice(2)) * 60)) ) ) return 0; } else if (mask[0].toUpperCase() == "T") { //topics older than X mins? if ((mask[1] == ">") && (this.topictime < (time() - (parseInt(mask.slice(2)) * 60)) ) ) return 0; else if ((mask[1] == "<") && (this.topictime > (time() - (parseInt(mask.slice(2)) * 60)) ) ) return 0; } else if (mask[0] == "!") { // doesn't match mask X if (IRC_match(this.nam,mask.slice(1).toUpperCase())) return 0; } else { // if all else fails, we're matching a generic channel mask. if (!IRC_match(this.nam,mask)) return 0; } return 1; // if we made it here, we matched something.}
function Channel_matchnick(inline) {
function Channel_matchnick(nickpart) {
function Channel_matchnick(inline) { var i=0; var j=0; var count=0; var tmp_str="\x01N\x01BMatching Nicks:"; var nick_var=""; var partial=inline.toUpperCase(); var matched=""; var start=""; if(partial.lastIndexOf(" ")!=-1) { partial=partial.substr(partial.lastIndexOf(" ")+1); start=inline.slice(0,inline.lastIndexOf(" ")+1); } if(partial=="") { screen.print_line("\x01H\x01BNothing to match.\x01N\x01W"); } for(i=0;i<this.nick.length;i++) { if(partial==this.nick[i].substr(0,partial.length).toUpperCase()) { tmp_str=tmp_str+" "+nick[i]; nick_var=this.nick[i]; count++; if(matched=="") { matched=nick_var.toUpperCase(); } else { nick_var=nick_var.substr(0,matched.length); for(j=nick_var.length;matched.substr(0,j) != nick_var.substr(0,j).toUpperCase();j--) {} nick_var=nick_var.substr(0,j); matched=nick_var.toUpperCase(); } } } if(count>1 && matched.length==partial.length) { screen.print_line(tmp_str+"\x01N\x01W"); return inline; } if(count<1) { screen.print_line("\x01H\x01BNo matching nicks.\x01N\x01W"); return inline; } if(partial==inline.toUpperCase()) { if(count==1) { return nick_var+": "; } return nick_var; } if(count==1) { return start+nick_var+" "; } return start+nick_var;}
var partial=inline.toUpperCase();
var partial=nickpart.toUpperCase();
function Channel_matchnick(inline) { var i=0; var j=0; var count=0; var tmp_str="\x01N\x01BMatching Nicks:"; var nick_var=""; var partial=inline.toUpperCase(); var matched=""; var start=""; if(partial.lastIndexOf(" ")!=-1) { partial=partial.substr(partial.lastIndexOf(" ")+1); start=inline.slice(0,inline.lastIndexOf(" ")+1); } if(partial=="") { screen.print_line("\x01H\x01BNothing to match.\x01N\x01W"); } for(i=0;i<this.nick.length;i++) { if(partial==this.nick[i].substr(0,partial.length).toUpperCase()) { tmp_str=tmp_str+" "+nick[i]; nick_var=this.nick[i]; count++; if(matched=="") { matched=nick_var.toUpperCase(); } else { nick_var=nick_var.substr(0,matched.length); for(j=nick_var.length;matched.substr(0,j) != nick_var.substr(0,j).toUpperCase();j--) {} nick_var=nick_var.substr(0,j); matched=nick_var.toUpperCase(); } } } if(count>1 && matched.length==partial.length) { screen.print_line(tmp_str+"\x01N\x01W"); return inline; } if(count<1) { screen.print_line("\x01H\x01BNo matching nicks.\x01N\x01W"); return inline; } if(partial==inline.toUpperCase()) { if(count==1) { return nick_var+": "; } return nick_var; } if(count==1) { return start+nick_var+" "; } return start+nick_var;}
if(partial.lastIndexOf(" ")!=-1) { partial=partial.substr(partial.lastIndexOf(" ")+1); start=inline.slice(0,inline.lastIndexOf(" ")+1); }
function Channel_matchnick(inline) { var i=0; var j=0; var count=0; var tmp_str="\x01N\x01BMatching Nicks:"; var nick_var=""; var partial=inline.toUpperCase(); var matched=""; var start=""; if(partial.lastIndexOf(" ")!=-1) { partial=partial.substr(partial.lastIndexOf(" ")+1); start=inline.slice(0,inline.lastIndexOf(" ")+1); } if(partial=="") { screen.print_line("\x01H\x01BNothing to match.\x01N\x01W"); } for(i=0;i<this.nick.length;i++) { if(partial==this.nick[i].substr(0,partial.length).toUpperCase()) { tmp_str=tmp_str+" "+nick[i]; nick_var=this.nick[i]; count++; if(matched=="") { matched=nick_var.toUpperCase(); } else { nick_var=nick_var.substr(0,matched.length); for(j=nick_var.length;matched.substr(0,j) != nick_var.substr(0,j).toUpperCase();j--) {} nick_var=nick_var.substr(0,j); matched=nick_var.toUpperCase(); } } } if(count>1 && matched.length==partial.length) { screen.print_line(tmp_str+"\x01N\x01W"); return inline; } if(count<1) { screen.print_line("\x01H\x01BNo matching nicks.\x01N\x01W"); return inline; } if(partial==inline.toUpperCase()) { if(count==1) { return nick_var+": "; } return nick_var; } if(count==1) { return start+nick_var+" "; } return start+nick_var;}
tmp_str=tmp_str+" "+nick[i];
tmp_str=tmp_str+" "+this.nick[i];
function Channel_matchnick(inline) { var i=0; var j=0; var count=0; var tmp_str="\x01N\x01BMatching Nicks:"; var nick_var=""; var partial=inline.toUpperCase(); var matched=""; var start=""; if(partial.lastIndexOf(" ")!=-1) { partial=partial.substr(partial.lastIndexOf(" ")+1); start=inline.slice(0,inline.lastIndexOf(" ")+1); } if(partial=="") { screen.print_line("\x01H\x01BNothing to match.\x01N\x01W"); } for(i=0;i<this.nick.length;i++) { if(partial==this.nick[i].substr(0,partial.length).toUpperCase()) { tmp_str=tmp_str+" "+nick[i]; nick_var=this.nick[i]; count++; if(matched=="") { matched=nick_var.toUpperCase(); } else { nick_var=nick_var.substr(0,matched.length); for(j=nick_var.length;matched.substr(0,j) != nick_var.substr(0,j).toUpperCase();j--) {} nick_var=nick_var.substr(0,j); matched=nick_var.toUpperCase(); } } } if(count>1 && matched.length==partial.length) { screen.print_line(tmp_str+"\x01N\x01W"); return inline; } if(count<1) { screen.print_line("\x01H\x01BNo matching nicks.\x01N\x01W"); return inline; } if(partial==inline.toUpperCase()) { if(count==1) { return nick_var+": "; } return nick_var; } if(count==1) { return start+nick_var+" "; } return start+nick_var;}
if(count>1 && matched.length==partial.length) { screen.print_line(tmp_str+"\x01N\x01W"); return inline; }
function Channel_matchnick(inline) { var i=0; var j=0; var count=0; var tmp_str="\x01N\x01BMatching Nicks:"; var nick_var=""; var partial=inline.toUpperCase(); var matched=""; var start=""; if(partial.lastIndexOf(" ")!=-1) { partial=partial.substr(partial.lastIndexOf(" ")+1); start=inline.slice(0,inline.lastIndexOf(" ")+1); } if(partial=="") { screen.print_line("\x01H\x01BNothing to match.\x01N\x01W"); } for(i=0;i<this.nick.length;i++) { if(partial==this.nick[i].substr(0,partial.length).toUpperCase()) { tmp_str=tmp_str+" "+nick[i]; nick_var=this.nick[i]; count++; if(matched=="") { matched=nick_var.toUpperCase(); } else { nick_var=nick_var.substr(0,matched.length); for(j=nick_var.length;matched.substr(0,j) != nick_var.substr(0,j).toUpperCase();j--) {} nick_var=nick_var.substr(0,j); matched=nick_var.toUpperCase(); } } } if(count>1 && matched.length==partial.length) { screen.print_line(tmp_str+"\x01N\x01W"); return inline; } if(count<1) { screen.print_line("\x01H\x01BNo matching nicks.\x01N\x01W"); return inline; } if(partial==inline.toUpperCase()) { if(count==1) { return nick_var+": "; } return nick_var; } if(count==1) { return start+nick_var+" "; } return start+nick_var;}
return inline;
return null;
function Channel_matchnick(inline) { var i=0; var j=0; var count=0; var tmp_str="\x01N\x01BMatching Nicks:"; var nick_var=""; var partial=inline.toUpperCase(); var matched=""; var start=""; if(partial.lastIndexOf(" ")!=-1) { partial=partial.substr(partial.lastIndexOf(" ")+1); start=inline.slice(0,inline.lastIndexOf(" ")+1); } if(partial=="") { screen.print_line("\x01H\x01BNothing to match.\x01N\x01W"); } for(i=0;i<this.nick.length;i++) { if(partial==this.nick[i].substr(0,partial.length).toUpperCase()) { tmp_str=tmp_str+" "+nick[i]; nick_var=this.nick[i]; count++; if(matched=="") { matched=nick_var.toUpperCase(); } else { nick_var=nick_var.substr(0,matched.length); for(j=nick_var.length;matched.substr(0,j) != nick_var.substr(0,j).toUpperCase();j--) {} nick_var=nick_var.substr(0,j); matched=nick_var.toUpperCase(); } } } if(count>1 && matched.length==partial.length) { screen.print_line(tmp_str+"\x01N\x01W"); return inline; } if(count<1) { screen.print_line("\x01H\x01BNo matching nicks.\x01N\x01W"); return inline; } if(partial==inline.toUpperCase()) { if(count==1) { return nick_var+": "; } return nick_var; } if(count==1) { return start+nick_var+" "; } return start+nick_var;}
if(partial==inline.toUpperCase()) { if(count==1) { return nick_var+": "; } return nick_var;
if(count>1 && matched.length==partial.length) { screen.print_line(tmp_str+"\x01N\x01W"); return null;
function Channel_matchnick(inline) { var i=0; var j=0; var count=0; var tmp_str="\x01N\x01BMatching Nicks:"; var nick_var=""; var partial=inline.toUpperCase(); var matched=""; var start=""; if(partial.lastIndexOf(" ")!=-1) { partial=partial.substr(partial.lastIndexOf(" ")+1); start=inline.slice(0,inline.lastIndexOf(" ")+1); } if(partial=="") { screen.print_line("\x01H\x01BNothing to match.\x01N\x01W"); } for(i=0;i<this.nick.length;i++) { if(partial==this.nick[i].substr(0,partial.length).toUpperCase()) { tmp_str=tmp_str+" "+nick[i]; nick_var=this.nick[i]; count++; if(matched=="") { matched=nick_var.toUpperCase(); } else { nick_var=nick_var.substr(0,matched.length); for(j=nick_var.length;matched.substr(0,j) != nick_var.substr(0,j).toUpperCase();j--) {} nick_var=nick_var.substr(0,j); matched=nick_var.toUpperCase(); } } } if(count>1 && matched.length==partial.length) { screen.print_line(tmp_str+"\x01N\x01W"); return inline; } if(count<1) { screen.print_line("\x01H\x01BNo matching nicks.\x01N\x01W"); return inline; } if(partial==inline.toUpperCase()) { if(count==1) { return nick_var+": "; } return nick_var; } if(count==1) { return start+nick_var+" "; } return start+nick_var;}
if(count==1) { return start+nick_var+" "; } return start+nick_var;
return nick_var;
function Channel_matchnick(inline) { var i=0; var j=0; var count=0; var tmp_str="\x01N\x01BMatching Nicks:"; var nick_var=""; var partial=inline.toUpperCase(); var matched=""; var start=""; if(partial.lastIndexOf(" ")!=-1) { partial=partial.substr(partial.lastIndexOf(" ")+1); start=inline.slice(0,inline.lastIndexOf(" ")+1); } if(partial=="") { screen.print_line("\x01H\x01BNothing to match.\x01N\x01W"); } for(i=0;i<this.nick.length;i++) { if(partial==this.nick[i].substr(0,partial.length).toUpperCase()) { tmp_str=tmp_str+" "+nick[i]; nick_var=this.nick[i]; count++; if(matched=="") { matched=nick_var.toUpperCase(); } else { nick_var=nick_var.substr(0,matched.length); for(j=nick_var.length;matched.substr(0,j) != nick_var.substr(0,j).toUpperCase();j--) {} nick_var=nick_var.substr(0,j); matched=nick_var.toUpperCase(); } } } if(count>1 && matched.length==partial.length) { screen.print_line(tmp_str+"\x01N\x01W"); return inline; } if(count<1) { screen.print_line("\x01H\x01BNo matching nicks.\x01N\x01W"); return inline; } if(partial==inline.toUpperCase()) { if(count==1) { return nick_var+": "; } return nick_var; } if(count==1) { return start+nick_var+" "; } return start+nick_var;}
chan_occupants="";
var chan_occupants="";
function Channel_occupants() { chan_occupants=""; for(thisChannel_user in this.users) { Channel_user=Clients[this.users[thisChannel_user]]; if (Channel_user.nick && (Channel_user.conntype != TYPE_SERVER)) { if (chan_occupants) chan_occupants += " "; if (this.ismode(Channel_user.id,CHANLIST_OP)) chan_occupants += "@"; if (this.ismode(Channel_user.id,CHANLIST_VOICE)) chan_occupants += "+"; chan_occupants += Channel_user.nick; } } return chan_occupants;}
if (this.ismode(Channel_user.id,CHANLIST_OP))
if (this.ismode(Channel_user.id,CHANMODE_OP))
function Channel_occupants() { var chan_occupants=""; for(thisChannel_user in this.users) { var Channel_user=Clients[this.users[thisChannel_user]]; if (Channel_user.nick && (Channel_user.conntype != TYPE_SERVER)) { if (chan_occupants) chan_occupants += " "; if (this.ismode(Channel_user.id,CHANLIST_OP)) chan_occupants += "@"; if (this.ismode(Channel_user.id,CHANLIST_VOICE)) chan_occupants += "+"; chan_occupants += Channel_user.nick; } } return chan_occupants;}
if (this.ismode(Channel_user.id,CHANLIST_VOICE))
if (this.ismode(Channel_user.id,CHANMODE_VOICE))
function Channel_occupants() { var chan_occupants=""; for(thisChannel_user in this.users) { var Channel_user=Clients[this.users[thisChannel_user]]; if (Channel_user.nick && (Channel_user.conntype != TYPE_SERVER)) { if (chan_occupants) chan_occupants += " "; if (this.ismode(Channel_user.id,CHANLIST_OP)) chan_occupants += "@"; if (this.ismode(Channel_user.id,CHANLIST_VOICE)) chan_occupants += "+"; chan_occupants += Channel_user.nick; } } return chan_occupants;}
Channel_user=Clients[this.users[thisChannel_user]];
var Channel_user=Clients[this.users[thisChannel_user]];
function Channel_occupants() { var chan_occupants=""; for(thisChannel_user in this.users) { Channel_user=Clients[this.users[thisChannel_user]]; if (Channel_user.nick && (Channel_user.conntype != TYPE_SERVER)) { if (chan_occupants) chan_occupants += " "; if (this.ismode(Channel_user.id,CHANLIST_OP)) chan_occupants += "@"; if (this.ismode(Channel_user.id,CHANLIST_VOICE)) chan_occupants += "+"; chan_occupants += Channel_user.nick; } } return chan_occupants;}
currentBouquet = document.channelselector.bouquet.selectedIndex;
function channelChange(){ currentChannel = document.channelselector.channel.selectedIndex; if (currentChannel >= 0) { var channel = document.channelselector.channel.options[currentChannel].value; switchChannel(channel, currentBouquet, currentChannel); }}
this.join(default_channel);
function Channels() { this.length=0; this.index=0; this.channel=new Array(); this.join=Channels_join; this.part=Channels_part; this.joined=Channels_joined; this.current getter=function() {return this.channel[this.index];}; this.join(default_channel); this.nick_change=Channels_nick_change; this.nick_quit=Channels_nick_quit; this.nick_part=Channels_nick_part; this.nick_add=Channels_nick_add;}
this.channel[this.channel.length]=new Channel(cname);
function Channels_joined(cname) { this.channel[this.channel.length]=new Channel(cname); this.index=this.channel.length; this.length++;}
this.channel[this.channels.length]=new Channel(cname);
function Channels_joined(cname) { this.channel[this.channel.length]=new Channel(cname); this.index=this.channel.length; this.length++;}
this.channel[this.channels.length]=new Channel(cname);
this.channel[this.channel.length]=new Channel(cname);
function Channels_joined(cname) { this.index=this.channel.length; this.channel[this.channels.length]=new Channel(cname); this.length++;}
for(i=0;i<this.length;i++) {
for(i=0;i<this.channel.length;i++) {
function Channels_nick_change(from,to) { var i=0; var j=0; for(i=0;i<this.length;i++) { for(j=0;j<this.channel[i].nick.length;j++) { if(this.channel[i].nick[j].toUpperCase()==from.toUpperCase()) { this.channel[i].nick[j]=to; } } }}
if(this.index>=(length-1)) {
if(this.index>=(this.length-1)) {
function Channels_part(cname,message) { var i; if(this.current==undefined) { return; } cname=this.current.name; for(i=0;i<this.length;i++) { if(cname.toUpperCase()==this.channel[i].name) { this.channel[i].part(message); this.channel.splice(i,1); this.length -= 1; } } if(this.index>=(length-1)) { this.index=0; }}
this.hotkeys=KEY_LEFT+KEY_RIGHT+"\b\x7f\x1b";
this.hotkeys=KEY_LEFT+KEY_RIGHT+"\b\x7f\x1b"+ctrl('O')+ctrl('U')+ctrl('T')+ctrl('K')+ctrl('P');
function Chatmenu(){ var width=27; this.items=new Array(); this.xpos=24; this.ypos=2; this.lpadding="\xb3"; this.rpadding="\xb3"; this.hotkeys=KEY_LEFT+KEY_RIGHT+"\b\x7f\x1b"; this.add(top_bar(width),undefined,undefined,"",""); this.add("|Multinode Chat","M",width); this.add("|Private Node to Node Chat","P",width); this.add("|Chat With The SysOp","C",width); this.add("|Talk With The System Guru","T",width); this.add("|Finger A Remote User/System","F",width); this.add("I|RC Chat","R",width); this.add("InterBBS |Instant Messages","I",width); this.add(format_opt("|Settings",width,true),"S",width); this.add(bottom_bar(width),undefined,undefined,"",""); this.timeout=100; this.callback=message_callback;}
var objRegExp = /^\d\d*$/;
var objRegExp = /^\d+$/;
function check_and_replace_int( id, val ){ var objRegExp = /^\d\d*$/; if( value( id ) != '' && ( !objRegExp.test( value( id ) ) || parseInt( value( id ) ) < 1 ) ) return document.getElementById( id ).value = val; return document.getElementById( id ).value;}
} else if (p == false) { p = search_paths(header_name, PHP_EXTRA_INCLUDES, null);
function CHECK_HEADER_ADD_INCLUDE(header_name, flag_name, path_to_check, use_env){ if (use_env == null) { use_env = true; } if (path_to_check == null) { path_to_check = php_usual_include_suspects; } else { path_to_check += ";" + php_usual_include_suspects; } var p = search_paths(header_name, path_to_check, use_env ? "INCLUDE" : null); var have = 0; var sym; if (typeof(p) == "string") { ADD_FLAG(flag_name, '/I "' + p + '" '); have = 1; } sym = header_name.toUpperCase(); sym = sym.replace(new RegExp("[\\\\/\.-]", "g"), "_"); AC_DEFINE("HAVE_" + sym, have); return p;}
} else { if (false != search_paths(header_name, PHP_EXTRA_LIBS, null)) { ADD_FLAG("LIBS_" + target.toUpperCase(), libname); have = 1; }
function CHECK_LIB(libname, target, path_to_check){ if (path_to_check == null) { path_to_check = php_usual_lib_suspects; } else { path_to_check += ";" + php_usual_lib_suspects; } var p = search_paths(libname, path_to_check, "LIB"); var have = 0; if (typeof(p) == "string") { ADD_FLAG("LDFLAGS_" + target.toUpperCase(), '/libpath:"' + p + '" '); ADD_FLAG("LIBS_" + target.toUpperCase(), libname); have = 1; } else if (p == true) { ADD_FLAG("LIBS_" + target.toUpperCase(), libname); have = 1; }// AC_DEFINE("HAVE_" + header_name.toUpperCase().replace(new RegExp("/\\\\-\.", "g"), "_"), have); return p;}
if (!p) { p = search_paths(subdir + "\\" + libname, path_to_check, "LIB"); if (p) { p += "\\" + subdir; } }
function CHECK_LIB(libnames, target, path_to_check){ if (target == null) { target = ""; } else { target = "_" + target.toUpperCase(); } if (path_to_check == null) { path_to_check = php_usual_lib_suspects; } else { path_to_check += ";" + php_usual_lib_suspects; } var have = 0; var p; var i; var libname; libnames = libnames.split(';'); for (i = 0; i < libnames.length; i++) { libname = libnames[i]; p = search_paths(libname, path_to_check, "LIB"); if (typeof(p) == "string") { ADD_FLAG("LDFLAGS" + target, '/libpath:"' + p + '" '); ADD_FLAG("LIBS" + target, libname); have = 1; } else if (p == true) { ADD_FLAG("LIBS" + target, libname); have = 1; } else { /* not found in the defaults or the explicit paths, * so check the general extra libs; if we find * it here, no need to add another /libpath: for it as we * already have it covered, but we need to add the lib * to LIBS_XXX */ if (false != search_paths(libname, PHP_EXTRA_LIBS, null)) { ADD_FLAG("LIBS" + target, libname); have = 1; } } if (have) { break; } }// AC_DEFINE("HAVE_" + header_name.toUpperCase().replace(new RegExp("/\\\\-\.", "g"), "_"), have); return have;}
if ( box.checked == false ) { box.checked = true;
if ( box ) { if ( box.checked == false ) { box.checked = true; } } else { alert("You cannot change the order of items, as an item in the list is `Checked Out`"); return;
function checkAll_button( n ) { for ( var j = 0; j <= n; j++ ) { box = eval( "document.adminForm.cb" + j ); if ( box.checked == false ) { box.checked = true; } }}
submitform('saveorder');
function checkAll_button( n ) { for ( var j = 0; j <= n; j++ ) { box = eval( "document.adminForm.cb" + j ); if ( box.checked == false ) { box.checked = true; } }}
document.removeEvent('mousemove', this.checkAndDrag.bindWithEvent(this)); document.addEvent('mousemove', this.drag.bindWithEvent(this));
document.removeEvent('mousemove', this.bound.checkAndDrag); document.addEvent('mousemove', this.bound.drag);
checkAndDrag: function(event){ var distance = Math.round(Math.sqrt(Math.pow(event.page.x - this.mouse.start.x, 2)+Math.pow(event.page.y - this.mouse.start.y, 2))); if (distance > this.options.snap){ document.removeEvent('mousemove', this.checkAndDrag.bindWithEvent(this)); document.addEvent('mousemove', this.drag.bindWithEvent(this)); this.drag(event); this.fireEvent('onSnap', this.element); } event.stop(); },
if (/^chrome:\/\ self.isChrome = true; } else { self.isChrome = false; }
var checkChrome = function() { var loc = window.document.location.href; try { loc = window.top.document.location.href; } catch (e) { // can't see the top (that means we might be chrome, but it's impossible to be sure) self.isChromeDetectable = "no, top location couldn't be read in this window"; } if (/^chrome:\/\//.test(loc)) { self.isChrome = true; } else { self.isChrome = false; } }
var text = inVal.replace(/^\s*(.*?)\s*$/, "$1");
var text = f_core.Trim(inVal);
Checker_trim: function(validator, inVal) { // Handle empty string if (inVal == "") { return inVal; } var text = inVal.replace(/^\s*(.*?)\s*$/, "$1"); validator.a_setObject(text); return text; },
if (loaded != this.url) {
if (!OpenLayers.Util.isEquivalentUrl(loaded, this.url)) {
checkImgURL: function () { // Sometimes our image will load after it has already been removed // from the map, in which case this check is not needed. if (this.layer) { var loaded = this.layer.alpha ? this.imgDiv.firstChild.src : this.imgDiv.src; if (loaded != this.url) { this.imgDiv.style.display = "none"; } } },
clearHideTimers();
clearHideTimers(popup_index);
function checkPopupCoord(x, y, popup_index){ var parent = (popup_index > 0 ? popups[popup_index - 1].name : "none"); if(popup_index < 0) return; p = popups[popup_index]; //setStatus("x:"+x+", y:"+y+", i:"+p.inside+", p:"+popup_index+ // ", p.x:"+p.x+", p.y:"+p.y+", p.w:"+p.w+", p.h:"+p.h+ // ", p.t:"+p.hide_timer+"."); //alert("x: "+x+", y: "+y+", i:"+p.inside+", p: "+popups.length+"."); if((x > p.x && x < p.x + p.w) && (y > p.y && y < p.y + p.h)) { p.inside = true; clearHideTimers(); } else { if(p.inside) { if(!p.hide_timer) { p.hide_timer = setTimeout("clearToPopup('"+parent+"')", 500); } if(popups.length == 0) releaseMouseEvent(); } checkPopupCoord(x, y, popup_index - 1); }}
p.hide_timer = setTimeout("clearToPopup('"+parent+"')", 500);
p.hide_timer = setTimeout("clearToPopup('"+parent+"')", p.properties.hide_delay);
function checkPopupCoord(x, y, popup_index){ var parent = (popup_index > 0 ? popups[popup_index - 1].name : "none"); if(popup_index < 0) return; p = popups[popup_index]; //setStatus("x:"+x+", y:"+y+", i:"+p.inside+", p:"+popup_index+ // ", p.x:"+p.x+", p.y:"+p.y+", p.w:"+p.w+", p.h:"+p.h+ // ", p.t:"+p.hide_timer+"."); //alert("x: "+x+", y: "+y+", i:"+p.inside+", p: "+popups.length+"."); if((x > p.x && x < p.x + p.w) && (y > p.y && y < p.y + p.h)) { p.inside = true; clearHideTimers(); } else { if(p.inside) { if(!p.hide_timer) { p.hide_timer = setTimeout("clearToPopup('"+parent+"')", 500); } if(popups.length == 0) releaseMouseEvent(); } checkPopupCoord(x, y, popup_index - 1); }}
if (newlen != fl.doclen) {
if (!newlen || (newlen != fl.doclen)) {
function checkSafariLoad(){ var allLoaded = true; for (var i = 0; i < FileLoader.cnt; i++) { var fl = FileLoader.elements[i]; if (fl.loaded == false) { var ifr = document.getElementById(fl.frameName); if (ifr.contentDocument.body != null) { // Since we don't know for sure when the new document has finished // loading (nope, adding an onLoad handler dynamically doesn't work) // we'll poll until the document length stabilizes. var newlen = ifr.contentDocument.body.innerHTML.length; if (newlen != fl.doclen) { // Not yet loaded fl.doclen = newlen; allLoaded = false; } else { fl.loaded = true; fl.document = ifr.contentDocument; fl.onload(fl); } } else allLoaded = false; } } if (allLoaded) { clearInterval(FileLoader.interval); FileLoader.interval = 0; }}
editor.view.refresh();
Editor.checkTimestamp = function() { editor.log.debug('checkTimestamp'); if (editor.testCase.checkTimestamp()) { if (window.confirm(Editor.getString('confirmReload'))) { var testCase = editor.currentFormat.loadFile(editor.testCase.file); if (testCase) { editor.setTestCase(testCase); editor.view.refresh(); } } }}
for (var i = 0; i < children.length; i++) { if (Element.Class.has(children[i], className)) {
for (var i = 0; i < children.length; i++) if (Element.Class.has(children[i], className))
childrenWith: function(element, className) { var children = $(element).getElementsByTagName('*'); var elements = new Array(); for (var i = 0; i < children.length; i++) { if (Element.Class.has(children[i], className)) { elements.push(children[i]); break; } } return elements; }
break; } }
childrenWith: function(element, className) { var children = $(element).getElementsByTagName('*'); var elements = new Array(); for (var i = 0; i < children.length; i++) { if (Element.Class.has(children[i], className)) { elements.push(children[i]); break; } } return elements; }
return [$A($(element).getElementsByTagName('*'))[findFirst ? 'detect' : 'select']( function(c) { return c.className ? Element.hasClassName(c, className) : false; })].flatten();
var classNameRegExp = new RegExp("(^|\\s)" + className + "(\\s|$)"); var results = $A($(element).getElementsByTagName('*'))[findFirst ? 'detect' : 'select']( function(c) { return (c.className && c.className.match(classNameRegExp)); }); if(!results) results = []; return results;
Element.childrenWithClassName = function(element, className, findFirst) { return [$A($(element).getElementsByTagName('*'))[findFirst ? 'detect' : 'select']( function(c) { return c.className ? Element.hasClassName(c, className) : false; })].flatten();}
return [$A($(element).getElementsByTagName('*'))[findFirst ? 'detect' : 'select']( function(c) { return c.className ? c.className.match(classNameRegExp) : false; })].flatten();
var results = $A($(element).getElementsByTagName('*'))[findFirst ? 'detect' : 'select']( function(c) { return (c.className && c.className.match(classNameRegExp)); }); if(!results) results = []; return results;
Element.childrenWithClassName = function(element, className, findFirst) { var classNameRegExp = new RegExp("(^|\\s)" + className + "(\\s|$)"); return [$A($(element).getElementsByTagName('*'))[findFirst ? 'detect' : 'select']( function(c) { return c.className ? c.className.match(classNameRegExp) : false; })].flatten();}
return c.className ? Element.hasClassName(c, className) : false;
return c.className ? c.className.match(classNameRegExp) : false;
Element.childrenWithClassName = function(element, className, findFirst) { return [$A($(element).getElementsByTagName('*'))[findFirst ? 'detect' : 'select']( function(c) { return c.className ? Element.hasClassName(c, className) : false; })].flatten();}
if(system.matchuser(str,true) || system.trashcan(str))
if(system.matchuser(str,true)!=user.number || system.trashcan(str))
function chk_qwk_id(str){ if(str.length<2 || str.length>8) return(false); if(Number(str)>0 || Number(str)<0) return(false); /* I know this could be much smaller using regexp */ if(str.indexOf(' ')>=0) return(false); if(str.indexOf('.')>=0) return(false); if(str.indexOf(':')>=0) return(false); if(str.indexOf(';')>=0) return(false); if(str.indexOf('\\')>=0) return(false); if(str.indexOf('/')>=0) return(false); if(str.indexOf('|')>=0) return(false); if(str.indexOf('+')>=0) return(false); if(str.indexOf('"')>=0) return(false); if(str.indexOf('&')>=0) return(false); if(system.matchuser(str,true) || system.trashcan(str)) return(false); return(true);}
document.getElementById("userExtensionsURL").value = "file:" + encodeURI(fp.file.path);
document.getElementById("userExtensionsURL").value = FileUtils.fileURI(fp.file);
function chooseUserExtensionsURL() { var nsIFilePicker = Components.interfaces.nsIFilePicker; var fp = Components.classes["@mozilla.org/filepicker;1"] .createInstance(nsIFilePicker); fp.init(window, "Select user-extensions.js file", nsIFilePicker.modeOpen); fp.appendFilters(nsIFilePicker.filterAll); var res = fp.show(); if (res == nsIFilePicker.returnOK) { document.getElementById("userExtensionsURL").value = "file:" + encodeURI(fp.file.path); }}
s.send("QUIT\r\n"); s.close();
gnats.close();
function clean_exit(s,code){ s.send("QUIT\r\n"); s.close(); exit(code);}
var editClass = tinyMCE.getParam("noneditable_editable_class", "mceEditable"); var nonEditClass = tinyMCE.getParam("noneditable_noneditable_class", "mceNonEditable");
var editClass = tinyMCE.getParam("noneditable_editable_class", "mceItemEditable"); var nonEditClass = tinyMCE.getParam("noneditable_noneditable_class", "mceItemNonEditable");
cleanup : function(type, content, inst) { switch (type) { case "insert_to_editor_dom": var nodes = tinyMCE.getNodeTree(content, new Array(), 1); var editClass = tinyMCE.getParam("noneditable_editable_class", "mceEditable"); var nonEditClass = tinyMCE.getParam("noneditable_noneditable_class", "mceNonEditable"); for (var i=0; i<nodes.length; i++) { var elm = nodes[i]; // Convert contenteditable to classes var editable = tinyMCE.getAttrib(elm, "contenteditable"); if (new RegExp("true|false","gi").test(editable)) TinyMCE_NonEditablePlugin._setEditable(elm, editable == "true"); if (tinyMCE.isMSIE) { var className = elm.className ? elm.className : ""; if (className.indexOf(editClass) != -1) elm.contentEditable = true; if (className.indexOf(nonEditClass) != -1) elm.contentEditable = false; } } break; case "insert_to_editor": if (tinyMCE.isMSIE) { var editClass = tinyMCE.getParam("noneditable_editable_class", "mceEditable"); var nonEditClass = tinyMCE.getParam("noneditable_noneditable_class", "mceNonEditable"); content = content.replace(new RegExp("class=\"(.*)(" + editClass + ")([^\"]*)\"", "gi"), 'class="$1$2$3" contenteditable="true"'); content = content.replace(new RegExp("class=\"(.*)(" + nonEditClass + ")([^\"]*)\"", "gi"), 'class="$1$2$3" contenteditable="false"'); } break; case "get_from_editor_dom": if (tinyMCE.getParam("noneditable_leave_contenteditable", false)) { var nodes = tinyMCE.getNodeTree(content, new Array(), 1); for (var i=0; i<nodes.length; i++) nodes[i].removeAttribute("contenteditable"); } break; } return content; },
var imgs = content.getElementsByTagName("img"); for (var i=0; i<imgs.length; i++) {
var imgs = content.getElementsByTagName("img"), src, i; for (i=0; i<imgs.length; i++) {
cleanup : function(type, content) { switch (type) { case "insert_to_editor_dom": var imgs = content.getElementsByTagName("img"); for (var i=0; i<imgs.length; i++) { var onmouseover = tinyMCE.cleanupEventStr(tinyMCE.getAttrib(imgs[i], 'onmouseover')); var onmouseout = tinyMCE.cleanupEventStr(tinyMCE.getAttrib(imgs[i], 'onmouseout')); if ((src = this._getImageSrc(onmouseover)) != "") { if (tinyMCE.getParam('convert_urls')) src = tinyMCE.convertRelativeToAbsoluteURL(tinyMCE.settings['base_href'], src); imgs[i].setAttribute('onmouseover', "this.src='" + src + "';"); } if ((src = this._getImageSrc(onmouseout)) != "") { if (tinyMCE.getParam('convert_urls')) src = tinyMCE.convertRelativeToAbsoluteURL(tinyMCE.settings['base_href'], src); imgs[i].setAttribute('onmouseout', "this.src='" + src + "';"); } } break; case "get_from_editor_dom": var imgs = content.getElementsByTagName("img"); for (var i=0; i<imgs.length; i++) { var onmouseover = tinyMCE.cleanupEventStr(tinyMCE.getAttrib(imgs[i], 'onmouseover')); var onmouseout = tinyMCE.cleanupEventStr(tinyMCE.getAttrib(imgs[i], 'onmouseout')); if ((src = this._getImageSrc(onmouseover)) != "") { if (tinyMCE.getParam('convert_urls')) src = eval(tinyMCE.settings['urlconverter_callback'] + "(src, null, true);"); imgs[i].setAttribute('onmouseover', "this.src='" + src + "';"); } if ((src = this._getImageSrc(onmouseout)) != "") { if (tinyMCE.getParam('convert_urls')) src = eval(tinyMCE.settings['urlconverter_callback'] + "(src, null, true);"); imgs[i].setAttribute('onmouseout', "this.src='" + src + "';"); } } break; } return content; },
for (var i = 0; i < element.childNodes.length; i++) { var node = element.childNodes[i];
var node = element.firstChild; while (node) { var nextNode = node.nextSibling;
cleanWhitespace: function(element) { element = $(element); for (var i = 0; i < element.childNodes.length; i++) { var node = element.childNodes[i]; if (node.nodeType == 3 && !/\S/.test(node.nodeValue)) Element.remove(node); } return element; },
Element.remove(node);
element.removeChild(node); node = nextNode;
cleanWhitespace: function(element) { element = $(element); for (var i = 0; i < element.childNodes.length; i++) { var node = element.childNodes[i]; if (node.nodeType == 3 && !/\S/.test(node.nodeValue)) Element.remove(node); } return element; },
var element = $(element);
element = $(element);
cleanWhitespace: function(element) { var element = $(element); for (var i = 0; i < element.childNodes.length; i++) { var node = element.childNodes[i]; if (node.nodeType == 3 && !/\S/.test(node.nodeValue)) Element.remove(node); } }
}
},
cleanWhitespace: function(element) { var element = $(element); for (var i = 0; i < element.childNodes.length; i++) { var node = element.childNodes[i]; if (node.nodeType == 3 && !/\S/.test(node.nodeValue)) Element.remove(node); } }
for (i = 0; i < arguments.length; i++)
for (var i = 0; i < arguments.length; i++)
clear: function() { for (i = 0; i < arguments.length; i++) $(arguments[i]).value = ''; },
console.ctrlkey_passthru=orig_passthru;
function clear_screen(){ /* * Called whenever a command needs to exit the menu for user interaction. * * If you'd like a header before non-menu stuff, this is the place to put * it. */ console.attributes=7; console.clear();}
bgh=mtop-ypos;
bgh=height;
function cleararea(xpos,ypos,width,height,eol_allowed){ /* * This function "clears" an area of the screen to the * background. * eol_allowed indicates that you can clear to eol without * breaking anything. */ var x; var y; if(use_bg) { var bgx; var bgy; var bgw; var bbh; var bgxo; var bgyo; var between; var mtop; /* Redraw main menu line if asked */ if(ypos==1) { console.gotoxy(1,1); console.attributes=0x17; console.cleartoeol(); mainbar.draw(); ypos++; height--; } /* Calculate the position of the top line of the message window */ mtop=console.screen_rows-msg_rows+1; /* Calculate the correct values for the Bagkround draw */ bgx=xpos; bgy=ypos; bgxo=xpos-1; /* zero-based */ bgyo=ypos-2; /* zero-based and make allowance for top line (The top of BackGround is at line 2) */ bgw=width; bgh=mtop-ypos; /* Height is here to the message window */ if(bgyo+bgh>BackGround.height) /* Too high? */ bgh=BackGround.height-bgyo; if(ypos+bgh > mtop) bgh=mtop-ypos; if(bgw>0 && bgh>0) { /* Anything to draw? */ BackGround.draw(bgx,bgy,bgw,bgh,bgxo,bgyo); /* Decrement height, increment ypos to account for drawn area */ ypos+=bgh; height-=bgh; } if(height<=0) /* All done? */ return; while(height>0 && ypos < mtop) { console.gotoxy(1,ypos); console.attributes=LBShell_Attr; console.cleartoeol(); ypos++; height--; } if(height<=0) /* All done? */ return; /* Calculate the correct values for the MessageWindow draw */ bgx=xpos; bgy=ypos; bgxo=xpos-1; /* zero-based */ bgyo=ypos-2; bgw=width; bgh=height; /* The rest is all message baby */ MessageWindow.draw(bgx,bgy,bgw,bgh,bgxo,bgyo); return; } for(y=ypos; y<ypos+height; y++) { if(eol_allowed) { if(y==1) { console.gotoxy(1,1); console.attributes=0x17; console.cleartoeol(); mainbar.draw(); } else if(y<console.screen_rows-8) { console.gotoxy(xpos,y); console.attributes=LBShell_Attr; console.cleartoeol(); } else { console.gotoxy(1,y); switch(y) { case console.screen_rows-8: console.attributes=LBShell_Attr; console.putmsg("\x01n \x01n\x01h\xdc\xdc\xdc\xdc \xdb \xdc\xdc \xdc\xdc\xde\xdb \xdc \xdc\xdc\xdc\xdc \xdc\xdc \xdc\xdc \xdc\xdc\xdc\xdc\xdc\xdc\xdc \x01n\x01b\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc "); break; case console.screen_rows-7: console.attributes=LBShell_Attr; console.putmsg("\x01h\x01c\x016\xdf\x01n\x01c\xdc\xdc \x01h\x016\xdf\x01n \x01h\x016\xdf\x01n \x01n\x01c\xdc \x01h\x016\xdf\x01n \x01h\x016\xdf\x01n \x01c\xdc\x01h\x016\xdf\x01n\x01c\xdc\x01h\x016\xdf\x01n\x01c\xdc\xdc\xdc\x01h\xdf \x016\xdf\x01n \x01h\x016\xdf\x01n \x01c\xdc \x01h\x016\xdf\x01n \x01h\x016\xdf\x01n\x01c\xdc\xdc \xdc\x01bgj \xdb\x01w\x014@TIME-L@ @DATE@ \x01y\x01h@BOARDNAME-L19@ \x01n "); break; case console.screen_rows-6: console.attributes=LBShell_Attr; console.putmsg("\x01n \x01b\x01h\x014\xdf\x01n\x01b\xdd\x01h\xdf\x014\xdf\x010\xdf \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x01n\x01b\xdd\x01h\x014\xdf\x010 \x014\xdf\x01n\x01b\xdd\x01h\x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\x01n\x01b\xdb\x01h\x01w\x014Last On\x01k: \x01n\x014@LASTDATEON@ \x01h\x01cNode \x01k\x01n\x01c\x014@NODE-L3@ \x01wUp \x01c@UPTIME-L8@\x01n "); break; case console.screen_rows-5: console.attributes=LBShell_Attr; console.putmsg("\x01n\x01b \xdf\xdf \xdf \xdf \xdb\xdd\xdf\xdf\xdf\xdf \xdb\xdd \xdb\xdb\xdf\xdf \xdf \xdb\xdd\xdf\xdf\xdf \xdf \xdb\x014\x01h\x01wFirstOn\x01k:\x01n\x014 @SINCE@ \x01h\x01cCalls\x01n\x01c\x014@SERVED-R4@ \x01wof\x01c @TCALLS-L7@\x01n "); break; case console.screen_rows-4: console.attributes=LBShell_Attr; console.putmsg("\x01n \x01b\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf "); break; case console.screen_rows-3: console.attributes=7; console.cleartoeol(); console.putmsg(" \x01n\x01c[\x01h@GN@\x01n\x01c] @GRP@ [\x01h@SN@\x01n\x01c] @SUB@\x01n\r\n"); break; case console.screen_rows-2: console.attributes=7; console.cleartoeol(); console.putmsg(" \x01n\x01c(\x01h@LN@\x01n\x01c) @LIB@ (\x01h@DN@\x01n\x01c) @DIR@\x01n\r\n"); break; case console.screen_rows-1: console.attributes=LBShell_Attr; console.cleartoeol(); break; case console.screen_rows: console.attributes=LBShell_Attr; console.cleartoeol(); break; } } } else { /* Not allowed to clear to eol... */ /* * Right now, we're ***assuming*** that second-level menus are * never touching the bottom stuff. */ if(y==1) { console.gotoxy(1,1); console.attributes=0x17; console.cleartoeol(); mainbar.draw(); } else if(y<console.screen_rows-8) { console.attributes=LBShell_Attr; console.gotoxy(xpos,y); for(x=xpos; x<xpos+width; x++) console.write(' '); } else { console.gotoxy(1,y); switch(y) { case console.screen_rows-8: console.attributes=LBShell_Attr; console.putmsg("\x01n \x01n\x01h\xdc\xdc\xdc\xdc \xdb \xdc\xdc \xdc\xdc\xde\xdb \xdc \xdc\xdc\xdc\xdc \xdc\xdc \xdc\xdc \xdc\xdc\xdc\xdc\xdc\xdc\xdc \x01n\x01b\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc "); break; case console.screen_rows-7: console.attributes=LBShell_Attr; console.putmsg("\x01h\x01c\x016\xdf\x01n\x01c\xdc\xdc \x01h\x016\xdf\x01n \x01h\x016\xdf\x01n \x01n\x01c\xdc \x01h\x016\xdf\x01n \x01h\x016\xdf\x01n \x01c\xdc\x01h\x016\xdf\x01n\x01c\xdc\x01h\x016\xdf\x01n\x01c\xdc\xdc\xdc\x01h\xdf \x016\xdf\x01n \x01h\x016\xdf\x01n \x01c\xdc \x01h\x016\xdf\x01n \x01h\x016\xdf\x01n\x01c\xdc\xdc \xdc\x01bgj \xdb\x01w\x014@TIME-L@ @DATE@ \x01y\x01h@BOARDNAME-L19@ \x01n "); break; case console.screen_rows-6: console.attributes=LBShell_Attr; console.putmsg("\x01n \x01b\x01h\x014\xdf\x01n\x01b\xdd\x01h\xdf\x014\xdf\x010\xdf \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x01n\x01b\xdd\x01h\x014\xdf\x010 \x014\xdf\x01n\x01b\xdd\x01h\x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\x01n\x01b\xdb\x01h\x01w\x014Last On\x01k: \x01n\x014@LASTDATEON@ \x01h\x01cNode \x01k\x01n\x01c\x014@NODE-L3@ \x01wUp \x01c@UPTIME-L8@\x01n "); break; case console.screen_rows-5: console.attributes=LBShell_Attr; console.putmsg("\x01n\x01b \xdf\xdf \xdf \xdf \xdb\xdd\xdf\xdf\xdf\xdf \xdb\xdd \xdb\xdb\xdf\xdf \xdf \xdb\xdd\xdf\xdf\xdf \xdf \xdb\x014\x01h\x01wFirstOn\x01k:\x01n\x014 @SINCE@ \x01h\x01cCalls\x01n\x01c\x014@SERVED-R4@ \x01wof\x01c @TCALLS-L7@\x01n "); break; case console.screen_rows-4: console.attributes=LBShell_Attr; console.putmsg("\x01n \x01b\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf "); break; case console.screen_rows-3: console.attributes=7; console.cleartoeol(); console.putmsg(" \x01n\x01c[\x01h@GN@\x01n\x01c] @GRP@ [\x01h@SN@\x01n\x01c] @SUB@\x01n\r\n"); break; case console.screen_rows-2: console.attributes=7; console.cleartoeol(); console.putmsg(" \x01n\x01c(\x01h@LN@\x01n\x01c) @LIB@ (\x01h@DN@\x01n\x01c) @DIR@\x01n\r\n"); break; case console.screen_rows-1: console.attributes=LBShell_Attr; console.cleartoeol(); break; case console.screen_rows: console.attributes=LBShell_Attr; console.cleartoeol(); break; } } } }}
if(height-(ypos-2)>BackGround.height) {
if(height+(ypos-2)>BackGround.height) {
function cleararea(xpos,ypos,width,height,eol_allowed){ /* * This function "clears" an area of the screen to the * background. * eol_allowed indicates that you can clear to eol without * breaking anything. */ var x; var y; if(use_bg) { if(ypos==1) { console.gotoxy(1,1); console.attributes=0x17; console.cleartoeol(); mainbar.draw(); ypos++; height--; } if(height-(ypos-2)>BackGround.height) { BackGround.draw(xpos,ypos,width,BackGround.height-(ypos-2),xpos-1,ypos-2); for(y=ypos+(BackGround.height-(ypos-2));y<=console.screen_rows;y++) { console.gotoxy(1,y); console.attributes=LBShell_Attr; console.cleartoeol(); } } else BackGround.draw(xpos,ypos,width,height,xpos-1,ypos-2); return; } for(y=ypos; y<ypos+height; y++) { if(eol_allowed) { if(y==1) { console.gotoxy(1,1); console.attributes=0x17; console.cleartoeol(); mainbar.draw(); } else if(y<console.screen_rows-8) { console.gotoxy(xpos,y); console.attributes=LBShell_Attr; console.cleartoeol(); } else { console.gotoxy(1,y); switch(y) { case console.screen_rows-8: console.attributes=LBShell_Attr; console.putmsg("\x01n \x01n\x01h\xdc\xdc\xdc\xdc \xdb \xdc\xdc \xdc\xdc\xde\xdb \xdc \xdc\xdc\xdc\xdc \xdc\xdc \xdc\xdc \xdc\xdc\xdc\xdc\xdc\xdc\xdc \x01n\x01b\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc "); break; case console.screen_rows-7: console.attributes=LBShell_Attr; console.putmsg("\x01h\x01c\x016\xdf\x01n\x01c\xdc\xdc \x01h\x016\xdf\x01n \x01h\x016\xdf\x01n \x01n\x01c\xdc \x01h\x016\xdf\x01n \x01h\x016\xdf\x01n \x01c\xdc\x01h\x016\xdf\x01n\x01c\xdc\x01h\x016\xdf\x01n\x01c\xdc\xdc\xdc\x01h\xdf \x016\xdf\x01n \x01h\x016\xdf\x01n \x01c\xdc \x01h\x016\xdf\x01n \x01h\x016\xdf\x01n\x01c\xdc\xdc \xdc\x01bgj \xdb\x01w\x014@TIME-L@ @DATE@ \x01y\x01h@BOARDNAME-L19@ \x01n "); break; case console.screen_rows-6: console.attributes=LBShell_Attr; console.putmsg("\x01n \x01b\x01h\x014\xdf\x01n\x01b\xdd\x01h\xdf\x014\xdf\x010\xdf \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x01n\x01b\xdd\x01h\x014\xdf\x010 \x014\xdf\x01n\x01b\xdd\x01h\x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\x01n\x01b\xdb\x01h\x01w\x014Last On\x01k: \x01n\x014@LASTDATEON@ \x01h\x01cNode \x01k\x01n\x01c\x014@NODE-L3@ \x01wUp \x01c@UPTIME-L8@\x01n "); break; case console.screen_rows-5: console.attributes=LBShell_Attr; console.putmsg("\x01n\x01b \xdf\xdf \xdf \xdf \xdb\xdd\xdf\xdf\xdf\xdf \xdb\xdd \xdb\xdb\xdf\xdf \xdf \xdb\xdd\xdf\xdf\xdf \xdf \xdb\x014\x01h\x01wFirstOn\x01k:\x01n\x014 @SINCE@ \x01h\x01cCalls\x01n\x01c\x014@SERVED-R4@ \x01wof\x01c @TCALLS-L7@\x01n "); break; case console.screen_rows-4: console.attributes=LBShell_Attr; console.putmsg("\x01n \x01b\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf "); break; case console.screen_rows-3: console.attributes=7; console.cleartoeol(); console.putmsg(" \x01n\x01c[\x01h@GN@\x01n\x01c] @GRP@ [\x01h@SN@\x01n\x01c] @SUB@\x01n\r\n"); break; case console.screen_rows-2: console.attributes=7; console.cleartoeol(); console.putmsg(" \x01n\x01c(\x01h@LN@\x01n\x01c) @LIB@ (\x01h@DN@\x01n\x01c) @DIR@\x01n\r\n"); break; case console.screen_rows-1: console.attributes=LBShell_Attr; console.cleartoeol(); break; case console.screen_rows: console.attributes=LBShell_Attr; console.cleartoeol(); break; } } } else { /* Not allowed to clear to eol... */ /* * Right now, we're ***assuming*** that second-level menus are * never touching the bottom stuff. */ if(y==1) { console.gotoxy(1,1); console.attributes=0x17; console.cleartoeol(); mainbar.draw(); } else if(y<console.screen_rows-8) { console.attributes=LBShell_Attr; console.gotoxy(xpos,y); for(x=xpos; x<xpos+width; x++) console.write(' '); } else { console.gotoxy(1,y); switch(y) { case console.screen_rows-8: console.attributes=LBShell_Attr; console.putmsg("\x01n \x01n\x01h\xdc\xdc\xdc\xdc \xdb \xdc\xdc \xdc\xdc\xde\xdb \xdc \xdc\xdc\xdc\xdc \xdc\xdc \xdc\xdc \xdc\xdc\xdc\xdc\xdc\xdc\xdc \x01n\x01b\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc\xdc "); break; case console.screen_rows-7: console.attributes=LBShell_Attr; console.putmsg("\x01h\x01c\x016\xdf\x01n\x01c\xdc\xdc \x01h\x016\xdf\x01n \x01h\x016\xdf\x01n \x01n\x01c\xdc \x01h\x016\xdf\x01n \x01h\x016\xdf\x01n \x01c\xdc\x01h\x016\xdf\x01n\x01c\xdc\x01h\x016\xdf\x01n\x01c\xdc\xdc\xdc\x01h\xdf \x016\xdf\x01n \x01h\x016\xdf\x01n \x01c\xdc \x01h\x016\xdf\x01n \x01h\x016\xdf\x01n\x01c\xdc\xdc \xdc\x01bgj \xdb\x01w\x014@TIME-L@ @DATE@ \x01y\x01h@BOARDNAME-L19@ \x01n "); break; case console.screen_rows-6: console.attributes=LBShell_Attr; console.putmsg("\x01n \x01b\x01h\x014\xdf\x01n\x01b\xdd\x01h\xdf\x014\xdf\x010\xdf \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x01n\x01b\xdd\x01h\x014\xdf\x010 \x014\xdf\x01n\x01b\xdd\x01h\x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\xdf\x010 \x014\x01n\x01b\xdb\x01h\x01w\x014Last On\x01k: \x01n\x014@LASTDATEON@ \x01h\x01cNode \x01k\x01n\x01c\x014@NODE-L3@ \x01wUp \x01c@UPTIME-L8@\x01n "); break; case console.screen_rows-5: console.attributes=LBShell_Attr; console.putmsg("\x01n\x01b \xdf\xdf \xdf \xdf \xdb\xdd\xdf\xdf\xdf\xdf \xdb\xdd \xdb\xdb\xdf\xdf \xdf \xdb\xdd\xdf\xdf\xdf \xdf \xdb\x014\x01h\x01wFirstOn\x01k:\x01n\x014 @SINCE@ \x01h\x01cCalls\x01n\x01c\x014@SERVED-R4@ \x01wof\x01c @TCALLS-L7@\x01n "); break; case console.screen_rows-4: console.attributes=LBShell_Attr; console.putmsg("\x01n \x01b\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf\xdf "); break; case console.screen_rows-3: console.attributes=7; console.cleartoeol(); console.putmsg(" \x01n\x01c[\x01h@GN@\x01n\x01c] @GRP@ [\x01h@SN@\x01n\x01c] @SUB@\x01n\r\n"); break; case console.screen_rows-2: console.attributes=7; console.cleartoeol(); console.putmsg(" \x01n\x01c(\x01h@LN@\x01n\x01c) @LIB@ (\x01h@DN@\x01n\x01c) @DIR@\x01n\r\n"); break; case console.screen_rows-1: console.attributes=LBShell_Attr; console.cleartoeol(); break; case console.screen_rows: console.attributes=LBShell_Attr; console.cleartoeol(); break; } } } }}
OpenLayers.Util.clearArray(row[iCol]);
row[iCol].destroy();
clearGrid:function() { if (this.grid) { for(var iRow=0; iRow < this.grid.length; iRow++) { var row = this.grid[iRow]; for(var iCol=0; iCol < row.length; iCol++) { OpenLayers.Util.clearArray(row[iCol]); } } } },
this.grid = [];
clearGrid:function() { if (this.grid) { for(var iRow=0; iRow < this.grid.length; iRow++) { var row = this.grid[iRow]; for(var iCol=0; iCol < row.length; iCol++) { OpenLayers.Util.clearArray(row[iCol]); } } } },
while(grid.length > 0) { var row = grid[0]; while(row.length > 0) { var tile = row[0]; tile.destroy(); row.remove(tile);
if (this.grid) { while(this.grid.length > 0) { var row = this.grid[0]; while(row.length > 0) { var tile = row[0]; tile.destroy(); row.remove(tile); } this.grid.remove(row);
clearGrid:function() { while(grid.length > 0) { var row = grid[0]; while(row.length > 0) { var tile = row[0]; tile.destroy(); row.remove(tile); } grid.remove(row); } }
grid.remove(row);
clearGrid:function() { while(grid.length > 0) { var row = grid[0]; while(row.length > 0) { var tile = row[0]; tile.destroy(); row.remove(tile); } grid.remove(row); } }
function clearHideTimers()
function clearHideTimers(from)
function clearHideTimers(){ for(var i = popups.length - 1; i >= 0; i--) if(popups[i].hide_timer) { clearTimeout(popups[i].hide_timer); popups[i].hide_timer = null; }}
for(var i = popups.length - 1; i >= 0; i--)
for(var i = from; i >= 0; i--)
function clearHideTimers(){ for(var i = popups.length - 1; i >= 0; i--) if(popups[i].hide_timer) { clearTimeout(popups[i].hide_timer); popups[i].hide_timer = null; }}
debug("clearQueryHistory: null historyNode");
debug.print("clearQueryHistory: null historyNode");
function clearQueryHistory() { var historyNode = document.getElementById(g_cq_history_node); if (! historyNode) { debug("clearQueryHistory: null historyNode"); return; } removeChildNodes(historyNode);}
removeChildNodes(historyNode);
historyNode.removeChildNodes();
function clearQueryHistory() { var historyNode = document.getElementById(g_cq_history_node); if (! historyNode) { debug("clearQueryHistory: null historyNode"); return; } removeChildNodes(historyNode);}
historyNode.removeChildNodes();
removeChildNodes(historyNode);
function clearQueryHistory() { var historyNode = document.getElementById(g_cq_history_node); if (! historyNode) { debug.print("clearQueryHistory: null historyNode"); return; } historyNode.removeChildNodes();}
clearHideTimers();
clearHideTimers(popups.length - 1);
function clearToPopup(popup){ // Remove all hide timers clearHideTimers(); while(popups.length > 0 && popup != popups[popups.length - 1].name) { hide(popups[popups.length - 1].name); popups.length--; }}
var tagName = event.target.tagName.toLowerCase(); var type = event.target.type; if (event.target.hasAttribute("onclick") || event.target.hasAttribute("href") || (tagName == "input" && (type == "submit" || type == "button" || type == "image" || type == "radio" || type == "checkbox"))) { self.listener.addCommand("click", getLocator(window, event.target), '', window);
var clickable = findClickableElement(event.target); if (clickable) { self.listener.addCommand("click", getLocator(window, clickable), '', window);
click: function(event) { var tagName = event.target.tagName.toLowerCase(); var type = event.target.type; if (event.target.hasAttribute("onclick") || event.target.hasAttribute("href") || (tagName == "input" && (type == "submit" || type == "button" || type == "image" || type == "radio" || type == "checkbox"))) { self.listener.addCommand("click", getLocator(window, event.target), '', window); } }
}
},
click: function(event) { var tagName = event.target.tagName.toLowerCase(); var type = event.target.type; if (event.target.hasAttribute("onclick") || event.target.hasAttribute("href") || (tagName == "input" && (type == "submit" || type == "button" || type == "image" || type == "radio" || type == "checkbox"))) { self.listener.addCommand("click", getLocator(window, event.target), '', window); } }
HTMLAnchorElement.prototype.click = function() { var evt = this.ownerDocument.createEvent('MouseEvents'); evt.initMouseEvent('click', true, true, this.ownerDocument.defaultView, 1, 0, 0, 0, 0, false, false, false, false, 0, null); this.dispatchEvent(evt); }
windowObject.HTMLAnchorElement.prototype.click = function() { var evt = this.ownerDocument.createEvent('MouseEvents'); evt.initMouseEvent('click', true, true, this.ownerDocument.defaultView, 1, 0, 0, 0, 0, false, false, false, false, 0, null); this.dispatchEvent(evt); }
HTMLAnchorElement.prototype.click = function() { var evt = this.ownerDocument.createEvent('MouseEvents'); evt.initMouseEvent('click', true, true, this.ownerDocument.defaultView, 1, 0, 0, 0, 0, false, false, false, false, 0, null); this.dispatchEvent(evt); }