Migrate to NOTREACHED() in ui/
NOTREACHED() and NOTREACHED_IN_MIGRATION() are both CHECK-fatal now. The former is [[noreturn]] so this CL also performs dead-code removal after the NOTREACHED(). This CL does not attempt to do additional rewrites of any surrounding code, like: if (!foo) { NOTREACHED(); } to CHECK(foo); Those transforms take a non-trivial amount of time (and there are thousands of instances). Cleanup can be left as an exercise for the reader. Bug: 40580068 Change-Id: Ib1ec65c775c4c64f0dffc002c232000d3688a2fb Cq-Include-Trybots: luci.chromium.try:linux-dcheck-off-rel Low-Coverage-Reason: OTHER Should-be-unreachable code Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5975073 Commit-Queue: Peter Boström <pbos@chromium.org> Reviewed-by: Sam McNally <sammc@chromium.org> Reviewed-by: Mitsuru Oshima <oshima@chromium.org> Cr-Commit-Position: refs/heads/main@{#1375585}
This commit is contained in:

committed by
Chromium LUCI CQ

parent
c19d3f573f
commit
e4f1aef5f3
ui
accelerated_widget_mac
accessibility
ax_action_handler_registry.ccax_enum_util.ccax_enum_util.hax_event_generator.ccax_node.ccax_node_data.ccax_node_position_fuzzer.ccax_position.hax_text_utils.ccax_tree_manager_base.cc
mojom
platform
atk_util_auralinux_unittest.cc
test_ax_tree_update.cctree_generator.ccautomation
ax_platform_node_auralinux.ccax_platform_node_base.ccax_platform_node_cocoa.mmax_platform_node_delegate.ccax_platform_node_mac.mmax_platform_node_textrangeprovider_win_fuzzer.ccax_platform_node_win.ccbrowser_accessibility.ccbrowser_accessibility_cocoa.mmbrowser_accessibility_com_win.ccbrowser_accessibility_mac.mmbrowser_accessibility_manager.ccinspect
ax_element_wrapper_mac.mmax_inspect_scenario.ccax_tree_formatter_base.ccax_tree_formatter_uia_win.cc
test_ax_node_wrapper.ccandroid
aura
env.ccenv_input_state_controller.cc
gestures
native_window_occlusion_tracker_win.ccnull_window_targeter.ccscreen_ozone.cctest
window.ccwindow_event_dispatcher.ccwindow_event_dispatcher_unittest.ccaura_extra
chromeos
compositor
display
display.ccdisplay_transform.ccdisplay_util.cc
manager
display_configurator.ccdisplay_layout_store.ccdisplay_manager.ccmanaged_display_info.cc
test
touch_transform_controller.ccupdate_display_configuration_task_unittest.ccutil
mojom
display_constants_mojom_traits.ccdisplay_layout_mojom_traits.ccdisplay_mojom_traits.ccdisplay_snapshot_mojom_traits.cc
screen_android.ccscreen_info.cctypes
win
events
android
ash
blink
event.ccevent_dispatcher_unittest.ccevent_rewriter.ccevent_rewriter_unittest.ccevent_target.ccevent_utils.ccfuchsia
gesture_detection
gesture_detector.ccgesture_event_data.ccgesture_event_data_packet.ccgesture_provider.ccgesture_touch_uma_histogram.cctouch_disposition_gesture_filter.cc
gesture_event_details.ccgestures
keycodes
mobile_scroller.ccmojom
null_event_targeter.ccozone
device
evdev
event_converter_evdev.ccevent_device_info.cc
events_ozone.cclibgestures_glue
tablet_event_converter_evdev_unittest.ccplatform
test
velocity_tracker
x
gfx
android
animation
bidi_line_iterator.ccbuffer_format_util.cccodec
color_analysis.cccolor_space.cccolor_transform.ccfont_render_params.ccgeometry
gpu_fence.ccgpu_fence_handle.ccimage
linux
mac
mojom
accelerated_widget_mojom_traits.hbuffer_types_mojom_traits.hca_layer_result_mojom_traits.cccolor_space_mojom_traits.hfont_render_params_mojom_traits.hoverlay_priority_hint_mojom_traits.hoverlay_transform_mojom_traits.hrrect_f_mojom_traits.hselection_bound_mojom_traits.hswap_result_mojom_traits.h
overlay_transform_utils.ccpaint_vector_icon.ccplatform_font_skia.ccrender_text.ccrender_text_harfbuzz.cctext_elider.ccvector_icon_utils.ccwin
x
gl
direct_composition_support.ccegl_bindings_autogen_mock.ccgenerate_bindings.pygl_bindings_autogen_gl.ccgl_bindings_autogen_mock.ccgl_context.ccgl_context_egl.ccgl_display.ccgl_fence.ccgl_fence_win.ccgl_gl_api_implementation.ccgl_mock.hgl_surface.ccgl_surface_egl.ccgl_version_info.cc
init
create_gr_gl_interface.ccgl_factory_android.ccgl_factory_ios.mmgl_factory_mac.ccgl_factory_ozone.ccgl_factory_win.ccgl_initializer_android.ccgl_initializer_ios.ccgl_initializer_mac.ccgl_initializer_ozone.ccgl_initializer_win.cc
mojom
scoped_restore_texture.ccswap_chain_presenter.cctest
gtk
gtk_ui.ccgtk_util.ccnative_theme_gtk.ccnav_button_provider_gtk.cc
printing
select_file_dialog_linux_gtk.cclatency
linux
message_center
native_theme
caption_style_win.cccommon_theme.ccnative_theme_android.ccnative_theme_base.ccnative_theme_fluent.ccnative_theme_ios.mmnative_theme_mac.mmnative_theme_utils.ccnative_theme_win.cc
ozone
common
demo
platform
cast
drm
common
gpu
drm_device.ccdrm_display.cchardware_display_plane.cchardware_display_plane_atomic.cchardware_display_plane_manager_unittest.ccscreen_manager.ccscreen_manager_unittest.cc
host
ozone_platform_drm.cctest
flatland
flatland_surface.ccflatland_sysmem_buffer_collection.ccflatland_sysmem_native_pixmap.ccvulkan_implementation_flatland.cc
headless
wayland
common
gpu
host
org_gnome_mutter_idle_monitor.ccwayland_buffer_factory.ccwayland_buffer_manager_host.ccwayland_clipboard.ccwayland_frame_manager.ccwayland_screen.ccwayland_window.ccwayland_window_factory.ccxdg_foreign_wrapper.ccxdg_popup_wrapper_impl.ccxdg_surface_wrapper_impl.ccxdg_toplevel_wrapper_impl.cc
test
x11
public
platform_window
qt
shell_dialogs
execute_select_file_win.ccselect_file_dialog_fuchsia.ccselect_file_dialog_linux_kde.ccselect_file_dialog_linux_portal.ccselect_file_dialog_mac.mmselect_file_dialog_win.ccshell_dialog_linux.cc
touch_selection
views
web_dialogs
webui
examples
browser
resources
cr_components
app_management
wm
@ -1261,8 +1261,7 @@ void CARendererLayerTree::ContentLayer::CommitToCA(
|
||||
green = blue = 1;
|
||||
break;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
}
|
||||
break;
|
||||
case CALayerType::kDefault:
|
||||
|
@ -137,8 +137,7 @@ bool WrappedTask::ShouldRunBefore(const WrappedTask& other) {
|
||||
if (sequence_number_ > other.sequence_number_)
|
||||
return false;
|
||||
// Sequence numbers are unique, so this should never happen.
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
void WrappedTask::Run() {
|
||||
@ -274,8 +273,7 @@ bool PumpableTaskRunner::PostNonNestableDelayedTask(
|
||||
base::TimeDelta delay) {
|
||||
// The correctness of non-nestable events hasn't been proven for this
|
||||
// structure.
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
bool PumpableTaskRunner::RunsTasksInCurrentSequence() const {
|
||||
|
@ -23,8 +23,7 @@ void AXActionHandlerRegistry::SetFrameIDForAXTreeID(
|
||||
const AXTreeID& ax_tree_id) {
|
||||
auto it = frame_to_ax_tree_id_map_.find(frame_id);
|
||||
if (it != frame_to_ax_tree_id_map_.end()) {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
frame_to_ax_tree_id_map_[frame_id] = ax_tree_id;
|
||||
|
@ -997,8 +997,7 @@ ax::mojom::Role StringToRole(const std::string& role) {
|
||||
}
|
||||
|
||||
// We should never pass in an invalid role.
|
||||
NOTREACHED_IN_MIGRATION() << "Invalid role was provided: " << role;
|
||||
return ax::mojom::Role::kUnknown;
|
||||
NOTREACHED() << "Invalid role was provided: " << role;
|
||||
}
|
||||
|
||||
const char* ToString(ax::mojom::State state) {
|
||||
@ -1088,8 +1087,7 @@ ax::mojom::State StringToState(const std::string& str) {
|
||||
}
|
||||
|
||||
// We should never pass in an invalid state.
|
||||
NOTREACHED_IN_MIGRATION() << "An invalid state was provided: " << str;
|
||||
return ax::mojom::State::kNone;
|
||||
NOTREACHED() << "An invalid state was provided: " << str;
|
||||
}
|
||||
|
||||
const char* ToString(ax::mojom::Action action) {
|
||||
@ -1439,9 +1437,8 @@ ax::mojom::StringAttribute StringToStringAttribute(
|
||||
} else if (string_attribute == "kVirtualContent") {
|
||||
return ax::mojom::StringAttribute::kVirtualContent;
|
||||
} else {
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "An invalid StringAttribute was provided: " << string_attribute;
|
||||
return ax::mojom::StringAttribute::kNone;
|
||||
NOTREACHED() << "An invalid StringAttribute was provided: "
|
||||
<< string_attribute;
|
||||
}
|
||||
}
|
||||
|
||||
@ -1727,9 +1724,7 @@ ax::mojom::IntAttribute StringToIntAttribute(const std::string& int_attribute) {
|
||||
return ax::mojom::IntAttribute::kMaxLength;
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "An invalid IntAttribute was provided: " << int_attribute;
|
||||
return ax::mojom::IntAttribute::kNone;
|
||||
NOTREACHED() << "An invalid IntAttribute was provided: " << int_attribute;
|
||||
}
|
||||
|
||||
const char* ToString(ax::mojom::FloatAttribute float_attribute) {
|
||||
@ -1857,9 +1852,7 @@ ax::mojom::BoolAttribute StringToBoolAttribute(
|
||||
} else if (bool_attribute == "kLongClickable") {
|
||||
return ax::mojom::BoolAttribute::kLongClickable;
|
||||
} else {
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "An invalid BoolAttribute was provided: " << bool_attribute;
|
||||
return ax::mojom::BoolAttribute::kNone;
|
||||
NOTREACHED() << "An invalid BoolAttribute was provided: " << bool_attribute;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -198,9 +198,7 @@ T ParseAXEnum(const char* attribute) {
|
||||
return result.value();
|
||||
}
|
||||
|
||||
LOG(ERROR) << "Could not parse: " << attribute;
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return T::kNone;
|
||||
NOTREACHED() << "Could not parse: " << attribute;
|
||||
}
|
||||
|
||||
} // namespace ui
|
||||
|
@ -1481,9 +1481,7 @@ AXEventGenerator::Event ParseGeneratedEvent(const char* attribute) {
|
||||
if (MaybeParseGeneratedEvent(attribute, &event))
|
||||
return event;
|
||||
|
||||
LOG(ERROR) << "Could not parse: " << attribute;
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return AXEventGenerator::Event::NONE;
|
||||
NOTREACHED() << "Could not parse: " << attribute;
|
||||
}
|
||||
|
||||
} // namespace ui
|
||||
|
@ -727,10 +727,8 @@ std::optional<int> AXNode::CompareTo(const AXNode& other) const {
|
||||
return 1;
|
||||
|
||||
if (our_ancestors.empty() || other_ancestors.empty()) {
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "The common ancestor should be followed by two uncommon "
|
||||
"children in the two corresponding lists of ancestors.";
|
||||
return std::nullopt;
|
||||
NOTREACHED() << "The common ancestor should be followed by two uncommon "
|
||||
"children in the two corresponding lists of ancestors.";
|
||||
}
|
||||
|
||||
size_t this_uncommon_ancestor_index = our_ancestors.top()->GetIndexInParent();
|
||||
|
@ -182,8 +182,7 @@ bool IsNodeIdIntAttribute(ax::mojom::IntAttribute attr) {
|
||||
return false;
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
// Returns true if |attr| contains a vector of node ids that would need
|
||||
@ -660,8 +659,7 @@ void AXNodeData::RemoveState(ax::mojom::State state_enum) {
|
||||
void AXNodeData::AddAction(ax::mojom::Action action_enum) {
|
||||
switch (action_enum) {
|
||||
case ax::mojom::Action::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
|
||||
// Note: all of the attributes are included here explicitly, rather than
|
||||
// using "default:", so that it's a compiler error to add a new action
|
||||
|
@ -115,8 +115,7 @@ TestPositionType AXNodePositionFuzzerGenerator::CreateNewPosition(
|
||||
return ui::AXNodePosition::CreateTextPosition(
|
||||
*anchor, child_index_or_text_offset, affinity);
|
||||
case ui::AXPositionKind::NULL_POSITION:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return ui::AXNodePosition::CreateNullPosition();
|
||||
NOTREACHED();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -325,8 +325,7 @@ class AXPosition {
|
||||
|
||||
AXPositionInstance CloneWithDownstreamAffinity() const {
|
||||
if (!IsTextPosition()) {
|
||||
NOTREACHED_IN_MIGRATION() << "Only text positions have affinity.";
|
||||
return CreateNullPosition();
|
||||
NOTREACHED() << "Only text positions have affinity.";
|
||||
}
|
||||
|
||||
AXPositionInstance clone_with_downstream_affinity = Clone();
|
||||
@ -337,8 +336,7 @@ class AXPosition {
|
||||
|
||||
AXPositionInstance CloneWithUpstreamAffinity() const {
|
||||
if (!IsTextPosition()) {
|
||||
NOTREACHED_IN_MIGRATION() << "Only text positions have affinity.";
|
||||
return CreateNullPosition();
|
||||
NOTREACHED() << "Only text positions have affinity.";
|
||||
}
|
||||
|
||||
AXPositionInstance clone_with_upstream_affinity = Clone();
|
||||
@ -592,8 +590,7 @@ class AXPosition {
|
||||
|
||||
switch (kind_) {
|
||||
case AXPositionKind::NULL_POSITION:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
case AXPositionKind::TREE_POSITION: {
|
||||
// If this is a "before text" or an "after text" tree position, it's
|
||||
// pointing to the anchor itself, which we've determined to be
|
||||
@ -766,8 +763,7 @@ class AXPosition {
|
||||
case AXPositionKind::NULL_POSITION:
|
||||
return false;
|
||||
case AXPositionKind::TREE_POSITION:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
case AXPositionKind::TEXT_POSITION: {
|
||||
const std::vector<int32_t>& word_starts =
|
||||
text_position->GetWordStartOffsets();
|
||||
@ -794,8 +790,7 @@ class AXPosition {
|
||||
case AXPositionKind::NULL_POSITION:
|
||||
return false;
|
||||
case AXPositionKind::TREE_POSITION:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
case AXPositionKind::TEXT_POSITION: {
|
||||
const std::vector<int32_t>& word_ends =
|
||||
text_position->GetWordEndOffsets();
|
||||
@ -810,8 +805,7 @@ class AXPosition {
|
||||
case AXPositionKind::NULL_POSITION:
|
||||
return false;
|
||||
case AXPositionKind::TREE_POSITION:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
case AXPositionKind::TEXT_POSITION:
|
||||
// We treat a position after some white space that is not connected to
|
||||
// any node after it via "next on line ID", to be equivalent to a
|
||||
@ -860,8 +854,7 @@ class AXPosition {
|
||||
case AXPositionKind::NULL_POSITION:
|
||||
return false;
|
||||
case AXPositionKind::TREE_POSITION:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
case AXPositionKind::TEXT_POSITION:
|
||||
// Text positions on objects with no text should not be considered at
|
||||
// end of line because the empty position may share a text offset with
|
||||
@ -1008,8 +1001,7 @@ class AXPosition {
|
||||
case AXPositionKind::NULL_POSITION:
|
||||
return false;
|
||||
case AXPositionKind::TREE_POSITION:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
case AXPositionKind::TEXT_POSITION: {
|
||||
const std::vector<int32_t>& sentence_starts =
|
||||
text_position->GetAnchor()->GetIntListAttribute(
|
||||
@ -1037,8 +1029,7 @@ class AXPosition {
|
||||
case AXPositionKind::NULL_POSITION:
|
||||
return false;
|
||||
case AXPositionKind::TREE_POSITION:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
case AXPositionKind::TEXT_POSITION: {
|
||||
const std::vector<int32_t>& sentence_ends =
|
||||
text_position->GetAnchor()->GetIntListAttribute(
|
||||
@ -1076,8 +1067,7 @@ class AXPosition {
|
||||
case AXPositionKind::NULL_POSITION:
|
||||
return false;
|
||||
case AXPositionKind::TREE_POSITION:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
case AXPositionKind::TEXT_POSITION: {
|
||||
// 1. The current leaf text position must be at the start of an anchor,
|
||||
// or after a '\n' character if white space is preserved (e.g. when
|
||||
@ -1152,8 +1142,7 @@ class AXPosition {
|
||||
case AXPositionKind::NULL_POSITION:
|
||||
return false;
|
||||
case AXPositionKind::TREE_POSITION:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
case AXPositionKind::TEXT_POSITION: {
|
||||
// 1. The current leaf text position must be at the end of an anchor, or
|
||||
// before a '\n' character if white space is preserved (e.g. when using
|
||||
@ -1209,8 +1198,7 @@ class AXPosition {
|
||||
case AXPositionKind::NULL_POSITION:
|
||||
return false;
|
||||
case AXPositionKind::TREE_POSITION:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
case AXPositionKind::TEXT_POSITION: {
|
||||
if (text_position->AtStartOfAnchor()) {
|
||||
AXPositionInstance previous_position =
|
||||
@ -1255,8 +1243,7 @@ class AXPosition {
|
||||
case AXPositionKind::NULL_POSITION:
|
||||
return false;
|
||||
case AXPositionKind::TREE_POSITION:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
case AXPositionKind::TEXT_POSITION: {
|
||||
if (!text_position->AtStartOfAnchor())
|
||||
return false;
|
||||
@ -1283,8 +1270,7 @@ class AXPosition {
|
||||
case AXPositionKind::NULL_POSITION:
|
||||
return false;
|
||||
case AXPositionKind::TREE_POSITION:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
case AXPositionKind::TEXT_POSITION: {
|
||||
if (!text_position->AtEndOfAnchor())
|
||||
return false;
|
||||
@ -2002,14 +1988,12 @@ class AXPosition {
|
||||
AXPositionInstance resulting_position = CreateNullPosition();
|
||||
switch (boundary) {
|
||||
case ax::mojom::TextBoundary::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
|
||||
case ax::mojom::TextBoundary::kCharacter:
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
resulting_position = CreatePreviousCharacterPosition(options);
|
||||
break;
|
||||
@ -2022,8 +2006,7 @@ class AXPosition {
|
||||
case ax::mojom::TextBoundary::kFormatEnd:
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
resulting_position = CreatePreviousFormatEndPosition(options);
|
||||
break;
|
||||
@ -2036,8 +2019,7 @@ class AXPosition {
|
||||
case ax::mojom::TextBoundary::kFormatStart:
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
resulting_position = CreatePreviousFormatStartPosition(options);
|
||||
break;
|
||||
@ -2050,8 +2032,7 @@ class AXPosition {
|
||||
case ax::mojom::TextBoundary::kFormatStartOrEnd:
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
resulting_position = CreatePreviousFormatStartPosition(options);
|
||||
break;
|
||||
@ -2064,8 +2045,7 @@ class AXPosition {
|
||||
case ax::mojom::TextBoundary::kLineEnd:
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
resulting_position = CreatePreviousLineEndPosition(options);
|
||||
break;
|
||||
@ -2078,8 +2058,7 @@ class AXPosition {
|
||||
case ax::mojom::TextBoundary::kLineStart:
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
resulting_position = CreatePreviousLineStartPosition(options);
|
||||
break;
|
||||
@ -2092,8 +2071,7 @@ class AXPosition {
|
||||
case ax::mojom::TextBoundary::kLineStartOrEnd:
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
resulting_position = CreatePreviousLineStartPosition(options);
|
||||
break;
|
||||
@ -2106,8 +2084,7 @@ class AXPosition {
|
||||
case ax::mojom::TextBoundary::kObject:
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
resulting_position = CreatePositionAtStartOfAnchor();
|
||||
break;
|
||||
@ -2120,8 +2097,7 @@ class AXPosition {
|
||||
case ax::mojom::TextBoundary::kPageEnd:
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
resulting_position = CreatePreviousPageEndPosition(options);
|
||||
break;
|
||||
@ -2134,8 +2110,7 @@ class AXPosition {
|
||||
case ax::mojom::TextBoundary::kPageStart:
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
resulting_position = CreatePreviousPageStartPosition(options);
|
||||
break;
|
||||
@ -2148,8 +2123,7 @@ class AXPosition {
|
||||
case ax::mojom::TextBoundary::kPageStartOrEnd:
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
resulting_position = CreatePreviousPageStartPosition(options);
|
||||
break;
|
||||
@ -2162,8 +2136,7 @@ class AXPosition {
|
||||
case ax::mojom::TextBoundary::kParagraphEnd:
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
resulting_position = CreatePreviousParagraphEndPosition(options);
|
||||
break;
|
||||
@ -2176,8 +2149,7 @@ class AXPosition {
|
||||
case ax::mojom::TextBoundary::kParagraphStart:
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
resulting_position = CreatePreviousParagraphStartPosition(options);
|
||||
break;
|
||||
@ -2195,8 +2167,7 @@ class AXPosition {
|
||||
case ax::mojom::TextBoundary::kParagraphStartSkippingEmptyParagraphs:
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
resulting_position =
|
||||
CreatePreviousParagraphStartPositionSkippingEmptyParagraphs(
|
||||
@ -2213,8 +2184,7 @@ class AXPosition {
|
||||
case ax::mojom::TextBoundary::kParagraphStartOrEnd:
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
resulting_position = CreatePreviousParagraphStartPosition(options);
|
||||
break;
|
||||
@ -2227,8 +2197,7 @@ class AXPosition {
|
||||
case ax::mojom::TextBoundary::kSentenceEnd:
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
resulting_position = CreatePreviousSentenceEndPosition(options);
|
||||
break;
|
||||
@ -2241,8 +2210,7 @@ class AXPosition {
|
||||
case ax::mojom::TextBoundary::kSentenceStart:
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
resulting_position = CreatePreviousSentenceStartPosition(options);
|
||||
break;
|
||||
@ -2255,8 +2223,7 @@ class AXPosition {
|
||||
case ax::mojom::TextBoundary::kSentenceStartOrEnd:
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
resulting_position = CreatePreviousSentenceStartPosition(options);
|
||||
break;
|
||||
@ -2272,8 +2239,7 @@ class AXPosition {
|
||||
"disallowed from crossing boundaries.";
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
resulting_position = CreatePositionAtStartOfContent();
|
||||
break;
|
||||
@ -2286,8 +2252,7 @@ class AXPosition {
|
||||
case ax::mojom::TextBoundary::kWordEnd:
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
resulting_position = CreatePreviousWordEndPosition(options);
|
||||
break;
|
||||
@ -2300,8 +2265,7 @@ class AXPosition {
|
||||
case ax::mojom::TextBoundary::kWordStart:
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
resulting_position = CreatePreviousWordStartPosition(options);
|
||||
break;
|
||||
@ -2314,8 +2278,7 @@ class AXPosition {
|
||||
case ax::mojom::TextBoundary::kWordStartOrEnd:
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
resulting_position = CreatePreviousWordStartPosition(options);
|
||||
break;
|
||||
@ -2451,8 +2414,7 @@ class AXPosition {
|
||||
|
||||
switch (kind_) {
|
||||
case AXPositionKind::NULL_POSITION:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return CreateNullPosition();
|
||||
NOTREACHED();
|
||||
case AXPositionKind::TREE_POSITION:
|
||||
return CreateTreePositionAtStartOfAnchor(*child_anchor);
|
||||
case AXPositionKind::TEXT_POSITION:
|
||||
@ -2501,8 +2463,7 @@ class AXPosition {
|
||||
|
||||
switch (kind_) {
|
||||
case AXPositionKind::NULL_POSITION:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return CreateNullPosition();
|
||||
NOTREACHED();
|
||||
|
||||
case AXPositionKind::TREE_POSITION: {
|
||||
if (IsLeafNodeForTreePosition(*parent_anchor)) {
|
||||
@ -2529,8 +2490,7 @@ class AXPosition {
|
||||
|
||||
switch (move_direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return CreateNullPosition();
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
// "move_direction" is only important when this position is an
|
||||
// "embedded object in parent", i.e., when this position's anchor is
|
||||
@ -2636,8 +2596,7 @@ class AXPosition {
|
||||
// of motion, and also reset the affinity.
|
||||
switch (move_direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return CreateNullPosition();
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
// Keep the offset to be right before the embedded object
|
||||
// character.
|
||||
@ -3498,8 +3457,7 @@ class AXPosition {
|
||||
AXPositionInstance next_position;
|
||||
switch (move_direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return CreateNullPosition();
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
if (text_position->AtStartOfAnchor()) {
|
||||
next_position = text_position->CreatePreviousLeafTextPosition(
|
||||
@ -3521,8 +3479,7 @@ class AXPosition {
|
||||
AXBoundaryBehavior::kStopAtAnchorBoundary) {
|
||||
switch (move_direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return CreateNullPosition();
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
return CreatePositionAtStartOfAnchor()->AsUnignoredPosition(
|
||||
AXPositionAdjustmentBehavior::kMoveBackward);
|
||||
@ -3538,8 +3495,7 @@ class AXPosition {
|
||||
// this loop we'll try to do some adjustments to text_position.
|
||||
switch (move_direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return CreateNullPosition();
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
text_position = text_position->CreatePositionAtStartOfAnchor();
|
||||
break;
|
||||
@ -3573,8 +3529,7 @@ class AXPosition {
|
||||
AXBoundaryBehavior::kStopAtAnchorBoundary) {
|
||||
switch (move_direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return CreateNullPosition();
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
text_position = CreatePositionAtStartOfAnchor()->AsUnignoredPosition(
|
||||
AXPositionAdjustmentBehavior::kMoveBackward);
|
||||
@ -3662,8 +3617,7 @@ class AXPosition {
|
||||
AXPositionInstance next_position;
|
||||
switch (move_direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return CreateNullPosition();
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
next_position =
|
||||
text_position
|
||||
@ -3688,8 +3642,7 @@ class AXPosition {
|
||||
AXBoundaryBehavior::kStopAtAnchorBoundary) {
|
||||
switch (move_direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return CreateNullPosition();
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
return CreatePositionAtStartOfAnchor()->AsUnignoredPosition(
|
||||
AXPositionAdjustmentBehavior::kMoveBackward);
|
||||
@ -3705,8 +3658,7 @@ class AXPosition {
|
||||
// this loop we'll try to do some adjustments to text_position.
|
||||
switch (move_direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return CreateNullPosition();
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
text_position = text_position->CreatePositionAtStartOfAnchor();
|
||||
break;
|
||||
@ -3740,8 +3692,7 @@ class AXPosition {
|
||||
AXBoundaryBehavior::kStopAtAnchorBoundary) {
|
||||
switch (move_direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return CreateNullPosition();
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
return CreatePositionAtStartOfAnchor()->AsUnignoredPosition(
|
||||
AXPositionAdjustmentBehavior::kMoveBackward);
|
||||
@ -5410,8 +5361,7 @@ class AXPosition {
|
||||
return preceding_block || preceding_line_break;
|
||||
}
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
}
|
||||
}
|
||||
|
||||
@ -5542,8 +5492,7 @@ class AXPosition {
|
||||
(move_type == AXMoveType::kAncestor ||
|
||||
move_type == AXMoveType::kSibling);
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
static const std::vector<int32_t>& GetSentenceStartOffsetsFunc(
|
||||
@ -5667,8 +5616,7 @@ class AXPosition {
|
||||
|
||||
switch (move_direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return CreateNullPosition();
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward: {
|
||||
auto offsets_iterator =
|
||||
std::lower_bound(boundary_offsets.begin(), boundary_offsets.end(),
|
||||
@ -5721,8 +5669,7 @@ class AXPosition {
|
||||
get_offsets.Run(text_position);
|
||||
switch (move_direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return CreateNullPosition();
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
if (boundary_offsets.empty()) {
|
||||
return text_position->CreatePositionAtStartOfAnchor();
|
||||
@ -5780,8 +5727,7 @@ class AXPosition {
|
||||
|
||||
switch (move_direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return CreateNullPosition();
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward:
|
||||
// If we are at a text offset greater than 0, we will simply decrease
|
||||
// the offset by one; otherwise, we will create a position at the end of
|
||||
|
@ -37,8 +37,7 @@ base::i18n::BreakIterator::BreakType ICUBreakTypeForBoundaryType(
|
||||
case ax::mojom::TextBoundary::kParagraphStart:
|
||||
return base::i18n::BreakIterator::BREAK_NEWLINE;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION() << boundary;
|
||||
return base::i18n::BreakIterator::BREAK_NEWLINE;
|
||||
NOTREACHED() << boundary;
|
||||
}
|
||||
}
|
||||
|
||||
@ -111,8 +110,7 @@ size_t FindAccessibleTextBoundary(const std::u16string& text,
|
||||
|
||||
switch (boundary) {
|
||||
case ax::mojom::TextBoundary::kLineStart:
|
||||
NOTREACHED_IN_MIGRATION() << boundary; // This is handled above.
|
||||
return result;
|
||||
NOTREACHED() << boundary; // This is handled above.
|
||||
case ax::mojom::TextBoundary::kCharacter:
|
||||
if (break_iter.IsGraphemeBoundary(result)) {
|
||||
// If we are searching forward and we are still at the start offset,
|
||||
|
@ -41,8 +41,7 @@ AXTreeManagerBase::AXTreeManagerBase(std::unique_ptr<AXTree> tree) {
|
||||
|
||||
const AXTreeID& tree_id = tree->GetAXTreeID();
|
||||
if (tree_id.type() == ax::mojom::AXTreeIDType::kUnknown) {
|
||||
NOTREACHED_IN_MIGRATION() << "Invalid tree ID.\n" << tree->ToString();
|
||||
return;
|
||||
NOTREACHED() << "Invalid tree ID.\n" << tree->ToString();
|
||||
}
|
||||
|
||||
tree_ = std::move(tree);
|
||||
@ -94,14 +93,12 @@ AXTree* AXTreeManagerBase::GetTree() const {
|
||||
std::unique_ptr<AXTree> AXTreeManagerBase::SetTree(
|
||||
std::unique_ptr<AXTree> tree) {
|
||||
if (!tree) {
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
NOTREACHED()
|
||||
<< "Attempting to set a new tree, but no tree has been provided.";
|
||||
return {};
|
||||
}
|
||||
|
||||
if (tree->GetAXTreeID().type() == ax::mojom::AXTreeIDType::kUnknown) {
|
||||
NOTREACHED_IN_MIGRATION() << "Invalid tree ID.\n" << tree->ToString();
|
||||
return {};
|
||||
NOTREACHED() << "Invalid tree ID.\n" << tree->ToString();
|
||||
}
|
||||
|
||||
if (tree_) {
|
||||
|
@ -21,8 +21,7 @@ bool UnionTraits<ax::mojom::AXTreeIDDataView, ui::AXTreeID>::Read(
|
||||
return true;
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
} // namespace mojo
|
||||
|
@ -27,8 +27,9 @@ class AtkUtilAuraLinuxTest : public AXPlatformNodeTest {
|
||||
|
||||
TestAXNodeWrapper* wrapper =
|
||||
TestAXNodeWrapper::GetOrCreate(GetTree(), GetRoot());
|
||||
if (!wrapper)
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
if (!wrapper) {
|
||||
NOTREACHED();
|
||||
}
|
||||
AXPlatformNodeAuraLinux::SetApplication(wrapper->ax_platform_node());
|
||||
|
||||
AtkUtilAuraLinux::GetInstance()->InitializeForTesting();
|
||||
@ -42,8 +43,9 @@ class AtkUtilAuraLinuxTest : public AXPlatformNodeTest {
|
||||
void TearDown() override {
|
||||
TestAXNodeWrapper* wrapper =
|
||||
TestAXNodeWrapper::GetOrCreate(GetTree(), GetRoot());
|
||||
if (!wrapper)
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
if (!wrapper) {
|
||||
NOTREACHED();
|
||||
}
|
||||
g_object_unref(wrapper->ax_platform_node()->GetNativeViewAccessible());
|
||||
|
||||
AXPlatformNodeTest::TearDown();
|
||||
|
@ -87,8 +87,7 @@ bool ShouldIgnoreAXEventForAutomation(ax::mojom::Event event_type) {
|
||||
return false;
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
bool ShouldIgnoreGeneratedEventForAutomation(
|
||||
@ -181,8 +180,7 @@ bool ShouldIgnoreGeneratedEventForAutomation(
|
||||
return true;
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
std::tuple<ax::mojom::Event, AXEventGenerator::Event>
|
||||
|
@ -29,8 +29,7 @@ AutomationPosition::AutomationPosition(const AXNode& node,
|
||||
position_->SnapToMaxTextOffsetIfBeyond();
|
||||
break;
|
||||
case AXPositionKind::NULL_POSITION:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1168,8 +1168,7 @@ void AutomationV8Bindings::AddV8Routes() {
|
||||
node->GetStringListAttribute(
|
||||
ax::mojom::StringListAttribute::kCustomActionDescriptions);
|
||||
if (custom_action_ids.size() != custom_action_descriptions.size()) {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
v8::Local<v8::Context> context = isolate->GetCurrentContext();
|
||||
|
@ -4385,8 +4385,7 @@ bool AXPlatformNodeAuraLinux::
|
||||
return child->GrabFocusOrSetSequentialFocusNavigationStartingPoint();
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
const gchar* AXPlatformNodeAuraLinux::GetDefaultActionName() {
|
||||
@ -4805,8 +4804,7 @@ int AXPlatformNodeAuraLinux::FindStartOfStyle(
|
||||
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return start_offset;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward: {
|
||||
auto iterator = offset_to_text_attributes_.upper_bound(start_offset);
|
||||
--iterator;
|
||||
@ -4821,8 +4819,7 @@ int AXPlatformNodeAuraLinux::FindStartOfStyle(
|
||||
}
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return start_offset;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
const TextAttributeList& AXPlatformNodeAuraLinux::GetTextAttributes(
|
||||
|
@ -1513,7 +1513,7 @@ void AXPlatformNodeBase::ComputeAttributes(PlatformAttributeList* attributes) {
|
||||
// aria-dropeffect is deprecated in WAI-ARIA 1.1.
|
||||
if (delegate_->HasIntAttribute(
|
||||
ax::mojom::IntAttribute::kDropeffectDeprecated)) {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
// Expose class attribute.
|
||||
|
@ -1568,8 +1568,7 @@ const ui::CocoaActionList& GetCocoaActionListForTesting() {
|
||||
|
||||
switch (static_cast<ax::mojom::AriaCurrentState>(ariaCurrent)) {
|
||||
case ax::mojom::AriaCurrentState::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return @"false";
|
||||
NOTREACHED();
|
||||
case ax::mojom::AriaCurrentState::kFalse:
|
||||
return @"false";
|
||||
case ax::mojom::AriaCurrentState::kTrue:
|
||||
@ -1586,8 +1585,7 @@ const ui::CocoaActionList& GetCocoaActionListForTesting() {
|
||||
return @"time";
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return @"false";
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
- (NSNumber*)AXARIAColumnCount {
|
||||
|
@ -141,8 +141,7 @@ AXNodePosition::AXPositionInstance AXPlatformNodeDelegate::CreateTextPositionAt(
|
||||
}
|
||||
|
||||
gfx::NativeViewAccessible AXPlatformNodeDelegate::GetNSWindow() {
|
||||
NOTREACHED_IN_MIGRATION() << "Only available on macOS.";
|
||||
return nullptr;
|
||||
NOTREACHED() << "Only available on macOS.";
|
||||
}
|
||||
|
||||
gfx::NativeViewAccessible AXPlatformNodeDelegate::GetNativeViewAccessible() {
|
||||
@ -151,8 +150,7 @@ gfx::NativeViewAccessible AXPlatformNodeDelegate::GetNativeViewAccessible() {
|
||||
// overridden this method. On all other platforms, this method should not be
|
||||
// called yet. In the future, when all subclasses have moved over to be
|
||||
// implemented by AXPlatformNode, we may make this method completely virtual.
|
||||
NOTREACHED_IN_MIGRATION() << "https://crbug.com/703369";
|
||||
return nullptr;
|
||||
NOTREACHED() << "https://crbug.com/703369";
|
||||
}
|
||||
|
||||
gfx::NativeViewAccessible AXPlatformNodeDelegate::GetParent() const {
|
||||
|
@ -170,7 +170,7 @@ bool IsNameExposedInAXValueForRole(ax::mojom::Role role) {
|
||||
void AXPlatformNodeMac::AddAttributeToList(const char* name,
|
||||
const char* value,
|
||||
PlatformAttributeList* attributes) {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
} // namespace ui
|
||||
|
@ -174,7 +174,7 @@ void MutateTextRangeProvider(ComPtr<ITextRangeProvider>& text_range,
|
||||
&units_moved);
|
||||
return;
|
||||
case TextRangeMutation::kLast:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
NOTREACHED();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -5044,8 +5044,7 @@ IFACEMETHODIMP AXPlatformNodeWin::Navigate(
|
||||
break;
|
||||
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
if (neighbor) {
|
||||
@ -5481,9 +5480,8 @@ HRESULT AXPlatformNodeWin::GetPropertyValueImpl(PROPERTYID property_id,
|
||||
if (SupportsOrientation(GetRole())) {
|
||||
if (HasState(ax::mojom::State::kHorizontal) &&
|
||||
HasState(ax::mojom::State::kVertical)) {
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "An accessibility object cannot have a horizontal "
|
||||
"and a vertical orientation at the same time.";
|
||||
NOTREACHED() << "An accessibility object cannot have a horizontal "
|
||||
"and a vertical orientation at the same time.";
|
||||
}
|
||||
if (HasState(ax::mojom::State::kHorizontal)) {
|
||||
result->vt = VT_I4;
|
||||
@ -7240,7 +7238,7 @@ std::wstring AXPlatformNodeWin::ComputeUIAProperties() {
|
||||
properties.emplace_back(L"pressed=mixed");
|
||||
} else if (GetRole() == ax::mojom::Role::kSwitch) {
|
||||
// This is disallowed both by the ARIA standard and by Blink.
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
NOTREACHED();
|
||||
} else {
|
||||
properties.emplace_back(L"checked=mixed");
|
||||
}
|
||||
@ -7262,7 +7260,7 @@ std::wstring AXPlatformNodeWin::ComputeUIAProperties() {
|
||||
|
||||
// aria-dropeffect is deprecated in WAI-ARIA 1.1.
|
||||
if (HasIntAttribute(ax::mojom::IntAttribute::kDropeffectDeprecated)) {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
NOTREACHED();
|
||||
}
|
||||
StateToUIAAriaProperty(properties, ax::mojom::State::kExpanded, "expanded");
|
||||
|
||||
@ -8407,8 +8405,7 @@ AXPlatformNodeWin* AXPlatformNodeWin::GetLowestAccessibleElementForUIA() {
|
||||
node = node->GetParentPlatformNodeWin();
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return nullptr;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
AXPlatformNodeWin* AXPlatformNodeWin::GetFirstTextOnlyDescendant() {
|
||||
|
@ -42,7 +42,6 @@ namespace ui {
|
||||
|
||||
#if DCHECK_IS_ON()
|
||||
static int browser_accessibility_count = 0;
|
||||
static bool has_dumped_possible_leak = false;
|
||||
// If there are more than 10 million objects alive at once, dump.
|
||||
// It is likely to be a leak if we have > 100 tabs x 10000 objects.
|
||||
constexpr int kDumpBrowserAccessibilityLeakNumObjects = 10000000;
|
||||
@ -75,10 +74,9 @@ BrowserAccessibility::BrowserAccessibility(BrowserAccessibilityManager* manager,
|
||||
DCHECK(node);
|
||||
DCHECK(node->IsDataValid());
|
||||
#if DCHECK_IS_ON()
|
||||
if (++browser_accessibility_count > kDumpBrowserAccessibilityLeakNumObjects &&
|
||||
!has_dumped_possible_leak) {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
has_dumped_possible_leak = true;
|
||||
if (++browser_accessibility_count > kDumpBrowserAccessibilityLeakNumObjects) {
|
||||
// Possible leak.
|
||||
NOTREACHED();
|
||||
}
|
||||
#endif
|
||||
}
|
||||
@ -912,8 +910,7 @@ BrowserAccessibility::GetUIADirectChildrenInRange(AXPlatformNodeDelegate* start,
|
||||
AXPlatformNodeDelegate* end) {
|
||||
// This method is only called on Windows. Other platforms should not call it.
|
||||
// The BrowserAccessibilityWin subclass overrides this method.
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return {};
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
//
|
||||
@ -1957,8 +1954,7 @@ void BrowserAccessibility::MergeSpellingAndGrammarIntoTextAttributes(
|
||||
int start_offset,
|
||||
TextAttributeMap* text_attributes) {
|
||||
if (!text_attributes) {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
TextAttributeList prev_attributes;
|
||||
|
@ -1357,10 +1357,8 @@ bool ui::IsNSRange(id value) {
|
||||
case ax::mojom::SortDirection::kOther:
|
||||
return NSAccessibilityUnknownSortDirectionValue;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
return nil;
|
||||
}
|
||||
|
||||
// Returns a text marker that points to the first character in the document that
|
||||
|
@ -1751,8 +1751,7 @@ LONG BrowserAccessibilityComWin::FindStartOfStyle(
|
||||
|
||||
switch (direction) {
|
||||
case ax::mojom::MoveDirection::kNone:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return start_offset;
|
||||
NOTREACHED();
|
||||
case ax::mojom::MoveDirection::kBackward: {
|
||||
if (offset_to_text_attributes().empty())
|
||||
return 0;
|
||||
@ -1770,8 +1769,7 @@ LONG BrowserAccessibilityComWin::FindStartOfStyle(
|
||||
}
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return start_offset;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
BrowserAccessibilityComWin* BrowserAccessibilityComWin::GetFromID(
|
||||
|
@ -61,10 +61,8 @@ void BrowserAccessibilityMac::ReplaceNativeObject() {
|
||||
// could have never called this method without a platform node having been
|
||||
// created.
|
||||
if (!platform_node_) {
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "No platform node exists, so there should not be any "
|
||||
"native wrapper to replace.";
|
||||
return;
|
||||
NOTREACHED() << "No platform node exists, so there should not be any "
|
||||
"native wrapper to replace.";
|
||||
}
|
||||
|
||||
// We need to keep the old native wrapper alive until we set up the new one
|
||||
@ -75,9 +73,7 @@ void BrowserAccessibilityMac::ReplaceNativeObject() {
|
||||
// We should have never called this method if a native wrapper has not been
|
||||
// created, but keep a null check just in case.
|
||||
if (!old_native_obj) {
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "No native wrapper exists, so there is nothing to replace.";
|
||||
return;
|
||||
NOTREACHED() << "No native wrapper exists, so there is nothing to replace.";
|
||||
}
|
||||
|
||||
// Replace child in parent.
|
||||
|
@ -1027,8 +1027,7 @@ void BrowserAccessibilityManager::Scroll(const BrowserAccessibility& node,
|
||||
case ax::mojom::Action::kScrollRight:
|
||||
break;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "Cannot call Scroll with action=" << scroll_action;
|
||||
NOTREACHED() << "Cannot call Scroll with action=" << scroll_action;
|
||||
}
|
||||
AXActionData action_data;
|
||||
action_data.action = scroll_action;
|
||||
@ -1967,8 +1966,7 @@ BrowserAccessibilityManager::RetargetBrowserAccessibilityForEvents(
|
||||
// ClusterFuzz was able to come up with a reliably-reproducible test case
|
||||
// which can be seen in https://crbug.com/1362230. This needs to be
|
||||
// investigated further.
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return nullptr;
|
||||
NOTREACHED();
|
||||
}
|
||||
return GetFromAXNode(RetargetForEvents(node->node(), event_type));
|
||||
}
|
||||
|
@ -106,9 +106,8 @@ NSArray* AXElementWrapper::Children() const {
|
||||
return nil;
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
NOTREACHED()
|
||||
<< "Only AXUIElementRef and BrowserAccessibilityCocoa are supported.";
|
||||
return nil;
|
||||
}
|
||||
|
||||
NSSize AXElementWrapper::Size() const {
|
||||
@ -117,9 +116,8 @@ NSSize AXElementWrapper::Size() const {
|
||||
}
|
||||
|
||||
if (!IsAXUIElement()) {
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
NOTREACHED()
|
||||
<< "Only AXUIElementRef and BrowserAccessibilityCocoa are supported.";
|
||||
return NSMakeSize(0, 0);
|
||||
}
|
||||
|
||||
id value = *GetAttributeValue(NSAccessibilitySizeAttribute);
|
||||
@ -154,9 +152,8 @@ NSPoint AXElementWrapper::Position() const {
|
||||
return NSMakePoint(0, 0);
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
NOTREACHED()
|
||||
<< "Only AXUIElementRef and BrowserAccessibilityCocoa are supported.";
|
||||
return NSMakePoint(0, 0);
|
||||
}
|
||||
|
||||
NSArray* AXElementWrapper::AttributeNames() const {
|
||||
@ -181,9 +178,8 @@ NSArray* AXElementWrapper::AttributeNames() const {
|
||||
return nil;
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
NOTREACHED()
|
||||
<< "Only AXUIElementRef and BrowserAccessibilityCocoa are supported.";
|
||||
return nil;
|
||||
}
|
||||
|
||||
NSArray* AXElementWrapper::ParameterizedAttributeNames() const {
|
||||
@ -201,9 +197,8 @@ NSArray* AXElementWrapper::ParameterizedAttributeNames() const {
|
||||
return nil;
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
NOTREACHED()
|
||||
<< "Only AXUIElementRef and BrowserAccessibilityCocoa are supported.";
|
||||
return nil;
|
||||
}
|
||||
|
||||
AXOptionalNSObject AXElementWrapper::GetAttributeValue(
|
||||
@ -299,7 +294,7 @@ void AXElementWrapper::SetAttributeValue(NSString* attribute, id value) const {
|
||||
return;
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
NOTREACHED()
|
||||
<< "Only AXUIElementRef and BrowserAccessibilityCocoa are supported.";
|
||||
}
|
||||
|
||||
@ -317,9 +312,8 @@ NSArray* AXElementWrapper::ActionNames() const {
|
||||
return nil;
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
NOTREACHED()
|
||||
<< "Only AXUIElementRef and BrowserAccessibilityCocoa are supported.";
|
||||
return nil;
|
||||
}
|
||||
|
||||
void AXElementWrapper::PerformAction(NSString* action) const {
|
||||
@ -334,7 +328,7 @@ void AXElementWrapper::PerformAction(NSString* action) const {
|
||||
return;
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
NOTREACHED()
|
||||
<< "Only AXUIElementRef and BrowserAccessibilityCocoa are supported.";
|
||||
}
|
||||
|
||||
|
@ -175,8 +175,7 @@ void AXInspectScenario::ProcessDirective(Directive directive,
|
||||
break;
|
||||
}
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION() << "Unrecognized " << directive << " directive";
|
||||
break;
|
||||
NOTREACHED() << "Unrecognized " << directive << " directive";
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -77,9 +77,8 @@ std::string AXTreeFormatterBase::FormatTree(
|
||||
}
|
||||
|
||||
base::Value::Dict AXTreeFormatterBase::BuildTreeForNode(AXNode* root) const {
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
NOTREACHED()
|
||||
<< "Only supported when called on AccessibilityTreeFormatterBlink.";
|
||||
return base::Value::Dict();
|
||||
}
|
||||
|
||||
std::string AXTreeFormatterBase::EvaluateScript(
|
||||
@ -94,8 +93,7 @@ std::string AXTreeFormatterBase::EvaluateScript(
|
||||
const std::vector<AXScriptInstruction>& instructions,
|
||||
size_t start_index,
|
||||
size_t end_index) const {
|
||||
NOTREACHED_IN_MIGRATION() << "Not implemented";
|
||||
return {};
|
||||
NOTREACHED() << "Not implemented";
|
||||
}
|
||||
|
||||
void AXTreeFormatterBase::RecursiveFormatTree(const base::Value::Dict& dict,
|
||||
@ -165,9 +163,8 @@ void AXTreeFormatterBase::set_show_ids(bool show_ids) {
|
||||
std::string AXTreeFormatterBase::DumpInternalAccessibilityTree(
|
||||
AXTreeID tree_id,
|
||||
const std::vector<AXPropertyFilter>& property_filters) {
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
NOTREACHED()
|
||||
<< "Only supported when called on AccessibilityTreeFormatterBlink.";
|
||||
return std::string("");
|
||||
}
|
||||
|
||||
std::vector<AXPropertyNode> AXTreeFormatterBase::PropertyFilterNodesFor(
|
||||
|
@ -1288,8 +1288,7 @@ void AXTreeFormatterUia::ProcessValueForOutput(const std::string& name,
|
||||
break;
|
||||
}
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -850,8 +850,7 @@ std::u16string TestAXNodeWrapper::GetLocalizedStringForImageAnnotationStatus(
|
||||
return std::u16string();
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return std::u16string();
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
std::u16string TestAXNodeWrapper::GetStyleNameAttributeAsLocalizedString()
|
||||
|
@ -68,8 +68,7 @@ bool StringToBool(const std::string& s) {
|
||||
}
|
||||
|
||||
// TODO: Specify which node this error was found at.
|
||||
NOTREACHED_IN_MIGRATION() << "Invalid value passed to StringToBool: " << s;
|
||||
return false;
|
||||
NOTREACHED() << "Invalid value passed to StringToBool: " << s;
|
||||
}
|
||||
|
||||
void ParseAndAddNodeProperties(
|
||||
@ -153,7 +152,7 @@ void ParseAndAddNodeProperties(
|
||||
|
||||
} else {
|
||||
// TODO: Will extend to more properties here.
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
NOTREACHED()
|
||||
<< "Either an invalid property was specified, or this function does "
|
||||
"not currently support the specified property.";
|
||||
}
|
||||
|
@ -47,8 +47,7 @@ int TreeGenerator::IgnoredPermutationCountPerUniqueTree(int tree_index) const {
|
||||
unique_tree_count_so_far += unique_tree_count;
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return 0;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
void TreeGenerator::BuildUniqueTreeWithIgnoredNodes(
|
||||
|
@ -513,7 +513,7 @@ void DelegatedFrameHostAndroid::CancelSuccessfulPresentationTimeRequest() {
|
||||
|
||||
void DelegatedFrameHostAndroid::OnFirstSurfaceActivation(
|
||||
const viz::SurfaceInfo& surface_info) {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
void DelegatedFrameHostAndroid::OnFrameTokenChanged(
|
||||
|
@ -72,8 +72,7 @@ gfx::Transform ComputeTransform(EdgeEffect::Edge edge,
|
||||
viewport_size.height() / 2.f) *
|
||||
gfx::Transform::Make90degRotation();
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION() << "Invalid edge: " << edge;
|
||||
return gfx::Transform();
|
||||
NOTREACHED() << "Invalid edge: " << edge;
|
||||
};
|
||||
}
|
||||
|
||||
@ -90,8 +89,7 @@ gfx::SizeF ComputeOrientedSize(EdgeEffect::Edge edge,
|
||||
case EdgeEffect::EDGE_RIGHT:
|
||||
return gfx::SizeF(viewport_size.height(), viewport_size.width());
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION() << "Invalid edge: " << edge;
|
||||
return gfx::SizeF();
|
||||
NOTREACHED() << "Invalid edge: " << edge;
|
||||
};
|
||||
}
|
||||
|
||||
|
@ -59,9 +59,8 @@ const SkBitmap& HandleViewResources::GetBitmap(
|
||||
case ui::TouchHandleOrientation::CENTER:
|
||||
return center_bitmap_;
|
||||
case ui::TouchHandleOrientation::UNDEFINED:
|
||||
NOTREACHED_IN_MIGRATION() << "Invalid touch handle orientation.";
|
||||
NOTREACHED() << "Invalid touch handle orientation.";
|
||||
};
|
||||
return center_bitmap_;
|
||||
}
|
||||
|
||||
float HandleViewResources::GetDrawableHorizontalPaddingRatio() const {
|
||||
|
@ -147,9 +147,7 @@ bool OverscrollRefresh::WillHandleScrollUpdate(
|
||||
return true;
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "Invalid overscroll state: " << scroll_consumption_state_;
|
||||
return false;
|
||||
NOTREACHED() << "Invalid overscroll state: " << scroll_consumption_state_;
|
||||
}
|
||||
|
||||
void OverscrollRefresh::ReleaseWithoutActivation() {
|
||||
|
@ -293,8 +293,7 @@ std::unique_ptr<ui::EventTargetIterator> Env::GetChildIterator() const {
|
||||
}
|
||||
|
||||
ui::EventTargeter* Env::GetEventTargeter() {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return nullptr;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
} // namespace aura
|
||||
|
@ -63,8 +63,7 @@ void EnvInputStateController::UpdateStateForTouchEvent(
|
||||
break;
|
||||
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
}
|
||||
const gfx::Point& location_in_root = event.root_location();
|
||||
const auto* root_window = window->GetRootWindow();
|
||||
|
@ -292,7 +292,7 @@ class GestureEventConsumeDelegate : public TestWindowDelegate {
|
||||
// Only used in unified gesture detection.
|
||||
break;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
NOTREACHED();
|
||||
}
|
||||
if (wait_until_event_ == gesture->type() && run_loop_) {
|
||||
run_loop_->Quit();
|
||||
@ -473,7 +473,7 @@ class GestureEventSynthDelegate : public TestWindowDelegate {
|
||||
mouse_exit_ = true;
|
||||
break;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
NOTREACHED();
|
||||
}
|
||||
event->SetHandled();
|
||||
}
|
||||
|
@ -94,9 +94,7 @@ void NativeWindowOcclusionTrackerWin::DeleteInstanceForTesting() {
|
||||
void NativeWindowOcclusionTrackerWin::Enable(Window* window) {
|
||||
DCHECK(window->IsRootWindow());
|
||||
if (window->HasObserver(this)) {
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "window shouldn't already be observing occlusion tracker";
|
||||
return;
|
||||
NOTREACHED() << "window shouldn't already be observing occlusion tracker";
|
||||
}
|
||||
// Add this as an observer so that we can be notified
|
||||
// when it's no longer true that all windows are minimized, and when the
|
||||
|
@ -19,8 +19,7 @@ ui::EventTarget* NullWindowTargeter::FindTargetForEvent(ui::EventTarget* root,
|
||||
ui::EventTarget* NullWindowTargeter::FindNextBestTarget(
|
||||
ui::EventTarget* previous_target,
|
||||
ui::Event* event) {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return nullptr;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
} // namespace aura
|
||||
|
@ -28,7 +28,7 @@ ScreenOzone::ScreenOzone() {
|
||||
// that call into `Screen` functions below have a valid `platform_screen_`.
|
||||
platform->InitScreen(platform_screen_.get());
|
||||
} else {
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
NOTREACHED()
|
||||
<< "PlatformScreen is not implemented for this ozone platform.";
|
||||
}
|
||||
}
|
||||
|
@ -193,8 +193,7 @@ bool UIControlsOzone::SendMouseEventsNotifyWhenDone(
|
||||
changed_button_flag = ui::EF_RIGHT_MOUSE_BUTTON;
|
||||
break;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
// Process the accelerator key state.
|
||||
|
@ -794,7 +794,7 @@ Window* Window::GetEventHandlerForPoint(const gfx::Point& local_point) {
|
||||
return match;
|
||||
break;
|
||||
case EventTargetingPolicy::kNone:
|
||||
NOTREACHED_IN_MIGRATION(); // This case is handled early on.
|
||||
NOTREACHED(); // This case is handled early on.
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -797,7 +797,7 @@ ui::EventDispatchDetails WindowEventDispatcher::DispatchHeldEvents() {
|
||||
dispatch_details = OnEventFromSource(event.get());
|
||||
} else {
|
||||
// TODO(rbyers): GESTURE_TAP_DOWN not yet supported: crbug.com/170987.
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
NOTREACHED();
|
||||
}
|
||||
if (dispatch_details.dispatcher_destroyed)
|
||||
return dispatch_details;
|
||||
|
@ -714,11 +714,9 @@ std::string EventTypeToString(ui::EventType type) {
|
||||
|
||||
default:
|
||||
// We should explicitly require each event type.
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "Received unexpected event: " << base::to_underlying(type);
|
||||
break;
|
||||
NOTREACHED() << "Received unexpected event: "
|
||||
<< base::to_underlying(type);
|
||||
}
|
||||
return "";
|
||||
}
|
||||
|
||||
std::string EventTypesToString(const EventFilterRecorder::Events& events) {
|
||||
|
@ -54,7 +54,7 @@ void WindowPositionInRootMonitor::OnWindowParentChanged(aura::Window* window,
|
||||
ancestors_.back()->RemoveObserver(this);
|
||||
ancestors_.pop_back();
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
void WindowPositionInRootMonitor::OnWindowBoundsChanged(
|
||||
|
@ -37,8 +37,7 @@ int GetChromeOSDeviceTypeResourceId() {
|
||||
return IDS_GENERIC_CHROMEOS_DEVICE_NAME;
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return IDS_GENERIC_CHROMEOS_DEVICE_NAME;
|
||||
NOTREACHED();
|
||||
#endif
|
||||
}
|
||||
|
||||
@ -63,8 +62,7 @@ int GetChromeOSDeviceTypeInPluralResourceId() {
|
||||
return IDS_GENERIC_CHROMEOS_DEVICE_NAME_IN_PLURAL;
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return IDS_GENERIC_CHROMEOS_DEVICE_NAME_IN_PLURAL;
|
||||
NOTREACHED();
|
||||
#endif
|
||||
}
|
||||
|
||||
|
@ -855,13 +855,13 @@ void Compositor::FrameSinksToThrottleUpdated(
|
||||
|
||||
void Compositor::OnFirstSurfaceActivation(
|
||||
const viz::SurfaceInfo& surface_info) {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
void Compositor::OnFrameTokenChanged(uint32_t frame_token,
|
||||
base::TimeTicks activation_time) {
|
||||
// TODO(yiyix, fsamuel): Implement frame token propagation for Compositor.
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
Compositor::TrackerState::TrackerState() = default;
|
||||
|
@ -789,8 +789,7 @@ LayerAnimationElement::ToAnimatableProperty(cc::TargetProperty::Type property) {
|
||||
case cc::TargetProperty::OPACITY:
|
||||
return OPACITY;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return AnimatableProperty();
|
||||
NOTREACHED();
|
||||
}
|
||||
}
|
||||
|
||||
@ -842,8 +841,7 @@ std::string LayerAnimationElement::AnimatablePropertiesToString(
|
||||
str.append("GRADIENT_MASK");
|
||||
break;
|
||||
case SENTINEL:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
}
|
||||
property_count++;
|
||||
}
|
||||
|
@ -21,8 +21,7 @@ std::string_view LayerTypeToString(LayerType type) {
|
||||
case LayerType::LAYER_NINE_PATCH:
|
||||
return "nine_patch";
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return {};
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
} // namespace ui
|
||||
|
@ -69,8 +69,7 @@ const char* ToRotationString(display::Display::Rotation rotation) {
|
||||
case display::Display::ROTATE_270:
|
||||
return "270";
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return "unknown";
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
} // namespace
|
||||
@ -138,8 +137,7 @@ display::Display::Rotation Display::DegreesToRotation(int degrees) {
|
||||
return display::Display::ROTATE_180;
|
||||
if (degrees == 270)
|
||||
return display::Display::ROTATE_270;
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return display::Display::ROTATE_0;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
// static
|
||||
@ -154,8 +152,7 @@ int Display::RotationToDegrees(display::Display::Rotation rotation) {
|
||||
case display::Display::ROTATE_270:
|
||||
return 270;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return 0;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
// static
|
||||
@ -199,8 +196,7 @@ int Display::RotationAsDegree() const {
|
||||
case ROTATE_270:
|
||||
return 270;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return 0;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
const gfx::DisplayColorSpaces& Display::GetColorSpaces() const {
|
||||
@ -227,7 +223,7 @@ void Display::SetRotationAsDegree(int rotation) {
|
||||
break;
|
||||
default:
|
||||
// We should not reach that but we will just ignore the call if we do.
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
NOTREACHED();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -38,8 +38,7 @@ gfx::OverlayTransform DisplayRotationToOverlayTransform(
|
||||
case display::Display::ROTATE_270:
|
||||
return gfx::OVERLAY_TRANSFORM_ROTATE_CLOCKWISE_270;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return gfx::OVERLAY_TRANSFORM_NONE;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
} // namespace display
|
||||
|
@ -104,8 +104,7 @@ mojom::ScreenOrientation DisplayUtil::GetOrientationTypeForMobile(
|
||||
return natural_portrait ? mojom::ScreenOrientation::kLandscapeSecondary
|
||||
: mojom::ScreenOrientation::kPortraitPrimary;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return mojom::ScreenOrientation::kPortraitPrimary;
|
||||
NOTREACHED();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -274,10 +274,8 @@ bool DisplayConfigurator::DisplayLayoutManagerImpl::GetDisplayLayout(
|
||||
|
||||
switch (new_display_state) {
|
||||
case MULTIPLE_DISPLAY_STATE_INVALID:
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "Ignoring request to enter invalid state with " << displays.size()
|
||||
<< " connected display(s)";
|
||||
return false;
|
||||
NOTREACHED() << "Ignoring request to enter invalid state with "
|
||||
<< displays.size() << " connected display(s)";
|
||||
case MULTIPLE_DISPLAY_STATE_HEADLESS:
|
||||
if (displays.size() != 0) {
|
||||
LOG(WARNING) << "Ignoring request to enter headless mode with "
|
||||
|
@ -76,13 +76,9 @@ void DisplayLayoutStore::RegisterLayoutForDisplayIdList(
|
||||
}
|
||||
|
||||
if (!DisplayLayout::Validate(list, *layout.get())) {
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "Attempting to register an invalid layout: ids="
|
||||
<< DisplayIdListToString(list) << ", layout=" << layout->ToString();
|
||||
// We never allow to register an invalid layout, instead, we revert back to
|
||||
// a default layout.
|
||||
CreateDefaultDisplayLayout(list);
|
||||
return;
|
||||
NOTREACHED() << "Attempting to register an invalid layout: ids="
|
||||
<< DisplayIdListToString(list)
|
||||
<< ", layout=" << layout->ToString();
|
||||
}
|
||||
|
||||
layouts_[list] = std::move(layout);
|
||||
|
@ -1627,8 +1627,7 @@ Display DisplayManager::GetMirroringDisplayForUnifiedDesktop(
|
||||
}
|
||||
}
|
||||
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return Display();
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
int DisplayManager::GetMirroringDisplayRowIndexInUnifiedMatrix(
|
||||
|
@ -112,8 +112,7 @@ std::string PanelOrientationToString(PanelOrientation orientation) {
|
||||
case kRightUp:
|
||||
return "RightUp";
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return "";
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
} // namespace
|
||||
|
@ -149,8 +149,7 @@ Builder::~Builder() = default;
|
||||
|
||||
std::unique_ptr<FakeDisplaySnapshot> Builder::Build() {
|
||||
if (modes_.empty() || id_ == kInvalidDisplayId) {
|
||||
NOTREACHED_IN_MIGRATION() << "Display modes or display ID missing";
|
||||
return nullptr;
|
||||
NOTREACHED() << "Display modes or display ID missing";
|
||||
}
|
||||
|
||||
const int64_t alternate_id = ProduceAlternativeSchemeIdForId(id_);
|
||||
|
@ -31,8 +31,7 @@ MultipleDisplayState TestDisplayLayoutManager::GetDisplayState() const {
|
||||
}
|
||||
|
||||
chromeos::DisplayPowerState TestDisplayLayoutManager::GetPowerState() const {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return chromeos::DISPLAY_POWER_ALL_ON;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
bool TestDisplayLayoutManager::GetDisplayLayout(
|
||||
@ -41,8 +40,7 @@ bool TestDisplayLayoutManager::GetDisplayLayout(
|
||||
chromeos::DisplayPowerState new_power_state,
|
||||
const base::flat_set<int64_t>& new_vrr_enabled_state,
|
||||
std::vector<DisplayConfigureRequest>* requests) const {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
std::vector<raw_ptr<DisplaySnapshot, VectorExperimental>>
|
||||
|
@ -220,8 +220,7 @@ void TestNativeDisplayDelegate::DoSetHDCPState(
|
||||
|
||||
switch (state) {
|
||||
case HDCP_STATE_ENABLED:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
|
||||
case HDCP_STATE_DESIRED:
|
||||
hdcp_state_ =
|
||||
|
@ -94,9 +94,7 @@ bool GetCalibratedTransform(
|
||||
// NOTE: If the determinant is zero then the inverse cannot be computed. The
|
||||
// only solution is to restart touch calibration and get new points from user.
|
||||
if (!product_matrix.GetInverse(&product_matrix_inverse)) {
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "Touch Calibration failed. Determinant is zero.";
|
||||
return false;
|
||||
NOTREACHED() << "Touch Calibration failed. Determinant is zero.";
|
||||
}
|
||||
|
||||
product_matrix_inverse.set_rc(3, 3, 0);
|
||||
|
@ -126,8 +126,7 @@ class TestDisplayLayoutManager : public DisplayLayoutManager {
|
||||
}
|
||||
|
||||
DisplayConfigurator::DisplayStateList GetDisplayStates() const override {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return DisplayConfigurator::DisplayStateList();
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
bool IsMirroring() const override {
|
||||
|
@ -113,8 +113,7 @@ std::string MultipleDisplayStateToString(MultipleDisplayState state) {
|
||||
case MULTIPLE_DISPLAY_STATE_MULTI_EXTENDED:
|
||||
return "MULTI_EXTENDED";
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION() << "Unknown state " << state;
|
||||
return "INVALID";
|
||||
NOTREACHED() << "Unknown state " << state;
|
||||
}
|
||||
|
||||
bool GetContentProtectionMethods(DisplayConnectionType type,
|
||||
@ -191,8 +190,7 @@ std::vector<float> GetDisplayZoomFactorForDsf(float dsf) {
|
||||
return std::vector<float>(bucket.second.begin(), bucket.second.end());
|
||||
}
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION() << "Received a DSF not on the list: " << dsf;
|
||||
return {1.f / dsf, 1.f};
|
||||
NOTREACHED() << "Received a DSF not on the list: " << dsf;
|
||||
}
|
||||
|
||||
ManagedDisplayInfo::ManagedDisplayModeList CreateInternalManagedDisplayModeList(
|
||||
|
@ -34,8 +34,7 @@ display::mojom::DisplayConnectionType EnumTraits<
|
||||
return display::mojom::DisplayConnectionType::
|
||||
DISPLAY_CONNECTION_TYPE_NETWORK;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return display::mojom::DisplayConnectionType::DISPLAY_CONNECTION_TYPE_NONE;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
bool EnumTraits<display::mojom::DisplayConnectionType,
|
||||
@ -86,8 +85,7 @@ EnumTraits<display::mojom::HDCPState, display::HDCPState>::ToMojom(
|
||||
case display::HDCPState::HDCP_STATE_ENABLED:
|
||||
return display::mojom::HDCPState::HDCP_STATE_ENABLED;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return display::mojom::HDCPState::HDCP_STATE_UNDESIRED;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
// static
|
||||
@ -126,9 +124,7 @@ display::mojom::ContentProtectionMethod EnumTraits<
|
||||
return display::mojom::ContentProtectionMethod::
|
||||
CONTENT_PROTECTION_METHOD_HDCP_TYPE_1;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return display::mojom::ContentProtectionMethod::
|
||||
CONTENT_PROTECTION_METHOD_NONE;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
// static
|
||||
@ -169,8 +165,7 @@ display::mojom::PanelOrientation EnumTraits<
|
||||
case display::PanelOrientation::kRightUp:
|
||||
return display::mojom::PanelOrientation::RIGHT_UP;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return display::mojom::PanelOrientation::NORMAL;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
// static
|
||||
@ -210,8 +205,7 @@ display::mojom::PrivacyScreenState EnumTraits<
|
||||
case display::PrivacyScreenState::kNotSupported:
|
||||
return display::mojom::PrivacyScreenState::NOT_SUPPORTED;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return display::mojom::PrivacyScreenState::NOT_SUPPORTED;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
// static
|
||||
@ -252,8 +246,7 @@ EnumTraits<display::mojom::VariableRefreshRateState,
|
||||
case display::VariableRefreshRateState::kVrrNotCapable:
|
||||
return display::mojom::VariableRefreshRateState::kVrrNotCapable;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return display::mojom::VariableRefreshRateState::kVrrNotCapable;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
// static
|
||||
|
@ -19,8 +19,7 @@ EnumTraits<display::mojom::Position, display::DisplayPlacement::Position>::
|
||||
case display::DisplayPlacement::LEFT:
|
||||
return display::mojom::Position::LEFT;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return display::mojom::Position::TOP;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
bool EnumTraits<display::mojom::Position, display::DisplayPlacement::Position>::
|
||||
@ -53,8 +52,7 @@ EnumTraits<display::mojom::OffsetReference,
|
||||
case display::DisplayPlacement::BOTTOM_RIGHT:
|
||||
return display::mojom::OffsetReference::BOTTOM_RIGHT;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return display::mojom::OffsetReference::TOP_LEFT;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
bool EnumTraits<display::mojom::OffsetReference,
|
||||
|
@ -19,8 +19,7 @@ EnumTraits<display::mojom::Rotation, display::Display::Rotation>::ToMojom(
|
||||
case display::Display::ROTATE_270:
|
||||
return display::mojom::Rotation::VALUE_270;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return display::mojom::Rotation::VALUE_0;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
bool EnumTraits<display::mojom::Rotation, display::Display::Rotation>::
|
||||
@ -40,8 +39,7 @@ bool EnumTraits<display::mojom::Rotation, display::Display::Rotation>::
|
||||
*out = display::Display::ROTATE_270;
|
||||
return true;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
display::mojom::TouchSupport
|
||||
@ -55,8 +53,7 @@ EnumTraits<display::mojom::TouchSupport, display::Display::TouchSupport>::
|
||||
case display::Display::TouchSupport::UNAVAILABLE:
|
||||
return display::mojom::TouchSupport::UNAVAILABLE;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return display::mojom::TouchSupport::UNKNOWN;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
bool EnumTraits<display::mojom::TouchSupport, display::Display::TouchSupport>::
|
||||
@ -73,8 +70,7 @@ bool EnumTraits<display::mojom::TouchSupport, display::Display::TouchSupport>::
|
||||
*out = display::Display::TouchSupport::UNAVAILABLE;
|
||||
return true;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
display::mojom::AccelerometerSupport
|
||||
@ -89,8 +85,7 @@ EnumTraits<display::mojom::AccelerometerSupport,
|
||||
case display::Display::AccelerometerSupport::UNAVAILABLE:
|
||||
return display::mojom::AccelerometerSupport::UNAVAILABLE;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return display::mojom::AccelerometerSupport::UNKNOWN;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
bool EnumTraits<display::mojom::AccelerometerSupport,
|
||||
@ -108,8 +103,7 @@ bool EnumTraits<display::mojom::AccelerometerSupport,
|
||||
*out = display::Display::AccelerometerSupport::UNAVAILABLE;
|
||||
return true;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
bool StructTraits<display::mojom::DisplayDataView, display::Display>::Read(
|
||||
|
@ -30,8 +30,7 @@ static uint64_t GetModeIndex(
|
||||
modes[i].get()->refresh_rate() == mode->refresh_rate())
|
||||
return i;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return std::numeric_limits<uint64_t>::max();
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
} // namespace
|
||||
|
@ -13,11 +13,9 @@ gfx::NativeWindow Screen::GetWindowForView(gfx::NativeView view) {
|
||||
// Android cannot use this method to convert |NativeView| to |NativeWindow|
|
||||
// since it causes cyclic dependency. |GetDisplayNearestView| should be
|
||||
// overriden directly.
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "Wrong screen instance is used. Make sure to use the correct "
|
||||
"Screen instance that has proper implementation of "
|
||||
"|GetDisplayNearestView| for Android.";
|
||||
return nullptr;
|
||||
NOTREACHED() << "Wrong screen instance is used. Make sure to use the correct "
|
||||
"Screen instance that has proper implementation of "
|
||||
"|GetDisplayNearestView| for Android.";
|
||||
}
|
||||
|
||||
} // namespace display
|
||||
|
@ -24,8 +24,7 @@ const char* ToOrientationString(mojom::ScreenOrientation orientation_type) {
|
||||
case mojom::ScreenOrientation::kLandscapeSecondary:
|
||||
return "LandscapeSecondary";
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return "unknown";
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
} // namespace
|
||||
|
@ -58,8 +58,7 @@ float EvaluateLut(float x,
|
||||
lut_j1 = lut[j1].b;
|
||||
break;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
return (alpha * lut_j0 + one_minus_alpha * lut_j1) / 65535.f;
|
||||
|
@ -27,8 +27,7 @@ std::string DisplayConnectionTypeString(DisplayConnectionType type) {
|
||||
case DISPLAY_CONNECTION_TYPE_NETWORK:
|
||||
return "network";
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return std::string();
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
} // namespace display
|
||||
|
@ -135,9 +135,7 @@ DisplayPlacement::Position CalculateDisplayPosition(
|
||||
? DisplayPlacement::Position::TOP
|
||||
: DisplayPlacement::Position::BOTTOM;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "CalculateDisplayPosition relies on touching DisplayInfos.";
|
||||
return DisplayPlacement::Position::RIGHT;
|
||||
NOTREACHED() << "CalculateDisplayPosition relies on touching DisplayInfos.";
|
||||
}
|
||||
|
||||
DisplayPlacement CalculateDisplayPlacement(
|
||||
|
@ -150,8 +150,7 @@ Display::Rotation OrientationToRotation(DWORD orientation) {
|
||||
case DMDO_270:
|
||||
return Display::ROTATE_270;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return Display::ROTATE_0;
|
||||
NOTREACHED();
|
||||
}
|
||||
}
|
||||
|
||||
@ -792,24 +791,20 @@ void ScreenWin::UpdateDisplayInfosIfNeeded() {
|
||||
}
|
||||
|
||||
HWND ScreenWin::GetHWNDFromNativeWindow(gfx::NativeWindow window) const {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return nullptr;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
gfx::NativeWindow ScreenWin::GetNativeWindowFromHWND(HWND hwnd) const {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return nullptr;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
bool ScreenWin::IsNativeWindowOccluded(gfx::NativeWindow window) const {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
std::optional<bool> ScreenWin::IsWindowOnCurrentVirtualDesktop(
|
||||
gfx::NativeWindow window) const {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return std::nullopt;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
ScreenWin::ScreenWin(bool initialize_from_system)
|
||||
|
@ -56,10 +56,8 @@ MotionEventAndroid::Action FromAndroidAction(int android_action) {
|
||||
ACTION_CASE(BUTTON_PRESS);
|
||||
ACTION_CASE(BUTTON_RELEASE);
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "Invalid Android MotionEvent action: " << android_action;
|
||||
NOTREACHED() << "Invalid Android MotionEvent action: " << android_action;
|
||||
}
|
||||
return MotionEventAndroid::Action::CANCEL;
|
||||
}
|
||||
|
||||
int ToAndroidAction(MotionEventAndroid::Action action) {
|
||||
@ -76,9 +74,8 @@ int ToAndroidAction(MotionEventAndroid::Action action) {
|
||||
ACTION_REVERSE_CASE(BUTTON_PRESS);
|
||||
ACTION_REVERSE_CASE(BUTTON_RELEASE);
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION() << "Invalid MotionEvent action: " << action;
|
||||
NOTREACHED() << "Invalid MotionEvent action: " << action;
|
||||
}
|
||||
return JNI_MotionEvent::ACTION_CANCEL;
|
||||
}
|
||||
|
||||
int ToAndroidToolType(MotionEventAndroid::ToolType tool_type) {
|
||||
@ -89,10 +86,8 @@ int ToAndroidToolType(MotionEventAndroid::ToolType tool_type) {
|
||||
TOOL_TYPE_REVERSE_CASE(MOUSE);
|
||||
TOOL_TYPE_REVERSE_CASE(ERASER);
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "Invalid MotionEvent tool type: " << tool_type;
|
||||
NOTREACHED() << "Invalid MotionEvent tool type: " << tool_type;
|
||||
}
|
||||
return JNI_MotionEvent::TOOL_TYPE_UNKNOWN;
|
||||
}
|
||||
|
||||
#undef ACTION_CASE
|
||||
@ -380,10 +375,9 @@ MotionEventAndroid::ToolType MotionEventAndroid::FromAndroidToolType(
|
||||
TOOL_TYPE_CASE(MOUSE);
|
||||
TOOL_TYPE_CASE(ERASER);
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "Invalid Android MotionEvent tool type: " << android_tool_type;
|
||||
NOTREACHED() << "Invalid Android MotionEvent tool type: "
|
||||
<< android_tool_type;
|
||||
}
|
||||
return MotionEventAndroid::ToolType::UNKNOWN;
|
||||
}
|
||||
|
||||
#undef TOOL_TYPE_CASE
|
||||
|
@ -581,8 +581,7 @@ void RecordSearchPlusDigitFKeyRewrite(ui::EventType event_type,
|
||||
base::RecordAction(base::UserMetricsAction("SearchPlusDigitRewrite_F12"));
|
||||
break;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
}
|
||||
}
|
||||
|
||||
@ -629,8 +628,7 @@ void RecordSixPackEventRewrites(EventRewriterAsh::Delegate* delegate,
|
||||
base::UserMetricsAction("SearchBasedKeyRewrite_PageDown"));
|
||||
break;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
}
|
||||
} else {
|
||||
switch (key_code) {
|
||||
@ -657,8 +655,7 @@ void RecordSixPackEventRewrites(EventRewriterAsh::Delegate* delegate,
|
||||
base::UserMetricsAction("AltBasedKeyRewrite_PageDown"));
|
||||
break;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -730,8 +727,7 @@ void RecordFunctionKeyFromKeyCode(ui::KeyboardCode key_code,
|
||||
event_enum);
|
||||
break;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -70,8 +70,7 @@ WebInputEvent::Type ToWebTouchEventType(MotionEvent::Action action) {
|
||||
case MotionEvent::Action::BUTTON_RELEASE:
|
||||
break;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION() << "Invalid MotionEvent::Action = " << action;
|
||||
return WebInputEvent::Type::kUndefined;
|
||||
NOTREACHED() << "Invalid MotionEvent::Action = " << action;
|
||||
}
|
||||
|
||||
// Note that the action index is meaningful only in the context of
|
||||
@ -104,8 +103,7 @@ WebTouchPoint::State ToWebTouchPointState(const MotionEvent& event,
|
||||
case MotionEvent::Action::BUTTON_RELEASE:
|
||||
break;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION() << "Invalid MotionEvent::Action.";
|
||||
return WebTouchPoint::State::kStateUndefined;
|
||||
NOTREACHED() << "Invalid MotionEvent::Action.";
|
||||
}
|
||||
|
||||
WebPointerProperties::PointerType ToWebPointerType(
|
||||
@ -122,8 +120,7 @@ WebPointerProperties::PointerType ToWebPointerType(
|
||||
case MotionEvent::ToolType::ERASER:
|
||||
return WebPointerProperties::PointerType::kEraser;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION() << "Invalid MotionEvent::ToolType = " << tool_type;
|
||||
return WebPointerProperties::PointerType::kUnknown;
|
||||
NOTREACHED() << "Invalid MotionEvent::ToolType = " << tool_type;
|
||||
}
|
||||
|
||||
WebPointerProperties::PointerType ToWebPointerType(
|
||||
@ -140,9 +137,8 @@ WebPointerProperties::PointerType ToWebPointerType(
|
||||
case EventPointerType::kEraser:
|
||||
return WebPointerProperties::PointerType::kEraser;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION() << "Invalid EventPointerType = "
|
||||
<< static_cast<int>(event_pointer_type);
|
||||
return WebPointerProperties::PointerType::kUnknown;
|
||||
NOTREACHED() << "Invalid EventPointerType = "
|
||||
<< static_cast<int>(event_pointer_type);
|
||||
}
|
||||
}
|
||||
|
||||
@ -319,8 +315,7 @@ WebGestureEvent CreateWebGestureEvent(const GestureEventDetails& details,
|
||||
source_device = WebGestureDevice::kTouchpad;
|
||||
break;
|
||||
case GestureDeviceType::DEVICE_UNKNOWN:
|
||||
NOTREACHED_IN_MIGRATION() << "Unknown device type is not allowed";
|
||||
break;
|
||||
NOTREACHED() << "Unknown device type is not allowed";
|
||||
}
|
||||
WebGestureEvent gesture(WebInputEvent::Type::kUndefined,
|
||||
EventFlagsToWebEventModifiers(flags), timestamp,
|
||||
@ -472,9 +467,8 @@ WebGestureEvent CreateWebGestureEvent(const GestureEventDetails& details,
|
||||
gesture.SetType(WebInputEvent::Type::kUndefined);
|
||||
break;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "EventType provided wasn't a valid gesture event: "
|
||||
<< base::to_underlying(details.type());
|
||||
NOTREACHED() << "EventType provided wasn't a valid gesture event: "
|
||||
<< base::to_underlying(details.type());
|
||||
}
|
||||
|
||||
return gesture;
|
||||
@ -769,8 +763,7 @@ EventPointerType WebPointerTypeToEventPointerType(
|
||||
case WebPointerProperties::PointerType::kUnknown:
|
||||
return EventPointerType::kUnknown;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION() << "Invalid pointer type";
|
||||
return EventPointerType::kUnknown;
|
||||
NOTREACHED() << "Invalid pointer type";
|
||||
}
|
||||
|
||||
blink::WebGestureEvent ScrollBeginFromScrollUpdate(
|
||||
@ -829,8 +822,7 @@ std::unique_ptr<WebGestureEvent> CreateWebGestureEventFromGestureEventAndroid(
|
||||
event_type = WebInputEvent::Type::kGestureDoubleTap;
|
||||
break;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION() << "Unknown gesture event type";
|
||||
return std::make_unique<WebGestureEvent>();
|
||||
NOTREACHED() << "Unknown gesture event type";
|
||||
}
|
||||
auto web_event = std::make_unique<WebGestureEvent>(
|
||||
event_type, WebInputEvent::kNoModifiers,
|
||||
|
@ -73,7 +73,7 @@ blink::WebKeyboardEvent MakeWebKeyboardEventFromUiEvent(const KeyEvent& event) {
|
||||
type = blink::WebInputEvent::Type::kKeyUp;
|
||||
break;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
blink::WebKeyboardEvent webkit_event(
|
||||
@ -134,7 +134,7 @@ blink::WebMouseWheelEvent MakeWebMouseWheelEventFromUiEvent(
|
||||
webkit_event.phase = blink::WebMouseWheelEvent::kPhaseEnded;
|
||||
break;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
switch (event.momentum_phase()) {
|
||||
@ -157,7 +157,7 @@ blink::WebMouseWheelEvent MakeWebMouseWheelEventFromUiEvent(
|
||||
webkit_event.momentum_phase = blink::WebMouseWheelEvent::kPhaseBlocked;
|
||||
break;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
return webkit_event;
|
||||
@ -174,12 +174,11 @@ blink::WebGestureEvent MakeWebGestureEventFromUiEvent(
|
||||
type = blink::WebInputEvent::Type::kGestureFlingCancel;
|
||||
break;
|
||||
case EventType::kScroll:
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "Invalid gesture type: " << base::to_underlying(event.type());
|
||||
break;
|
||||
NOTREACHED() << "Invalid gesture type: "
|
||||
<< base::to_underlying(event.type());
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "Unknown gesture type: " << base::to_underlying(event.type());
|
||||
NOTREACHED() << "Unknown gesture type: "
|
||||
<< base::to_underlying(event.type());
|
||||
}
|
||||
|
||||
blink::WebGestureEvent webkit_event(
|
||||
|
@ -121,7 +121,7 @@ WebMouseEvent WebMouseEventBuilder::Build(
|
||||
button = WebMouseEvent::Button::kForward;
|
||||
break;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
// set modifiers:
|
||||
|
@ -1174,9 +1174,8 @@ ScrollEvent::ScrollEvent(const PlatformEvent& native_event)
|
||||
GetFlingData(native_event, &x_offset_, &y_offset_, &x_offset_ordinal_,
|
||||
&y_offset_ordinal_, nullptr);
|
||||
} else {
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "Unexpected event type " << base::to_underlying(type())
|
||||
<< " when constructing a ScrollEvent.";
|
||||
NOTREACHED() << "Unexpected event type " << base::to_underlying(type())
|
||||
<< " when constructing a ScrollEvent.";
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -93,7 +93,7 @@ class TestEventHandler : public EventHandler {
|
||||
EXPECT_TRUE(expect_pre_target_);
|
||||
received_pre_target_ = true;
|
||||
} else {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
NOTREACHED();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -71,8 +71,7 @@ EventDispatchDetails EventRewriter::RewriteEvent(
|
||||
EventRewriteStatus EventRewriter::RewriteEvent(
|
||||
const Event& event,
|
||||
std::unique_ptr<Event>* rewritten_event) {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return EVENT_REWRITE_DISCARD;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
bool EventRewriter::SupportsNonRootLocation() const {
|
||||
@ -85,8 +84,7 @@ bool EventRewriter::SupportsNonRootLocation() const {
|
||||
EventRewriteStatus EventRewriter::NextDispatchEvent(
|
||||
const Event& last_event,
|
||||
std::unique_ptr<Event>* new_event) {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return EVENT_REWRITE_DISCARD;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
// TODO(kpschoedel): Remove old API.
|
||||
|
@ -73,8 +73,7 @@ std::unique_ptr<Event> CreateEventForType(EventType type) {
|
||||
return std::make_unique<ScrollEvent>(
|
||||
type, gfx::Point(), base::TimeTicks::Now(), 0, 0, 0, 0, 0, 0);
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION() << base::to_underlying(type);
|
||||
return nullptr;
|
||||
NOTREACHED() << base::to_underlying(type);
|
||||
}
|
||||
}
|
||||
|
||||
@ -113,8 +112,7 @@ class TestConstantEventRewriterOld : public EventRewriter {
|
||||
EventRewriteStatus NextDispatchEvent(
|
||||
const Event& last_event,
|
||||
std::unique_ptr<Event>* new_event) override {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return status_;
|
||||
NOTREACHED();
|
||||
}
|
||||
bool SupportsNonRootLocation() const override { return true; }
|
||||
|
||||
@ -242,7 +240,7 @@ class TestStateMachineEventRewriter : public EventRewriter {
|
||||
if (details.dispatcher_destroyed || find->second.state_action == RETURN)
|
||||
return details;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
private:
|
||||
|
@ -21,8 +21,7 @@ void EventTarget::ConvertEventToTarget(const EventTarget* target,
|
||||
|
||||
gfx::PointF EventTarget::GetScreenLocationF(
|
||||
const ui::LocatedEvent& event) const {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return event.root_location_f();
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
gfx::Point EventTarget::GetScreenLocation(const ui::LocatedEvent& event) const {
|
||||
|
@ -291,14 +291,12 @@ std::string_view EventTypeName(EventType type) {
|
||||
CASE_TYPE(EventType::kCancelMode);
|
||||
CASE_TYPE(EventType::kUmaData);
|
||||
case EventType::kLast:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return "";
|
||||
NOTREACHED();
|
||||
// Don't include default, so that we get an error when new type is added.
|
||||
}
|
||||
#undef CASE_TYPE
|
||||
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return "";
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
std::vector<std::string_view> EventFlagsNames(int event_flags) {
|
||||
|
@ -499,7 +499,7 @@ TEST_F(PointerEventsHandlerTest, MouseWheelEventWithButtonPressed) {
|
||||
auto e = event->AsMouseEvent()->Clone();
|
||||
mouse_events.push_back(std::move(e));
|
||||
} else {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
NOTREACHED();
|
||||
}
|
||||
}));
|
||||
RunLoopUntilIdle(); // Server gets watch call.
|
||||
@ -537,7 +537,7 @@ TEST_F(PointerEventsHandlerTest, MouseWheelEventWithButtonDownBundled) {
|
||||
auto e = event->AsMouseEvent()->Clone();
|
||||
mouse_events.push_back(std::move(e));
|
||||
} else {
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
NOTREACHED();
|
||||
}
|
||||
}));
|
||||
RunLoopUntilIdle(); // Server gets watch call.
|
||||
|
@ -148,8 +148,7 @@ bool GestureDetector::OnTouchEvent(const MotionEvent& ev,
|
||||
case MotionEvent::Action::HOVER_MOVE:
|
||||
case MotionEvent::Action::BUTTON_PRESS:
|
||||
case MotionEvent::Action::BUTTON_RELEASE:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return handled;
|
||||
NOTREACHED();
|
||||
|
||||
case MotionEvent::Action::POINTER_DOWN: {
|
||||
down_focus_x_ = last_focus_x_ = focus_x;
|
||||
|
@ -26,8 +26,7 @@ EventPointerType ToEventPointerType(MotionEvent::ToolType tool_type) {
|
||||
case MotionEvent::ToolType::ERASER:
|
||||
return EventPointerType::kEraser;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION() << "Invalid ToolType = " << tool_type;
|
||||
return EventPointerType::kUnknown;
|
||||
NOTREACHED() << "Invalid ToolType = " << tool_type;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -32,11 +32,9 @@ GestureEventDataPacket::GestureSource ToGestureSource(
|
||||
case ui::MotionEvent::Action::HOVER_MOVE:
|
||||
case ui::MotionEvent::Action::BUTTON_PRESS:
|
||||
case ui::MotionEvent::Action::BUTTON_RELEASE:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return GestureEventDataPacket::INVALID;
|
||||
NOTREACHED();
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return GestureEventDataPacket::INVALID;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
} // namespace
|
||||
|
@ -977,8 +977,7 @@ void GestureProvider::OnTouchEventHandlingBegin(const MotionEvent& event) {
|
||||
case MotionEvent::Action::HOVER_MOVE:
|
||||
case MotionEvent::Action::BUTTON_PRESS:
|
||||
case MotionEvent::Action::BUTTON_RELEASE:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
}
|
||||
}
|
||||
|
||||
@ -1028,8 +1027,7 @@ void GestureProvider::OnTouchEventHandlingEnd(const MotionEvent& event) {
|
||||
case MotionEvent::Action::HOVER_MOVE:
|
||||
case MotionEvent::Action::BUTTON_PRESS:
|
||||
case MotionEvent::Action::BUTTON_RELEASE:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -96,8 +96,7 @@ UMAEventType GestureTouchUMAHistogram::UMAEventTypeFromEvent(
|
||||
return UMA_ET_GESTURE_DOUBLE_TAP;
|
||||
if (tap_count == 3)
|
||||
return UMA_ET_GESTURE_TRIPLE_TAP;
|
||||
NOTREACHED_IN_MIGRATION() << "Received tap with tapcount " << tap_count;
|
||||
return UMA_ET_UNKNOWN;
|
||||
NOTREACHED() << "Received tap with tapcount " << tap_count;
|
||||
}
|
||||
case EventType::kGestureTapDown:
|
||||
return UMA_ET_GESTURE_TAP_DOWN;
|
||||
@ -150,8 +149,7 @@ UMAEventType GestureTouchUMAHistogram::UMAEventTypeFromEvent(
|
||||
case EventType::kGestureDoubleTap:
|
||||
return UMA_ET_GESTURE_DOUBLE_TAP;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return UMA_ET_UNKNOWN;
|
||||
NOTREACHED();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -125,8 +125,7 @@ DispositionHandlingInfo GetDispositionHandlingInfo(EventType type) {
|
||||
default:
|
||||
break;
|
||||
}
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return Info(RT_NONE);
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
int GetGestureTypeIndex(EventType type) {
|
||||
|
@ -65,8 +65,8 @@ GestureEventDetails::GestureEventDetails(ui::EventType type,
|
||||
break;
|
||||
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION() << "Invalid event type for constructor: "
|
||||
<< base::to_underlying(type);
|
||||
NOTREACHED() << "Invalid event type for constructor: "
|
||||
<< base::to_underlying(type);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -113,8 +113,7 @@ bool MotionEventAura::OnTouch(const TouchEvent& touch) {
|
||||
UpdateTouch(touch);
|
||||
break;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return false;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
UpdateCachedAction(touch);
|
||||
@ -182,8 +181,7 @@ void MotionEventAura::UpdateCachedAction(const TouchEvent& touch) {
|
||||
set_action(Action::MOVE);
|
||||
break;
|
||||
default:
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
break;
|
||||
NOTREACHED();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -191,8 +191,7 @@ DomKey TestDomKeyboardLayoutMap::GetDomKeyFromDomCodeForLayout(
|
||||
if (test_layout_id == kKeyboardLayoutWithNoValidKeys)
|
||||
return GetDomKeyForLayoutWithNoValidKeys();
|
||||
|
||||
NOTREACHED_IN_MIGRATION();
|
||||
return DomKey::NONE;
|
||||
NOTREACHED();
|
||||
}
|
||||
|
||||
void TestDomKeyboardLayoutMap::AddKeyboardLayout(uint32_t test_layout_id) {
|
||||
|
@ -411,10 +411,8 @@ bool MobileScroller::ComputeScrollOffsetInternal(base::TimeTicks time) {
|
||||
const float u = time_passed.InSecondsF() * duration_seconds_reciprocal_;
|
||||
switch (mode_) {
|
||||
case UNDEFINED:
|
||||
NOTREACHED_IN_MIGRATION()
|
||||
<< "|StartScroll()| or |Fling()| must be called prior to "
|
||||
"scroll offset computation.";
|
||||
return false;
|
||||
NOTREACHED() << "|StartScroll()| or |Fling()| must be called prior to "
|
||||
"scroll offset computation.";
|
||||
|
||||
case SCROLL_MODE: {
|
||||
float x = g_viscosity_constants.Get().ApplyViscosity(u);
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user