Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-3058

SelectionPreserver does not work properly with selection contents deletion on IE

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • 1.7.1, 1.8 M1
    • 1.7
    • WYSIWYG Editor
    • None
    • IE
    • Unit

    Description

      If the selection contents are completely deleted after a SelectionPreserver.store(), then, in certain situations, the actual selection (caret) can slide in one of the spans that mark the start and end of the selection preserver. If content is added at this point, it is added in these elements and, upon, SelectionPreserver.restore() will be deleted with the markers.

      One example is the replacement of an image with the InsertHTML command with selection preserving: when the selection is on the image and the image element is deleted, the caret slides in the preserver's marker spans, causing the new html (the one to be inserted) to be added in the span and deleted upon selection restore.

      This behaviour was noticed on IE7, and it does not reproduce on FF.

      Attachments

        Issue Links

          Activity

            People

              mflorea Marius Dumitru Florea
              lucaa Anca Luca
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: