Fossil SCM

On the /vdiff page, show a timeline with both check-ins using different highlights on each check-in.

drh 2019-08-27 00:11 trunk
Commit 6e40f866abec68e1217f0f0bb5f00bbadf9380b9fd5a940a68fe79147c06914b
--- skins/ardoise/css.txt
+++ skins/ardoise/css.txt
@@ -947,10 +947,38 @@
947947
border-radius: 5px;
948948
border: solid #ff8000;
949949
vertical-align: top;
950950
text-align: left;
951951
background: #442800
952
+}
953
+span.timelineSelected {
954
+ border-radius: 5px;
955
+ border: solid #ff8000;
956
+ vertical-align: top;
957
+ text-align: left;
958
+ background: #442800
959
+}
960
+.timelineSelected {}
961
+.timelineSecondary {}
962
+.timelineSecondary > .timelineColumnarCell,
963
+.timelineSecondary > .timelineCompactCell,
964
+.timelineSecondary > .timelineDetailCell,
965
+.timelineSecondary > .timelineModernCell,
966
+.timelineSecondary > .timelineVerboseCell {
967
+ padding: .75em;
968
+ border-radius: 5px;
969
+ border: solid #0080ff;
970
+ vertical-align: top;
971
+ text-align: left;
972
+ background: #002844
973
+}
974
+span.timelineSecondary {
975
+ border-radius: 5px;
976
+ border: solid #0080ff;
977
+ vertical-align: top;
978
+ text-align: left;
979
+ background: #002844
952980
}
953981
.timelineCurrent > .timelineColumnarCell,
954982
.timelineCurrent > .timelineCompactCell,
955983
.timelineCurrent > .timelineDetailCell,
956984
.timelineCurrent > .timelineModernCell,
957985
--- skins/ardoise/css.txt
+++ skins/ardoise/css.txt
@@ -947,10 +947,38 @@
947 border-radius: 5px;
948 border: solid #ff8000;
949 vertical-align: top;
950 text-align: left;
951 background: #442800
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
952 }
953 .timelineCurrent > .timelineColumnarCell,
954 .timelineCurrent > .timelineCompactCell,
955 .timelineCurrent > .timelineDetailCell,
956 .timelineCurrent > .timelineModernCell,
957
--- skins/ardoise/css.txt
+++ skins/ardoise/css.txt
@@ -947,10 +947,38 @@
947 border-radius: 5px;
948 border: solid #ff8000;
949 vertical-align: top;
950 text-align: left;
951 background: #442800
952 }
953 span.timelineSelected {
954 border-radius: 5px;
955 border: solid #ff8000;
956 vertical-align: top;
957 text-align: left;
958 background: #442800
959 }
960 .timelineSelected {}
961 .timelineSecondary {}
962 .timelineSecondary > .timelineColumnarCell,
963 .timelineSecondary > .timelineCompactCell,
964 .timelineSecondary > .timelineDetailCell,
965 .timelineSecondary > .timelineModernCell,
966 .timelineSecondary > .timelineVerboseCell {
967 padding: .75em;
968 border-radius: 5px;
969 border: solid #0080ff;
970 vertical-align: top;
971 text-align: left;
972 background: #002844
973 }
974 span.timelineSecondary {
975 border-radius: 5px;
976 border: solid #0080ff;
977 vertical-align: top;
978 text-align: left;
979 background: #002844
980 }
981 .timelineCurrent > .timelineColumnarCell,
982 .timelineCurrent > .timelineCompactCell,
983 .timelineCurrent > .timelineDetailCell,
984 .timelineCurrent > .timelineModernCell,
985
--- skins/blitz/css.txt
+++ skins/blitz/css.txt
@@ -1060,16 +1060,19 @@
10601060
background-color: #ffc;
10611061
border-bottom: 1px solid #ddd;
10621062
border-right: 1px solid #ddd;
10631063
}
10641064
1065
-tr.timelineSelected {
1065
+.timelineSelected {
10661066
border-left: 2px solid orange;
10671067
background-color: #ffffe8;
10681068
border-bottom: 1px solid #ddd;
10691069
border-right: 1px solid #ddd;
10701070
}
1071
+.timelineSecondary {
1072
+ background-color: #e8ffff;
1073
+}
10711074
10721075
tr.timelineCurrent td.timelineTableCell {
10731076
}
10741077
10751078
tr.timelineBottom td {
10761079
--- skins/blitz/css.txt
+++ skins/blitz/css.txt
@@ -1060,16 +1060,19 @@
1060 background-color: #ffc;
1061 border-bottom: 1px solid #ddd;
1062 border-right: 1px solid #ddd;
1063 }
1064
1065 tr.timelineSelected {
1066 border-left: 2px solid orange;
1067 background-color: #ffffe8;
1068 border-bottom: 1px solid #ddd;
1069 border-right: 1px solid #ddd;
1070 }
 
 
 
1071
1072 tr.timelineCurrent td.timelineTableCell {
1073 }
1074
1075 tr.timelineBottom td {
1076
--- skins/blitz/css.txt
+++ skins/blitz/css.txt
@@ -1060,16 +1060,19 @@
1060 background-color: #ffc;
1061 border-bottom: 1px solid #ddd;
1062 border-right: 1px solid #ddd;
1063 }
1064
1065 .timelineSelected {
1066 border-left: 2px solid orange;
1067 background-color: #ffffe8;
1068 border-bottom: 1px solid #ddd;
1069 border-right: 1px solid #ddd;
1070 }
1071 .timelineSecondary {
1072 background-color: #e8ffff;
1073 }
1074
1075 tr.timelineCurrent td.timelineTableCell {
1076 }
1077
1078 tr.timelineBottom td {
1079
--- skins/eagle/css.txt
+++ skins/eagle/css.txt
@@ -168,13 +168,16 @@
168168
font-family: "courier new";
169169
border-spacing: 0px 2px;
170170
// border-collapse: collapse;
171171
}
172172
173
-tr.timelineSelected {
173
+.timelineSelected {
174174
background-color: #7EA2D9;
175175
}
176
+.timelineSecondary {
177
+ background-color: #7EA27E;
178
+}
176179
177180
/* commit node */
178181
.tl-node {
179182
width: 10px;
180183
height: 10px;
181184
--- skins/eagle/css.txt
+++ skins/eagle/css.txt
@@ -168,13 +168,16 @@
168 font-family: "courier new";
169 border-spacing: 0px 2px;
170 // border-collapse: collapse;
171 }
172
173 tr.timelineSelected {
174 background-color: #7EA2D9;
175 }
 
 
 
176
177 /* commit node */
178 .tl-node {
179 width: 10px;
180 height: 10px;
181
--- skins/eagle/css.txt
+++ skins/eagle/css.txt
@@ -168,13 +168,16 @@
168 font-family: "courier new";
169 border-spacing: 0px 2px;
170 // border-collapse: collapse;
171 }
172
173 .timelineSelected {
174 background-color: #7EA2D9;
175 }
176 .timelineSecondary {
177 background-color: #7EA27E;
178 }
179
180 /* commit node */
181 .tl-node {
182 width: 10px;
183 height: 10px;
184
--- skins/xekri/css.txt
+++ skins/xekri/css.txt
@@ -803,10 +803,12 @@
803803
.timelineTable .timelineSelected {
804804
background: #222;
805805
border: 0;
806806
box-shadow: none;
807807
}
808
+.timelineSelected {}
809
+.timelineSecondary {}
808810
809811
.timelineTable .timelineSelected .timelineTime {
810812
background: #333;
811813
border-radius: 1rem 0 0 1rem;
812814
box-shadow: 2px 2px 1px #000;
@@ -823,10 +825,17 @@
823825
.timelineTable .timelineSelected .timelineDetailCell {
824826
background: #333;
825827
border-radius: 0 1rem 1rem 0;
826828
box-shadow: 2px 2px 1px #000;
827829
}
830
+
831
+span.timelineSelected {
832
+ padding: 0 1em 0 1em;
833
+ border-radius: 1rem;
834
+ background: #333;
835
+ box-shadow: 2px 2px 1px #000;
836
+}
828837
829838
.timelineTable .timelineModernCell .timelineModernComment ,
830839
.timelineTable .timelineModernCell .timelineModernDetail ,
831840
.timelineTable .timelineCompactCell .timelineCompactComment ,
832841
.timelineTable .timelineCompactCell .timelineCompactDetail ,
833842
--- skins/xekri/css.txt
+++ skins/xekri/css.txt
@@ -803,10 +803,12 @@
803 .timelineTable .timelineSelected {
804 background: #222;
805 border: 0;
806 box-shadow: none;
807 }
 
 
808
809 .timelineTable .timelineSelected .timelineTime {
810 background: #333;
811 border-radius: 1rem 0 0 1rem;
812 box-shadow: 2px 2px 1px #000;
@@ -823,10 +825,17 @@
823 .timelineTable .timelineSelected .timelineDetailCell {
824 background: #333;
825 border-radius: 0 1rem 1rem 0;
826 box-shadow: 2px 2px 1px #000;
827 }
 
 
 
 
 
 
 
828
829 .timelineTable .timelineModernCell .timelineModernComment ,
830 .timelineTable .timelineModernCell .timelineModernDetail ,
831 .timelineTable .timelineCompactCell .timelineCompactComment ,
832 .timelineTable .timelineCompactCell .timelineCompactDetail ,
833
--- skins/xekri/css.txt
+++ skins/xekri/css.txt
@@ -803,10 +803,12 @@
803 .timelineTable .timelineSelected {
804 background: #222;
805 border: 0;
806 box-shadow: none;
807 }
808 .timelineSelected {}
809 .timelineSecondary {}
810
811 .timelineTable .timelineSelected .timelineTime {
812 background: #333;
813 border-radius: 1rem 0 0 1rem;
814 box-shadow: 2px 2px 1px #000;
@@ -823,10 +825,17 @@
825 .timelineTable .timelineSelected .timelineDetailCell {
826 background: #333;
827 border-radius: 0 1rem 1rem 0;
828 box-shadow: 2px 2px 1px #000;
829 }
830
831 span.timelineSelected {
832 padding: 0 1em 0 1em;
833 border-radius: 1rem;
834 background: #333;
835 box-shadow: 2px 2px 1px #000;
836 }
837
838 .timelineTable .timelineModernCell .timelineModernComment ,
839 .timelineTable .timelineModernCell .timelineModernDetail ,
840 .timelineTable .timelineCompactCell .timelineCompactComment ,
841 .timelineTable .timelineCompactCell .timelineCompactDetail ,
842
+1 -1
--- src/branch.c
+++ src/branch.c
@@ -661,9 +661,9 @@
661661
** many descenders to (off-screen) parents. */
662662
tmFlags = TIMELINE_DISJOINT | TIMELINE_NOSCROLL;
663663
if( PB("ng")==0 ) tmFlags |= TIMELINE_GRAPH;
664664
if( PB("brbg")!=0 ) tmFlags |= TIMELINE_BRCOLOR;
665665
if( PB("ubg")!=0 ) tmFlags |= TIMELINE_UCOLOR;
666
- www_print_timeline(&q, tmFlags, 0, 0, 0, 0, brtimeline_extra);
666
+ www_print_timeline(&q, tmFlags, 0, 0, 0, 0, 0, brtimeline_extra);
667667
db_finalize(&q);
668668
style_footer();
669669
}
670670
--- src/branch.c
+++ src/branch.c
@@ -661,9 +661,9 @@
661 ** many descenders to (off-screen) parents. */
662 tmFlags = TIMELINE_DISJOINT | TIMELINE_NOSCROLL;
663 if( PB("ng")==0 ) tmFlags |= TIMELINE_GRAPH;
664 if( PB("brbg")!=0 ) tmFlags |= TIMELINE_BRCOLOR;
665 if( PB("ubg")!=0 ) tmFlags |= TIMELINE_UCOLOR;
666 www_print_timeline(&q, tmFlags, 0, 0, 0, 0, brtimeline_extra);
667 db_finalize(&q);
668 style_footer();
669 }
670
--- src/branch.c
+++ src/branch.c
@@ -661,9 +661,9 @@
661 ** many descenders to (off-screen) parents. */
662 tmFlags = TIMELINE_DISJOINT | TIMELINE_NOSCROLL;
663 if( PB("ng")==0 ) tmFlags |= TIMELINE_GRAPH;
664 if( PB("brbg")!=0 ) tmFlags |= TIMELINE_BRCOLOR;
665 if( PB("ubg")!=0 ) tmFlags |= TIMELINE_UCOLOR;
666 www_print_timeline(&q, tmFlags, 0, 0, 0, 0, 0, brtimeline_extra);
667 db_finalize(&q);
668 style_footer();
669 }
670
--- src/default_css.txt
+++ src/default_css.txt
@@ -38,16 +38,19 @@
3838
tr.timelineCurrent {
3939
padding: .1em .2em;
4040
border: 1px dashed #446979;
4141
box-shadow: 1px 1px 4px rgba(0, 0, 0, 0.5);
4242
}
43
-tr.timelineSelected {
43
+.timelineSelected {
4444
padding: .1em .2em;
4545
border: 2px solid lightgray;
4646
background-color: #ffc;
4747
box-shadow: 1px 1px 4px rgba(0, 0, 0, 0.5);
4848
}
49
+.timelineSecondary {
50
+ background-color: #ffc;
51
+}
4952
tr.timelineSelected td {
5053
border-radius: 0;
5154
border-width: 0;
5255
}
5356
tr.timelineCurrent td {
5457
--- src/default_css.txt
+++ src/default_css.txt
@@ -38,16 +38,19 @@
38 tr.timelineCurrent {
39 padding: .1em .2em;
40 border: 1px dashed #446979;
41 box-shadow: 1px 1px 4px rgba(0, 0, 0, 0.5);
42 }
43 tr.timelineSelected {
44 padding: .1em .2em;
45 border: 2px solid lightgray;
46 background-color: #ffc;
47 box-shadow: 1px 1px 4px rgba(0, 0, 0, 0.5);
48 }
 
 
 
49 tr.timelineSelected td {
50 border-radius: 0;
51 border-width: 0;
52 }
53 tr.timelineCurrent td {
54
--- src/default_css.txt
+++ src/default_css.txt
@@ -38,16 +38,19 @@
38 tr.timelineCurrent {
39 padding: .1em .2em;
40 border: 1px dashed #446979;
41 box-shadow: 1px 1px 4px rgba(0, 0, 0, 0.5);
42 }
43 .timelineSelected {
44 padding: .1em .2em;
45 border: 2px solid lightgray;
46 background-color: #ffc;
47 box-shadow: 1px 1px 4px rgba(0, 0, 0, 0.5);
48 }
49 .timelineSecondary {
50 background-color: #ffc;
51 }
52 tr.timelineSelected td {
53 border-radius: 0;
54 border-width: 0;
55 }
56 tr.timelineCurrent td {
57
--- src/descendants.c
+++ src/descendants.c
@@ -540,11 +540,11 @@
540540
** many descenders to (off-screen) parents. */
541541
tmFlags = TIMELINE_LEAFONLY | TIMELINE_DISJOINT | TIMELINE_NOSCROLL;
542542
if( fNg==0 ) tmFlags |= TIMELINE_GRAPH;
543543
if( fBrBg ) tmFlags |= TIMELINE_BRCOLOR;
544544
if( fUBg ) tmFlags |= TIMELINE_UCOLOR;
545
- www_print_timeline(&q, tmFlags, 0, 0, 0, 0, 0);
545
+ www_print_timeline(&q, tmFlags, 0, 0, 0, 0, 0, 0);
546546
db_finalize(&q);
547547
@ <br />
548548
style_footer();
549549
}
550550
551551
--- src/descendants.c
+++ src/descendants.c
@@ -540,11 +540,11 @@
540 ** many descenders to (off-screen) parents. */
541 tmFlags = TIMELINE_LEAFONLY | TIMELINE_DISJOINT | TIMELINE_NOSCROLL;
542 if( fNg==0 ) tmFlags |= TIMELINE_GRAPH;
543 if( fBrBg ) tmFlags |= TIMELINE_BRCOLOR;
544 if( fUBg ) tmFlags |= TIMELINE_UCOLOR;
545 www_print_timeline(&q, tmFlags, 0, 0, 0, 0, 0);
546 db_finalize(&q);
547 @ <br />
548 style_footer();
549 }
550
551
--- src/descendants.c
+++ src/descendants.c
@@ -540,11 +540,11 @@
540 ** many descenders to (off-screen) parents. */
541 tmFlags = TIMELINE_LEAFONLY | TIMELINE_DISJOINT | TIMELINE_NOSCROLL;
542 if( fNg==0 ) tmFlags |= TIMELINE_GRAPH;
543 if( fBrBg ) tmFlags |= TIMELINE_BRCOLOR;
544 if( fUBg ) tmFlags |= TIMELINE_UCOLOR;
545 www_print_timeline(&q, tmFlags, 0, 0, 0, 0, 0, 0);
546 db_finalize(&q);
547 @ <br />
548 style_footer();
549 }
550
551
+1 -1
--- src/finfo.c
+++ src/finfo.c
@@ -780,11 +780,11 @@
780780
/* 7 */ " isaux"
781781
" FROM mlink WHERE mid=%d ORDER BY 1",
782782
mid
783783
);
784784
@ <h1>MLINK table for check-in %h(zCI)</h1>
785
- render_checkin_context(mid, 1);
785
+ render_checkin_context(mid, 0, 1);
786786
style_table_sorter();
787787
@ <hr />
788788
@ <div class='brlist'>
789789
@ <table class='sortable' data-column-types='ttxtttt' data-init-sort='1'>
790790
@ <thead><tr>
791791
--- src/finfo.c
+++ src/finfo.c
@@ -780,11 +780,11 @@
780 /* 7 */ " isaux"
781 " FROM mlink WHERE mid=%d ORDER BY 1",
782 mid
783 );
784 @ <h1>MLINK table for check-in %h(zCI)</h1>
785 render_checkin_context(mid, 1);
786 style_table_sorter();
787 @ <hr />
788 @ <div class='brlist'>
789 @ <table class='sortable' data-column-types='ttxtttt' data-init-sort='1'>
790 @ <thead><tr>
791
--- src/finfo.c
+++ src/finfo.c
@@ -780,11 +780,11 @@
780 /* 7 */ " isaux"
781 " FROM mlink WHERE mid=%d ORDER BY 1",
782 mid
783 );
784 @ <h1>MLINK table for check-in %h(zCI)</h1>
785 render_checkin_context(mid, 0, 1);
786 style_table_sorter();
787 @ <hr />
788 @ <div class='brlist'>
789 @ <table class='sortable' data-column-types='ttxtttt' data-init-sort='1'>
790 @ <thead><tr>
791
+44 -30
--- src/info.c
+++ src/info.c
@@ -252,34 +252,46 @@
252252
253253
/*
254254
** Show the context graph (immediate parents and children) for
255255
** check-in rid.
256256
*/
257
-void render_checkin_context(int rid, int parentsOnly){
257
+void render_checkin_context(int rid, int rid2, int parentsOnly){
258258
Blob sql;
259259
Stmt q;
260
+ int rx[2];
261
+ int i, n;
262
+ rx[0] = rid;
263
+ rx[1] = rid2;
264
+ n = rid2 ? 2 : 1;
260265
blob_zero(&sql);
261266
blob_append(&sql, timeline_query_for_www(), -1);
262
- db_multi_exec(
263
- "CREATE TEMP TABLE IF NOT EXISTS ok(rid INTEGER PRIMARY KEY);"
264
- "DELETE FROM ok;"
265
- "INSERT INTO ok VALUES(%d);"
266
- "INSERT OR IGNORE INTO ok SELECT pid FROM plink WHERE cid=%d;",
267
- rid, rid
268
- );
269
- if( !parentsOnly ){
270
- db_multi_exec(
271
- "INSERT OR IGNORE INTO ok SELECT cid FROM plink WHERE pid=%d;", rid
272
- );
273
- if( db_table_exists("repository","cherrypick") ){
274
- db_multi_exec(
275
- "INSERT OR IGNORE INTO ok "
276
- " SELECT parentid FROM cherrypick WHERE childid=%d;"
277
- "INSERT OR IGNORE INTO ok "
278
- " SELECT childid FROM cherrypick WHERE parentid=%d;",
279
- rid, rid
280
- );
267
+
268
+ db_multi_exec(
269
+ "CREATE TEMP TABLE IF NOT EXISTS ok(rid INTEGER PRIMARY KEY);"
270
+ "DELETE FROM ok;"
271
+ );
272
+ for(i=0; i<n; i++){
273
+ db_multi_exec(
274
+ "INSERT INTO ok VALUES(%d);"
275
+ "INSERT OR IGNORE INTO ok SELECT pid FROM plink WHERE cid=%d;",
276
+ rx[i], rx[i]
277
+ );
278
+ }
279
+ if( !parentsOnly ){
280
+ for(i=0; i<n; i++){
281
+ db_multi_exec(
282
+ "INSERT OR IGNORE INTO ok SELECT cid FROM plink WHERE pid=%d;", rx[i]
283
+ );
284
+ if( db_table_exists("repository","cherrypick") ){
285
+ db_multi_exec(
286
+ "INSERT OR IGNORE INTO ok "
287
+ " SELECT parentid FROM cherrypick WHERE childid=%d;"
288
+ "INSERT OR IGNORE INTO ok "
289
+ " SELECT childid FROM cherrypick WHERE parentid=%d;",
290
+ rx[i], rx[i]
291
+ );
292
+ }
281293
}
282294
}
283295
blob_append_sql(&sql, " AND event.objid IN ok ORDER BY mtime DESC");
284296
db_prepare(&q, "%s", blob_sql_text(&sql));
285297
www_print_timeline(&q,
@@ -286,11 +298,11 @@
286298
TIMELINE_GRAPH
287299
|TIMELINE_FILLGAPS
288300
|TIMELINE_NOSCROLL
289301
|TIMELINE_XMERGE
290302
|TIMELINE_CHPICK,
291
- 0, 0, 0, rid, 0);
303
+ 0, 0, 0, rid, rid2, 0);
292304
db_finalize(&q);
293305
}
294306
295307
/*
296308
** Show a graph all wiki, tickets, and check-ins that refer to object zUuid.
@@ -317,11 +329,11 @@
317329
blob_zero(&sql);
318330
blob_append(&sql, timeline_query_for_www(), -1);
319331
blob_append_sql(&sql, " AND event.objid IN ok ORDER BY mtime DESC");
320332
db_prepare(&q, "%s", blob_sql_text(&sql));
321333
www_print_timeline(&q, TIMELINE_DISJOINT|TIMELINE_GRAPH|TIMELINE_NOSCROLL,
322
- 0, 0, 0, 0, 0);
334
+ 0, 0, 0, 0, 0, 0);
323335
db_finalize(&q);
324336
}
325337
326338
/*
327339
** WEBPAGE: test-backlinks
@@ -350,11 +362,11 @@
350362
blob_zero(&sql);
351363
blob_append(&sql, timeline_query_for_www(), -1);
352364
blob_append_sql(&sql, " AND event.objid IN ok ORDER BY mtime DESC");
353365
db_prepare(&q, "%s", blob_sql_text(&sql));
354366
www_print_timeline(&q, TIMELINE_DISJOINT|TIMELINE_GRAPH|TIMELINE_NOSCROLL,
355
- 0, 0, 0, 0, 0);
367
+ 0, 0, 0, 0, 0, 0);
356368
db_finalize(&q);
357369
style_footer();
358370
}
359371
360372
@@ -605,25 +617,27 @@
605617
" SELECT tagxref.origid"
606618
" FROM tagxref JOIN tag ON tagxref.tagid=tag.tagid"
607619
" WHERE tagxref.rid=%d;",
608620
rid, rid, rid
609621
);
622
+#if 0
610623
db_multi_exec(
611624
"SELECT tag.tagid, tagname, "
612625
" (SELECT uuid FROM blob WHERE rid=tagxref.srcid AND rid!=%d),"
613626
" value, datetime(tagxref.mtime,toLocal()), tagtype,"
614627
" (SELECT uuid FROM blob WHERE rid=tagxref.origid AND rid!=%d)"
615628
" FROM tagxref JOIN tag ON tagxref.tagid=tag.tagid"
616629
" WHERE tagxref.rid=%d"
617630
" ORDER BY tagname /*sort*/", rid, rid, rid
618631
);
632
+#endif
619633
blob_zero(&sql);
620634
blob_append(&sql, timeline_query_for_www(), -1);
621635
blob_append_sql(&sql, " AND event.objid IN ok ORDER BY mtime DESC");
622636
db_prepare(&q, "%s", blob_sql_text(&sql));
623637
www_print_timeline(&q, TIMELINE_DISJOINT|TIMELINE_GRAPH|TIMELINE_NOSCROLL,
624
- 0, 0, 0, rid, 0);
638
+ 0, 0, 0, rid, 0, 0);
625639
db_finalize(&q);
626640
style_footer();
627641
}
628642
629643
/*
@@ -896,11 +910,11 @@
896910
if( !PB("nowiki") ){
897911
wiki_render_associated("checkin", zUuid, 0);
898912
}
899913
render_backlink_graph(zUuid, "<div class=\"section\">References</div>\n");
900914
@ <div class="section">Context</div>
901
- render_checkin_context(rid, 0);
915
+ render_checkin_context(rid, 0, 0);
902916
@ <div class="section">Changes</div>
903917
@ <div class="sectionmenu">
904918
diffFlags = construct_diff_flags(diffType);
905919
zW = (diffFlags&DIFF_IGNORE_ALLWS)?"&w":"";
906920
if( diffType!=0 ){
@@ -1249,22 +1263,22 @@
12491263
if( diffType!=0 ){
12501264
style_submenu_checkbox("w", "Ignore Whitespace", 0, 0);
12511265
}
12521266
style_header("Check-in Differences");
12531267
if( P("nohdr")==0 ){
1254
- @ <h2>Difference From:</h2><blockquote>
1255
- checkin_description(ridFrom);
1256
- @ </blockquote><h2>To:</h2><blockquote>
1257
- checkin_description(ridTo);
1258
- @ </blockquote>
1268
+ @ <h2>Difference From <span class='timelineSelected'>\
1269
+ @ %z(href("%R/info/%h",zFrom))%h(zFrom)</a></span>
1270
+ @ To <span class='timelineSelected timelineSecondary'>\
1271
+ @ %z(href("%R/info/%h",zTo))%h(zTo)</a></span></h2>
12591272
if( pRe ){
12601273
@ <p><b>Only differences that match regular expression "%h(zRe)"
12611274
@ are shown.</b></p>
12621275
}
12631276
if( zGlob ){
12641277
@ <p><b>Only files matching the glob "%h(zGlob)" are shown.</b></p>
12651278
}
1279
+ render_checkin_context(ridFrom, ridTo, 0);
12661280
@<hr /><p>
12671281
}
12681282
12691283
manifest_file_rewind(pFrom);
12701284
pFileFrom = manifest_file_next(pFrom, 0);
12711285
--- src/info.c
+++ src/info.c
@@ -252,34 +252,46 @@
252
253 /*
254 ** Show the context graph (immediate parents and children) for
255 ** check-in rid.
256 */
257 void render_checkin_context(int rid, int parentsOnly){
258 Blob sql;
259 Stmt q;
 
 
 
 
 
260 blob_zero(&sql);
261 blob_append(&sql, timeline_query_for_www(), -1);
262 db_multi_exec(
263 "CREATE TEMP TABLE IF NOT EXISTS ok(rid INTEGER PRIMARY KEY);"
264 "DELETE FROM ok;"
265 "INSERT INTO ok VALUES(%d);"
266 "INSERT OR IGNORE INTO ok SELECT pid FROM plink WHERE cid=%d;",
267 rid, rid
268 );
269 if( !parentsOnly ){
270 db_multi_exec(
271 "INSERT OR IGNORE INTO ok SELECT cid FROM plink WHERE pid=%d;", rid
272 );
273 if( db_table_exists("repository","cherrypick") ){
274 db_multi_exec(
275 "INSERT OR IGNORE INTO ok "
276 " SELECT parentid FROM cherrypick WHERE childid=%d;"
277 "INSERT OR IGNORE INTO ok "
278 " SELECT childid FROM cherrypick WHERE parentid=%d;",
279 rid, rid
280 );
 
 
 
 
 
 
 
281 }
282 }
283 blob_append_sql(&sql, " AND event.objid IN ok ORDER BY mtime DESC");
284 db_prepare(&q, "%s", blob_sql_text(&sql));
285 www_print_timeline(&q,
@@ -286,11 +298,11 @@
286 TIMELINE_GRAPH
287 |TIMELINE_FILLGAPS
288 |TIMELINE_NOSCROLL
289 |TIMELINE_XMERGE
290 |TIMELINE_CHPICK,
291 0, 0, 0, rid, 0);
292 db_finalize(&q);
293 }
294
295 /*
296 ** Show a graph all wiki, tickets, and check-ins that refer to object zUuid.
@@ -317,11 +329,11 @@
317 blob_zero(&sql);
318 blob_append(&sql, timeline_query_for_www(), -1);
319 blob_append_sql(&sql, " AND event.objid IN ok ORDER BY mtime DESC");
320 db_prepare(&q, "%s", blob_sql_text(&sql));
321 www_print_timeline(&q, TIMELINE_DISJOINT|TIMELINE_GRAPH|TIMELINE_NOSCROLL,
322 0, 0, 0, 0, 0);
323 db_finalize(&q);
324 }
325
326 /*
327 ** WEBPAGE: test-backlinks
@@ -350,11 +362,11 @@
350 blob_zero(&sql);
351 blob_append(&sql, timeline_query_for_www(), -1);
352 blob_append_sql(&sql, " AND event.objid IN ok ORDER BY mtime DESC");
353 db_prepare(&q, "%s", blob_sql_text(&sql));
354 www_print_timeline(&q, TIMELINE_DISJOINT|TIMELINE_GRAPH|TIMELINE_NOSCROLL,
355 0, 0, 0, 0, 0);
356 db_finalize(&q);
357 style_footer();
358 }
359
360
@@ -605,25 +617,27 @@
605 " SELECT tagxref.origid"
606 " FROM tagxref JOIN tag ON tagxref.tagid=tag.tagid"
607 " WHERE tagxref.rid=%d;",
608 rid, rid, rid
609 );
 
610 db_multi_exec(
611 "SELECT tag.tagid, tagname, "
612 " (SELECT uuid FROM blob WHERE rid=tagxref.srcid AND rid!=%d),"
613 " value, datetime(tagxref.mtime,toLocal()), tagtype,"
614 " (SELECT uuid FROM blob WHERE rid=tagxref.origid AND rid!=%d)"
615 " FROM tagxref JOIN tag ON tagxref.tagid=tag.tagid"
616 " WHERE tagxref.rid=%d"
617 " ORDER BY tagname /*sort*/", rid, rid, rid
618 );
 
619 blob_zero(&sql);
620 blob_append(&sql, timeline_query_for_www(), -1);
621 blob_append_sql(&sql, " AND event.objid IN ok ORDER BY mtime DESC");
622 db_prepare(&q, "%s", blob_sql_text(&sql));
623 www_print_timeline(&q, TIMELINE_DISJOINT|TIMELINE_GRAPH|TIMELINE_NOSCROLL,
624 0, 0, 0, rid, 0);
625 db_finalize(&q);
626 style_footer();
627 }
628
629 /*
@@ -896,11 +910,11 @@
896 if( !PB("nowiki") ){
897 wiki_render_associated("checkin", zUuid, 0);
898 }
899 render_backlink_graph(zUuid, "<div class=\"section\">References</div>\n");
900 @ <div class="section">Context</div>
901 render_checkin_context(rid, 0);
902 @ <div class="section">Changes</div>
903 @ <div class="sectionmenu">
904 diffFlags = construct_diff_flags(diffType);
905 zW = (diffFlags&DIFF_IGNORE_ALLWS)?"&w":"";
906 if( diffType!=0 ){
@@ -1249,22 +1263,22 @@
1249 if( diffType!=0 ){
1250 style_submenu_checkbox("w", "Ignore Whitespace", 0, 0);
1251 }
1252 style_header("Check-in Differences");
1253 if( P("nohdr")==0 ){
1254 @ <h2>Difference From:</h2><blockquote>
1255 checkin_description(ridFrom);
1256 @ </blockquote><h2>To:</h2><blockquote>
1257 checkin_description(ridTo);
1258 @ </blockquote>
1259 if( pRe ){
1260 @ <p><b>Only differences that match regular expression "%h(zRe)"
1261 @ are shown.</b></p>
1262 }
1263 if( zGlob ){
1264 @ <p><b>Only files matching the glob "%h(zGlob)" are shown.</b></p>
1265 }
 
1266 @<hr /><p>
1267 }
1268
1269 manifest_file_rewind(pFrom);
1270 pFileFrom = manifest_file_next(pFrom, 0);
1271
--- src/info.c
+++ src/info.c
@@ -252,34 +252,46 @@
252
253 /*
254 ** Show the context graph (immediate parents and children) for
255 ** check-in rid.
256 */
257 void render_checkin_context(int rid, int rid2, int parentsOnly){
258 Blob sql;
259 Stmt q;
260 int rx[2];
261 int i, n;
262 rx[0] = rid;
263 rx[1] = rid2;
264 n = rid2 ? 2 : 1;
265 blob_zero(&sql);
266 blob_append(&sql, timeline_query_for_www(), -1);
267
268 db_multi_exec(
269 "CREATE TEMP TABLE IF NOT EXISTS ok(rid INTEGER PRIMARY KEY);"
270 "DELETE FROM ok;"
271 );
272 for(i=0; i<n; i++){
273 db_multi_exec(
274 "INSERT INTO ok VALUES(%d);"
275 "INSERT OR IGNORE INTO ok SELECT pid FROM plink WHERE cid=%d;",
276 rx[i], rx[i]
277 );
278 }
279 if( !parentsOnly ){
280 for(i=0; i<n; i++){
281 db_multi_exec(
282 "INSERT OR IGNORE INTO ok SELECT cid FROM plink WHERE pid=%d;", rx[i]
283 );
284 if( db_table_exists("repository","cherrypick") ){
285 db_multi_exec(
286 "INSERT OR IGNORE INTO ok "
287 " SELECT parentid FROM cherrypick WHERE childid=%d;"
288 "INSERT OR IGNORE INTO ok "
289 " SELECT childid FROM cherrypick WHERE parentid=%d;",
290 rx[i], rx[i]
291 );
292 }
293 }
294 }
295 blob_append_sql(&sql, " AND event.objid IN ok ORDER BY mtime DESC");
296 db_prepare(&q, "%s", blob_sql_text(&sql));
297 www_print_timeline(&q,
@@ -286,11 +298,11 @@
298 TIMELINE_GRAPH
299 |TIMELINE_FILLGAPS
300 |TIMELINE_NOSCROLL
301 |TIMELINE_XMERGE
302 |TIMELINE_CHPICK,
303 0, 0, 0, rid, rid2, 0);
304 db_finalize(&q);
305 }
306
307 /*
308 ** Show a graph all wiki, tickets, and check-ins that refer to object zUuid.
@@ -317,11 +329,11 @@
329 blob_zero(&sql);
330 blob_append(&sql, timeline_query_for_www(), -1);
331 blob_append_sql(&sql, " AND event.objid IN ok ORDER BY mtime DESC");
332 db_prepare(&q, "%s", blob_sql_text(&sql));
333 www_print_timeline(&q, TIMELINE_DISJOINT|TIMELINE_GRAPH|TIMELINE_NOSCROLL,
334 0, 0, 0, 0, 0, 0);
335 db_finalize(&q);
336 }
337
338 /*
339 ** WEBPAGE: test-backlinks
@@ -350,11 +362,11 @@
362 blob_zero(&sql);
363 blob_append(&sql, timeline_query_for_www(), -1);
364 blob_append_sql(&sql, " AND event.objid IN ok ORDER BY mtime DESC");
365 db_prepare(&q, "%s", blob_sql_text(&sql));
366 www_print_timeline(&q, TIMELINE_DISJOINT|TIMELINE_GRAPH|TIMELINE_NOSCROLL,
367 0, 0, 0, 0, 0, 0);
368 db_finalize(&q);
369 style_footer();
370 }
371
372
@@ -605,25 +617,27 @@
617 " SELECT tagxref.origid"
618 " FROM tagxref JOIN tag ON tagxref.tagid=tag.tagid"
619 " WHERE tagxref.rid=%d;",
620 rid, rid, rid
621 );
622 #if 0
623 db_multi_exec(
624 "SELECT tag.tagid, tagname, "
625 " (SELECT uuid FROM blob WHERE rid=tagxref.srcid AND rid!=%d),"
626 " value, datetime(tagxref.mtime,toLocal()), tagtype,"
627 " (SELECT uuid FROM blob WHERE rid=tagxref.origid AND rid!=%d)"
628 " FROM tagxref JOIN tag ON tagxref.tagid=tag.tagid"
629 " WHERE tagxref.rid=%d"
630 " ORDER BY tagname /*sort*/", rid, rid, rid
631 );
632 #endif
633 blob_zero(&sql);
634 blob_append(&sql, timeline_query_for_www(), -1);
635 blob_append_sql(&sql, " AND event.objid IN ok ORDER BY mtime DESC");
636 db_prepare(&q, "%s", blob_sql_text(&sql));
637 www_print_timeline(&q, TIMELINE_DISJOINT|TIMELINE_GRAPH|TIMELINE_NOSCROLL,
638 0, 0, 0, rid, 0, 0);
639 db_finalize(&q);
640 style_footer();
641 }
642
643 /*
@@ -896,11 +910,11 @@
910 if( !PB("nowiki") ){
911 wiki_render_associated("checkin", zUuid, 0);
912 }
913 render_backlink_graph(zUuid, "<div class=\"section\">References</div>\n");
914 @ <div class="section">Context</div>
915 render_checkin_context(rid, 0, 0);
916 @ <div class="section">Changes</div>
917 @ <div class="sectionmenu">
918 diffFlags = construct_diff_flags(diffType);
919 zW = (diffFlags&DIFF_IGNORE_ALLWS)?"&w":"";
920 if( diffType!=0 ){
@@ -1249,22 +1263,22 @@
1263 if( diffType!=0 ){
1264 style_submenu_checkbox("w", "Ignore Whitespace", 0, 0);
1265 }
1266 style_header("Check-in Differences");
1267 if( P("nohdr")==0 ){
1268 @ <h2>Difference From <span class='timelineSelected'>\
1269 @ %z(href("%R/info/%h",zFrom))%h(zFrom)</a></span>
1270 @ To <span class='timelineSelected timelineSecondary'>\
1271 @ %z(href("%R/info/%h",zTo))%h(zTo)</a></span></h2>
 
1272 if( pRe ){
1273 @ <p><b>Only differences that match regular expression "%h(zRe)"
1274 @ are shown.</b></p>
1275 }
1276 if( zGlob ){
1277 @ <p><b>Only files matching the glob "%h(zGlob)" are shown.</b></p>
1278 }
1279 render_checkin_context(ridFrom, ridTo, 0);
1280 @<hr /><p>
1281 }
1282
1283 manifest_file_rewind(pFrom);
1284 pFileFrom = manifest_file_next(pFrom, 0);
1285
+1 -1
--- src/moderate.c
+++ src/moderate.c
@@ -184,11 +184,11 @@
184184
blob_append_sql(&sql,
185185
" AND event.objid IN (SELECT objid FROM modreq)"
186186
" ORDER BY event.mtime DESC"
187187
);
188188
db_prepare(&q, "%s", blob_sql_text(&sql));
189
- www_print_timeline(&q, 0, 0, 0, 0, 0, 0);
189
+ www_print_timeline(&q, 0, 0, 0, 0, 0, 0, 0);
190190
db_finalize(&q);
191191
}
192192
style_footer();
193193
}
194194
195195
--- src/moderate.c
+++ src/moderate.c
@@ -184,11 +184,11 @@
184 blob_append_sql(&sql,
185 " AND event.objid IN (SELECT objid FROM modreq)"
186 " ORDER BY event.mtime DESC"
187 );
188 db_prepare(&q, "%s", blob_sql_text(&sql));
189 www_print_timeline(&q, 0, 0, 0, 0, 0, 0);
190 db_finalize(&q);
191 }
192 style_footer();
193 }
194
195
--- src/moderate.c
+++ src/moderate.c
@@ -184,11 +184,11 @@
184 blob_append_sql(&sql,
185 " AND event.objid IN (SELECT objid FROM modreq)"
186 " ORDER BY event.mtime DESC"
187 );
188 db_prepare(&q, "%s", blob_sql_text(&sql));
189 www_print_timeline(&q, 0, 0, 0, 0, 0, 0, 0);
190 db_finalize(&q);
191 }
192 style_footer();
193 }
194
195
+1 -1
--- src/tag.c
+++ src/tag.c
@@ -776,10 +776,10 @@
776776
** many descenders to (off-screen) parents. */
777777
tmFlags = TIMELINE_XMERGE | TIMELINE_FILLGAPS | TIMELINE_NOSCROLL;
778778
if( PB("ng")==0 ) tmFlags |= TIMELINE_GRAPH;
779779
if( PB("brbg")!=0 ) tmFlags |= TIMELINE_BRCOLOR;
780780
if( PB("ubg")!=0 ) tmFlags |= TIMELINE_UCOLOR;
781
- www_print_timeline(&q, tmFlags, 0, 0, 0, 0, 0);
781
+ www_print_timeline(&q, tmFlags, 0, 0, 0, 0, 0, 0);
782782
db_finalize(&q);
783783
@ <br />
784784
style_footer();
785785
}
786786
--- src/tag.c
+++ src/tag.c
@@ -776,10 +776,10 @@
776 ** many descenders to (off-screen) parents. */
777 tmFlags = TIMELINE_XMERGE | TIMELINE_FILLGAPS | TIMELINE_NOSCROLL;
778 if( PB("ng")==0 ) tmFlags |= TIMELINE_GRAPH;
779 if( PB("brbg")!=0 ) tmFlags |= TIMELINE_BRCOLOR;
780 if( PB("ubg")!=0 ) tmFlags |= TIMELINE_UCOLOR;
781 www_print_timeline(&q, tmFlags, 0, 0, 0, 0, 0);
782 db_finalize(&q);
783 @ <br />
784 style_footer();
785 }
786
--- src/tag.c
+++ src/tag.c
@@ -776,10 +776,10 @@
776 ** many descenders to (off-screen) parents. */
777 tmFlags = TIMELINE_XMERGE | TIMELINE_FILLGAPS | TIMELINE_NOSCROLL;
778 if( PB("ng")==0 ) tmFlags |= TIMELINE_GRAPH;
779 if( PB("brbg")!=0 ) tmFlags |= TIMELINE_BRCOLOR;
780 if( PB("ubg")!=0 ) tmFlags |= TIMELINE_UCOLOR;
781 www_print_timeline(&q, tmFlags, 0, 0, 0, 0, 0, 0);
782 db_finalize(&q);
783 @ <br />
784 style_footer();
785 }
786
+11 -4
--- src/timeline.c
+++ src/timeline.c
@@ -243,11 +243,12 @@
243243
Stmt *pQuery, /* Query to implement the timeline */
244244
int tmFlags, /* Flags controlling display behavior */
245245
const char *zThisUser, /* Suppress links to this user */
246246
const char *zThisTag, /* Suppress links to this tag */
247247
const char *zLeftBranch, /* Strive to put this branch on the left margin */
248
- int selectedRid, /* Highlight the line with this RID value */
248
+ int selectedRid, /* Highlight the line with this RID value or zero */
249
+ int secondRid, /* Secondary highlight (or zero) */
249250
void (*xExtra)(int) /* Routine to call on each line of display */
250251
){
251252
int mxWikiLen;
252253
Blob comment;
253254
int prevTagid = 0;
@@ -395,10 +396,13 @@
395396
}
396397
pendingEndTr = 1;
397398
if( rid==selectedRid ){
398399
@ <tr class="timelineSelected">
399400
isSelectedOrCurrent = 1;
401
+ }else if( rid==secondRid ){
402
+ @ <tr class="timelineSelected timelineSecondary">
403
+ isSelectedOrCurrent = 1;
400404
}else if( rid==vid ){
401405
@ <tr class="timelineCurrent">
402406
isSelectedOrCurrent = 1;
403407
}else {
404408
@ <tr>
@@ -1601,11 +1605,12 @@
16011605
int pd_rid;
16021606
double rBefore, rAfter, rCirca; /* Boundary times */
16031607
const char *z;
16041608
char *zOlderButton = 0; /* URL for Older button at the bottom */
16051609
char *zNewerButton = 0; /* URL for Newer button at the top */
1606
- int selectedRid = -9999999; /* Show a highlight on this RID */
1610
+ int selectedRid = 0; /* Show a highlight on this RID */
1611
+ int secondaryRid = 0; /* Show secondary highlight */
16071612
int disableY = 0; /* Disable type selector on submenu */
16081613
int advancedMenu = 0; /* Use the advanced menu design */
16091614
char *zPlural; /* Ending for plural forms */
16101615
int showCherrypicks = 1; /* True to show cherrypick merges */
16111616
@@ -1625,10 +1630,12 @@
16251630
}
16261631
}else{
16271632
z = "50";
16281633
nEntry = 50;
16291634
}
1635
+ secondaryRid = name_to_typed_rid(P("sel2"),"ci");
1636
+ selectedRid = name_to_typed_rid(P("sel1"),"ci");
16301637
cgi_replace_query_parameter("n",z);
16311638
cookie_write_parameter("n","n",0);
16321639
tmFlags |= timeline_ss_submenu();
16331640
cookie_link_parameter("advm","advm","0");
16341641
advancedMenu = atoi(PD("advm","0"));
@@ -2414,11 +2421,11 @@
24142421
24152422
if( zNewerButton ){
24162423
@ %z(chref("button","%z",zNewerButton))More&nbsp;&uarr;</a>
24172424
}
24182425
www_print_timeline(&q, tmFlags, zThisUser, zThisTag, zBrName,
2419
- selectedRid, 0);
2426
+ selectedRid, secondaryRid, 0);
24202427
db_finalize(&q);
24212428
if( zOlderButton ){
24222429
@ %z(chref("button","%z",zOlderButton))More&nbsp;&darr;</a>
24232430
}
24242431
style_footer();
@@ -2907,11 +2914,11 @@
29072914
zId = db_text(0, "SELECT timestamp FROM timeline"
29082915
" ORDER BY sortby DESC LIMIT 1");
29092916
@ <h2>%d(iAgo) Year%s(iAgo>1?"s":"") Ago
29102917
@ <small>%z(href("%R/timeline?c=%t",zId))(more context)</a>\
29112918
@ </small></h2>
2912
- www_print_timeline(&q, TIMELINE_GRAPH, 0, 0, 0, 0, 0);
2919
+ www_print_timeline(&q, TIMELINE_GRAPH, 0, 0, 0, 0, 0, 0);
29132920
}
29142921
db_finalize(&q);
29152922
style_footer();
29162923
}
29172924
29182925
--- src/timeline.c
+++ src/timeline.c
@@ -243,11 +243,12 @@
243 Stmt *pQuery, /* Query to implement the timeline */
244 int tmFlags, /* Flags controlling display behavior */
245 const char *zThisUser, /* Suppress links to this user */
246 const char *zThisTag, /* Suppress links to this tag */
247 const char *zLeftBranch, /* Strive to put this branch on the left margin */
248 int selectedRid, /* Highlight the line with this RID value */
 
249 void (*xExtra)(int) /* Routine to call on each line of display */
250 ){
251 int mxWikiLen;
252 Blob comment;
253 int prevTagid = 0;
@@ -395,10 +396,13 @@
395 }
396 pendingEndTr = 1;
397 if( rid==selectedRid ){
398 @ <tr class="timelineSelected">
399 isSelectedOrCurrent = 1;
 
 
 
400 }else if( rid==vid ){
401 @ <tr class="timelineCurrent">
402 isSelectedOrCurrent = 1;
403 }else {
404 @ <tr>
@@ -1601,11 +1605,12 @@
1601 int pd_rid;
1602 double rBefore, rAfter, rCirca; /* Boundary times */
1603 const char *z;
1604 char *zOlderButton = 0; /* URL for Older button at the bottom */
1605 char *zNewerButton = 0; /* URL for Newer button at the top */
1606 int selectedRid = -9999999; /* Show a highlight on this RID */
 
1607 int disableY = 0; /* Disable type selector on submenu */
1608 int advancedMenu = 0; /* Use the advanced menu design */
1609 char *zPlural; /* Ending for plural forms */
1610 int showCherrypicks = 1; /* True to show cherrypick merges */
1611
@@ -1625,10 +1630,12 @@
1625 }
1626 }else{
1627 z = "50";
1628 nEntry = 50;
1629 }
 
 
1630 cgi_replace_query_parameter("n",z);
1631 cookie_write_parameter("n","n",0);
1632 tmFlags |= timeline_ss_submenu();
1633 cookie_link_parameter("advm","advm","0");
1634 advancedMenu = atoi(PD("advm","0"));
@@ -2414,11 +2421,11 @@
2414
2415 if( zNewerButton ){
2416 @ %z(chref("button","%z",zNewerButton))More&nbsp;&uarr;</a>
2417 }
2418 www_print_timeline(&q, tmFlags, zThisUser, zThisTag, zBrName,
2419 selectedRid, 0);
2420 db_finalize(&q);
2421 if( zOlderButton ){
2422 @ %z(chref("button","%z",zOlderButton))More&nbsp;&darr;</a>
2423 }
2424 style_footer();
@@ -2907,11 +2914,11 @@
2907 zId = db_text(0, "SELECT timestamp FROM timeline"
2908 " ORDER BY sortby DESC LIMIT 1");
2909 @ <h2>%d(iAgo) Year%s(iAgo>1?"s":"") Ago
2910 @ <small>%z(href("%R/timeline?c=%t",zId))(more context)</a>\
2911 @ </small></h2>
2912 www_print_timeline(&q, TIMELINE_GRAPH, 0, 0, 0, 0, 0);
2913 }
2914 db_finalize(&q);
2915 style_footer();
2916 }
2917
2918
--- src/timeline.c
+++ src/timeline.c
@@ -243,11 +243,12 @@
243 Stmt *pQuery, /* Query to implement the timeline */
244 int tmFlags, /* Flags controlling display behavior */
245 const char *zThisUser, /* Suppress links to this user */
246 const char *zThisTag, /* Suppress links to this tag */
247 const char *zLeftBranch, /* Strive to put this branch on the left margin */
248 int selectedRid, /* Highlight the line with this RID value or zero */
249 int secondRid, /* Secondary highlight (or zero) */
250 void (*xExtra)(int) /* Routine to call on each line of display */
251 ){
252 int mxWikiLen;
253 Blob comment;
254 int prevTagid = 0;
@@ -395,10 +396,13 @@
396 }
397 pendingEndTr = 1;
398 if( rid==selectedRid ){
399 @ <tr class="timelineSelected">
400 isSelectedOrCurrent = 1;
401 }else if( rid==secondRid ){
402 @ <tr class="timelineSelected timelineSecondary">
403 isSelectedOrCurrent = 1;
404 }else if( rid==vid ){
405 @ <tr class="timelineCurrent">
406 isSelectedOrCurrent = 1;
407 }else {
408 @ <tr>
@@ -1601,11 +1605,12 @@
1605 int pd_rid;
1606 double rBefore, rAfter, rCirca; /* Boundary times */
1607 const char *z;
1608 char *zOlderButton = 0; /* URL for Older button at the bottom */
1609 char *zNewerButton = 0; /* URL for Newer button at the top */
1610 int selectedRid = 0; /* Show a highlight on this RID */
1611 int secondaryRid = 0; /* Show secondary highlight */
1612 int disableY = 0; /* Disable type selector on submenu */
1613 int advancedMenu = 0; /* Use the advanced menu design */
1614 char *zPlural; /* Ending for plural forms */
1615 int showCherrypicks = 1; /* True to show cherrypick merges */
1616
@@ -1625,10 +1630,12 @@
1630 }
1631 }else{
1632 z = "50";
1633 nEntry = 50;
1634 }
1635 secondaryRid = name_to_typed_rid(P("sel2"),"ci");
1636 selectedRid = name_to_typed_rid(P("sel1"),"ci");
1637 cgi_replace_query_parameter("n",z);
1638 cookie_write_parameter("n","n",0);
1639 tmFlags |= timeline_ss_submenu();
1640 cookie_link_parameter("advm","advm","0");
1641 advancedMenu = atoi(PD("advm","0"));
@@ -2414,11 +2421,11 @@
2421
2422 if( zNewerButton ){
2423 @ %z(chref("button","%z",zNewerButton))More&nbsp;&uarr;</a>
2424 }
2425 www_print_timeline(&q, tmFlags, zThisUser, zThisTag, zBrName,
2426 selectedRid, secondaryRid, 0);
2427 db_finalize(&q);
2428 if( zOlderButton ){
2429 @ %z(chref("button","%z",zOlderButton))More&nbsp;&darr;</a>
2430 }
2431 style_footer();
@@ -2907,11 +2914,11 @@
2914 zId = db_text(0, "SELECT timestamp FROM timeline"
2915 " ORDER BY sortby DESC LIMIT 1");
2916 @ <h2>%d(iAgo) Year%s(iAgo>1?"s":"") Ago
2917 @ <small>%z(href("%R/timeline?c=%t",zId))(more context)</a>\
2918 @ </small></h2>
2919 www_print_timeline(&q, TIMELINE_GRAPH, 0, 0, 0, 0, 0, 0);
2920 }
2921 db_finalize(&q);
2922 style_footer();
2923 }
2924
2925
+1 -1
--- src/tkt.c
+++ src/tkt.c
@@ -896,11 +896,11 @@
896896
timeline_query_for_www(), tagid, zFullUuid, zFullUuid, zFullUuid
897897
);
898898
}
899899
db_prepare(&q, "%z", zSQL/*safe-for-%s*/);
900900
www_print_timeline(&q, TIMELINE_ARTID|TIMELINE_DISJOINT|TIMELINE_GRAPH,
901
- 0, 0, 0, 0, 0);
901
+ 0, 0, 0, 0, 0, 0);
902902
db_finalize(&q);
903903
style_footer();
904904
}
905905
906906
/*
907907
--- src/tkt.c
+++ src/tkt.c
@@ -896,11 +896,11 @@
896 timeline_query_for_www(), tagid, zFullUuid, zFullUuid, zFullUuid
897 );
898 }
899 db_prepare(&q, "%z", zSQL/*safe-for-%s*/);
900 www_print_timeline(&q, TIMELINE_ARTID|TIMELINE_DISJOINT|TIMELINE_GRAPH,
901 0, 0, 0, 0, 0);
902 db_finalize(&q);
903 style_footer();
904 }
905
906 /*
907
--- src/tkt.c
+++ src/tkt.c
@@ -896,11 +896,11 @@
896 timeline_query_for_www(), tagid, zFullUuid, zFullUuid, zFullUuid
897 );
898 }
899 db_prepare(&q, "%z", zSQL/*safe-for-%s*/);
900 www_print_timeline(&q, TIMELINE_ARTID|TIMELINE_DISJOINT|TIMELINE_GRAPH,
901 0, 0, 0, 0, 0, 0);
902 db_finalize(&q);
903 style_footer();
904 }
905
906 /*
907

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button