aboutsummaryrefslogtreecommitdiffstats
path: root/theme
diff options
context:
space:
mode:
Diffstat (limited to 'theme')
-rw-r--r--theme/dive_export.html2
-rw-r--r--theme/list_lib.js13
2 files changed, 15 insertions, 0 deletions
diff --git a/theme/dive_export.html b/theme/dive_export.html
index 91c47dbe9..e1d89f48c 100644
--- a/theme/dive_export.html
+++ b/theme/dive_export.html
@@ -111,6 +111,8 @@ window.onload=function(){
showAllDives();
document.getElementById("divePanel").style.display='none';
document.body.style.visibility='visible';
+
+ document.onkeydown = switchDives;
}
function changeAdvSearch(e){
diff --git a/theme/list_lib.js b/theme/list_lib.js
index 0d84516d2..4347475c6 100644
--- a/theme/list_lib.js
+++ b/theme/list_lib.js
@@ -1026,3 +1026,16 @@ function prevDetailedDive()
showDiveDetails(--dive_id);
}
}
+
+function switchDives(e)
+{
+ if(document.getElementById("divePanel").style.display == 'block'){
+ e = e || window.event;
+ if (e.keyCode == '37') {
+ prevDetailedDive();
+ }
+ else if (e.keyCode == '39') {
+ nextDetailedDive();
+ }
+ }
+}