Open Bug 97632 Opened 23 years ago Updated 4 years ago

Data dragged from multiple cells into another table can not be undone

Categories

(Core :: DOM: Editor, defect, P5)

defect

Tracking

()

mozilla1.4beta

People

(Reporter: TucsonTester2, Unassigned)

References

Details

From Bugzilla Helper:
User-Agent: Mozilla/5.0 (Windows; U; Win98; en-US; rv:0.9.3+) Gecko/20010828
Netscape6/6.1b1
BuildID:    20010828

After creating a table and putting text into each cell I highlighted the text by
dragging my mouse across it.  After that I dragged that from the table into
another table's cell.  Once the information was in there I could not undo the
action.  I could not highlight the text either.

Reproducible: Always
Steps to Reproduce:
1.Open Composer
2.Create a 2x2 100%width table using the table button in the toolbar
3.Type text into each cell
4.Create a new table, like the one in step 2, below the first table.
5.Highlight only the text in the first table by dragging your mouse across the cells
6.Click and hold on a highlighted are of the text
7.Drag the text into a cell in the second table that was created
8.Click on edit then undo

Actual Results:  Once I clicked on undo, which was an active option, the text
did not go back into the seperate cells.  In fact it did nothing at all.  When I
checked the html source it showed that there were extra tags with each piece of
cell data. Each piece of data from the cells was wrapped in <td> tags. Instead
each piece of data should just be regular text.  Also, if I dragged this same
data onto the regular page not tags would be added.

If you cut and paste the text it will actually be a copy of the first table with
the data.  But when you do the cut it only takes out the cell data and not the
table itself.

Expected Results:  I would expect that each piece of text would be put into the
cell without any problem.  Also if I wanted to undo the operation, that should
be available as well.

Here is an example of some html from the source after performing the above steps:

<table cellpadding="2" cellspacing="2" border="1" width="100%">
  <tbody>
    <tr>
      <td valign="Top"><tr>
        <td valign="Top">cell 1<br>
        </td>
        <td valign="Top">cell 2<br>
        </td>
      </tr>
      <tr>
        <td valign="Top">cell 3<br>
        </td>
        <td valign="Top">cell 4</td>
      </tr>
      <br>
      </td>
      <td valign="Top"><br>
      </td>
    </tr>
    <tr>
      <td valign="Top"><br>
      </td>
      <td valign="Top"><br>
      </td>
    </tr>
  </tbody>
</table>
I can confirm this on Linux 0.9.3 Milestone and in build 2001083016
Confirmed on 9-10 build
Status: UNCONFIRMED → NEW
Ever confirmed: true
-->cmanske

reporter:  is this a problem just for dragged selection or also a problem with 
copy/paste?  Can the paste be undone?
Assignee: brade → cmanske
If you use a copy/paste with the text it puts the text in a 2x2 table inside of
the cell, so it is more like it copied the table instead of the text.  That
operation can be undone though.
There is no problem if only contents within one cell is selected. The problem is
that if you try to drag-select all the contents of a cell, you are very likely
to have crossed into the next cell without realizing it. When that happens, the 
cell included in the selection messes things up.
Another problem that will be solved by not allowing selection of text across 
cell boundaries.
Status: NEW → ASSIGNED
Depends on: 98558
Target Milestone: --- → mozilla1.0
Milestone load balancing.
Target Milestone: mozilla1.0 → mozilla0.9.8
moving milestone and reassigning
Assignee: cmanske → jfrancis
Status: ASSIGNED → NEW
Target Milestone: mozilla0.9.8 → mozilla0.9.9
the swami says: things that will not land in 099!
Target Milestone: mozilla0.9.9 → mozilla1.0
Moving bugs to Mozilla1.1 that are not EDITORBASE+.
Target Milestone: mozilla1.0 → mozilla1.1
This is also a problem when trying to undo the drag of *some* (sorry) bulleted
lists.

In general, I'm noticing undo problems when dragging things, lists, tables,
images, etc. copy/paste seems to provide more consistent undo capability.
The trunk is the wave of the future!
Target Milestone: mozilla1.1alpha → mozilla1.1beta
The days of having a half dozen milestones out in front of us to divide bugs 
between seem to be gone, though I dont know why.  Lumping everything together as 
far out as I can.  I'll pull back things that I am working on as I go.
Target Milestone: mozilla1.1beta → mozilla1.2beta
[ushing these out as far as bugzilla will let me.  I'll pull them back as I work
on them.
Target Milestone: mozilla1.2beta → mozilla1.4beta
QA Contact: sujay → editor
Assignee: mozeditor → nobody

Bulk-downgrade of unassigned, >=5 years untouched DOM/Storage bugs' priority.

If you have reason to believe this is wrong (especially for the severity), please write a comment and ni :jstutte.

Severity: normal → S4
Priority: -- → P5
You need to log in before you can comment on or make changes to this bug.