Fossil

Diff
Login

Diff

Differences From Artifact [410f7774c4]:

To Artifact [50dfe05ee3]:


1322
1323
1324
1325
1326
1327
1328

























1329
1330
1331
1332
1333
1334
1335
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360







+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+







    }
    assert( i<=count(az) );
  }
  if( i>2 ){
    style_submenu_multichoice("y", i/2, az, isDisabled);
  }
}

/*
** Add the select/option box to the timeline submenu that is used to
** set the ss= parameter that determines the viewing mode.
**
** Return the TIMELINE_* value appropriate for the view-style.
*/
int timeline_ss_submenu(void){
  static const char *azViewStyles[] = {
     "m", "Modern View",
     "c", "Compact View",
     "v", "Verbose View",
     "j", "Columnar View",
  };
  int tmFlags;
  cookie_link_parameter("ss","ss","m");
  style_submenu_multichoice("ss", 4, azViewStyles, 0);
  switch( PD("ss","m")[0] ){
    case 'c':  tmFlags = TIMELINE_COMPACT;  break;
    case 'v':  tmFlags = TIMELINE_VERBOSE;  break;
    case 'j':  tmFlags = TIMELINE_COLUMNAR; break;
    default:   tmFlags = TIMELINE_MODERN;   break;
  }    
  return tmFlags;
}

/*
** If the zChng string is not NULL, then it should be a comma-separated
** list of glob patterns for filenames.  Add an term to the WHERE clause
** for the SQL statement under construction that excludes any check-in that
** does not modify one or more files matching the globs.
*/
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1688
1689
1690
1691
1692
1693
1694







1695
1696
1697
1698
1699
1700
1701







-
-
-
-
-
-
-







  int pd_rid;
  double rBefore, rAfter, rCirca;     /* Boundary times */
  const char *z;
  char *zOlderButton = 0;             /* URL for Older button at the bottom */
  char *zNewerButton = 0;             /* URL for Newer button at the top */
  int selectedRid = -9999999;         /* Show a highlight on this RID */
  int disableY = 0;                   /* Disable type selector on submenu */
  char cViewStyle;                    /* Overall style of the page */
  static const char *azViewStyles[] = {
     "m", "Modern View",
     "c", "Compact View",
     "v", "Verbose View",
     "j", "Columnar View",
  };

  /* Set number of rows to display */
  cookie_parse(DISPLAY_SETTINGS_COOKIE);
  cookie_read_parameter("n","n");
  z = P("n");
  if( z==0 ) z = db_get("timeline-default-length",0);
  if( z ){
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702

1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716




1717
1718
1719
1720
1721
1722
1723
1724







-
-
-
-
+







    }
  }else{
    z = "50";
    nEntry = 50;
  }
  cgi_replace_query_parameter("n",z);
  cookie_write_parameter("n","n",0);
  cookie_link_parameter("ss","ss","n");
  cViewStyle = PD("ss","n")[0];
  style_submenu_multichoice("ss", 4, azViewStyles, 0);
  
  tmFlags |= timeline_ss_submenu();  

  /* To view the timeline, must have permission to read project data.
  */
  pd_rid = name_to_typed_rid(P("dp"),"ci");
  if( pd_rid ){
    p_rid = d_rid = pd_rid;
  }
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1784
1785
1786
1787
1788
1789
1790






1791
1792
1793
1794
1795
1796
1797







-
-
-
-
-
-







  }
  if( (zTagSql && db_int(0,"SELECT count(*) "
      "FROM tagxref NATURAL JOIN tag WHERE %s",zTagSql/*safe-for-%s*/)<=nEntry)
  ){
    nEntry = -1;
    zCirca = 0;
  }
  switch( cViewStyle ){
    case 'c':  tmFlags |= TIMELINE_COMPACT;  break;
    case 'v':  tmFlags |= TIMELINE_VERBOSE;  break;
    case 'j':  tmFlags |= TIMELINE_COLUMNAR; break;
    default:   tmFlags |= TIMELINE_MODERN;   break;
  }    
  if( zType[0]=='a' ){
    tmFlags |= TIMELINE_BRIEF | TIMELINE_GRAPH;
  }else{
    tmFlags |= TIMELINE_GRAPH;
  }
  if( PB("ng") || zSearch!=0 ){
    tmFlags &= ~TIMELINE_GRAPH;