mirror of
https://github.com/klzgrad/naiveproxy.git
synced 2024-12-01 01:36:09 +03:00
42 lines
1.6 KiB
Plaintext
42 lines
1.6 KiB
Plaintext
// Copyright 2018 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;
|
|
|
|
import "ui/gfx/geometry/mojo/geometry.mojom";
|
|
|
|
enum FocusRingBehavior { FADE_OUT_FOCUS_RING, PERSIST_FOCUS_RING };
|
|
|
|
// Interface for ash client (e.g. Chrome) to control and query accessibility
|
|
// focus ring features.
|
|
interface AccessibilityFocusRingController {
|
|
// Sets the focus ring color for the given caller.
|
|
SetFocusRingColor(uint32 skcolor, string caller_id);
|
|
|
|
// Resets the focus ring color back to the default for the given caller.
|
|
ResetFocusRingColor(string caller_id);
|
|
|
|
// Draws a focus ring around the given set of rects in screen coordinates. Use
|
|
// |focus_ring_behavior| to specify whether the focus ring should persist or
|
|
// fade out for the given caller.
|
|
SetFocusRing(array<gfx.mojom.Rect> rects_in_screen,
|
|
FocusRingBehavior focus_ring_behavior,
|
|
string caller_id);
|
|
|
|
// Hides focus ring on screen for the given caller.
|
|
HideFocusRing(string caller_id);
|
|
|
|
// Draws a highlight at the given rects in screen coordinates. Rects may be
|
|
// overlapping and will be merged into one layer. This looks similar to
|
|
// selecting a region with the cursor, except it is drawn in the foreground
|
|
// rather than behind a text layer.
|
|
// TODO(katie): Add |caller_id| to highlights as well if other Accessibility
|
|
// tools or extensions want to use this API.
|
|
SetHighlights(array<gfx.mojom.Rect> rects_in_screen, uint32 skcolor);
|
|
|
|
// Hides highlight on screen.
|
|
// TODO(katie): Add |caller_id| to highlights as well.
|
|
HideHighlights();
|
|
};
|