Commit b0fbc842 authored by Jun Mukai's avatar Jun Mukai Committed by Commit Bot

Remove event_properties.mojom

TBR=tsepez@chromium.org

Bug: 958198
Test: trybot
Change-Id: If8f75baae9b1a9677c53bfb8d7620def30fb100f
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1613699Reviewed-by: default avatarJun Mukai <mukai@chromium.org>
Reviewed-by: default avatarScott Violet <sky@chromium.org>
Commit-Queue: Jun Mukai <mukai@chromium.org>
Cr-Commit-Position: refs/heads/master@{#660538}
parent 3b61d694
......@@ -28,7 +28,6 @@ mojom("interfaces_internal") {
"assistant_volume_control.mojom",
"constants.mojom",
"cros_display_config.mojom",
"event_properties.mojom",
"event_rewriter_controller.mojom",
"first_run_helper.mojom",
"highlighter_controller.mojom",
......
// Copyright 2017 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
module ash.mojom;
// This is added to KeyEvents that ash has an accelerator for. This is only used
// for accelerators ash does not handle immediately. That is, those the target
// is given priority to process.
// No value is set for this property, the presence indicates ash has an
// accelerator.
const string kWillProcessAccelerator_KeyEventProperty =
"ash:will-process-accelerator";
......@@ -5,26 +5,16 @@
#include "chrome/browser/ui/ash/ash_util.h"
#include "ash/public/cpp/shell_window_ids.h"
#include "ash/public/interfaces/event_properties.mojom.h"
#include "ash/shell.h"
#include "base/macros.h"
#include "components/session_manager/core/session_manager.h"
#include "content/public/common/service_manager_connection.h"
#include "ui/aura/window_event_dispatcher.h"
#include "ui/display/display.h"
#include "ui/display/screen.h"
#include "ui/views/widget/widget.h"
#include "ui/wm/core/shadow_types.h"
#include "ui/wm/core/window_animations.h"
namespace ash_util {
bool WillAshProcessAcceleratorForEvent(const ui::KeyEvent& key_event) {
return key_event.properties() &&
key_event.properties()->count(
ash::mojom::kWillProcessAccelerator_KeyEventProperty);
}
void SetupWidgetInitParamsForContainer(views::Widget::InitParams* params,
int container_id) {
DCHECK_GE(container_id, ash::kShellWindowId_MinContainer);
......
......@@ -17,15 +17,8 @@ namespace service_manager {
class Connector;
}
namespace ui {
class KeyEvent;
} // namespace ui
namespace ash_util {
// Returns true if ash has an accelerator for |key_event| that is enabled.
bool WillAshProcessAcceleratorForEvent(const ui::KeyEvent& key_event);
// Sets up |params| to place the widget in an ash shell window container on
// the primary display. See ash/public/cpp/shell_window_ids.h for |container_id|
// values.
......
......@@ -173,7 +173,6 @@
#if defined(OS_CHROMEOS)
#include "ash/public/cpp/accelerators.h"
#include "chrome/browser/ui/ash/ash_util.h"
#include "chrome/browser/ui/ash/window_properties.h"
#include "chrome/browser/ui/views/frame/top_controls_slide_controller_chromeos.h"
#include "chrome/grit/chrome_unscaled_resources.h"
......@@ -1636,14 +1635,6 @@ content::KeyboardEventProcessingResult BrowserView::PreHandleKeyboardEvent(
if (result != content::KeyboardEventProcessingResult::NOT_HANDLED)
return result;
#if defined(OS_CHROMEOS)
if (event.os_event && event.os_event->IsKeyEvent() &&
ash_util::WillAshProcessAcceleratorForEvent(
*event.os_event->AsKeyEvent())) {
return content::KeyboardEventProcessingResult::HANDLED_DONT_UPDATE_EVENT;
}
#endif
int id;
if (!FindCommandIdForAccelerator(accelerator, &id)) {
// |accelerator| is not a browser command, it may be handled by ash (e.g.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment