Commit f5a0654f authored by Sergio Villar Senin's avatar Sergio Villar Senin Committed by Commit Bot

Remove WebEditingCommandType from Blink's API surface

It's only used inside Blink so it does not make sense to expose it. As it is no
longer part of the public API, we're renaming WebEditingCommandType to
EditingCommandType.

Bug: 919392
Change-Id: I22e9ffa7ac9717d57cfc006ee7061ea8eb1ab0d4
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1949793Reviewed-by: default avatarKentaro Hara <haraken@chromium.org>
Commit-Queue: Sergio Villar <svillar@igalia.com>
Cr-Commit-Position: refs/heads/master@{#721457}
parent e7cb4dc3
......@@ -197,7 +197,6 @@ source_set("blink_headers") {
"platform/web_double_size.h",
"platform/web_drag_data.h",
"platform/web_drag_operation.h",
"platform/web_editing_command_type.h",
"platform/web_effective_connection_type.h",
"platform/web_encrypted_media_client.h",
"platform/web_encrypted_media_key_information.h",
......
......@@ -33,6 +33,7 @@ blink_core_sources("editing") {
"commands/drag_and_drop_command.h",
"commands/edit_command.cc",
"commands/edit_command.h",
"commands/editing_command_type.h",
"commands/editing_commands_utilities.cc",
"commands/editing_commands_utilities.h",
"commands/editing_state.cc",
......
......@@ -3,7 +3,7 @@
// found in the LICENSE file.
#include "base/stl_util.h"
#include "third_party/blink/public/platform/web_editing_command_type.h"
#include "third_party/blink/renderer/core/editing/commands/editing_command_type.h"
#include "third_party/blink/renderer/core/editing/commands/editor_command.h"
#include "third_party/blink/renderer/core/editing/commands/editor_command_names.h"
#include "third_party/blink/renderer/core/editing/editor.h"
......@@ -20,19 +20,19 @@ namespace {
struct CommandNameEntry {
const char* name;
WebEditingCommandType type;
EditingCommandType type;
};
const CommandNameEntry kCommandNameEntries[] = {
#define V(name) {#name, WebEditingCommandType::k##name},
#define V(name) {#name, EditingCommandType::k##name},
FOR_EACH_BLINK_EDITING_COMMAND_NAME(V)
#undef V
};
// Test all commands except WebEditingCommandType::Invalid.
// Test all commands except EditingCommandType::Invalid.
static_assert(
base::size(kCommandNameEntries) + 1 ==
static_cast<size_t>(WebEditingCommandType::kNumberOfCommandTypes),
"must test all valid WebEditingCommandType");
static_cast<size_t>(EditingCommandType::kNumberOfCommandTypes),
"must test all valid EditingCommandType");
} // anonymous namespace
......
......@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef THIRD_PARTY_BLINK_PUBLIC_PLATFORM_WEB_EDITING_COMMAND_TYPE_H_
#define THIRD_PARTY_BLINK_PUBLIC_PLATFORM_WEB_EDITING_COMMAND_TYPE_H_
#ifndef THIRD_PARTY_BLINK_RENDERER_CORE_EDITING_COMMANDS_EDITING_COMMAND_TYPE_H_
#define THIRD_PARTY_BLINK_RENDERER_CORE_EDITING_COMMANDS_EDITING_COMMAND_TYPE_H_
namespace blink {
......@@ -11,7 +11,7 @@ namespace blink {
// you should assign new values and update MappedEditingCommands
// in tools/metrics/histograms/histograms.xml, and add the new command to
// EditorCommand.cpp.
enum class WebEditingCommandType {
enum class EditingCommandType {
kInvalid = 0,
kAlignJustified = 1,
kAlignLeft = 2,
......@@ -206,4 +206,4 @@ enum class WebEditingCommandType {
} // namespace blink
#endif // THIRD_PARTY_BLINK_PUBLIC_PLATFORM_WEB_EDITING_COMMAND_TYPE_H_
#endif // THIRD_PARTY_BLINK_RENDERER_CORE_EDITING_COMMANDS_EDITING_COMMAND_TYPE_H_
......@@ -5,9 +5,9 @@
#include "third_party/blink/renderer/core/events/input_event.h"
#include "base/stl_util.h"
#include "third_party/blink/public/platform/web_editing_command_type.h"
#include "third_party/blink/renderer/core/dom/events/event_dispatcher.h"
#include "third_party/blink/renderer/core/dom/range.h"
#include "third_party/blink/renderer/core/editing/commands/editing_command_type.h"
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