Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
| Comment: | Make it easier to hit the graph nodes for click-to-diff when running on phones and tablets. |
|---|---|
| Downloads: | Tarball | ZIP archive |
| Timelines: | family | ancestors | descendants | both | trunk |
| Files: | files | file ages | folders |
| SHA1: |
781e5bed896b2b9e0214ba2583074b0e |
| User & Date: | drh 2013-01-04 18:23:20.215 |
Context
|
2013-01-04
| ||
| 18:43 | auto-captcha should default to "off". ... (check-in: ac103f64c3 user: drh tags: trunk) | |
| 18:23 | Make it easier to hit the graph nodes for click-to-diff when running on phones and tablets. ... (check-in: 781e5bed89 user: drh tags: trunk) | |
| 13:04 | Add comments explaining the purpose (optimization) of the zInit[] array in the regex matcher. Back out the previous change that inserts non-plane-0 unicode characters into zInit[] as that change might overflow the zInit[] array. ... (check-in: c23e6444f5 user: drh tags: trunk) | |
Changes
Changes to src/timeline.c.
| ︙ | ︙ | |||
209 210 211 212 213 214 215 |
zPrevDate[0] = 0;
mxWikiLen = db_get_int("timeline-max-comment", 0);
if( tmFlags & TIMELINE_GRAPH ){
pGraph = graph_init();
/* style is not moved to css, because this is
** a technical div for the timeline graph
*/
| | | > | 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 |
zPrevDate[0] = 0;
mxWikiLen = db_get_int("timeline-max-comment", 0);
if( tmFlags & TIMELINE_GRAPH ){
pGraph = graph_init();
/* style is not moved to css, because this is
** a technical div for the timeline graph
*/
@ <div id="canvas" style="position:relative;height:0px;width:0px;"
@ onclick="clickOnGraph(event)"></div>
}
db_static_prepare(&qbranch,
"SELECT value FROM tagxref WHERE tagid=%d AND tagtype>0 AND rid=:rid",
TAG_BRANCH
);
@ <table id="timelineTable" class="timelineTable"
@ onclick="clickOnGraph(event)">
blob_zero(&comment);
while( db_step(pQuery)==SQLITE_ROW ){
int rid = db_column_int(pQuery, 0);
const char *zUuid = db_column_text(pQuery, 1);
int isLeaf = db_column_int(pQuery, 5);
const char *zBgClr = db_column_text(pQuery, 6);
const char *zDate = db_column_text(pQuery, 2);
|
| ︙ | ︙ | |||
725 726 727 728 729 730 731 |
@ var left = absoluteX("m"+rowinfo[0].id) - absoluteX("canvas") + 15;
@ var width = nrail*railPitch;
@ for(var i in rowinfo){
@ rowinfo[i].y = absoluteY("m"+rowinfo[i].id) + 10 - canvasY;
@ rowinfo[i].x = left + rowinfo[i].r*railPitch;
@ }
@ var btm = absoluteY("grbtm") + 10 - canvasY;
| < < < < < < < < < < < < < < < < < < < < < < < < < < | > > | | | | 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 |
@ var left = absoluteX("m"+rowinfo[0].id) - absoluteX("canvas") + 15;
@ var width = nrail*railPitch;
@ for(var i in rowinfo){
@ rowinfo[i].y = absoluteY("m"+rowinfo[i].id) + 10 - canvasY;
@ rowinfo[i].x = left + rowinfo[i].r*railPitch;
@ }
@ var btm = absoluteY("grbtm") + 10 - canvasY;
@ for(var i in rowinfo){
@ drawNode(rowinfo[i], left, btm);
@ }
@ if( selRow!=null ) clickOnRow(selRow);
@ }
@ function clickOnGraph(event){
@ var x=event.clientX-absoluteX("canvas");
@ var y=event.clientY-absoluteY("canvas");
@ if(window.pageXOffset!=null){
@ x += window.pageXOffset;
@ y += window.pageYOffset;
@ }else{
@ var d = window.document.documentElement;
@ if(document.compatMode!="CSS1Compat") d = d.body;
@ x += d.scrollLeft;
@ y += d.scrollTop;
@ }
if( P("clicktest")!=0 ){
@ alert("click at "+x+","+y)
}
@ for(var i in rowinfo){
@ p = rowinfo[i];
@ if( p.y<y-11 ) continue;
@ if( p.y>y+9 ) break;
@ if( p.x>x-11 && p.x<x+9 ){
@ clickOnRow(p);
@ break;
@ }
@ }
@ }
@ function clickOnRow(p){
@ if( selRow==null ){
|
| ︙ | ︙ |