[Libreoffice-commits] online.git: loleaflet/dist loleaflet/src

Henry Castro hcastro at collabora.com
Sat Jan 7 03:12:31 UTC 2017


 loleaflet/dist/loleaflet-help.html        |    1 +
 loleaflet/src/map/handler/Map.Keyboard.js |    6 ++++++
 2 files changed, 7 insertions(+)

New commits:
commit 73cf6f71fbe1ccb1946958b06e8deab16176a82c
Author: Henry Castro <hcastro at collabora.com>
Date:   Fri Jan 6 23:11:48 2017 -0400

    tdf#103779: Help menu accessibility, part 2
    
    Add a keyboard shortcut ctrl + h to display the
    Keyboard shortcuts help

diff --git a/loleaflet/dist/loleaflet-help.html b/loleaflet/dist/loleaflet-help.html
index 2184635..bfed701 100644
--- a/loleaflet/dist/loleaflet-help.html
+++ b/loleaflet/dist/loleaflet-help.html
@@ -31,6 +31,7 @@
             <tr> <td class="function">Cut</td> <td class="shortcut">Ctrl + X</td> </tr>
             <tr> <td class="function">Paste as unformatted text</td> <td class="shortcut">Ctrl + Alt + Shift + V</td> </tr>
             <tr> <td class="function">Print (Download as PDF)</td> <td class="shortcut">Ctrl + P</td> </tr>
+            <tr> <td class="function">Display the Keyboard shortcuts help</td> <td class="shortcut">Ctrl + H</td> </tr>
         </table>
     </div>
     <div id="text-shortcuts" style="display: none;">
diff --git a/loleaflet/src/map/handler/Map.Keyboard.js b/loleaflet/src/map/handler/Map.Keyboard.js
index 84c72d3..77302a8 100644
--- a/loleaflet/src/map/handler/Map.Keyboard.js
+++ b/loleaflet/src/map/handler/Map.Keyboard.js
@@ -398,6 +398,12 @@ L.Map.Keyboard = L.Handler.extend({
 			e.originalEvent.preventDefault();
 		}
 
+		if (e.originalEvent.ctrlKey && (e.originalEvent.key === 'h' || e.originalEvent.key === 'H')) {
+			map.showLOKeyboardHelp();
+			e.originalEvent.preventDefault();
+			return true;
+		}
+
 		if (e.originalEvent.ctrlKey && (e.originalEvent.key === 'z' || e.originalEvent.key === 'Z')) {
 			this._map._socket.sendMessage('uno .uno:Undo');
 			e.originalEvent.preventDefault();


More information about the Libreoffice-commits mailing list