Changeset 53203 in webkit
- Timestamp:
- Jan 13, 2010 1:59:28 PM (14 years ago)
- Location:
- trunk
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r53201 r53203 1 2010-01-13 Brian Weinstein <bweinstein@apple.com> 2 3 Reviewed by Adam Roben. 4 5 REGRESSION (r49268): DHTML drag not allowed unless event.dataTransfer.effectAllowed 6 is set (differs from HTML5). 7 Fixes <https://bugs.webkit.org/show_bug.cgi?id=33607> and <rdar://7507114>. 8 9 Updated the drag and drop test to test if effectAllowed isn't set, in addition 10 to its other tests. 11 12 * fast/events/drag-and-drop-expected.txt: 13 * fast/events/drag-and-drop.html: 14 1 15 2010-01-13 Dirk Schulze <krit@webkit.org> 2 16 -
trunk/LayoutTests/fast/events/drag-and-drop-expected.txt
r50888 r53203 12 12 PASS event.dataTransfer.dropEffect is "move" 13 13 PASS event.dataTransfer.dropEffect is "link" 14 PASS event.dataTransfer.dropEffect is "none" 15 16 When effectAllowed == "undefined" 17 18 PASS event.dataTransfer.effectAllowed is "uninitialized" 19 PASS event.dataTransfer.dropEffect is "none" 20 PASS event.dataTransfer.effectAllowed is "uninitialized" 21 PASS event.dataTransfer.dropEffect is "copy" 22 PASS event.dataTransfer.effectAllowed is "uninitialized" 23 PASS event.dataTransfer.dropEffect is "move" 24 PASS event.dataTransfer.effectAllowed is "uninitialized" 25 PASS event.dataTransfer.dropEffect is "link" 26 PASS event.dataTransfer.effectAllowed is "uninitialized" 14 27 PASS event.dataTransfer.dropEffect is "none" 15 28 -
trunk/LayoutTests/fast/events/drag-and-drop.html
r50888 r53203 40 40 { 41 41 event = e; 42 e.dataTransfer.effectAllowed = effectAllowedElem.options[effectAllowedElem.selectedIndex].value; 42 if (effectAllowedElem.options[effectAllowedElem.selectedIndex].value != "undefined") 43 e.dataTransfer.effectAllowed = effectAllowedElem.options[effectAllowedElem.selectedIndex].value; 44 43 45 e.dataTransfer.setData('Text', e.target.textContent); 44 46 } … … 88 90 var chosenEffectAllowed = effectAllowedElem.options[effectAllowedElem.selectedIndex].value; 89 91 var actualDropEffect = e.dataTransfer.dropEffect; 92 93 if (chosenEffectAllowed === "undefined") { 94 // If no effectAllowed is set, we should default to uninitialized. Make sure that's the case. 95 shouldBeEqualToString("event.dataTransfer.effectAllowed", "uninitialized"); 96 97 // Then set the chosenEffectAllowed so isDropEffectAllowed matches the HTML5 spec, and 98 // doesn't need special cases for undefined. 99 chosenEffectAllowed = "uninitialized"; 100 } 90 101 91 102 if (isDropEffectAllowed(chosenDropEffect, chosenEffectAllowed)) … … 149 160 <label for="effectAllowed">effectAllowed</label> <select id="effectAllowed"> 150 161 <option value="uninitialized">Uninitialized</option> 162 <option value="undefined">Undefined</option> 151 163 <option value="none">None</option> 152 164 <option value="all">All</option> -
trunk/WebCore/ChangeLog
r53200 r53203 1 2010-01-13 Brian Weinstein <bweinstein@apple.com> 2 3 Reviewed by Adam Roben. 4 5 REGRESSION (r49268): DHTML drag not allowed unless event.dataTransfer.effectAllowed 6 is set (differs from HTML5). 7 Fixes <https://bugs.webkit.org/show_bug.cgi?id=33607> and <rdar://7507114>. 8 9 If no effectAllowed is set in the dragStart operation, we should default to 10 uninitialized instead of none, so the user doesn't have to manually set the 11 effectAllowed to enable drag and drop. 12 13 * dom/Clipboard.cpp: 14 (WebCore::Clipboard::Clipboard): 15 1 16 2010-01-13 Dave Hyatt <hyatt@apple.com> 2 17 -
trunk/WebCore/dom/Clipboard.cpp
r50888 r53203 37 37 Clipboard::Clipboard(ClipboardAccessPolicy policy, bool isForDragging) 38 38 : m_policy(policy) 39 , m_effectAllowed("uninitialized") 39 40 , m_dragStarted(false) 40 41 , m_forDragging(isForDragging)
Note: See TracChangeset
for help on using the changeset viewer.