Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
| Comment: | Shortcut SHIFT+H to scroll to the focused entry without moving focus. This may be handy in conjunction with scrolling by arrow keys or PgUp/Dn. |
|---|---|
| Downloads: | Tarball | ZIP archive |
| Timelines: | family | ancestors | descendants | both | timeline-keyboard-navigation |
| Files: | files | file ages | folders |
| SHA3-256: |
8d1edb82061eb09e4fcbdc2fb13b78cf |
| User & Date: | florian 2022-08-07 08:09:00.000 |
Context
|
2022-08-07
| ||
| 08:12 | Coding style fixes and comment updates. ... (check-in: ae932acdd2 user: florian tags: timeline-keyboard-navigation) | |
| 08:09 | Shortcut SHIFT+H to scroll to the focused entry without moving focus. This may be handy in conjunction with scrolling by arrow keys or PgUp/Dn. ... (check-in: 8d1edb8206 user: florian tags: timeline-keyboard-navigation) | |
|
2022-08-05
| ||
| 06:39 | Also fix URLs for non-filtered /timeline links opened from /finfo pages, plus some code and comment cleanups. ... (check-in: 3ae1390f17 user: florian tags: timeline-keyboard-navigation) | |
Changes
Changes to src/graph.js.
| ︙ | ︙ | |||
954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 |
var
mSHIFT = 1<<13,
kFRST = mSHIFT | 78 /* SHIFT+N */,
kNEXT = 78 /* N */,
kPREV = 77 /* M */,
kLAST = mSHIFT | 77 /* SHIFT+M */,
kCYCL = 72 /* H */,
kTICK = 188 /* , */,
kUNTK = mSHIFT | 188 /* , */,
kCPYH = 66 /* B */,
kCPYB = mSHIFT | 66 /* SHIFT+B */,
kTMLN = 74 /* J */,
kTMLB = mSHIFT | 74 /* J */,
kVIEW = 75 /* K */,
kDONE = 27 /* ESC */,
mod = evt.altKey<<15 | evt.ctrlKey<<14 | evt.shiftKey<<13,
key = ( evt.which || evt.keyCode ) | mod;
var dx = 0;
switch( key ){
case kFRST: dx = -2; break;
case kNEXT: dx = -1; break;
case kPREV: dx = +1; break;
case kLAST: dx = +2; break;
case kCYCL:
case kTICK:
case kUNTK:
case kCPYH:
case kCPYB:
case kTMLN:
case kTMLB:
case kVIEW:
case kDONE: break;
default: return;
}
| > > > > > > > | | 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 |
var
mSHIFT = 1<<13,
kFRST = mSHIFT | 78 /* SHIFT+N */,
kNEXT = 78 /* N */,
kPREV = 77 /* M */,
kLAST = mSHIFT | 77 /* SHIFT+M */,
kCYCL = 72 /* H */,
kSCRL = mSHIFT | 72 /* H */,
kTICK = 188 /* , */,
kUNTK = mSHIFT | 188 /* , */,
kCPYH = 66 /* B */,
kCPYB = mSHIFT | 66 /* SHIFT+B */,
kTMLN = 74 /* J */,
kTMLB = mSHIFT | 74 /* J */,
kVIEW = 75 /* K */,
kDONE = 27 /* ESC */,
mod = evt.altKey<<15 | evt.ctrlKey<<14 | evt.shiftKey<<13,
key = ( evt.which || evt.keyCode ) | mod;
var dx = 0;
switch( key ){
case kFRST: dx = -2; break;
case kNEXT: dx = -1; break;
case kPREV: dx = +1; break;
case kLAST: dx = +2; break;
case kCYCL:
case kSCRL:
case kTICK:
case kUNTK:
case kCPYH:
case kCPYB:
case kTMLN:
case kTMLB:
case kVIEW:
case kDONE: break;
default: return;
}
if( key==kSCRL ){
var td = document.querySelector('.timelineFocused');
if( td ) focusScrollToIntoViewTheFossilWay(td);
return;
}
else if( key==kUNTK ){
var tid = focusTickedId();
if( tid ){
var gn = document.getElementById('tln'+tid.slice(1));
if( gn ) gn.click();
}
return;
}
|
| ︙ | ︙ |
Changes to src/timeline.c.
| ︙ | ︙ | |||
1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 | ** Keyboard navigation shortcuts: ** ** N Focus first (newest) entry. ** n Focus next (newer) entry, or open next page. ** m Focus previous (older) entry, or open previous page. ** M Focus last (oldest) entry. ** h Move focus between selected, current (check-out) and ticked entries. ** , Tick/untick the node of the focused entry. ** ; Untick the nodes of all entries. ** b Copy the commit hash of the focused entry to clipboard. ** B Copy the branch name of the focused entry to clipboard. ** j View timeline of focused entry. ** J View timeline of focused entry filtered by branch. ** k View details of focused entry. | > | 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 | ** Keyboard navigation shortcuts: ** ** N Focus first (newest) entry. ** n Focus next (newer) entry, or open next page. ** m Focus previous (older) entry, or open previous page. ** M Focus last (oldest) entry. ** h Move focus between selected, current (check-out) and ticked entries. ** H Scroll to focused entry. ** , Tick/untick the node of the focused entry. ** ; Untick the nodes of all entries. ** b Copy the commit hash of the focused entry to clipboard. ** B Copy the branch name of the focused entry to clipboard. ** j View timeline of focused entry. ** J View timeline of focused entry filtered by branch. ** k View details of focused entry. |
| ︙ | ︙ |