source:
Dev/trunk/d3/src/time/day.js
@
76
Last change on this file since 76 was 76, checked in by fpvanagthoven, 14 years ago | |
---|---|
File size: 190 bytes |
Line | |
---|---|
1 | d3.time.day = function(date) { |
2 | return new Date(date.getFullYear(), date.getMonth(), date.getDate()); |
3 | }; |
4 | |
5 | d3.time.day.utc = function(date) { |
6 | return new Date(~~(date / 864e5) * 864e5); |
7 | }; |
Note: See TracBrowser
for help on using the repository browser.