⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 243785 in webkit


Ignore:
Timestamp:
Apr 2, 2019, 8:46:37 PM (7 years ago)
Author:
timothy@apple.com
Message:

Cursor count badge reverts to Zero during Drag & Drop of multiple items.
https://bugs.webkit.org/show_bug.cgi?id=196511

Reviewed by Daniel Bates.

  • page/DragController.cpp:

(WebCore::DragController::tryDocumentDrag): Don't set m_numberOfItemsToBeAccepted to
zero when dragging to a non-file input element.

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r243782 r243785  
     12019-04-02  Timothy Hatcher  <timothy@apple.com>
     2
     3        Cursor count badge reverts to Zero during Drag & Drop of multiple items.
     4        https://bugs.webkit.org/show_bug.cgi?id=196511
     5
     6        Reviewed by Daniel Bates.
     7
     8        * page/DragController.cpp:
     9        (WebCore::DragController::tryDocumentDrag): Don't set m_numberOfItemsToBeAccepted to
     10        zero when dragging to a non-file input element.
     11
    1122019-04-02  Chris Dumez  <cdumez@apple.com>
    213
  • trunk/Source/WebCore/page/DragController.cpp

    r243163 r243785  
    443443        Frame* innerFrame = element->document().frame();
    444444        dragOperation = dragIsMove(innerFrame->selection(), dragData) ? DragOperationMove : DragOperationCopy;
    445         m_numberOfItemsToBeAccepted = 0;
    446445
    447446        unsigned numberOfFiles = dragData.numberOfFiles();
     
    460459            m_fileInputElementUnderMouse->setCanReceiveDroppedFiles(m_numberOfItemsToBeAccepted);
    461460        } else {
    462             // We are not over a file input element. The dragged item(s) will only
    463             // be loaded into the view the number of dragged items is 1.
    464             m_numberOfItemsToBeAccepted = numberOfFiles != 1 ? 0 : 1;
     461            // We are not over a file input element. The dragged item(s) will loaded into the view,
     462            // dropped as text paths on other input elements, or handled by script on the page.
     463            m_numberOfItemsToBeAccepted = numberOfFiles;
    465464        }
    466465
Note: See TracChangeset for help on using the changeset viewer.