Ticket #1344: 1344.patch

File 1344.patch, 3.4 KB (added by Martin Kou, 16 years ago)
  • _whatsnew.html

     
    115115                        Enter in an &lt;o:p&gt; tag in IE does not generate line breaks.</li>
    116116                <li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/481">#481</a>] Fixed the issue where the image
    117117                        preview in image dialog sometimes doesn't display after selecting the image from server browser.</li>
     118                <li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/1344">#1344</a>] Added warning message on
     119                        Copy, Cut and Paste operation failure on IE due to paste permission settings.</li>
    118120        </ul>
    119121        <p>
    120122                <a href="_whatsnew_history.html">See previous versions history</a>
  • editor/_source/commandclasses/fck_othercommands.js

     
    406406{
    407407        Execute : function()
    408408        {
     409                if ( FCKBrowserInfo.IsIE && !FCK._CheckIsPastingEnabled() )
     410                {
     411                        alert( FCKLang.PasteErrorCopy ) ;
     412                        return ;
     413                }
    409414                FCK.ExecuteNamedCommand( this.Name ) ;
    410415        },
    411416
     
    418423        }
    419424};
    420425
     426// FCKCutCommand
     427var FCKCutCommand = function()
     428{
     429        this.Name = 'Cut' ;
     430}
     431
     432FCKCutCommand.prototype =
     433{
     434        Execute : function()
     435        {
     436                if ( FCKBrowserInfo.IsIE && !FCK._CheckIsPastingEnabled() )
     437                {
     438                        alert( FCKLang.PasteErrorCut ) ;
     439                        return ;
     440                }
     441                FCK.ExecuteNamedCommand( this.Name ) ;
     442        },
     443
     444        GetState : function()
     445        {
     446                if ( FCK.EditMode != FCK_EDITMODE_WYSIWYG )
     447                        return FCK_TRISTATE_DISABLED ;
     448                return FCK.GetNamedCommandState( 'Cut' ) ;
     449        }
     450};
     451
     452
    421453var FCKAnchorDeleteCommand = function()
    422454{
    423455        this.Name = 'AnchorDelete' ;
  • editor/_source/internals/fck_ie.js

     
    304304
    305305FCK._CheckIsPastingEnabled = function( returnContents )
    306306{
     307        if ( !returnContents )
     308                return clipboardData.getData( 'Text' ) !== undefined ;
     309
    307310        // The following seams to be the only reliable way to check is script
    308311        // pasting operations are enabled in the security settings of IE6 and IE7.
    309312        // It adds a little bit of overhead to the check, but so far that's the
     
    319322
    320323        document.body.detachEvent( 'onpaste', FCK_CheckPasting_Listener ) ;
    321324
    322         if ( FCK._PasteIsEnabled )
    323         {
    324                 if ( !returnContents )
    325                         oReturn = true ;
    326         }
    327         else
     325        if ( !FCK._PasteIsEnabled )
    328326                oReturn = false ;
    329327
    330328        delete FCK._PasteIsEnabled ;
  • editor/_source/internals/fckcommands.js

     
    127127                case 'Undo'     : oCommand = new FCKUndoCommand() ; break ;
    128128                case 'Redo'     : oCommand = new FCKRedoCommand() ; break ;
    129129                case 'Copy'     : oCommand = new FCKCopyCommand() ; break ;
     130                case 'Cut'      : oCommand = new FCKCutCommand() ; break ;
    130131
    131132                case 'SelectAll'                        : oCommand = new FCKSelectAllCommand() ; break ;
    132133                case 'InsertOrderedList'        : oCommand = new FCKListCommand( 'insertorderedlist', 'ol' ) ; break ;
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy