#include "ui/views/controls/button/menu_button_controller.h"
#include <utility>
#include "base/functional/bind.h"
#include "ui/accessibility/ax_enums.mojom.h"
#include "ui/accessibility/ax_node_data.h"
#include "ui/base/dragdrop/drag_drop_types.h"
#include "ui/base/interaction/element_identifier.h"
#include "ui/events/event_constants.h"
#include "ui/events/types/event_type.h"
#include "ui/views/accessibility/view_accessibility.h"
#include "ui/views/animation/ink_drop.h"
#include "ui/views/controls/button/button.h"
#include "ui/views/controls/button/button_controller_delegate.h"
#include "ui/views/controls/button/menu_button.h"
#include "ui/views/interaction/element_tracker_views.h"
#include "ui/views/mouse_constants.h"
#include "ui/views/style/platform_style.h"
#include "ui/views/view_class_properties.h"
#include "ui/views/widget/root_view.h"
#include "ui/views/widget/widget.h"
TimeTicks;
namespace views {
namespace {
ui::EventType NotifyActionToMouseEventType(
ButtonController::NotifyAction notify_action) { … }
}
MenuButtonController::PressedLock::PressedLock(
MenuButtonController* menu_button_controller)
: … { … }
MenuButtonController::PressedLock::PressedLock(
MenuButtonController* menu_button_controller,
bool is_sibling_menu_show,
const ui::LocatedEvent* event)
: … { … }
std::unique_ptr<MenuButtonController::PressedLock>
MenuButtonController::TakeLock() { … }
std::unique_ptr<MenuButtonController::PressedLock>
MenuButtonController::TakeLock(bool is_sibling_menu_show,
const ui::LocatedEvent* event) { … }
MenuButtonController::PressedLock::~PressedLock() { … }
MenuButtonController::MenuButtonController(
Button* button,
Button::PressedCallback callback,
std::unique_ptr<ButtonControllerDelegate> delegate)
: … { … }
MenuButtonController::~MenuButtonController() = default;
bool MenuButtonController::OnMousePressed(const ui::MouseEvent& event) { … }
void MenuButtonController::OnMouseReleased(const ui::MouseEvent& event) { … }
void MenuButtonController::OnMouseMoved(const ui::MouseEvent& event) { … }
void MenuButtonController::OnMouseEntered(const ui::MouseEvent& event) { … }
void MenuButtonController::OnMouseExited(const ui::MouseEvent& event) { … }
bool MenuButtonController::OnKeyPressed(const ui::KeyEvent& event) { … }
bool MenuButtonController::OnKeyReleased(const ui::KeyEvent& event) { … }
void MenuButtonController::UpdateButtonAccessibleDefaultActionVerb() { … }
bool MenuButtonController::IsTriggerableEvent(const ui::Event& event) { … }
void MenuButtonController::OnGestureEvent(ui::GestureEvent* event) { … }
bool MenuButtonController::Activate(const ui::Event* event) { … }
bool MenuButtonController::IsTriggerableEventType(const ui::Event& event) { … }
void MenuButtonController::NotifyClick() { … }
void MenuButtonController::IncrementPressedLocked(
bool snap_ink_drop_to_activated,
const ui::LocatedEvent* event) { … }
void MenuButtonController::DecrementPressedLocked() { … }
void MenuButtonController::OnButtonStateChangedWhilePressedLocked() { … }
}