mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-05-17 01:15:24 +00:00
Monotone-Parent: 01621f78171d7d62c9f2ae9d1fdfb5891f9447d7
Monotone-Revision: fc65291441ddc5ab8f0f12739ef176375714b331 Monotone-Author: wsourdeau@inverse.ca Monotone-Date: 2007-06-07T23:23:29 Monotone-Branch: ca.inverse.sogo
This commit is contained in:
@@ -77,6 +77,28 @@ Date.prototype.daysUpTo = function(otherDate) {
|
||||
return days;
|
||||
}
|
||||
|
||||
Date.prototype.getDayString = function() {
|
||||
var newString = this.getYear() + 1900;
|
||||
var month = '' + (this.getMonth() + 1);
|
||||
if (month.length == 1)
|
||||
month = '0' + month;
|
||||
newString += month;
|
||||
var day = '' + this.getDate();
|
||||
if (day.length == 1)
|
||||
day = '0' + day;
|
||||
newString += day;
|
||||
|
||||
return newString;
|
||||
}
|
||||
|
||||
Date.prototype.getHourString = function() {
|
||||
var newString = this.getHours() + '00';
|
||||
if (newString.length == 3)
|
||||
newString = '0' + newString;
|
||||
|
||||
return newString;
|
||||
}
|
||||
|
||||
Date.prototype.stringWithSeparator = function(separator) {
|
||||
var month = '' + (this.getMonth() + 1);
|
||||
var day = '' + this.getDate();
|
||||
|
||||
@@ -417,9 +417,17 @@ function isNodeSelected(node) {
|
||||
}
|
||||
|
||||
function acceptMultiSelect(node) {
|
||||
var accept = ('' + node.getAttribute('multiselect')).toLowerCase();
|
||||
var response = false;
|
||||
var attribute = node.getAttribute('multiselect');
|
||||
if (attribute) {
|
||||
log("node '" + node.getAttribute("id")
|
||||
+ "' is still using old-stylemultiselect!");
|
||||
response = (attribute.toLowerCase() == 'yes');
|
||||
}
|
||||
else
|
||||
response = node.multiselect;
|
||||
|
||||
return (accept == 'yes');
|
||||
return response;
|
||||
}
|
||||
|
||||
function onRowClick(event) {
|
||||
@@ -1163,12 +1171,8 @@ function onBodyClickContextMenu(event) {
|
||||
function configureSortableTableHeaders() {
|
||||
var headers = document.getElementsByClassName("sortableTableHeader");
|
||||
for (var i = 0; i < headers.length; i++) {
|
||||
var anchor = $(headers[i]).childNodesWithTag("a")[0];
|
||||
if (!anchor.link) {
|
||||
anchor.link = anchor.getAttribute("href");
|
||||
anchor.href = "#";
|
||||
Event.observe(anchor, "click", onHeaderClick.bindAsEventListener(anchor), true);
|
||||
}
|
||||
var header = headers[i];
|
||||
Event.observe(header, "click", onHeaderClick.bindAsEventListener(header));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user