summaryrefslogtreecommitdiff
path: root/chromium/ui/keyboard/keyboard.mojom
blob: 5850df46a459c1551adb9162f50a719c8e3589d6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
// Copyright 2016 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 keyboard.mojom;

import "ui/gfx/geometry/mojo/geometry.mojom";

interface KeyboardObserver {
  // Sent any time state changes in the keyboard.
  OnKeyboardStateChanged(bool is_enabled,
                         bool is_visible,
                         uint64 display_id,
                         gfx.mojom.Rect bounds);
};

interface Keyboard {
  // TODO(sky): needs display id.
  Show();
  Hide();

  // Adds an observer. OnKeyboardStateChanged() is immediately called to give
  // the initial state.
  AddObserver(KeyboardObserver observer);
};