loleaflet/src/map/handler/Map.Keyboard.js |    6 ++++++
 1 file changed, 6 insertions(+)

New commits:
commit 8dd56fafe7d9fe0db15f09ad0c49357178c2aaba
Author: farukuzun <[email protected]>
Date:   Mon Jan 4 21:57:22 2016 +0200

    loleaflet: Fix Ctrl+Alt+C (insert comment) on Firefox
    
    On Firefox, pressing Ctrl+Alt+c (uppercase "C" is working fine)
    to insert a comment causes a "c" letter in comment box,
    because KeyboardEvent.char[0] deprecated. It is working
    quite well in other browsers. A workaround is needed for Firefox.
    
    [0]: https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/char
    
    Change-Id: Iaf89c8b3b758e99189dd982e2d36aef559a32f1a
    Reviewed-on: https://gerrit.libreoffice.org/21086
    Reviewed-by: Andras Timar <[email protected]>
    Tested-by: Andras Timar <[email protected]>

diff --git a/loleaflet/src/map/handler/Map.Keyboard.js 
b/loleaflet/src/map/handler/Map.Keyboard.js
index 6df4b4c..6ef3c23 100644
--- a/loleaflet/src/map/handler/Map.Keyboard.js
+++ b/loleaflet/src/map/handler/Map.Keyboard.js
@@ -340,6 +340,12 @@ L.Map.Keyboard = L.Handler.extend({
 
                if (e.originalEvent.altKey || e.originalEvent.shiftKey) {
 
+                       // need to handle Ctrl + Alt + C separately for Firefox
+                       if (e.originalEvent.key === 'c' && 
e.originalEvent.altKey) {
+                               L.Socket.sendMessage('uno 
.uno:InsertAnnotation');
+                               return true;
+                       }
+
                        // Ctrl + Alt
                        if (!e.originalEvent.shiftKey) {
                                switch (e.originalEvent.keyCode) {
_______________________________________________
Libreoffice-commits mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to