Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(25)

Side by Side Diff: third_party/WebKit/Source/core/editing/commands/DragAndDropCommand.h

Issue 2374743002: [InputEvent] Support |deleteByDrag|, |insertFromDrop| and fire in sequential order (Closed)
Patch Set: Yosin's review Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef DragAndDropCommand_h
6 #define DragAndDropCommand_h
7
8 #include "core/editing/commands/CompositeEditCommand.h"
9
10 namespace blink {
11
12 // |DragAndDropCommand| is a dummy command. It doesn't do anything by itself, bu t will act as a catcher for the following |DeleteByDrag| and |InsertFromDrop| co mmands, and combine them into a single undo entry.
yosin_UTC9 2016/10/03 09:19:03 Could you reflow a comment to fit in 80 chars / li
chongz 2016/10/04 02:18:39 Done.
13 // In the future when necessary, this mechanism can be generalized into a common command wrapper to achieve undo group.
14 class DragAndDropCommand final : public CompositeEditCommand {
15 public:
16 static DragAndDropCommand* create(Document& document)
17 {
18 return new DragAndDropCommand(document);
19 }
20
21 bool isCommandGroupWrapper() const override;
22 bool isDragAndDropCommand() const override;
23
24 private:
25 explicit DragAndDropCommand(Document&);
26
27 void doApply(EditingState*) override;
28 InputEvent::InputType inputType() const override;
29 };
30
31 } // namespace blink
32
33 #endif // DragAndDropCommand_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698