Ticket #11839: 11839.patch

File 11839.patch, 1.9 KB (added by jozsefilles, 11 years ago)
  • plugins/sourcearea/plugin.js

    From 2881e51a8aa6bc3b0fd52f3de5efacb3ad4d26d2 Mon Sep 17 00:00:00 2001
    From: Jozsef Illes <jozsef.illes@liferay.com>
    Date: Mon, 24 Mar 2014 17:21:23 +0100
    Subject: [PATCH 1/2] LPS-42191 Re-activate text area after resize in source mode (fixes IE 9)
    
    ---
     plugins/sourcearea/plugin.js |    4 ++++
     1 files changed, 4 insertions(+), 0 deletions(-)
    
    diff --git a/plugins/sourcearea/plugin.js b/plugins/sourcearea/plugin.js
    index 7af5f10..cd123f7 100644
    a b  
    7777                        });
    7878
    7979                        function onResize() {
     80                                var isTextareaActive = (document.activeElement == this.$);
     81
    8082                                // Holder rectange size is stretched by textarea,
    8183                                // so hide it just for a moment.
    8284                                this.hide();
     
    8486                                this.setStyle( 'width', this.getParent().$.clientWidth + 'px' );
    8587                                // When we have proper holder size, show textarea again.
    8688                                this.show();
     89
     90                                isTextareaActive && this.$.focus();
    8791                        }
    8892                }
    8993        });
  • plugins/sourcearea/plugin.js

    -- 
    1.7.1
    
    
    From 4e72bc6c066206d391fd153f9f65e2f49c6438f1 Mon Sep 17 00:00:00 2001
    From: Byran Zaugg <byran.zaugg@liferay.com>
    Date: Tue, 15 Apr 2014 12:48:15 -0700
    Subject: [PATCH 2/2] LPS-42191 Source format to CKEditor's standards.
    
    ---
     plugins/sourcearea/plugin.js |    5 +++--
     1 files changed, 3 insertions(+), 2 deletions(-)
    
    diff --git a/plugins/sourcearea/plugin.js b/plugins/sourcearea/plugin.js
    index cd123f7..7b012ad 100644
    a b  
    7777                        });
    7878
    7979                        function onResize() {
    80                                 var isTextareaActive = (document.activeElement == this.$);
     80                                var isTextareaActive = ( document.activeElement == this.$ );
    8181
    8282                                // Holder rectange size is stretched by textarea,
    8383                                // so hide it just for a moment.
     
    8787                                // When we have proper holder size, show textarea again.
    8888                                this.show();
    8989
    90                                 isTextareaActive && this.$.focus();
     90                                if ( isTextareaActive )
     91                                        this.$.focus();
    9192                        }
    9293                }
    9394        });
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy