<html> 
<head>
<script src=../editing.js type="text/javascript"></script>
<script>
function editingTest() {
  
    if (!window.testRunner)
        return;
    if (window.internals)
        internals.settings.setEditingBehavior("mac");

    extendSelectionForwardByWordCommand();
    
    window.testRunner.waitUntilDone();
    
    // Drag 'hello'
    var e = document.getElementById("dragme");
    x = e.offsetLeft + 10;
    y = e.offsetTop + e.offsetHeight / 2;
    eventSender.mouseMoveTo(x, y);
    eventSender.mouseDown();
    // and drop it off to the right somewhere
    eventSender.leapForward(500);
    eventSender.mouseMoveTo(x + 300, y);
    eventSender.mouseUp();

    window.testRunner.notifyDone();
}
</script>
<title>Drag and drop within a text input field modifies page</title> 
</head> 
<body>
<p>This tests non-smartmove drag/drop. The space should be deleted on move,
but not reinserted on drop, resulting in "worldhello".</p>
<div contenteditable="true" id="test"><span id="dragme">hello</span> world</div>
<script>runEditingTest();</script>
</body>
</html>
