Commit 272c44bb authored by Zhuoyu Qian's avatar Zhuoyu Qian Committed by Commit Bot

Split ClipboardCommands static-only functions out of EditorCommand.cpp

This CL introduce "ClipboardCommand.cpp" with moving |ClipboardCommands|
member into it. Make EditorCommand simpler for improving code health.

Bug: 818552
Signed-off-by: default avatarZhuoyu Qian <zhuoyu.qian@samsung.com>
Change-Id: Icede39fc714367fe57e886f0f9ef23e1989f7518
Reviewed-on: https://chromium-review.googlesource.com/948243Reviewed-by: default avatarYoshifumi Inoue <yosin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#544280}
parent 6c8110b1
...@@ -101,6 +101,7 @@ blink_core_sources("editing") { ...@@ -101,6 +101,7 @@ blink_core_sources("editing") {
"commands/ApplyStyleCommand.h", "commands/ApplyStyleCommand.h",
"commands/BreakBlockquoteCommand.cpp", "commands/BreakBlockquoteCommand.cpp",
"commands/BreakBlockquoteCommand.h", "commands/BreakBlockquoteCommand.h",
"commands/ClipboardCommands.cpp",
"commands/ClipboardCommands.h", "commands/ClipboardCommands.h",
"commands/CompositeEditCommand.cpp", "commands/CompositeEditCommand.cpp",
"commands/CompositeEditCommand.h", "commands/CompositeEditCommand.h",
......
...@@ -32,7 +32,6 @@ ...@@ -32,7 +32,6 @@
#ifndef ClipboardCommands_h #ifndef ClipboardCommands_h
#define ClipboardCommands_h #define ClipboardCommands_h
#include "core/clipboard/DataTransferAccessPolicy.h"
#include "core/editing/Forward.h" #include "core/editing/Forward.h"
#include "platform/wtf/Allocator.h" #include "platform/wtf/Allocator.h"
#include "platform/wtf/text/WTFString.h" #include "platform/wtf/text/WTFString.h"
...@@ -45,6 +44,7 @@ class Event; ...@@ -45,6 +44,7 @@ class Event;
class LocalFrame; class LocalFrame;
class Pasteboard; class Pasteboard;
enum class DataTransferAccessPolicy;
enum class EditorCommandSource; enum class EditorCommandSource;
enum class PasteMode; enum class PasteMode;
...@@ -114,6 +114,10 @@ class ClipboardCommands { ...@@ -114,6 +114,10 @@ class ClipboardCommands {
static void PasteWithPasteboard(LocalFrame&, static void PasteWithPasteboard(LocalFrame&,
Pasteboard*, Pasteboard*,
EditorCommandSource); EditorCommandSource);
using FragmentAndPlainText = std::pair<DocumentFragment*, const bool>;
static FragmentAndPlainText GetFragmentFromClipboard(LocalFrame&,
Pasteboard*);
}; };
} // namespace blink } // namespace blink
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment